Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate examples use linear handles (except abitest) #1909

Merged
merged 3 commits into from
Apr 16, 2021
Merged
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 examples/aggregator/client/android/cpp/client.cc
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ JNIEXPORT void JNICALL Java_com_google_oak_aggregator_MainActivity_createChannel
// The particular value corresponds to the hash on the `aggregator.wasm` line in
// https://github.com/project-oak/oak/blob/hashes/reproducibility_index.
oak::label::Label label = oak::WebAssemblyModuleHashLabel(
absl::HexStringToBytes("5df07e7163209d363d9c4733910a71947582403627e2916a0daea661052360c6"));
absl::HexStringToBytes("8757bbf4c470b1c33c830a37fb9ce95feb56fe9b2b1a7003d3150ef21a9ea31a"));
kChannel = Aggregator::NewStub(oak::ApplicationClient::CreateChannel(
address, oak::ApplicationClient::GetTlsChannelCredentials(ca_cert), label));
JNI_LOG("gRPC channel has been created");
Expand Down
2 changes: 1 addition & 1 deletion examples/aggregator/client/cpp/aggregator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ int main(int argc, char** argv) {
//
// TODO(#1674): Add appropriate TLS endpoint tag to the label as well.
oak::label::Label label = oak::WebAssemblyModuleHashLabel(
absl::HexStringToBytes("5df07e7163209d363d9c4733910a71947582403627e2916a0daea661052360c6"));
absl::HexStringToBytes("8757bbf4c470b1c33c830a37fb9ce95feb56fe9b2b1a7003d3150ef21a9ea31a"));
// Connect to the Oak Application.
auto stub = Aggregator::NewStub(oak::ApplicationClient::CreateChannel(
address, oak::ApplicationClient::GetTlsChannelCredentials(ca_cert_path), label));
Expand Down
2 changes: 1 addition & 1 deletion examples/aggregator/config.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
grpc_server_listen_address = "[::]:8080"
backend_server_address = "https://localhost:8888"
aggregator_module_hash = "5df07e7163209d363d9c4733910a71947582403627e2916a0daea661052360c6"
aggregator_module_hash = "8757bbf4c470b1c33c830a37fb9ce95feb56fe9b2b1a7003d3150ef21a9ea31a"
4 changes: 2 additions & 2 deletions examples/aggregator/module/rust/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ either = "*"
hex = "*"
itertools = "*"
log = "*"
oak = "=0.1.0"
oak = { version = "=0.1.0", features = ["linear-handles"] }
oak_abi = "=0.1.0"
oak_io = "=0.1.0"
oak_services = "=0.1.0"
Expand All @@ -29,7 +29,7 @@ assert_matches = "*"
env_logger = "*"
log = "*"
maplit = "*"
oak_runtime = "=0.1.0"
oak_runtime = { version = "=0.1.0", features = ["linear-handles"] }
oak_sign = "=0.1.0"
oak_tests = "=0.1.0"
tokio = { version = "*", features = ["macros", "rt-threaded", "stream"] }
Expand Down
4 changes: 2 additions & 2 deletions examples/chat/module/rust/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ crate-type = ["cdylib"]
[dependencies]
anyhow = "*"
log = "*"
oak = "=0.1.0"
oak = { version = "=0.1.0", features = ["linear-handles"] }
oak_abi = "=0.1.0"
oak_io = "=0.1.0"
oak_services = "=0.1.0"
Expand All @@ -27,7 +27,7 @@ chat_grpc = "=0.1.0"
env_logger = "*"
log = "*"
oak_client = "=0.1.0"
oak_runtime = "=0.1.0"
oak_runtime = { version = "=0.1.0", features = ["linear-handles"] }
oak_sign = "=0.1.0"
oak_tests = "=0.1.0"
serial_test = "*"
Expand Down
12 changes: 2 additions & 10 deletions examples/injection/module/rust/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,11 @@ crate-type = ["cdylib"]
[dependencies]
anyhow = "*"
log = "*"
oak = { version = "=0.1.0", features = ["linear-handles"] }
oak_abi = "=0.1.0"
oak_io = "=0.1.0"
oak_services = "=0.1.0"
prost = "*"

[dependencies.oak]
version = "=0.1.0"
default-features = false
features = ["linear-handles"]

[dependencies.oak_io]
version = "=0.1.0"
default-features = false
features = ["linear-handles"]

