Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ We provide eighteen code samples to help developers understand how to write Encl

* `file` sample shows how to read/write files in SGX enclave.

* `hello-rust` is the helloworld sample writtin in pure Rust.
* `hello-rust` is the helloworld sample written, writing in pure Rust.

* `backtrace` is a sample showing how to enabling backtrace mechanism inside the enclave.

Expand Down
8 changes: 4 additions & 4 deletions release_notes.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ soon as possible!

**Supports Rust stable-2019-05-14** in stable branch (rustc 1.34.2)

* Bug fix in sgx_alloc. Correct the MIN_ALIGN to 8 bytes according to Intel's memory alloctor.
* Bug fix in sgx_alloc. Correct the MIN_ALIGN to 8 bytes according to Intel's memory allocator.

* Bug fix in sgx_tstd/panicking.rs. Now master branch can output panic strings correctly.

Expand Down Expand Up @@ -227,7 +227,7 @@ soon as possible!

# Rust SGX SDK v1.0.0 Release Notes

Baidu X-Lab provides Rust SGX SDK that is a bundle of basic libraries, scripts and ported libraries for developing Intel SGX programs in Rust programming language. Based on this SDK, developers could easily build up their SGX programs in Rust. Rust SGX SDK provides the strongest defence and helps protect the secret data reside in an enclave effectively even when the OS is compromised. It is important to real world data privacy and cloud security. Since the first day of open source, we have recevied many recommendations and supports from both academic and industry. Today, we are proudly releasing the 1.0.0 version of Rust SGX SDK, indicating that Rust SGX SDK is becoming stable and ready for production.
Baidu X-Lab provides Rust SGX SDK that is a bundle of basic libraries, scripts and ported libraries for developing Intel SGX programs in Rust programming language. Based on this SDK, developers could easily build up their SGX programs in Rust. Rust SGX SDK provides the strongest defence and helps protect the secret data reside in an enclave effectively even when the OS is compromised. It is important to real world data privacy and cloud security. Since the first day of open source, we have received many recommendations and supports from both academic and industry. Today, we are proudly releasing the 1.0.0 version of Rust SGX SDK, indicating that Rust SGX SDK is becoming stable and ready for production.

