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
20 changes: 20 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -135,3 +135,23 @@ jobs:

- name: snmalloc correctness test
run: cd ./examples/mem-correctness-test && cargo run

- name: Cargo test -p enclave-runner-client --no-default-features --features alloc
run: cargo test --verbose --locked -p enclave-runner-client --no-default-features --features alloc

- name: Load vsock_loopback kernel module (non-blocking)
id: vsock
run: |
if sudo modprobe vsock_loopback; then
echo "loaded=true" >> "$GITHUB_OUTPUT"
else
echo "::warning title=vsock_loopback unavailable::Could not load vsock_loopback, skipping the enclave-runner-client loopback tests."
fi

- name: Cargo test -p enclave-runner-client --test loopback (vsock loopback)
if: steps.vsock.outputs.loaded == 'true'
run: cargo test --verbose --locked -p enclave-runner-client --test loopback -- --ignored

- name: Cargo test -p enclave-runner-client --no-default-features --features alloc --test loopback (vsock loopback)
if: steps.vsock.outputs.loaded == 'true'
run: cargo test --verbose --locked -p enclave-runner-client --no-default-features --features alloc --test loopback -- --ignored
85 changes: 69 additions & 16 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ members = [
"fortanix-vme/aws-nitro-enclaves/nitro-attestation-verify",
"fortanix-vme/aws-nitro-enclaves/nsm",
"fortanix-vme/aws-nitro-enclaves/tests/nsm-test",
"fortanix-vme/enclave-runner-client",
"fortanix-vme/fortanix-vme-abi",
"fortanix-vme/fortanix-vme-eif",
"fortanix-vme/fortanix-vme-initramfs",
Expand Down
32 changes: 32 additions & 0 deletions fortanix-vme/enclave-runner-client/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
[package]
name = "enclave-runner-client"
version = "0.1.0"
edition = "2024"
authors = ["Fortanix, Inc."]

[dependencies]
core = { version = "1.0.1", optional = true, package = "rustc-std-workspace-core" }
alloc = { version = "1.0.1", optional = true, package = "rustc-std-workspace-alloc" }

vsock = { git = "https://github.com/fortanix/vsock-rs.git", branch = "gianlu33/rte-1352-tmp", default-features = false, features = ["random_port"] }
serde_cbor = { version = "0.11", default-features = false, features = ["alloc"] }

# `fortanix/rust` patches libc to our `fortanix/libc` fork (branch `fortanixvme-2023-05-07-alpha),
# which is currently at version 0.2.175. Specifying a higher version here will make cargo use upstream
# libc, which will break std compilation as upstream libc is not aware of the fortanixvme target.
libc = { version = "0.2.175", default-features = false }

fortanix-vme-abi = { path = "../fortanix-vme-abi", default-features = false, features = ["serde"] }

[dev-dependencies]

[features]
std = ["vsock/std", "serde_cbor/std", "libc/std", "fortanix-vme-abi/std"]
default = ["std"]
rustc-dep-of-std = [
"core",
"alloc",
"vsock/rustc-dep-of-std",
"libc/rustc-dep-of-std",
"fortanix-vme-abi/rustc-dep-of-std",
]
Loading
Loading