[build-dependencies]
oak_utils = "*"
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ crate-type = ["cdylib", "rlib"]
[dependencies]
anyhow = "*"
log = "*"
oak = "=0.1.0"
oak = { version = "=0.1.0", features = ["linear-handles"] }
oak_abi = "=0.1.0"
oak_io = "=0.1.0"
oak_services = "=0.1.0"
Expand Down
4 changes: 2 additions & 2 deletions examples/private_set_intersection/main_module/rust/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ crate-type = ["cdylib", "rlib"]
anyhow = "*"
base64 = "*"
log = "*"
oak = "=0.1.0"
oak = { version = "=0.1.0", features = ["linear-handles"] }
oak_abi = "=0.1.0"
oak_io = "=0.1.0"
oak_services = "=0.1.0"
Expand All @@ -26,7 +26,7 @@ env_logger = "*"
hex = "*"
log = "*"
maplit = "*"
oak_runtime = "=0.1.0"
oak_runtime = { version = "=0.1.0", features = ["linear-handles"] }
oak_sign = "=0.1.0"
oak_tests = "=0.1.0"
private_set_intersection_grpc = "=0.1.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,10 @@ MCowBQYDK2VwAyEAf41SClNtR4i46v2Tuh1fQLbt/ZqRr1lENajCW92jyP4=
-----END PUBLIC KEY-----

-----BEGIN SIGNATURE-----
2no3OmxQVOTaN2JuUjzWiH3C61HhxPWx0SJgqC46+zPMSZVMfUnfcYGpighUyoRt
ijRNRkj78SVLBMaZ1TBICQ==
VmucIrimw9oMOqJl5cSyNyVg10whwB0fJybdnscNTdwKTihb1aaXFHQMVVg9jTOW
j4wvwSBmUAGrawQpRG4cDQ==
-----END SIGNATURE-----

-----BEGIN HASH-----
IU4hEIlGMBMEud5uEKRn1aoEWxcceQP/XDy48DDFCMk=
GsvGc2SRp3c3NyeppIBHsJBEYfNL13EaNs1aO63gDoY=
-----END HASH-----
2 changes: 1 addition & 1 deletion examples/proxy_attestation/module/rust/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ crate-type = ["cdylib", "rlib"]
[dependencies]
anyhow = "*"
log = "*"
oak = "=0.1.0"
oak = { version = "=0.1.0", features = ["linear-handles"] }
oak_abi = "=0.1.0"
oak_io = "=0.1.0"
oak_services = "=0.1.0"
Expand Down
2 changes: 1 addition & 1 deletion examples/translator/common/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ license = "Apache-2.0"

[dependencies]
log = "*"
oak = "=0.1.0"
oak = { version = "=0.1.0", features = ["linear-handles"] }
oak_io = "=0.1.0"
oak_services = "=0.1.0"
prost = "*"
Expand Down
4 changes: 2 additions & 2 deletions examples/translator/module/rust/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,15 @@ crate-type = ["cdylib"]
assert_matches = "*"
env_logger = "*"
log = "*"
oak_runtime = "=0.1.0"
oak_runtime = { version = "=0.1.0", features = ["linear-handles"] }
oak_tests = "=0.1.0"
tokio = { version = "*", features = ["macros", "rt-threaded", "stream"] }
translator_grpc = "=0.1.0"

[dependencies]
anyhow = "*"
log = "*"
oak = "=0.1.0"
oak = { version = "=0.1.0", features = ["linear-handles"] }
oak_abi = "=0.1.0"
oak_io = "=0.1.0"
oak_services = "=0.1.0"
Expand Down
4 changes: 2 additions & 2 deletions examples/trusted_database/module/rust/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ crate-type = ["cdylib", "rlib"]
[dependencies]
anyhow = "*"
log = "*"
oak = "=0.1.0"
oak = { version = "=0.1.0", features = ["linear-handles"] }
oak_abi = "=0.1.0"
oak_io = "=0.1.0"
oak_services = "=0.1.0"
Expand All @@ -24,7 +24,7 @@ assert_matches = "*"
env_logger = "*"
maplit = "*"
oak_abi = "=0.1.0"
oak_runtime = "=0.1.0"
oak_runtime = { version = "=0.1.0", features = ["linear-handles"] }
oak_services = "=0.1.0"
oak_tests = "=0.1.0"
tokio = { version = "*", features = ["macros", "rt-threaded", "stream"] }
Expand Down