Intel SGX is being well adopted by industry, such as Microsoft, Ali cloud and IBM, which indicates that SGX's ability for trusted computing and data protection has been accepted by giant companies and the software stack of Intel SGX is becoming more and more critical. Ideally, the SGX application should guarantee safety from the first line of its code, instead of consumpting tremenduous of engineer-months for code auditing and fuzzing. Thus, C/C++ is not the first choice of programming language for Intel SGX applications due to the lack of memory safety guarantees. To this end, we proposed **Rust SGX SDK** which brings the best practice of memory safety to SGX projects, and reduces the workload of developing flawless SGX projects significantly. Based on this, we can leverage new techniques such as [**Non-bypassable Security Paradigm**](documents/nbsp.pdf) to assist the formal verification of critical security attributes on large projects, which is believed to be the state-of-art of practical application security guarantee. Apart from the C/C++ SDK provided by Intel, Rust SGX SDK is the only recommended SDK listed on Intel SGX's [homepage](https://software.intel.com/en-us/sgx).

Expand Down Expand Up @@ -277,7 +277,7 @@ Good news! Rust SGX SDK proposal has been adopted by [RustFest'18](https://paris
# Rust SGX SDK v0.9.5 Release Notes
**Support latest Rust nightly build (nightly-2018-01-19-x86_64-unknown-linux-gnu)**

**Xargo support** Rust SGX SDK v0.9.5 provides `xargo` support with a target `x86_64-unknown-linux-sgx`. To compile a crate using `xargo`, add a corresponding json config and make appropirate changes to the source code, then compile it with `xargo build -target x86_64-unknown-linux-sgx --release`. Porting is easier! Please refer to the ported [third-party libraries](third_party/) for more details.
**Xargo support** Rust SGX SDK v0.9.5 provides `xargo` support with a target `x86_64-unknown-linux-sgx`. To compile a crate using `xargo`, add a corresponding json config and make appropriate changes to the source code, then compile it with `xargo build -target x86_64-unknown-linux-sgx --release`. Porting is easier! Please refer to the ported [third-party libraries](third_party/) for more details.

**Network access support** We port part of `std::net` to `sgx_tstd::net`. Now `sgx_tstd::net` supports most of socket functions by using 12 ocalls (defined in `edl/sgx_net.edl`).

Expand Down Expand Up @@ -311,7 +311,7 @@ All of the third-party libraries could be compiled by `make` or `XARGO_SGX=1 mak

## About xargo's sysroot

`xargo` would generate a *sysroot*, including all basic libraries. In the past, everytime a Rust-SGX project is compiled via `make`, the basic Rust-SGX runtime would be compiled. Now, if we use `xargo` to compile (`XARGO_SGX=1 make`), only the **first time** xargo builds the sysroot and saves them in Rust's directory and the basic Rust-SGX libraries would be re-used later.
`xargo` would generate a *sysroot*, including all basic libraries. In the past, every time a Rust-SGX project is compiled via `make`, the basic Rust-SGX runtime would be compiled. Now, if we use `xargo` to compile (`XARGO_SGX=1 make`), only the **first time** xargo builds the sysroot and saves them in Rust's directory and the basic Rust-SGX libraries would be re-used later.

The current sysroot includes:
1. libcompiler_builtins
Expand Down
2 changes: 1 addition & 1 deletion samplecode/psi/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ Example of a remote attestation with Intel's SGX including the communication wit

The code requires the installation of Intel SGX [here](https://github.com/01org/linux-sgx) and
the SGX driver [here](https://github.com/01org/linux-sgx-driver). Furthermore, also a developer account
for the usage of IAS has be registered [Deverloper account](https://software.intel.com/en-us/sgx).
for the usage of IAS has be registered [Developer account](https://software.intel.com/en-us/sgx).
After the registration with a certificate (can be self-signed for development purposes), Intel will
respond with a SPID which is needed to communicate with IAS.

Expand Down
2 changes: 1 addition & 1 deletion samplecode/remoteattestation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ Example of a remote attestation with Intel's SGX including the communication wit

The code requires the installation of Intel SGX [here](https://github.com/01org/linux-sgx) and
the SGX driver [here](https://github.com/01org/linux-sgx-driver). Furthermore, also a developer account
for the usage of IAS has be registered [Deverloper account](https://software.intel.com/en-us/sgx).
for the usage of IAS has be registered [Developer account](https://software.intel.com/en-us/sgx).
After the registration with a certificate (can be self-signed for development purposes), Intel will
respond with a SPID which is needed to communicate with IAS.

Expand Down
6 changes: 3 additions & 3 deletions samplecode/tr-mpc/Readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ This code sample contains an implementation of [Integrating Remote Attestation w

## Design

The same combination of (hardware,enviroment,context) will generates the same `mr_enclave` measurement. And it is almost impossible to counterfeit it.
The same combination of (hardware,environment,context) will generates the same `mr_enclave` measurement. And it is almost impossible to counterfeit it.

We could achieve trust computing and data privacy based on this feature.

Expand All @@ -17,11 +17,11 @@ Assuming that there are two players: Alice and Bob.
With Intel SGX, and baiduxlab/sgx-rust image, we could do this in the following steps:
- Alice shares the hash-computing code which will be run in SGX enclave with Bob.
- Bob checks whether there exists any security risk in this code.
- Alice tells Bob the context of compiling enviroment and builds her enclave.signed.so.
- Alice tells Bob the context of compiling environment and builds her enclave.signed.so.
- Bob compiles the code and runs his enclave and gets the corresoponding `mr_enclave`.
- Bod tries to connect with Alice's enclave and gets the `mr_enclave` from report and compares it with his.
- If passed, Bob sends data to Alice's enclave through TLS.
- Alice's enclave gets the data and computs hash of it.
- Alice's enclave gets the data and computes, computus hash of it.

## Requirements

Expand Down