diff --git a/.github/workflows/library_rust_tests.yml b/.github/workflows/library_rust_tests.yml index f193213d2..10fe5dfcf 100644 --- a/.github/workflows/library_rust_tests.yml +++ b/.github/workflows/library_rust_tests.yml @@ -57,7 +57,7 @@ jobs: - name: Setup Dafny uses: dafny-lang/setup-dafny-action@v1.7.0 with: - dafny-version: nightly-latest + dafny-version: nightly-2024-12-03-4954170 # Remove this after the formatting in Rust starts working - name: smithy-dafny Rust hacks diff --git a/DynamoDbEncryption/runtimes/rust/Cargo.toml b/DynamoDbEncryption/runtimes/rust/Cargo.toml index 57bdb1f42..f1da0d79e 100644 --- a/DynamoDbEncryption/runtimes/rust/Cargo.toml +++ b/DynamoDbEncryption/runtimes/rust/Cargo.toml @@ -3,7 +3,7 @@ name = "aws-db-esdk" version = "0.1.0" edition = "2021" rust-version = "1.80.0" -keywords = ["crypto", "cryptography", "security", "dynamodb", "ddb", "encryption", "client-side", "clientside"] +keywords = ["cryptography", "security", "dynamodb", "encryption", "client-side"] license = "ISC AND (Apache-2.0 OR ISC)" description = "aws-db-esdk is a library for implementing client side encryption with DynamoDB." homepage = "https://github.com/aws/aws-database-encryption-sdk-dynamodb/tree/main/releases/rust/db_esdk" @@ -24,7 +24,7 @@ aws-sdk-kms = "1.50.0" aws-smithy-runtime-api = {version = "1.7.3", features = ["client"] } aws-smithy-types = "1.2.9" chrono = "0.4.38" -dafny_runtime = { path = "../../../submodules/MaterialProviders/smithy-dafny/TestModels/dafny-dependencies/dafny_runtime_rust"} +dafny-runtime = "0.1.1" dashmap = "6.1.0" pem = "3.0.4" tokio = {version = "1.41.1", features = ["full"] } diff --git a/DynamoDbEncryption/runtimes/rust/src/intercept.rs b/DynamoDbEncryption/runtimes/rust/src/intercept.rs index 4ab4738d2..b7d08723a 100644 --- a/DynamoDbEncryption/runtimes/rust/src/intercept.rs +++ b/DynamoDbEncryption/runtimes/rust/src/intercept.rs @@ -16,7 +16,6 @@ use aws_sdk_dynamodb::{ use aws_smithy_runtime_api::client::interceptors::context::Input; use aws_smithy_types::config_bag::{Storable, StoreReplace}; -#[macro_export] macro_rules! modify_request { ($cfg:ident,$request:ident,$self:ident,$transform:ident) => {{ // store the original request @@ -44,7 +43,6 @@ macro_rules! modify_request { }}; } -#[macro_export] macro_rules! modify_response { ($cfg:ident,$type:ty,$response:ident,$self:ident,$transform:ident) => {{ // retrieve the original request diff --git a/releases/rust/db_esdk/Cargo.toml b/releases/rust/db_esdk/Cargo.toml index e63880bf1..f1da0d79e 100644 --- a/releases/rust/db_esdk/Cargo.toml +++ b/releases/rust/db_esdk/Cargo.toml @@ -3,7 +3,7 @@ name = "aws-db-esdk" version = "0.1.0" edition = "2021" rust-version = "1.80.0" -keywords = ["crypto", "cryptography", "security", "dynamodb", "ddb", "encryption", "client-side", "clientside"] +keywords = ["cryptography", "security", "dynamodb", "encryption", "client-side"] license = "ISC AND (Apache-2.0 OR ISC)" description = "aws-db-esdk is a library for implementing client side encryption with DynamoDB." homepage = "https://github.com/aws/aws-database-encryption-sdk-dynamodb/tree/main/releases/rust/db_esdk" @@ -24,7 +24,7 @@ aws-sdk-kms = "1.50.0" aws-smithy-runtime-api = {version = "1.7.3", features = ["client"] } aws-smithy-types = "1.2.9" chrono = "0.4.38" -dafny_runtime = { path = "./dafny_runtime_rust"} +dafny-runtime = "0.1.1" dashmap = "6.1.0" pem = "3.0.4" tokio = {version = "1.41.1", features = ["full"] } diff --git a/releases/rust/db_esdk/dafny_runtime_rust/Cargo.toml b/releases/rust/db_esdk/dafny_runtime_rust/Cargo.toml index d5244c747..92c31d457 100644 --- a/releases/rust/db_esdk/dafny_runtime_rust/Cargo.toml +++ b/releases/rust/db_esdk/dafny_runtime_rust/Cargo.toml @@ -1,7 +1,13 @@ [package] -name = "dafny_runtime" -version = "0.1.0" +name = "dafny-runtime" +version = "0.1.1" edition = "2021" +keywords = ["dafny"] +license = "ISC AND (Apache-2.0 OR ISC)" +description = "dafny-runtime is the runtime support library for Rust code gerated from Dafny." +repository = "https://github.com/aws/aws-database-encryption-sdk-dynamodb/tree/main/releases/rust/db_esdk/dafny_runtime_rust" +authors = ["AWS-CryptoTools"] +readme = "README.md" [dependencies] once_cell = "1.18.0" diff --git a/releases/rust/db_esdk/dafny_runtime_rust/README.md b/releases/rust/db_esdk/dafny_runtime_rust/README.md new file mode 100644 index 000000000..f0a4e1a89 --- /dev/null +++ b/releases/rust/db_esdk/dafny_runtime_rust/README.md @@ -0,0 +1 @@ +This is the runtime support library for Rust code generated from Dafny. diff --git a/releases/rust/db_esdk/src/intercept.rs b/releases/rust/db_esdk/src/intercept.rs index 4ab4738d2..b7d08723a 100644 --- a/releases/rust/db_esdk/src/intercept.rs +++ b/releases/rust/db_esdk/src/intercept.rs @@ -16,7 +16,6 @@ use aws_sdk_dynamodb::{ use aws_smithy_runtime_api::client::interceptors::context::Input; use aws_smithy_types::config_bag::{Storable, StoreReplace}; -#[macro_export] macro_rules! modify_request { ($cfg:ident,$request:ident,$self:ident,$transform:ident) => {{ // store the original request @@ -44,7 +43,6 @@ macro_rules! modify_request { }}; } -#[macro_export] macro_rules! modify_response { ($cfg:ident,$type:ty,$response:ident,$self:ident,$transform:ident) => {{ // retrieve the original request