diff --git a/.github/actions/install_smithy_dafny_codegen_dependencies/action.yml b/.github/actions/install_smithy_dafny_codegen_dependencies/action.yml index da00a4c70..89971fdf7 100644 --- a/.github/actions/install_smithy_dafny_codegen_dependencies/action.yml +++ b/.github/actions/install_smithy_dafny_codegen_dependencies/action.yml @@ -12,10 +12,10 @@ runs: uses: gradle/gradle-build-action@v2 with: arguments: :codegen-client:pTML :codegen-core:pTML :rust-runtime:pTML - build-root-directory: smithy-dafny/smithy-dafny-codegen-modules/smithy-rs + build-root-directory: mpl/smithy-dafny/smithy-dafny-codegen-modules/smithy-rs - name: Install smithy-dafny-codegen Python dependencies locally uses: gradle/gradle-build-action@v2 with: arguments: :smithy-python-codegen:pTML - build-root-directory: smithy-dafny/codegen/smithy-dafny-codegen-modules/smithy-python/codegen + build-root-directory: mpl/smithy-dafny/codegen/smithy-dafny-codegen-modules/smithy-python/codegen diff --git a/.github/actions/polymorph_codegen/action.yml b/.github/actions/polymorph_codegen/action.yml index 7f6b4f29b..66d0f7566 100644 --- a/.github/actions/polymorph_codegen/action.yml +++ b/.github/actions/polymorph_codegen/action.yml @@ -109,6 +109,13 @@ runs: run: | make polymorph_dotnet ${{ steps.dependencies.outputs.PROJECT_DEPENDENCIES }} + # TODO: Uncomment when checking in polymorph_rust code + # - name: Regenerate Rust code using smithy-dafny + # working-directory: ./${{ inputs.library }} + # shell: bash + # run: | + # make polymorph_rust ${{ steps.dependencies.outputs.PROJECT_DEPENDENCIES }} + - name: Check regenerated code against commited code # Composite action inputs seem to not actually support booleans properly for some reason if: inputs.diff-generated-code == 'true' diff --git a/.github/workflows/dafny_interop_test_vector_net.yml b/.github/workflows/dafny_interop_test_vector_net.yml index e7009fa35..66e9438a1 100644 --- a/.github/workflows/dafny_interop_test_vector_net.yml +++ b/.github/workflows/dafny_interop_test_vector_net.yml @@ -267,7 +267,6 @@ jobs: run: | git submodule update --init libraries git submodule update --init --recursive mpl - git submodule update --init smithy-dafny - name: Configure AWS Credentials uses: aws-actions/configure-aws-credentials@v4 diff --git a/.github/workflows/daily_ci.yml b/.github/workflows/daily_ci.yml index 1bfb902aa..c1655cbc6 100644 --- a/.github/workflows/daily_ci.yml +++ b/.github/workflows/daily_ci.yml @@ -11,13 +11,13 @@ jobs: if: github.event_name != 'schedule' || github.repository_owner == 'aws' uses: ./.github/workflows/library_codegen.yml with: - dafny: '4.8.0' + dafny: '4.8.1' daily-ci-verification: # Don't run the cron builds on forks if: github.event_name != 'schedule' || github.repository_owner == 'aws' uses: ./.github/workflows/library_dafny_verification.yml with: - dafny: '4.8.0' + dafny: '4.8.1' # daily-ci-java: # if: github.event_name != 'schedule' || github.repository_owner == 'aws' # uses: ./.github/workflows/library_java_tests.yml @@ -27,10 +27,15 @@ jobs: if: github.event_name != 'schedule' || github.repository_owner == 'aws' uses: ./.github/workflows/library_net_tests.yml with: - dafny: '4.8.0' + dafny: '4.8.1' + daily-ci-rust: + if: github.event_name != 'schedule' || github.repository_owner == 'aws' + uses: ./.github/workflows/library_rust_tests.yml + with: + dafny: '4.8.1' daily-ci-interop-tests: if: github.event_name != 'schedule' || github.repository_owner == 'aws' uses: ./.github/workflows/library_interop_tests.yml with: - dafny: '4.8.0' + dafny: '4.8.1' diff --git a/.github/workflows/library_codegen.yml b/.github/workflows/library_codegen.yml index e11e71685..90922d0fe 100644 --- a/.github/workflows/library_codegen.yml +++ b/.github/workflows/library_codegen.yml @@ -38,7 +38,6 @@ jobs: # it to verify the Dafny code. Instead we manually pull the submodules we DO need. - run: git submodule update --init libraries - run: git submodule update --init --recursive mpl - - run: git submodule update --init --recursive smithy-dafny # Only used to format generated code # and to translate version strings such as "nightly-latest" diff --git a/.github/workflows/library_dafny_verification.yml b/.github/workflows/library_dafny_verification.yml index 8219129df..c97c33fd0 100644 --- a/.github/workflows/library_dafny_verification.yml +++ b/.github/workflows/library_dafny_verification.yml @@ -19,7 +19,8 @@ jobs: strategy: matrix: library: [ - AwsEncryptionSDK + AwsEncryptionSDK, + TestVectors ] os: [ macos-13 ] runs-on: ${{ matrix.os }} @@ -36,7 +37,6 @@ jobs: run: | git submodule update --init libraries git submodule update --init --recursive mpl - git submodule update --init smithy-dafny # dafny-reportgenerator requires next6 # but only 7.0 is installed on macos-13-large diff --git a/.github/workflows/library_interop_test_vectors.yml b/.github/workflows/library_interop_test_vectors.yml new file mode 100644 index 000000000..87c98ad5f --- /dev/null +++ b/.github/workflows/library_interop_test_vectors.yml @@ -0,0 +1,216 @@ +# This workflow performs interoperability tests across the supported runtimes of the ESDK Dafny +name: Library Interoperability Dafny TestVectors + +on: + workflow_call: + inputs: + dafny: + description: "The Dafny version to use" + required: true + type: string + regenerate-code: + description: "Regenerate code using smithy-dafny" + required: false + default: false + type: boolean + +jobs: + generateEncryptVectors: + strategy: + matrix: + library: [TestVectors] + os: [ + # https://taskei.amazon.dev/tasks/CrypTool-5283 + # windows-latest, + ubuntu-latest, + macos-13, + ] + language: [java, net] + # https://taskei.amazon.dev/tasks/CrypTool-5284 + dotnet-version: ["6.0.x"] + runs-on: ${{ matrix.os }} + permissions: + id-token: write + contents: read + + steps: + - name: Support longpaths on Git checkout + run: | + git config --global core.longpaths true + + - uses: actions/checkout@v3 + # Not all submodules are needed. + # We manually pull the submodule we DO need. + - run: git submodule update --init libraries + - run: git submodule update --init --recursive mpl + + # Set up runtimes + - name: Setup .NET Core SDK ${{ matrix.dotnet-version }} + if: matrix.language == 'net' + uses: actions/setup-dotnet@v3 + with: + dotnet-version: ${{ matrix.dotnet-version }} + + - name: Setup Java 17 + if: matrix.language == 'java' + uses: actions/setup-java@v3 + with: + distribution: "corretto" + java-version: 17 + + - name: Setup Dafny + uses: dafny-lang/setup-dafny-action@v1.6.1 + with: + dafny-version: ${{ inputs.dafny }} + + - name: Regenerate code using smithy-dafny if necessary + if: ${{ inputs.regenerate-code }} + uses: ./.github/actions/polymorph_codegen + with: + dafny: ${{ inputs.dafny }} + library: ${{ matrix.library }} + diff-generated-code: false + + # Build implementation for each runtime + - name: Build ${{ matrix.library }} implementation in Java + if: matrix.language == 'java' + shell: bash + working-directory: ./${{ matrix.library }} + run: | + # This works because `node` is installed by default on GHA runners + CORES=$(node -e 'console.log(os.cpus().length)') + make build_java CORES=$CORES + + - name: Build ${{ matrix.library }} implementation in .NET + if: matrix.language == 'net' + shell: bash + working-directory: ./${{ matrix.library }} + run: | + # This works because `node` is installed by default on GHA runners + CORES=$(node -e 'console.log(os.cpus().length)') + make transpile_net + + - name: Setup gradle + if: matrix.language == 'java' + uses: gradle/gradle-build-action@v2 + with: + gradle-version: 7.2 + + # TestVectors will call KMS + - name: Configure AWS Credentials + uses: aws-actions/configure-aws-credentials@v2 + with: + aws-region: us-west-2 + role-to-assume: arn:aws:iam::370957321024:role/GitHub-CI-Public-ESDK-Dafny-Role-us-west-2 + role-session-name: InterOpTests + + - name: Create Manifests + working-directory: ./${{ matrix.library }} + run: make test_generate_vectors_${{ matrix.language }} + + - name: Create Encrypt Manifests + working-directory: ./${{ matrix.library }} + run: make test_encrypt_vectors_${{ matrix.language }} + + - name: Upload Encrypt Manifest and keys.json files + uses: actions/upload-artifact@v4 + with: + name: ${{matrix.os}}_vector_artifact_${{matrix.language}}_${{github.sha}} + path: | + ./${{matrix.library}}/runtimes/${{matrix.language}}/*.json + ./${{matrix.library}}/runtimes/${{matrix.language}}/plaintexts + ./${{matrix.library}}/runtimes/${{matrix.language}}/ciphertexts + + testInteroperablity: + needs: generateEncryptVectors + strategy: + matrix: + library: [TestVectors] + os: [ + # https://taskei.amazon.dev/tasks/CrypTool-5283 + # windows-latest, + ubuntu-latest, + macos-13, + ] + encrypting_language: [java, net] + decrypting_language: [java, net] + # https://taskei.amazon.dev/tasks/CrypTool-5284 + dotnet-version: ["6.0.x"] + runs-on: ${{ matrix.os }} + permissions: + id-token: write + contents: read + + steps: + - name: Support longpaths on Git checkout + run: | + git config --global core.longpaths true + # TestVectors will call KMS + - name: Configure AWS Credentials + uses: aws-actions/configure-aws-credentials@v2 + with: + aws-region: us-west-2 + role-to-assume: arn:aws:iam::370957321024:role/GitHub-CI-Public-ESDK-Dafny-Role-us-west-2 + role-session-name: InterOpTests + + - uses: actions/checkout@v3 + # Not all submodules are needed. + # We manually pull the submodule we DO need. + - run: git submodule update --init libraries + - run: git submodule update --init --recursive mpl + + - name: Setup .NET Core SDK ${{ matrix.dotnet-version }} + if: matrix.decrypting_language == 'net' + uses: actions/setup-dotnet@v3 + with: + dotnet-version: ${{ matrix.dotnet-version }} + + - name: Setup Java 17 + if: matrix.decrypting_language == 'java' + uses: actions/setup-java@v3 + with: + distribution: "corretto" + java-version: 17 + + - name: Setup Dafny + uses: dafny-lang/setup-dafny-action@v1.6.1 + with: + dafny-version: ${{ inputs.dafny }} + + - name: Regenerate code using smithy-dafny if necessary + if: ${{ inputs.regenerate-code }} + uses: ./.github/actions/polymorph_codegen + with: + dafny: ${{ inputs.dafny }} + library: ${{ matrix.library }} + diff-generated-code: false + + # Build implementation for each runtime + - name: Build ${{ matrix.library }} implementation in Java + if: matrix.decrypting_language == 'java' + working-directory: ./${{ matrix.library }} + shell: bash + run: | + # This works because `node` is installed by default on GHA runners + CORES=$(node -e 'console.log(os.cpus().length)') + make build_java CORES=$CORES + + - name: Build ${{ matrix.library }} implementation in .NET + if: matrix.decrypting_language == 'net' + working-directory: ./${{ matrix.library }} + shell: bash + run: | + # This works because `node` is installed by default on GHA runners + CORES=$(node -e 'console.log(os.cpus().length)') + make transpile_net + + - name: Download Encrypt Manifest Artifact + uses: actions/download-artifact@v4 + with: + name: ${{matrix.os}}_vector_artifact_${{matrix.encrypting_language}}_${{github.sha}} + path: ./${{matrix.library}}/runtimes/${{matrix.decrypting_language}} + + - name: Decrypt Encrypt Manifest + working-directory: ./${{ matrix.library }} + run: make test_decrypt_encrypt_vectors_${{matrix.decrypting_language}} + diff --git a/.github/workflows/library_interop_tests.yml b/.github/workflows/library_interop_tests.yml index 8af6a9462..a2e162743 100644 --- a/.github/workflows/library_interop_tests.yml +++ b/.github/workflows/library_interop_tests.yml @@ -46,7 +46,6 @@ jobs: run: | git submodule update --init libraries git submodule update --init --recursive mpl - git submodule update --init smithy-dafny - name: Configure AWS Credentials uses: aws-actions/configure-aws-credentials@v4 @@ -144,7 +143,7 @@ jobs: run: | git submodule update --init libraries git submodule update --init --recursive mpl - git submodule update --init smithy-dafny + - name: Configure AWS Credentials uses: aws-actions/configure-aws-credentials@v4 @@ -246,7 +245,7 @@ jobs: run: | git submodule update --init libraries git submodule update --init --recursive mpl - git submodule update --init smithy-dafny + - name: Configure AWS Credentials uses: aws-actions/configure-aws-credentials@v4 diff --git a/.github/workflows/library_java_tests.yml b/.github/workflows/library_java_tests.yml index 2893d3d4f..cfba10bc0 100644 --- a/.github/workflows/library_java_tests.yml +++ b/.github/workflows/library_java_tests.yml @@ -41,7 +41,6 @@ jobs: run: | git submodule update --init libraries git submodule update --init --recursive mpl - git submodule update --init smithy-dafny - name: Configure AWS Credentials uses: aws-actions/configure-aws-credentials@v2 diff --git a/.github/workflows/library_net_tests.yml b/.github/workflows/library_net_tests.yml index ab0ec1788..52cc2f3aa 100644 --- a/.github/workflows/library_net_tests.yml +++ b/.github/workflows/library_net_tests.yml @@ -52,7 +52,6 @@ jobs: run: | git submodule update --init libraries git submodule update --init --recursive mpl - git submodule update --init smithy-dafny - name: Configure AWS Credentials uses: aws-actions/configure-aws-credentials@v2 diff --git a/.github/workflows/library_rust_tests.yml b/.github/workflows/library_rust_tests.yml new file mode 100644 index 000000000..48506fc6d --- /dev/null +++ b/.github/workflows/library_rust_tests.yml @@ -0,0 +1,142 @@ +# This workflow performs tests in Rust. +name: Library Rust tests + +on: + workflow_call: + inputs: + dafny: + description: 'The Dafny version to run' + required: true + type: string + regenerate-code: + description: "Regenerate code using smithy-dafny" + required: false + default: false + type: boolean + +jobs: + testRust: + strategy: + fail-fast: false + matrix: + os: [ + windows-latest, + ubuntu-latest, + macos-12, + ] + runs-on: ${{ matrix.os }} + permissions: + id-token: write + contents: read + env: + # TODO: do we need this here? + DOTNET_CLI_TELEMETRY_OPTOUT: 1 + DOTNET_NOLOGO: 1 + steps: + - name: Support longpaths on Git checkout + run: | + git config --global core.longpaths true + - uses: actions/checkout@v2 + - name: Init Submodules + shell: bash + run: | + git submodule update --init libraries + git submodule update --init --recursive mpl + + - name: Configure AWS Credentials + uses: aws-actions/configure-aws-credentials@v2 + with: + aws-region: us-west-2 + role-to-assume: arn:aws:iam::370957321024:role/GitHub-CI-Public-ESDK-Dafny-Role-us-west-2 + role-session-name: RustTests + + - name: Setup Rust Toolchain for GitHub CI + uses: actions-rust-lang/setup-rust-toolchain@v1.10.1 + with: + components: rustfmt + # TODO - uncomment this after Rust formatter works + # - name: Rustfmt Check + # uses: actions-rust-lang/rustfmt@v1 + + # TODO: Use setup-dafny-actions with correct version when Dafny releases 4.8.2 + - name: Setup Dafny + uses: dafny-lang/setup-dafny-action@v1.7.0 + with: + dafny-version: nightly-latest + + # TODO: Remove this after the formatting in Rust starts working + - name: smithy-dafny Rust hacks + shell: bash + run: | + if [ "$RUNNER_OS" == "macOS" ]; then + sed -i '' 's|rustfmt --edition 2021 runtimes/rust/src/implementation_from_dafny.rs|#&|' mpl/smithy-dafny/SmithyDafnyMakefile.mk + else + sed -i 's|rustfmt --edition 2021 runtimes/rust/src/implementation_from_dafny.rs|#&|' mpl/smithy-dafny/SmithyDafnyMakefile.mk + fi + + - name: Setup Java 17 for codegen + uses: actions/setup-java@v3 + with: + distribution: "corretto" + java-version: "17" + + - name: Setup NASM for Windows (aws-lc-sys) + uses: ilammy/setup-nasm@v1 + + - name: Install Smithy-Dafny codegen dependencies + uses: ./.github/actions/install_smithy_dafny_codegen_dependencies + + - name: Regenerate code using smithy-dafny if necessary + if: ${{ inputs.regenerate-code }} + uses: ./.github/actions/polymorph_codegen + with: + dafny: ${{ env.DAFNY_VERSION }} + library: AwsEncryptionSDK + diff-generated-code: false + update-and-regenerate-mpl: true + + # TODO: Remove this after checking in Rust polymorph code + - name: Run make polymorph_rust + shell: bash + working-directory: ./AwsEncryptionSDK + run: | + make polymorph_rust + + - name: Compile AwsEncryptionSDK implementation + shell: bash + working-directory: ./AwsEncryptionSDK + run: | + # This works because `node` is installed by default on GHA runners + CORES=$(node -e 'console.log(os.cpus().length)') + make transpile_rust TRANSPILE_TESTS_IN_RUST=1 CORES=$CORES + + # Remove Rust hacks once Dafny fixes this + - name: Update implementation_from_dafny.rs to add deps + shell: bash + working-directory: ./AwsEncryptionSDK/runtimes/rust/src + run: | + if [ "$RUNNER_OS" == "macOS" ]; then + sed -i '' '/pub use types::aws_encryption_sdk_config::AwsEncryptionSdkConfig;/a\ + pub use crate::deps::aws_cryptography_materialProviders;\ + pub use crate::deps::aws_cryptography_keyStore;\ + pub use crate::deps::com_amazonaws_kms; + ' implementation_from_dafny.rs + else + sed -i '/pub use types::aws_encryption_sdk_config::AwsEncryptionSdkConfig;/a\ + pub use crate::deps::aws_cryptography_materialProviders;\ + pub use crate::deps::aws_cryptography_keyStore;\ + pub use crate::deps::com_amazonaws_kms; + ' implementation_from_dafny.rs + fi + + - name: Test Rust + working-directory: ./AwsEncryptionSDK + shell: bash + run: | + make test_rust + + - name: Test Examples for Rust + working-directory: ./AwsEncryptionSDK/runtimes/rust + shell: bash + run: | + cargo test --examples \ No newline at end of file diff --git a/.github/workflows/manual.yml b/.github/workflows/manual.yml index 74029c97d..3d4dec075 100644 --- a/.github/workflows/manual.yml +++ b/.github/workflows/manual.yml @@ -32,3 +32,8 @@ jobs: with: dafny: ${{ inputs.dafny }} regenerate-code: ${{ inputs.regenerate-code }} + manual-ci-rust: + uses: ./.github/workflows/library_rust_tests.yml + with: + dafny: ${{ inputs.dafny }} + regenerate-code: ${{ inputs.regenerate-code }} diff --git a/.github/workflows/nighly_dafny.yml b/.github/workflows/nighly_dafny.yml index 88b30fecf..de10f6510 100644 --- a/.github/workflows/nighly_dafny.yml +++ b/.github/workflows/nighly_dafny.yml @@ -31,6 +31,12 @@ jobs: with: dafny: 'nightly-latest' regenerate-code: true + dafny-nightly-rust: + if: github.event_name != 'schedule' || github.repository_owner == 'aws' + uses: ./.github/workflows/library_rust_tests.yml + with: + dafny: 'nightly-latest' + regenerate-code: true cut-issue-on-failure: runs-on: ubuntu-latest diff --git a/.github/workflows/pull.yml b/.github/workflows/pull.yml index 655eea31c..93e6a04c5 100644 --- a/.github/workflows/pull.yml +++ b/.github/workflows/pull.yml @@ -8,11 +8,11 @@ jobs: pr-ci-codegen: uses: ./.github/workflows/library_codegen.yml with: - dafny: '4.8.0' + dafny: '4.8.1' pr-ci-verification: uses: ./.github/workflows/library_dafny_verification.yml with: - dafny: '4.8.0' + dafny: '4.8.1' # pr-ci-java: # uses: ./.github/workflows/library_java_tests.yml # with: @@ -20,8 +20,12 @@ jobs: pr-ci-net: uses: ./.github/workflows/library_net_tests.yml with: - dafny: '4.8.0' + dafny: '4.8.1' pr-test-vectors: uses: ./.github/workflows/library_interop_tests.yml with: - dafny: '4.8.0' + dafny: '4.8.1' + pr-dafny-test-vectors: + uses: ./.github/workflows/library_interop_test_vectors.yml + with: + dafny: '4.8.1' diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index 0df538b37..9801151e6 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -10,11 +10,11 @@ jobs: pr-ci-codegen: uses: ./.github/workflows/library_codegen.yml with: - dafny: '4.8.0' + dafny: '4.8.1' push-ci-verification: uses: ./.github/workflows/library_dafny_verification.yml with: - dafny: '4.8.0' + dafny: '4.8.1' # push-ci-java: # uses: ./.github/workflows/library_java_tests.yml # with: @@ -22,8 +22,12 @@ jobs: push-ci-net: uses: ./.github/workflows/library_net_tests.yml with: - dafny: '4.8.0' + dafny: '4.8.1' + push-ci-rust: + uses: ./.github/workflows/library_rust_tests.yml + with: + dafny: '4.8.1' pr-test-vectors: uses: ./.github/workflows/library_interop_tests.yml with: - dafny: '4.8.0' + dafny: '4.8.1' diff --git a/.gitmodules b/.gitmodules index af8c2a073..cdab5a3bd 100644 --- a/.gitmodules +++ b/.gitmodules @@ -8,6 +8,9 @@ [submodule "mpl"] path = mpl url = https://github.com/aws/aws-cryptographic-material-providers-library-dafny.git -[submodule "smithy-dafny"] - path = smithy-dafny - url = https://github.com/awslabs/smithy-dafny +[submodule "AwsEncryptionSDK/runtimes/net/TestVectorsV3/TestVectors/resources/aws-encryption-sdk-test-vectors"] + path = AwsEncryptionSDK/runtimes/net/TestVectorsV3/TestVectors/resources/aws-encryption-sdk-test-vectors + url = https://github.com/awslabs/aws-encryption-sdk-test-vectors.git +[submodule "TestVectors/aws-encryption-sdk-test-vectors"] + path = TestVectors/aws-encryption-sdk-test-vectors + url = https://github.com/awslabs/aws-encryption-sdk-test-vectors.git diff --git a/AwsEncryptionSDK/.gitignore b/AwsEncryptionSDK/.gitignore index 0f6df2a2c..0b80638c5 100644 --- a/AwsEncryptionSDK/.gitignore +++ b/AwsEncryptionSDK/.gitignore @@ -1,9 +1,11 @@ TestResults ImplementationFromDafny.cs TestsFromDafny.cs +ImplementationFromDafny-cs.dtr +TestsFromDafny-cs.dtr bin/ obj/ # Ignore *-cs.dtr files -*-cs.dtr \ No newline at end of file +*-cs.dtr diff --git a/AwsEncryptionSDK/codegen-patches/AwsEncryptionSdk/java/dafny-4.8.1.patch b/AwsEncryptionSDK/codegen-patches/AwsEncryptionSdk/java/dafny-4.8.1.patch new file mode 100644 index 000000000..32602ec55 --- /dev/null +++ b/AwsEncryptionSDK/codegen-patches/AwsEncryptionSdk/java/dafny-4.8.1.patch @@ -0,0 +1,371 @@ +diff --git a/AwsEncryptionSDK/codegen-patches/java/dafny-4.8.1.patch b/AwsEncryptionSDK/codegen-patches/java/dafny-4.8.1.patch +index 6512cb85..e69de29b 100644 +--- a/AwsEncryptionSDK/codegen-patches/java/dafny-4.8.1.patch ++++ b/AwsEncryptionSDK/codegen-patches/java/dafny-4.8.1.patch +@@ -1,19 +0,0 @@ +-diff --git a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/EncryptInput.java b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/EncryptInput.java +-index 67ac1304..7282539c 100644 +---- a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/EncryptInput.java +-+++ b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/EncryptInput.java +-@@ -192,7 +192,7 @@ public class EncryptInput { +- "`frameLength` must be greater than or equal to 1" +- ); +- } +-- if (this._frameLengthSet && this.frameLength() > 4294967296) { +-+ if (this._frameLengthSet && this.frameLength() > 4294967296L) { +- throw new IllegalArgumentException( +- "`frameLength` must be less than or equal to 4294967296." +- ); +-diff --git a/mpl b/mpl +---- a/mpl +-+++ b/mpl +-@@ -1 +1 @@ +--Subproject commit ea0fe508dca214b9c9bdaf0fc21122e83971ef1b +-+Subproject commit ea0fe508dca214b9c9bdaf0fc21122e83971ef1b-dirty +diff --git a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/ToDafny.java b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/ToDafny.java +index 4a9bbfea..e83bfcf9 100644 +--- a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/ToDafny.java ++++ b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/ToDafny.java +@@ -42,11 +42,25 @@ public class ToDafny { + if (nativeValue instanceof CollectionOfErrors) { + return ToDafny.Error((CollectionOfErrors) nativeValue); + } +- return Error.create_Opaque(nativeValue); ++ return Error.create_Opaque( ++ nativeValue, ++ dafny.DafnySequence.asString( ++ java.util.Objects.nonNull(nativeValue.getMessage()) ++ ? nativeValue.getMessage() ++ : "" ++ ) ++ ); + } + + public static Error Error(OpaqueError nativeValue) { +- return Error.create_Opaque(nativeValue.obj()); ++ return Error.create_Opaque( ++ nativeValue.obj(), ++ dafny.DafnySequence.asString( ++ java.util.Objects.nonNull(nativeValue.altText()) ++ ? nativeValue.altText() ++ : "" ++ ) ++ ); + } + + public static Error Error(CollectionOfErrors nativeValue) { +@@ -70,27 +84,27 @@ public class ToDafny { + commitmentPolicy = + Objects.nonNull(nativeValue.commitmentPolicy()) + ? Option.create_Some( +- ESDKCommitmentPolicy._typeDescriptor(), +- software.amazon.cryptography.materialproviders.ToDafny.ESDKCommitmentPolicy( +- nativeValue.commitmentPolicy() +- ) ++ ESDKCommitmentPolicy._typeDescriptor(), ++ software.amazon.cryptography.materialproviders.ToDafny.ESDKCommitmentPolicy( ++ nativeValue.commitmentPolicy() + ) ++ ) + : Option.create_None(ESDKCommitmentPolicy._typeDescriptor()); + Option maxEncryptedDataKeys; + maxEncryptedDataKeys = + Objects.nonNull(nativeValue.maxEncryptedDataKeys()) + ? Option.create_Some( +- TypeDescriptor.LONG, +- (nativeValue.maxEncryptedDataKeys()) +- ) ++ TypeDescriptor.LONG, ++ (nativeValue.maxEncryptedDataKeys()) ++ ) + : Option.create_None(TypeDescriptor.LONG); + Option netV4_0_0_RetryPolicy; + netV4_0_0_RetryPolicy = + Objects.nonNull(nativeValue.netV4_0_0_RetryPolicy()) + ? Option.create_Some( +- NetV4__0__0__RetryPolicy._typeDescriptor(), +- ToDafny.NetV4_0_0_RetryPolicy(nativeValue.netV4_0_0_RetryPolicy()) +- ) ++ NetV4__0__0__RetryPolicy._typeDescriptor(), ++ ToDafny.NetV4_0_0_RetryPolicy(nativeValue.netV4_0_0_RetryPolicy()) ++ ) + : Option.create_None(NetV4__0__0__RetryPolicy._typeDescriptor()); + return new AwsEncryptionSdkConfig( + commitmentPolicy, +@@ -111,11 +125,11 @@ public class ToDafny { + materialsManager = + Objects.nonNull(nativeValue.materialsManager()) + ? Option.create_Some( +- TypeDescriptor.reference(ICryptographicMaterialsManager.class), +- software.amazon.cryptography.materialproviders.ToDafny.CryptographicMaterialsManager( +- nativeValue.materialsManager() +- ) ++ TypeDescriptor.reference(ICryptographicMaterialsManager.class), ++ software.amazon.cryptography.materialproviders.ToDafny.CryptographicMaterialsManager( ++ nativeValue.materialsManager() + ) ++ ) + : Option.create_None( + TypeDescriptor.reference(ICryptographicMaterialsManager.class) + ); +@@ -123,30 +137,30 @@ public class ToDafny { + keyring = + Objects.nonNull(nativeValue.keyring()) + ? Option.create_Some( +- TypeDescriptor.reference(IKeyring.class), +- software.amazon.cryptography.materialproviders.ToDafny.Keyring( +- nativeValue.keyring() +- ) ++ TypeDescriptor.reference(IKeyring.class), ++ software.amazon.cryptography.materialproviders.ToDafny.Keyring( ++ nativeValue.keyring() + ) ++ ) + : Option.create_None(TypeDescriptor.reference(IKeyring.class)); + Option< + DafnyMap< + ? extends DafnySequence, + ? extends DafnySequence +- > +- > encryptionContext; ++ > ++ > encryptionContext; + encryptionContext = + (Objects.nonNull(nativeValue.encryptionContext()) && +- nativeValue.encryptionContext().size() > 0) ++ nativeValue.encryptionContext().size() > 0) + ? Option.create_Some( +- DafnyMap._typeDescriptor( +- DafnySequence._typeDescriptor(TypeDescriptor.BYTE), +- DafnySequence._typeDescriptor(TypeDescriptor.BYTE) +- ), +- software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext( +- nativeValue.encryptionContext() +- ) ++ DafnyMap._typeDescriptor( ++ DafnySequence._typeDescriptor(TypeDescriptor.BYTE), ++ DafnySequence._typeDescriptor(TypeDescriptor.BYTE) ++ ), ++ software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext( ++ nativeValue.encryptionContext() + ) ++ ) + : Option.create_None( + DafnyMap._typeDescriptor( + DafnySequence._typeDescriptor(TypeDescriptor.BYTE), +@@ -172,7 +186,7 @@ public class ToDafny { + DafnyMap< + ? extends DafnySequence, + ? extends DafnySequence +- > encryptionContext; ++ > encryptionContext; + encryptionContext = + software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext( + nativeValue.encryptionContext() +@@ -197,20 +211,20 @@ public class ToDafny { + DafnyMap< + ? extends DafnySequence, + ? extends DafnySequence +- > +- > encryptionContext; ++ > ++ > encryptionContext; + encryptionContext = + (Objects.nonNull(nativeValue.encryptionContext()) && +- nativeValue.encryptionContext().size() > 0) ++ nativeValue.encryptionContext().size() > 0) + ? Option.create_Some( +- DafnyMap._typeDescriptor( +- DafnySequence._typeDescriptor(TypeDescriptor.BYTE), +- DafnySequence._typeDescriptor(TypeDescriptor.BYTE) +- ), +- software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext( +- nativeValue.encryptionContext() +- ) ++ DafnyMap._typeDescriptor( ++ DafnySequence._typeDescriptor(TypeDescriptor.BYTE), ++ DafnySequence._typeDescriptor(TypeDescriptor.BYTE) ++ ), ++ software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext( ++ nativeValue.encryptionContext() + ) ++ ) + : Option.create_None( + DafnyMap._typeDescriptor( + DafnySequence._typeDescriptor(TypeDescriptor.BYTE), +@@ -221,11 +235,11 @@ public class ToDafny { + materialsManager = + Objects.nonNull(nativeValue.materialsManager()) + ? Option.create_Some( +- TypeDescriptor.reference(ICryptographicMaterialsManager.class), +- software.amazon.cryptography.materialproviders.ToDafny.CryptographicMaterialsManager( +- nativeValue.materialsManager() +- ) ++ TypeDescriptor.reference(ICryptographicMaterialsManager.class), ++ software.amazon.cryptography.materialproviders.ToDafny.CryptographicMaterialsManager( ++ nativeValue.materialsManager() + ) ++ ) + : Option.create_None( + TypeDescriptor.reference(ICryptographicMaterialsManager.class) + ); +@@ -233,21 +247,21 @@ public class ToDafny { + keyring = + Objects.nonNull(nativeValue.keyring()) + ? Option.create_Some( +- TypeDescriptor.reference(IKeyring.class), +- software.amazon.cryptography.materialproviders.ToDafny.Keyring( +- nativeValue.keyring() +- ) ++ TypeDescriptor.reference(IKeyring.class), ++ software.amazon.cryptography.materialproviders.ToDafny.Keyring( ++ nativeValue.keyring() + ) ++ ) + : Option.create_None(TypeDescriptor.reference(IKeyring.class)); + Option algorithmSuiteId; + algorithmSuiteId = + Objects.nonNull(nativeValue.algorithmSuiteId()) + ? Option.create_Some( +- ESDKAlgorithmSuiteId._typeDescriptor(), +- software.amazon.cryptography.materialproviders.ToDafny.ESDKAlgorithmSuiteId( +- nativeValue.algorithmSuiteId() +- ) ++ ESDKAlgorithmSuiteId._typeDescriptor(), ++ software.amazon.cryptography.materialproviders.ToDafny.ESDKAlgorithmSuiteId( ++ nativeValue.algorithmSuiteId() + ) ++ ) + : Option.create_None(ESDKAlgorithmSuiteId._typeDescriptor()); + Option frameLength; + frameLength = +@@ -275,7 +289,7 @@ public class ToDafny { + DafnyMap< + ? extends DafnySequence, + ? extends DafnySequence +- > encryptionContext; ++ > encryptionContext; + encryptionContext = + software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext( + nativeValue.encryptionContext() +@@ -302,21 +316,21 @@ public class ToDafny { + ) { + switch (nativeValue) { + case FORBID_RETRY: +- { +- return NetV4__0__0__RetryPolicy.create_FORBID__RETRY(); +- } ++ { ++ return NetV4__0__0__RetryPolicy.create_FORBID__RETRY(); ++ } + case ALLOW_RETRY: +- { +- return NetV4__0__0__RetryPolicy.create_ALLOW__RETRY(); +- } ++ { ++ return NetV4__0__0__RetryPolicy.create_ALLOW__RETRY(); ++ } + default: +- { +- throw new RuntimeException( +- "Cannot convert " + ++ { ++ throw new RuntimeException( ++ "Cannot convert " + + nativeValue + + " to software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4__0__0__RetryPolicy." +- ); +- } ++ ); ++ } + } + } + +diff --git a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/EncryptInput.java b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/EncryptInput.java +index 67ac1304..7282539c 100644 +--- a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/EncryptInput.java ++++ b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/EncryptInput.java +@@ -192,7 +192,7 @@ public class EncryptInput { + "`frameLength` must be greater than or equal to 1" + ); + } +- if (this._frameLengthSet && this.frameLength() > 4294967296) { ++ if (this._frameLengthSet && this.frameLength() > 4294967296L) { + throw new IllegalArgumentException( + "`frameLength` must be less than or equal to 4294967296." + ); +diff --git a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/OpaqueError.java b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/OpaqueError.java +index c24a0e9e..2fb2fd63 100644 +--- a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/OpaqueError.java ++++ b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/OpaqueError.java +@@ -10,8 +10,14 @@ public class OpaqueError extends RuntimeException { + */ + private final Object obj; + ++ /** ++ * A best effort text representation of obj. ++ */ ++ private final String altText; ++ + protected OpaqueError(BuilderImpl builder) { + super(messageFromBuilder(builder), builder.cause()); ++ this.altText = builder.altText(); + this.obj = builder.obj(); + } + +@@ -46,6 +52,13 @@ public class OpaqueError extends RuntimeException { + return this.obj; + } + ++ /** ++ * @return A best effort text representation of obj. ++ */ ++ public String altText() { ++ return this.altText; ++ } ++ + public Builder toBuilder() { + return new BuilderImpl(this); + } +@@ -85,6 +98,16 @@ public class OpaqueError extends RuntimeException { + */ + Object obj(); + ++ /** ++ * @param altText A best effort text representation of obj. ++ */ ++ Builder altText(String altText); ++ ++ /** ++ * @return A best effort text representation of obj. ++ */ ++ String altText(); ++ + OpaqueError build(); + } + +@@ -96,6 +119,8 @@ public class OpaqueError extends RuntimeException { + + protected Object obj; + ++ protected String altText; ++ + protected BuilderImpl() {} + + protected BuilderImpl(OpaqueError model) { +@@ -131,6 +156,15 @@ public class OpaqueError extends RuntimeException { + return this.obj; + } + ++ public Builder altText(String altText) { ++ this.altText = altText; ++ return this; ++ } ++ ++ public String altText() { ++ return this.altText; ++ } ++ + public OpaqueError build() { + if ( + this.obj != null && this.cause == null && this.obj instanceof Throwable diff --git a/AwsEncryptionSDK/dafny/AwsEncryptionSdk/Model/AwsCryptographyEncryptionSdkTypes.dfy b/AwsEncryptionSDK/dafny/AwsEncryptionSdk/Model/AwsCryptographyEncryptionSdkTypes.dfy index eb23dbb55..ec102ba62 100644 --- a/AwsEncryptionSDK/dafny/AwsEncryptionSdk/Model/AwsCryptographyEncryptionSdkTypes.dfy +++ b/AwsEncryptionSDK/dafny/AwsEncryptionSdk/Model/AwsCryptographyEncryptionSdkTypes.dfy @@ -175,7 +175,7 @@ module {:extern "software.amazon.cryptography.encryptionsdk.internaldafny.types" // || (!exit(A(I)) && !access(B(I))) | CollectionOfErrors(list: seq, nameonly message: string) // The Opaque error, used for native, extern, wrapped or unknown errors - | Opaque(obj: object) + | Opaque(obj: object, alt_text : string) type OpaqueError = e: Error | e.Opaque? witness * } abstract module AbstractAwsCryptographyEncryptionSdkService diff --git a/AwsEncryptionSDK/project.properties b/AwsEncryptionSDK/project.properties index 02e193a7d..f5e8cdf0b 100644 --- a/AwsEncryptionSDK/project.properties +++ b/AwsEncryptionSDK/project.properties @@ -1,4 +1,4 @@ # This file stores the top level dafny version information. # All elements of the project need to agree on this version. -dafnyVersion=4.8.0 -dafnyRuntimeJavaVersion=4.8.0 +dafnyVersion=4.8.1 +dafnyRuntimeJavaVersion=4.8.1 diff --git a/AwsEncryptionSDK/runtimes/java/build.gradle.kts b/AwsEncryptionSDK/runtimes/java/build.gradle.kts index b3ee86fd0..cba6f6d5c 100644 --- a/AwsEncryptionSDK/runtimes/java/build.gradle.kts +++ b/AwsEncryptionSDK/runtimes/java/build.gradle.kts @@ -13,22 +13,26 @@ import java.util.Properties plugins { // Apply the java-library plugin for API and implementation separation. `java-library` + `maven-publish` } var props = Properties().apply { load(FileInputStream(File(rootProject.rootDir, "../../project.properties"))) } -var dafnyVersion = props.getProperty("dafnyVersion") +group = "software.amazon.cryptography" +version = "1.0.0-SNAPSHOT" +description = "AwsEncryptionSdk" repositories { // Use Maven Central for resolving dependencies. mavenCentral() + mavenLocal() } dependencies { - implementation("org.dafny:DafnyRuntime:${dafnyVersion}") + implementation("org.dafny:DafnyRuntime:4.8.0") implementation("software.amazon.smithy.dafny:conversion:0.1") - implementation("software.amazon.cryptography:aws-cryptographic-material-providers:1.4.0") + implementation("software.amazon.cryptography:aws-cryptographic-material-providers:1.7.0") // Use JUnit test framework. testImplementation("junit:junit:4.13.2") @@ -63,3 +67,15 @@ fun SourceDirectorySet.mainSourceSet() { srcDir("src/main/dafny-generated") srcDir("src/main/smithy-generated") } + +publishing { + publications.create("mavenLocal") { + groupId = "software.amazon.cryptography" + artifactId = "aws-encryption-sdk" + from(components["java"]) + } + repositories { + mavenLocal() + } +} + diff --git a/AwsEncryptionSDK/runtimes/java/src/main/java/software/amazon/cryptography/encryptionsdk/internaldafny/types/__default.java b/AwsEncryptionSDK/runtimes/java/src/main/java/software/amazon/cryptography/encryptionsdk/internaldafny/types/__default.java new file mode 100644 index 000000000..c9efdd237 --- /dev/null +++ b/AwsEncryptionSDK/runtimes/java/src/main/java/software/amazon/cryptography/encryptionsdk/internaldafny/types/__default.java @@ -0,0 +1,4 @@ +package software.amazon.cryptography.encryptionsdk.internaldafny.types; + +public class __default extends software.amazon.cryptography.encryptionsdk.internaldafny.types._ExternBase___default { +} diff --git a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/ToDafny.java b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/ToDafny.java index 537dafc94..e83bfcf9f 100644 --- a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/ToDafny.java +++ b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/ToDafny.java @@ -6,6 +6,7 @@ import Wrappers_Compile.Option; import dafny.DafnyMap; import dafny.DafnySequence; +import dafny.TypeDescriptor; import java.lang.Byte; import java.lang.Character; import java.lang.Long; @@ -41,11 +42,25 @@ public static Error Error(RuntimeException nativeValue) { if (nativeValue instanceof CollectionOfErrors) { return ToDafny.Error((CollectionOfErrors) nativeValue); } - return Error.create_Opaque(nativeValue); + return Error.create_Opaque( + nativeValue, + dafny.DafnySequence.asString( + java.util.Objects.nonNull(nativeValue.getMessage()) + ? nativeValue.getMessage() + : "" + ) + ); } public static Error Error(OpaqueError nativeValue) { - return Error.create_Opaque(nativeValue.obj()); + return Error.create_Opaque( + nativeValue.obj(), + dafny.DafnySequence.asString( + java.util.Objects.nonNull(nativeValue.altText()) + ? nativeValue.altText() + : "" + ) + ); } public static Error Error(CollectionOfErrors nativeValue) { @@ -69,23 +84,28 @@ public static AwsEncryptionSdkConfig AwsEncryptionSdkConfig( commitmentPolicy = Objects.nonNull(nativeValue.commitmentPolicy()) ? Option.create_Some( - software.amazon.cryptography.materialproviders.ToDafny.ESDKCommitmentPolicy( - nativeValue.commitmentPolicy() - ) + ESDKCommitmentPolicy._typeDescriptor(), + software.amazon.cryptography.materialproviders.ToDafny.ESDKCommitmentPolicy( + nativeValue.commitmentPolicy() ) - : Option.create_None(); + ) + : Option.create_None(ESDKCommitmentPolicy._typeDescriptor()); Option maxEncryptedDataKeys; maxEncryptedDataKeys = Objects.nonNull(nativeValue.maxEncryptedDataKeys()) - ? Option.create_Some((nativeValue.maxEncryptedDataKeys())) - : Option.create_None(); + ? Option.create_Some( + TypeDescriptor.LONG, + (nativeValue.maxEncryptedDataKeys()) + ) + : Option.create_None(TypeDescriptor.LONG); Option netV4_0_0_RetryPolicy; netV4_0_0_RetryPolicy = Objects.nonNull(nativeValue.netV4_0_0_RetryPolicy()) ? Option.create_Some( - ToDafny.NetV4_0_0_RetryPolicy(nativeValue.netV4_0_0_RetryPolicy()) - ) - : Option.create_None(); + NetV4__0__0__RetryPolicy._typeDescriptor(), + ToDafny.NetV4_0_0_RetryPolicy(nativeValue.netV4_0_0_RetryPolicy()) + ) + : Option.create_None(NetV4__0__0__RetryPolicy._typeDescriptor()); return new AwsEncryptionSdkConfig( commitmentPolicy, maxEncryptedDataKeys, @@ -105,35 +125,48 @@ public static DecryptInput DecryptInput( materialsManager = Objects.nonNull(nativeValue.materialsManager()) ? Option.create_Some( - software.amazon.cryptography.materialproviders.ToDafny.CryptographicMaterialsManager( - nativeValue.materialsManager() - ) + TypeDescriptor.reference(ICryptographicMaterialsManager.class), + software.amazon.cryptography.materialproviders.ToDafny.CryptographicMaterialsManager( + nativeValue.materialsManager() ) - : Option.create_None(); + ) + : Option.create_None( + TypeDescriptor.reference(ICryptographicMaterialsManager.class) + ); Option keyring; keyring = Objects.nonNull(nativeValue.keyring()) ? Option.create_Some( - software.amazon.cryptography.materialproviders.ToDafny.Keyring( - nativeValue.keyring() - ) + TypeDescriptor.reference(IKeyring.class), + software.amazon.cryptography.materialproviders.ToDafny.Keyring( + nativeValue.keyring() ) - : Option.create_None(); + ) + : Option.create_None(TypeDescriptor.reference(IKeyring.class)); Option< DafnyMap< ? extends DafnySequence, ? extends DafnySequence - > - > encryptionContext; + > + > encryptionContext; encryptionContext = (Objects.nonNull(nativeValue.encryptionContext()) && - nativeValue.encryptionContext().size() > 0) + nativeValue.encryptionContext().size() > 0) ? Option.create_Some( - software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext( - nativeValue.encryptionContext() - ) + DafnyMap._typeDescriptor( + DafnySequence._typeDescriptor(TypeDescriptor.BYTE), + DafnySequence._typeDescriptor(TypeDescriptor.BYTE) + ), + software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext( + nativeValue.encryptionContext() ) - : Option.create_None(); + ) + : Option.create_None( + DafnyMap._typeDescriptor( + DafnySequence._typeDescriptor(TypeDescriptor.BYTE), + DafnySequence._typeDescriptor(TypeDescriptor.BYTE) + ) + ); return new DecryptInput( ciphertext, materialsManager, @@ -153,7 +186,7 @@ public static DecryptOutput DecryptOutput( DafnyMap< ? extends DafnySequence, ? extends DafnySequence - > encryptionContext; + > encryptionContext; encryptionContext = software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext( nativeValue.encryptionContext() @@ -178,49 +211,63 @@ public static EncryptInput EncryptInput( DafnyMap< ? extends DafnySequence, ? extends DafnySequence - > - > encryptionContext; + > + > encryptionContext; encryptionContext = (Objects.nonNull(nativeValue.encryptionContext()) && - nativeValue.encryptionContext().size() > 0) + nativeValue.encryptionContext().size() > 0) ? Option.create_Some( - software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext( - nativeValue.encryptionContext() - ) + DafnyMap._typeDescriptor( + DafnySequence._typeDescriptor(TypeDescriptor.BYTE), + DafnySequence._typeDescriptor(TypeDescriptor.BYTE) + ), + software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext( + nativeValue.encryptionContext() ) - : Option.create_None(); + ) + : Option.create_None( + DafnyMap._typeDescriptor( + DafnySequence._typeDescriptor(TypeDescriptor.BYTE), + DafnySequence._typeDescriptor(TypeDescriptor.BYTE) + ) + ); Option materialsManager; materialsManager = Objects.nonNull(nativeValue.materialsManager()) ? Option.create_Some( - software.amazon.cryptography.materialproviders.ToDafny.CryptographicMaterialsManager( - nativeValue.materialsManager() - ) + TypeDescriptor.reference(ICryptographicMaterialsManager.class), + software.amazon.cryptography.materialproviders.ToDafny.CryptographicMaterialsManager( + nativeValue.materialsManager() ) - : Option.create_None(); + ) + : Option.create_None( + TypeDescriptor.reference(ICryptographicMaterialsManager.class) + ); Option keyring; keyring = Objects.nonNull(nativeValue.keyring()) ? Option.create_Some( - software.amazon.cryptography.materialproviders.ToDafny.Keyring( - nativeValue.keyring() - ) + TypeDescriptor.reference(IKeyring.class), + software.amazon.cryptography.materialproviders.ToDafny.Keyring( + nativeValue.keyring() ) - : Option.create_None(); + ) + : Option.create_None(TypeDescriptor.reference(IKeyring.class)); Option algorithmSuiteId; algorithmSuiteId = Objects.nonNull(nativeValue.algorithmSuiteId()) ? Option.create_Some( - software.amazon.cryptography.materialproviders.ToDafny.ESDKAlgorithmSuiteId( - nativeValue.algorithmSuiteId() - ) + ESDKAlgorithmSuiteId._typeDescriptor(), + software.amazon.cryptography.materialproviders.ToDafny.ESDKAlgorithmSuiteId( + nativeValue.algorithmSuiteId() ) - : Option.create_None(); + ) + : Option.create_None(ESDKAlgorithmSuiteId._typeDescriptor()); Option frameLength; frameLength = Objects.nonNull(nativeValue.frameLength()) - ? Option.create_Some((nativeValue.frameLength())) - : Option.create_None(); + ? Option.create_Some(TypeDescriptor.LONG, (nativeValue.frameLength())) + : Option.create_None(TypeDescriptor.LONG); return new EncryptInput( plaintext, encryptionContext, @@ -242,7 +289,7 @@ public static EncryptOutput EncryptOutput( DafnyMap< ? extends DafnySequence, ? extends DafnySequence - > encryptionContext; + > encryptionContext; encryptionContext = software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext( nativeValue.encryptionContext() @@ -269,21 +316,21 @@ public static NetV4__0__0__RetryPolicy NetV4_0_0_RetryPolicy( ) { switch (nativeValue) { case FORBID_RETRY: - { - return NetV4__0__0__RetryPolicy.create_FORBID__RETRY(); - } + { + return NetV4__0__0__RetryPolicy.create_FORBID__RETRY(); + } case ALLOW_RETRY: - { - return NetV4__0__0__RetryPolicy.create_ALLOW__RETRY(); - } + { + return NetV4__0__0__RetryPolicy.create_ALLOW__RETRY(); + } default: - { - throw new RuntimeException( - "Cannot convert " + + { + throw new RuntimeException( + "Cannot convert " + nativeValue + " to software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4__0__0__RetryPolicy." - ); - } + ); + } } } diff --git a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/EncryptInput.java b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/EncryptInput.java index 67ac13048..7282539c1 100644 --- a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/EncryptInput.java +++ b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/EncryptInput.java @@ -192,7 +192,7 @@ public EncryptInput build() { "`frameLength` must be greater than or equal to 1" ); } - if (this._frameLengthSet && this.frameLength() > 4294967296) { + if (this._frameLengthSet && this.frameLength() > 4294967296L) { throw new IllegalArgumentException( "`frameLength` must be less than or equal to 4294967296." ); diff --git a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/OpaqueError.java b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/OpaqueError.java index c24a0e9ec..2fb2fd638 100644 --- a/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/OpaqueError.java +++ b/AwsEncryptionSDK/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/model/OpaqueError.java @@ -10,8 +10,14 @@ public class OpaqueError extends RuntimeException { */ private final Object obj; + /** + * A best effort text representation of obj. + */ + private final String altText; + protected OpaqueError(BuilderImpl builder) { super(messageFromBuilder(builder), builder.cause()); + this.altText = builder.altText(); this.obj = builder.obj(); } @@ -46,6 +52,13 @@ public Object obj() { return this.obj; } + /** + * @return A best effort text representation of obj. + */ + public String altText() { + return this.altText; + } + public Builder toBuilder() { return new BuilderImpl(this); } @@ -85,6 +98,16 @@ public interface Builder { */ Object obj(); + /** + * @param altText A best effort text representation of obj. + */ + Builder altText(String altText); + + /** + * @return A best effort text representation of obj. + */ + String altText(); + OpaqueError build(); } @@ -96,6 +119,8 @@ static class BuilderImpl implements Builder { protected Object obj; + protected String altText; + protected BuilderImpl() {} protected BuilderImpl(OpaqueError model) { @@ -131,6 +156,15 @@ public Object obj() { return this.obj; } + public Builder altText(String altText) { + this.altText = altText; + return this; + } + + public String altText() { + return this.altText; + } + public OpaqueError build() { if ( this.obj != null && this.cause == null && this.obj instanceof Throwable diff --git a/AwsEncryptionSDK/runtimes/net/Generated/AwsEncryptionSdk/TypeConversion.cs b/AwsEncryptionSDK/runtimes/net/Generated/AwsEncryptionSdk/TypeConversion.cs index dc6e24f9d..2c38b09b9 100644 --- a/AwsEncryptionSDK/runtimes/net/Generated/AwsEncryptionSdk/TypeConversion.cs +++ b/AwsEncryptionSDK/runtimes/net/Generated/AwsEncryptionSdk/TypeConversion.cs @@ -471,12 +471,12 @@ public static software.amazon.cryptography.encryptionsdk.internaldafny.types._IE ); // OpaqueError is redundant, but listed for completeness. case OpaqueError exception: - return new software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_Opaque(exception); + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_Opaque(exception, Dafny.Sequence.FromString(exception.ToString())); case System.Exception exception: - return new software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_Opaque(exception); + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_Opaque(exception, Dafny.Sequence.FromString(exception.ToString())); default: // The switch MUST be complete for System.Exception, so `value` MUST NOT be an System.Exception. (How did you get here?) - return new software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_Opaque(value); + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_Opaque(value, Dafny.Sequence.FromString(value.ToString())); } } } diff --git a/SharedMakefileV2.mk b/SharedMakefileV2.mk index dfcb53329..5c22396f6 100644 --- a/SharedMakefileV2.mk +++ b/SharedMakefileV2.mk @@ -6,7 +6,7 @@ # that are shared by all libraries in this repo. PROJECT_ROOT := $(abspath $(dir $(abspath $(lastword $(MAKEFILE_LIST))))) -SMITHY_DAFNY_ROOT := $(PROJECT_ROOT)/smithy-dafny +SMITHY_DAFNY_ROOT := $(PROJECT_ROOT)/mpl/smithy-dafny GRADLEW := ./runtimes/java/gradlew VERIFY_TIMEOUT := 150 @@ -19,3 +19,6 @@ verify_service:DAFNY_OPTIONS=--allow-warnings --allow-external-contracts transpile_implementation_net: DAFNY_OPTIONS=--allow-warnings --compile-suffix --legacy-module-names --allow-external-contracts transpile_test_net: DAFNY_OPTIONS=--allow-warnings --include-test-runner --compile-suffix --legacy-module-names --allow-external-contracts + +transpile_implementation_java: DAFNY_OPTIONS=--allow-warnings --compile-suffix --legacy-data-constructors --legacy-module-names --allow-external-contracts +transpile_test_java: DAFNY_OPTIONS=--allow-warnings --include-test-runner --compile-suffix --legacy-data-constructors --legacy-module-names --allow-external-contracts diff --git a/TestVectors/.gitignore b/TestVectors/.gitignore new file mode 100644 index 000000000..4db3e5410 --- /dev/null +++ b/TestVectors/.gitignore @@ -0,0 +1,18 @@ +TestResults +ImplementationFromDafny.cs +TestsFromDafny.cs +ImplementationFromDafny-cs.dtr +TestsFromDafny-cs.dtr +**/bin +**/obj +runtimes/java/dafny +runtimes/**/encrypt-manifest.json +runtimes/**/decrypt-manifest.json +runtimes/**/keys.json +runtimes/**/ciphertexts/ +runtimes/**/plaintexts/ + +dafny/TestVectors/test/ciphertexts +dafny/TestVectors/test/plaintexts +dafny/TestVectors/test/test.json +dafny/TestVectors/test/decrypt-manifest.json diff --git a/TestVectors/Makefile b/TestVectors/Makefile new file mode 100644 index 000000000..4ea5a76fe --- /dev/null +++ b/TestVectors/Makefile @@ -0,0 +1,112 @@ +# Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +# SPDX-License-Identifier: Apache-2.0 + +CORES=2 + +include ../SharedMakefileV2.mk + +DIR_STRUCTURE_V2=V2 + +PROJECT_SERVICES := \ + TestVectors \ + +SMITHY_MODEL_ROOT := $(PROJECT_ROOT)/AwsEncryptionSDK/dafny/AwsEncryptionSdk/Model +OUTPUT_LOCAL_SERVICE_TestVectors:= --local-service-test + +SERVICE_NAMESPACE_TestVectors=aws.cryptography.encryptionSdk + +MAX_RESOURCE_COUNT=10000000 +# Order is important +# In java they MUST be built +# in the order they depend on each other +PROJECT_DEPENDENCIES := \ + mpl/AwsCryptographyPrimitives \ + mpl/ComAmazonawsKms \ + mpl/ComAmazonawsDynamodb \ + mpl/AwsCryptographicMaterialProviders \ + mpl/TestVectorsAwsCryptographicMaterialProviders \ + AwsEncryptionSDK \ + +# Since we are packaging projects differently, we cannot make assumptions +# about where the files are located. +# This is here to get unblocked but should be removed once we have migrated packages +# to the new packaging format. +PROJECT_INDEX := \ + mpl/AwsCryptographyPrimitives/src/Index.dfy \ + mpl/ComAmazonawsKms/src/Index.dfy \ + mpl/ComAmazonawsDynamodb/src/Index.dfy \ + mpl/AwsCryptographicMaterialProviders/dafny/AwsCryptographicMaterialProviders/src/Index.dfy \ + mpl/AwsCryptographicMaterialProviders/dafny/AwsCryptographyKeyStore/src/Index.dfy \ + mpl/TestVectorsAwsCryptographicMaterialProviders/dafny/KeyVectors/src/Index.dfy \ + mpl/TestVectorsAwsCryptographicMaterialProviders/dafny/TestVectorsAwsCryptographicMaterialProviders/src/LibraryIndex.dfy \ + AwsEncryptionSDK/dafny/AwsEncryptionSdk/src/Index.dfy \ + +STD_LIBRARY=mpl/StandardLibrary +SMITHY_DEPS=mpl/model + + +# Dependencies for each local service +SERVICE_DEPS_TestVectors := \ + mpl/AwsCryptographyPrimitives \ + mpl/ComAmazonawsKms \ + mpl/ComAmazonawsDynamodb \ + mpl/AwsCryptographicMaterialProviders/dafny/AwsCryptographicMaterialProviders \ + mpl/AwsCryptographicMaterialProviders/dafny/AwsCryptographyKeyStore \ + AwsEncryptionSDK/dafny/AwsEncryptionSdk \ + mpl/TestVectorsAwsCryptographicMaterialProviders/dafny/TestVectorsAwsCryptographicMaterialProviders \ + + +format_net: + pushd runtimes/net && dotnet format && popd + +IMPLEMENTATION_FROM_DAFNY_TV_JAVA_FILE=runtimes/java/src/main/dafny-generated/ImplementationFromDafny.java +IMPLEMENTATION_FROM_DAFNY_TV_JAVA_MPL_MAIN="dafny.Helpers.withHaltHandling(() -> { WrappedMaterialProvidersMain_Compile.__default.__Main(dafny.Helpers.FromMainArguments(args)); } );" +IMPLEMENTATION_FROM_DAFNY_TV_JAVA_ESDK_MAIN="dafny.Helpers.withHaltHandling(() -> { WrappedESDKMain_Compile.__default.Main2(dafny.Helpers.FromMainArguments(args)); } );" + +IMPLEMENTATION_FROM_DAFNY_TV_NET_FILE=runtimes/net/ImplementationFromDafny.cs +IMPLEMENTATION_FROM_DAFNY_TV_NET_MPL_MAIN="Dafny.Helpers.WithHaltHandling(() => WrappedMaterialProvidersMain_Compile.__default._Main(Dafny.Sequence>.FromMainArguments(args)));" +IMPLEMENTATION_FROM_DAFNY_TV_NET_ESDK_MAIN="Dafny.Helpers.WithHaltHandling(() => WrappedESDKMain_Compile.__default.Main2(Dafny.Sequence>.FromMainArguments(args)));" + +transpile_implementation_java: _replace_main_method_name_java +transpile_implementation_net: _replace_main_method_name_net + +_replace_main_method_name_java: + $(MAKE) _sed_file SED_FILE_PATH=$(IMPLEMENTATION_FROM_DAFNY_TV_JAVA_FILE) SED_BEFORE_STRING=$(IMPLEMENTATION_FROM_DAFNY_TV_JAVA_MPL_MAIN) SED_AFTER_STRING=$(IMPLEMENTATION_FROM_DAFNY_TV_JAVA_ESDK_MAIN) + +_replace_main_method_name_net: + $(MAKE) _sed_file SED_FILE_PATH=$(IMPLEMENTATION_FROM_DAFNY_TV_NET_FILE) SED_BEFORE_STRING=$(IMPLEMENTATION_FROM_DAFNY_TV_NET_MPL_MAIN) SED_AFTER_STRING=$(IMPLEMENTATION_FROM_DAFNY_TV_NET_ESDK_MAIN) + + +# Commands to generate and test test vectors +test_generate_vectors_java: + gradle -p runtimes/java run --args="encrypt-manifest --encrypt-manifest-output ." + gradle -p runtimes/java copyKeysJSONCurr + +test_generate_vectors_net: FRAMEWORK=net6.0 +test_generate_vectors_net: + dotnet restore runtimes/net + dotnet build runtimes/net + dotnet run --project runtimes/net --framework $(FRAMEWORK) encrypt-manifest --encrypt-manifest-output runtimes/net + cp dafny/TestVectors/test/keys.json runtimes/net + +test_encrypt_vectors_java: + gradle -p runtimes/java run --args="encrypt --manifest-path . --decrypt-manifest-path ." + +test_encrypt_vectors_net: FRAMEWORK=net6.0 +test_encrypt_vectors_net: + dotnet restore runtimes/net + dotnet build runtimes/net + dotnet run --project runtimes/net --framework $(FRAMEWORK) encrypt --manifest-path runtimes/net --decrypt-manifest-path runtimes/net + +test_decrypt_encrypt_vectors_java: + gradle -p runtimes/java run --args="decrypt --manifest-path ." + +test_decrypt_encrypt_vectors_net: FRAMEWORK=net6.0 +test_decrypt_encrypt_vectors_net: + dotnet restore runtimes/net + dotnet build runtimes/net + dotnet run --project runtimes/net --framework $(FRAMEWORK) decrypt --manifest-path runtimes/net + +_polymorph_dependencies: + @echo "No polymorphing of dependency" + diff --git a/TestVectors/README.md b/TestVectors/README.md new file mode 100644 index 000000000..001e41e58 --- /dev/null +++ b/TestVectors/README.md @@ -0,0 +1,31 @@ +# AWS Encryption SDK Test Vectors + +This project contains code encrypts and decrypts a suite unstructured data. +This validates the Encryption SDK's cross compatability between major versions +of the Encryption SDK and runtimes. + +## Getting Started + +### Development Requirements + +* Dafny 4.2.0: https://github.com/dafny-lang/dafny + + The code that executes the test vectors is written in Dafny. + You must install the Dafny runtime to compile the Dafny tests into Java. +* A .NET 6.0 TargetFramework or newer development environment + +### Building and Running + +1. Start in the root `./TestVectors` directory +2. Run `make transpile_net` +3. Run `make test_net_mac_intel` if running on a MacOS environment or +`make test_net` if running on a Windows or Linux environment. + +## Security + +See [CONTRIBUTING](CONTRIBUTING.md#security-issue-notifications) for more information. + +## License + +This project is licensed under the Apache-2.0 License. + diff --git a/TestVectors/aws-encryption-sdk-test-vectors b/TestVectors/aws-encryption-sdk-test-vectors new file mode 160000 index 000000000..b6a6c91e6 --- /dev/null +++ b/TestVectors/aws-encryption-sdk-test-vectors @@ -0,0 +1 @@ +Subproject commit b6a6c91e62cc67f891b5dc3d11b0f047d10baf76 diff --git a/TestVectors/codegen-patches/TestVectors/dafny/dafny-4.8.1.patch b/TestVectors/codegen-patches/TestVectors/dafny/dafny-4.8.1.patch new file mode 100644 index 000000000..2fa57313d --- /dev/null +++ b/TestVectors/codegen-patches/TestVectors/dafny/dafny-4.8.1.patch @@ -0,0 +1,15 @@ +diff --git a/TestVectors/dafny/TestVectors/Model/AwsCryptographyEncryptionSdkTypesWrapped.dfy b/TestVectors/dafny/TestVectors/Model/AwsCryptographyEncryptionSdkTypesWrapped.dfy +index 6aafd4df..f50dacb9 100644 +--- a/TestVectors/dafny/TestVectors/Model/AwsCryptographyEncryptionSdkTypesWrapped.dfy ++++ b/TestVectors/dafny/TestVectors/Model/AwsCryptographyEncryptionSdkTypesWrapped.dfy +@@ -2,6 +2,10 @@ + // SPDX-License-Identifier: Apache-2.0 + // Do not modify this file. This file is machine generated, and any changes to it will be overwritten. + include "../../../../mpl/StandardLibrary/src/Index.dfy" ++ // BEGIN MANUAL EDIT ++include "../../../../AwsEncryptionSDK/dafny/AwsEncryptionSdk/src/Index.dfy" ++include "../../../../mpl/TestVectorsAwsCryptographicMaterialProviders/dafny/KeyVectors/src/Index.dfy" ++ // END MANUAL EDIT + include "../src/Index.dfy" + abstract module WrappedAbstractAwsCryptographyEncryptionSdkService { + import opened Wrappers diff --git a/TestVectors/codegen-patches/TestVectors/dotnet/dafny-4.8.1.patch b/TestVectors/codegen-patches/TestVectors/dotnet/dafny-4.8.1.patch new file mode 100644 index 000000000..52f090c48 --- /dev/null +++ b/TestVectors/codegen-patches/TestVectors/dotnet/dafny-4.8.1.patch @@ -0,0 +1,59 @@ +diff --git a/TestVectors/runtimes/net/Generated/TestVectors/TypeConversion.cs b/TestVectors/runtimes/net/Generated/TestVectors/TypeConversion.cs +index c3a4c99f..d647a6ee 100644 +--- a/TestVectors/runtimes/net/Generated/TestVectors/TypeConversion.cs ++++ b/TestVectors/runtimes/net/Generated/TestVectors/TypeConversion.cs +@@ -15,14 +15,14 @@ namespace AWS.Cryptography.EncryptionSDK.Wrapped + { + software.amazon.cryptography.encryptionsdk.internaldafny.types.AwsEncryptionSdkConfig concrete = (software.amazon.cryptography.encryptionsdk.internaldafny.types.AwsEncryptionSdkConfig)value; AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkConfig converted = new AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkConfig(); if (concrete._commitmentPolicy.is_Some) converted.CommitmentPolicy = (AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M16_commitmentPolicy(concrete._commitmentPolicy); + if (concrete._maxEncryptedDataKeys.is_Some) converted.MaxEncryptedDataKeys = (long)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M20_maxEncryptedDataKeys(concrete._maxEncryptedDataKeys); +- if (concrete._netV4_0_0_RetryPolicy.is_Some) converted.NetV4__0__0__RetryPolicy = (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(concrete._netV4_0_0_RetryPolicy); return converted; ++ if (concrete._netV4__0__0__RetryPolicy.is_Some) converted.NetV4_0_0_RetryPolicy = (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(concrete._netV4__0__0__RetryPolicy); return converted; + } + public static software.amazon.cryptography.encryptionsdk.internaldafny.types._IAwsEncryptionSdkConfig ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig(AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkConfig value) + { + value.Validate(); + AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy var_commitmentPolicy = value.IsSetCommitmentPolicy() ? value.CommitmentPolicy : (AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy)null; + long? var_maxEncryptedDataKeys = value.IsSetMaxEncryptedDataKeys() ? value.MaxEncryptedDataKeys : (long?)null; +- AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy var_netV4_0_0_RetryPolicy = value.IsSetNetV4__0__0__RetryPolicy() ? value.NetV4__0__0__RetryPolicy : (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)null; ++ AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy var_netV4_0_0_RetryPolicy = value.IsSetNetV4__0__0__RetryPolicy() ? value.NetV4_0_0_RetryPolicy : (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)null; + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.AwsEncryptionSdkConfig(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M16_commitmentPolicy(var_commitmentPolicy), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M20_maxEncryptedDataKeys(var_maxEncryptedDataKeys), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(var_netV4_0_0_RetryPolicy)); + } + public static AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkException FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException(software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_AwsEncryptionSdkException value) +@@ -96,16 +96,16 @@ namespace AWS.Cryptography.EncryptionSDK.Wrapped + + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.EncryptOutput(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M10_ciphertext(value.Ciphertext), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M17_encryptionContext(value.EncryptionContext), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M16_algorithmSuiteId(value.AlgorithmSuiteId)); + } +- public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(software.amazon.cryptography.encryptionsdk.internaldafny.types._INetV4_0_0_RetryPolicy value) ++ public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(software.amazon.cryptography.encryptionsdk.internaldafny.types._INetV4__0__0__RetryPolicy value) + { + if (value.is_FORBID__RETRY) return AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.FORBID_RETRY; + if (value.is_ALLOW__RETRY) return AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.ALLOW_RETRY; + throw new System.ArgumentException("Invalid AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value"); + } +- public static software.amazon.cryptography.encryptionsdk.internaldafny.types._INetV4_0_0_RetryPolicy ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) ++ public static software.amazon.cryptography.encryptionsdk.internaldafny.types._INetV4__0__0__RetryPolicy ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) + { +- if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.FORBID_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4_0_0_RetryPolicy.create_FORBID__RETRY(); +- if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.ALLOW_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4_0_0_RetryPolicy.create_ALLOW__RETRY(); ++ if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.FORBID_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4__0__0__RetryPolicy.create_FORBID__RETRY(); ++ if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.ALLOW_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4__0__0__RetryPolicy.create_ALLOW__RETRY(); + throw new System.ArgumentException("Invalid AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value"); + } + public static AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M16_commitmentPolicy(Wrappers_Compile._IOption value) +@@ -124,13 +124,13 @@ namespace AWS.Cryptography.EncryptionSDK.Wrapped + { + return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S15_CountingNumbers((long)value)); + } +- public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(Wrappers_Compile._IOption value) ++ public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(Wrappers_Compile._IOption value) + { + return value.is_None ? (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)null : FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(value.Extract()); + } +- public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) ++ public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) + { +- return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy((AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)value)); ++ return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy((AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)value)); + } + public static string FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException__M7_message(Dafny.ISequence value) + { diff --git a/TestVectors/codegen-patches/TestVectors/java/dafny-4.8.1.patch b/TestVectors/codegen-patches/TestVectors/java/dafny-4.8.1.patch new file mode 100644 index 000000000..4f7e09f7b --- /dev/null +++ b/TestVectors/codegen-patches/TestVectors/java/dafny-4.8.1.patch @@ -0,0 +1,169 @@ +diff --git a/TestVectors/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/wrapped/TestESDK.java b/TestVectors/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/wrapped/TestESDK.java +index 1dc9dd24..262bb622 100644 +--- a/TestVectors/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/wrapped/TestESDK.java ++++ b/TestVectors/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/wrapped/TestESDK.java +@@ -4,9 +4,16 @@ + package software.amazon.cryptography.encryptionsdk.wrapped; + + import Wrappers_Compile.Result; ++import com.amazonaws.encryptionsdk.CryptoAlgorithm; ++import com.amazonaws.encryptionsdk.CryptoResult; ++import dafny.DafnyMap; ++import dafny.DafnySequence; + import java.lang.IllegalArgumentException; + import java.lang.RuntimeException; ++import java.nio.ByteBuffer; ++import java.util.Map; + import java.util.Objects; ++import com.amazonaws.encryptionsdk.AwsCrypto; + import software.amazon.cryptography.encryptionsdk.ESDK; + import software.amazon.cryptography.encryptionsdk.ToDafny; + import software.amazon.cryptography.encryptionsdk.ToNative; +@@ -16,10 +23,12 @@ import software.amazon.cryptography.encryptionsdk.internaldafny.types.EncryptInp + import software.amazon.cryptography.encryptionsdk.internaldafny.types.EncryptOutput; + import software.amazon.cryptography.encryptionsdk.internaldafny.types.Error; + import software.amazon.cryptography.encryptionsdk.internaldafny.types.IAwsEncryptionSdkClient; ++import software.amazon.cryptography.materialproviders.internaldafny.types.ESDKAlgorithmSuiteId; ++import software.amazon.smithy.dafny.conversion.ToDafny.Simple; + + public class TestESDK implements IAwsEncryptionSdkClient { + +- private final ESDK _impl; ++ private final AwsCrypto _impl; + + protected TestESDK(BuilderImpl builder) { + this._impl = builder.impl(); +@@ -33,9 +42,30 @@ public class TestESDK implements IAwsEncryptionSdkClient { + try { + software.amazon.cryptography.encryptionsdk.model.DecryptInput nativeInput = + ToNative.DecryptInput(dafnyInput); +- software.amazon.cryptography.encryptionsdk.model.DecryptOutput nativeOutput = +- this._impl.Decrypt(nativeInput); +- DecryptOutput dafnyOutput = ToDafny.DecryptOutput(nativeOutput); ++ final CryptoResult decryptResult; ++ ++ if (Objects.isNull(nativeInput.materialsManager())) { ++ // Call decrypt with keyring ++ if (Objects.isNull(nativeInput.encryptionContext())) { ++ decryptResult = this._impl.decryptData(nativeInput.keyring(), nativeInput.ciphertext().array()); ++ } else { ++ decryptResult = this._impl.decryptData(nativeInput.keyring(), nativeInput.ciphertext().array(), nativeInput.encryptionContext()); ++ } ++ } else { ++ if (Objects.isNull(nativeInput.encryptionContext())) { ++ decryptResult = this._impl.decryptData(nativeInput.materialsManager(), nativeInput.ciphertext().array()); ++ } else { ++ decryptResult = this._impl.decryptData(nativeInput.materialsManager(), nativeInput.ciphertext().array(), nativeInput.encryptionContext()); ++ } ++ } ++ DafnySequence plaintext = Simple.ByteSequence(decryptResult.getResult()); ++ DafnyMap, ? extends DafnySequence> encryptionContext = ++ software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext(decryptResult.getEncryptionContext()); ++ ESDKAlgorithmSuiteId algorithmSuiteId = software.amazon.cryptography.materialproviders.ToDafny.ESDKAlgorithmSuiteId( ++ decryptResult.getCryptoAlgorithm().getAlgorithmSuiteId().ESDK() ++ ); ++ DecryptOutput dafnyOutput = new DecryptOutput(plaintext, encryptionContext, algorithmSuiteId); ++ + return Result.create_Success( + DecryptOutput._typeDescriptor(), + Error._typeDescriptor(), +@@ -54,9 +84,35 @@ public class TestESDK implements IAwsEncryptionSdkClient { + try { + software.amazon.cryptography.encryptionsdk.model.EncryptInput nativeInput = + ToNative.EncryptInput(dafnyInput); +- software.amazon.cryptography.encryptionsdk.model.EncryptOutput nativeOutput = +- this._impl.Encrypt(nativeInput); +- EncryptOutput dafnyOutput = ToDafny.EncryptOutput(nativeOutput); ++ final CryptoResult encryptResult; ++ ++ // Java ESDK is special and you have to set the algorithm suite both in the keyring which the ++ // test vectors do, but also in the client itself. ++ CryptoAlgorithm cryptoAlgorithm = _getAlgorithmSuite(nativeInput.algorithmSuiteId()); ++ this._impl.setEncryptionAlgorithm(cryptoAlgorithm); ++ ++ if (Objects.isNull(nativeInput.materialsManager())) { ++ // Call decrypt with keyring ++ if (Objects.isNull(nativeInput.encryptionContext())) { ++ encryptResult = this._impl.encryptData(nativeInput.keyring(), nativeInput.plaintext().array()); ++ } else { ++ encryptResult = this._impl.encryptData(nativeInput.keyring(), nativeInput.plaintext().array(), nativeInput.encryptionContext()); ++ } ++ } else { ++ if (Objects.isNull(nativeInput.encryptionContext())) { ++ encryptResult = this._impl.encryptData(nativeInput.materialsManager(), nativeInput.plaintext().array()); ++ } else { ++ encryptResult = this._impl.encryptData(nativeInput.materialsManager(), nativeInput.plaintext().array(), nativeInput.encryptionContext()); ++ } ++ } ++ dafny.DafnySequence ciphertext = Simple.ByteSequence(encryptResult.getResult()); ++ DafnyMap, ? extends DafnySequence> encryptionContext = ++ software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext(encryptResult.getEncryptionContext()); ++ ESDKAlgorithmSuiteId algorithmSuiteId = software.amazon.cryptography.materialproviders.ToDafny.ESDKAlgorithmSuiteId( ++ encryptResult.getCryptoAlgorithm().getAlgorithmSuiteId().ESDK() ++ ); ++ ++ EncryptOutput dafnyOutput = new EncryptOutput(ciphertext, encryptionContext, algorithmSuiteId); + return Result.create_Success( + EncryptOutput._typeDescriptor(), + Error._typeDescriptor(), +@@ -71,26 +127,55 @@ public class TestESDK implements IAwsEncryptionSdkClient { + } + } + ++ private CryptoAlgorithm _getAlgorithmSuite(software.amazon.cryptography.materialproviders.model.ESDKAlgorithmSuiteId esdkAlgorithmSuiteId) { ++ switch (esdkAlgorithmSuiteId) { ++ case ALG_AES_128_GCM_IV12_TAG16_NO_KDF: ++ return CryptoAlgorithm.ALG_AES_128_GCM_IV12_TAG16_NO_KDF; ++ case ALG_AES_192_GCM_IV12_TAG16_NO_KDF: ++ return CryptoAlgorithm.ALG_AES_192_GCM_IV12_TAG16_NO_KDF; ++ case ALG_AES_256_GCM_IV12_TAG16_NO_KDF: ++ return CryptoAlgorithm.ALG_AES_256_GCM_IV12_TAG16_NO_KDF; ++ case ALG_AES_128_GCM_IV12_TAG16_HKDF_SHA256: ++ return CryptoAlgorithm.ALG_AES_128_GCM_IV12_TAG16_HKDF_SHA256; ++ case ALG_AES_192_GCM_IV12_TAG16_HKDF_SHA256: ++ return CryptoAlgorithm.ALG_AES_192_GCM_IV12_TAG16_HKDF_SHA256; ++ case ALG_AES_256_GCM_IV12_TAG16_HKDF_SHA256: ++ return CryptoAlgorithm.ALG_AES_256_GCM_IV12_TAG16_HKDF_SHA256; ++ case ALG_AES_128_GCM_IV12_TAG16_HKDF_SHA256_ECDSA_P256: ++ return CryptoAlgorithm.ALG_AES_128_GCM_IV12_TAG16_HKDF_SHA256_ECDSA_P256; ++ case ALG_AES_192_GCM_IV12_TAG16_HKDF_SHA384_ECDSA_P384: ++ return CryptoAlgorithm.ALG_AES_192_GCM_IV12_TAG16_HKDF_SHA384_ECDSA_P384; ++ case ALG_AES_256_GCM_IV12_TAG16_HKDF_SHA384_ECDSA_P384: ++ return CryptoAlgorithm.ALG_AES_256_GCM_IV12_TAG16_HKDF_SHA384_ECDSA_P384; ++ case ALG_AES_256_GCM_HKDF_SHA512_COMMIT_KEY: ++ return CryptoAlgorithm.ALG_AES_256_GCM_HKDF_SHA512_COMMIT_KEY; ++ case ALG_AES_256_GCM_HKDF_SHA512_COMMIT_KEY_ECDSA_P384: ++ return CryptoAlgorithm.ALG_AES_256_GCM_HKDF_SHA512_COMMIT_KEY_ECDSA_P384; ++ default: ++ throw new IllegalArgumentException("Unrecognized ESDK algorithmSuiteId: " + esdkAlgorithmSuiteId); ++ } ++ } ++ + public interface Builder { +- Builder impl(ESDK impl); ++ Builder impl(AwsCrypto impl); + +- ESDK impl(); ++ AwsCrypto impl(); + + TestESDK build(); + } + + static class BuilderImpl implements Builder { + +- protected ESDK impl; ++ protected AwsCrypto impl; + + protected BuilderImpl() {} + +- public Builder impl(ESDK impl) { ++ public Builder impl(AwsCrypto impl) { + this.impl = impl; + return this; + } + +- public ESDK impl() { ++ public AwsCrypto impl() { + return this.impl; + } + diff --git a/TestVectors/codegen-patches/dotnet/dafny-4.2.0.patch b/TestVectors/codegen-patches/dotnet/dafny-4.2.0.patch new file mode 100644 index 000000000..1486f5479 --- /dev/null +++ b/TestVectors/codegen-patches/dotnet/dafny-4.2.0.patch @@ -0,0 +1,69 @@ +diff --git a/TestVectors/runtimes/net/Generated/ESDK/TypeConversion.cs b/TestVectors/runtimes/net/Generated/ESDK/TypeConversion.cs +index e5036c48..1a4a943c 100644 +--- a/TestVectors/runtimes/net/Generated/ESDK/TypeConversion.cs ++++ b/TestVectors/runtimes/net/Generated/ESDK/TypeConversion.cs +@@ -3,6 +3,9 @@ + // Do not modify this file. This file is machine generated, and any changes to it will be overwritten. + using System.Linq; + using System; ++using software.amazon.cryptography.encryptionsdk.internaldafny.types; ++using Wrappers_Compile; ++ + namespace AWS.Cryptography.EncryptionSDK.Wrapped + { + public static class TypeConversion +@@ -11,14 +14,14 @@ namespace AWS.Cryptography.EncryptionSDK.Wrapped + { + software.amazon.cryptography.encryptionsdk.internaldafny.types.AwsEncryptionSdkConfig concrete = (software.amazon.cryptography.encryptionsdk.internaldafny.types.AwsEncryptionSdkConfig)value; AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkConfig converted = new AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkConfig(); if (concrete._commitmentPolicy.is_Some) converted.CommitmentPolicy = (AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M16_commitmentPolicy(concrete._commitmentPolicy); + if (concrete._maxEncryptedDataKeys.is_Some) converted.MaxEncryptedDataKeys = (long)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M20_maxEncryptedDataKeys(concrete._maxEncryptedDataKeys); +- if (concrete._netV4_0_0_RetryPolicy.is_Some) converted.NetV4__0__0__RetryPolicy = (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(concrete._netV4_0_0_RetryPolicy); return converted; ++ if (concrete._netV4__0__0__RetryPolicy.is_Some) converted.NetV4_0_0_RetryPolicy = (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(concrete._netV4__0__0__RetryPolicy); return converted; + } + public static software.amazon.cryptography.encryptionsdk.internaldafny.types._IAwsEncryptionSdkConfig ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig(AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkConfig value) + { + value.Validate(); + AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy var_commitmentPolicy = value.IsSetCommitmentPolicy() ? value.CommitmentPolicy : (AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy)null; + long? var_maxEncryptedDataKeys = value.IsSetMaxEncryptedDataKeys() ? value.MaxEncryptedDataKeys : (long?)null; +- AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy var_netV4_0_0_RetryPolicy = value.IsSetNetV4__0__0__RetryPolicy() ? value.NetV4__0__0__RetryPolicy : (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)null; ++ AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy var_netV4_0_0_RetryPolicy = value.IsSetNetV4__0__0__RetryPolicy() ? value.NetV4_0_0_RetryPolicy : (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)null; + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.AwsEncryptionSdkConfig(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M16_commitmentPolicy(var_commitmentPolicy), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M20_maxEncryptedDataKeys(var_maxEncryptedDataKeys), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(var_netV4_0_0_RetryPolicy)); + } + public static AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkException FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException(software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_AwsEncryptionSdkException value) +@@ -92,16 +95,16 @@ namespace AWS.Cryptography.EncryptionSDK.Wrapped + + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.EncryptOutput(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M10_ciphertext(value.Ciphertext), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M17_encryptionContext(value.EncryptionContext), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M16_algorithmSuiteId(value.AlgorithmSuiteId)); + } +- public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(software.amazon.cryptography.encryptionsdk.internaldafny.types._INetV4_0_0_RetryPolicy value) ++ public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(_INetV4__0__0__RetryPolicy value) + { + if (value.is_FORBID__RETRY) return AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.FORBID_RETRY; + if (value.is_ALLOW__RETRY) return AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.ALLOW_RETRY; + throw new System.ArgumentException("Invalid AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value"); + } +- public static software.amazon.cryptography.encryptionsdk.internaldafny.types._INetV4_0_0_RetryPolicy ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) ++ public static software.amazon.cryptography.encryptionsdk.internaldafny.types._INetV4__0__0__RetryPolicy ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) + { +- if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.FORBID_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4_0_0_RetryPolicy.create_FORBID__RETRY(); +- if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.ALLOW_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4_0_0_RetryPolicy.create_ALLOW__RETRY(); ++ if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.FORBID_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4__0__0__RetryPolicy.create_FORBID__RETRY(); ++ if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.ALLOW_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4__0__0__RetryPolicy.create_ALLOW__RETRY(); + throw new System.ArgumentException("Invalid AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value"); + } + public static AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M16_commitmentPolicy(Wrappers_Compile._IOption value) +@@ -120,13 +123,13 @@ namespace AWS.Cryptography.EncryptionSDK.Wrapped + { + return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S15_CountingNumbers((long)value)); + } +- public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(Wrappers_Compile._IOption value) ++ public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(_IOption<_INetV4__0__0__RetryPolicy> value) + { + return value.is_None ? (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)null : FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(value.Extract()); + } +- public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) ++ public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) + { +- return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy((AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)value)); ++ return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy((AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)value)); + } + public static string FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException__M7_message(Dafny.ISequence value) + { diff --git a/TestVectors/codegen-patches/dotnet/dafny-4.8.0.patch b/TestVectors/codegen-patches/dotnet/dafny-4.8.0.patch new file mode 100644 index 000000000..2199baf4d --- /dev/null +++ b/TestVectors/codegen-patches/dotnet/dafny-4.8.0.patch @@ -0,0 +1,59 @@ +diff --git a/TestVectors/runtimes/net/Generated/ESDK/TypeConversion.cs b/TestVectors/runtimes/net/Generated/ESDK/TypeConversion.cs +index e5036c48..277c8366 100644 +--- a/TestVectors/runtimes/net/Generated/ESDK/TypeConversion.cs ++++ b/TestVectors/runtimes/net/Generated/ESDK/TypeConversion.cs +@@ -11,14 +11,14 @@ namespace AWS.Cryptography.EncryptionSDK.Wrapped + { + software.amazon.cryptography.encryptionsdk.internaldafny.types.AwsEncryptionSdkConfig concrete = (software.amazon.cryptography.encryptionsdk.internaldafny.types.AwsEncryptionSdkConfig)value; AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkConfig converted = new AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkConfig(); if (concrete._commitmentPolicy.is_Some) converted.CommitmentPolicy = (AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M16_commitmentPolicy(concrete._commitmentPolicy); + if (concrete._maxEncryptedDataKeys.is_Some) converted.MaxEncryptedDataKeys = (long)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M20_maxEncryptedDataKeys(concrete._maxEncryptedDataKeys); +- if (concrete._netV4_0_0_RetryPolicy.is_Some) converted.NetV4__0__0__RetryPolicy = (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(concrete._netV4_0_0_RetryPolicy); return converted; ++ if (concrete._netV4__0__0__RetryPolicy.is_Some) converted.NetV4_0_0_RetryPolicy = (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(concrete._netV4__0__0__RetryPolicy); return converted; + } + public static software.amazon.cryptography.encryptionsdk.internaldafny.types._IAwsEncryptionSdkConfig ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig(AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkConfig value) + { + value.Validate(); + AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy var_commitmentPolicy = value.IsSetCommitmentPolicy() ? value.CommitmentPolicy : (AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy)null; + long? var_maxEncryptedDataKeys = value.IsSetMaxEncryptedDataKeys() ? value.MaxEncryptedDataKeys : (long?)null; +- AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy var_netV4_0_0_RetryPolicy = value.IsSetNetV4__0__0__RetryPolicy() ? value.NetV4__0__0__RetryPolicy : (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)null; ++ AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy var_netV4_0_0_RetryPolicy = value.IsSetNetV4__0__0__RetryPolicy() ? value.NetV4_0_0_RetryPolicy : (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)null; + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.AwsEncryptionSdkConfig(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M16_commitmentPolicy(var_commitmentPolicy), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M20_maxEncryptedDataKeys(var_maxEncryptedDataKeys), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(var_netV4_0_0_RetryPolicy)); + } + public static AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkException FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException(software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_AwsEncryptionSdkException value) +@@ -92,16 +92,16 @@ namespace AWS.Cryptography.EncryptionSDK.Wrapped + + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.EncryptOutput(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M10_ciphertext(value.Ciphertext), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M17_encryptionContext(value.EncryptionContext), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M16_algorithmSuiteId(value.AlgorithmSuiteId)); + } +- public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(software.amazon.cryptography.encryptionsdk.internaldafny.types._INetV4_0_0_RetryPolicy value) ++ public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(software.amazon.cryptography.encryptionsdk.internaldafny.types._INetV4__0__0__RetryPolicy value) + { + if (value.is_FORBID__RETRY) return AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.FORBID_RETRY; + if (value.is_ALLOW__RETRY) return AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.ALLOW_RETRY; + throw new System.ArgumentException("Invalid AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value"); + } +- public static software.amazon.cryptography.encryptionsdk.internaldafny.types._INetV4_0_0_RetryPolicy ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) ++ public static software.amazon.cryptography.encryptionsdk.internaldafny.types._INetV4__0__0__RetryPolicy ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) + { +- if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.FORBID_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4_0_0_RetryPolicy.create_FORBID__RETRY(); +- if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.ALLOW_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4_0_0_RetryPolicy.create_ALLOW__RETRY(); ++ if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.FORBID_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4__0__0__RetryPolicy.create_FORBID__RETRY(); ++ if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.ALLOW_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4__0__0__RetryPolicy.create_ALLOW__RETRY(); + throw new System.ArgumentException("Invalid AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value"); + } + public static AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M16_commitmentPolicy(Wrappers_Compile._IOption value) +@@ -120,13 +120,13 @@ namespace AWS.Cryptography.EncryptionSDK.Wrapped + { + return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S15_CountingNumbers((long)value)); + } +- public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(Wrappers_Compile._IOption value) ++ public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(Wrappers_Compile._IOption value) + { + return value.is_None ? (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)null : FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(value.Extract()); + } +- public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) ++ public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) + { +- return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy((AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)value)); ++ return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy((AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)value)); + } + public static string FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException__M7_message(Dafny.ISequence value) + { diff --git a/TestVectors/dafny/TestVectors/Model/AwsCryptographyEncryptionSdkTypesWrapped.dfy b/TestVectors/dafny/TestVectors/Model/AwsCryptographyEncryptionSdkTypesWrapped.dfy new file mode 100644 index 000000000..f50dacb9f --- /dev/null +++ b/TestVectors/dafny/TestVectors/Model/AwsCryptographyEncryptionSdkTypesWrapped.dfy @@ -0,0 +1,24 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 +// Do not modify this file. This file is machine generated, and any changes to it will be overwritten. +include "../../../../mpl/StandardLibrary/src/Index.dfy" + // BEGIN MANUAL EDIT +include "../../../../AwsEncryptionSDK/dafny/AwsEncryptionSdk/src/Index.dfy" +include "../../../../mpl/TestVectorsAwsCryptographicMaterialProviders/dafny/KeyVectors/src/Index.dfy" + // END MANUAL EDIT +include "../src/Index.dfy" +abstract module WrappedAbstractAwsCryptographyEncryptionSdkService { + import opened Wrappers + import opened StandardLibrary.UInt + import opened UTF8 + import opened Types = AwsCryptographyEncryptionSdkTypes + import WrappedService : AbstractAwsCryptographyEncryptionSdkService + function method WrappedDefaultAwsEncryptionSdkConfig(): AwsEncryptionSdkConfig + method {:extern} WrappedESDK(config: AwsEncryptionSdkConfig := WrappedDefaultAwsEncryptionSdkConfig()) + returns (res: Result) + ensures res.Success? ==> + && fresh(res.value) + && fresh(res.value.Modifies) + && fresh(res.value.History) + && res.value.ValidState() +} diff --git a/TestVectors/dafny/TestVectors/src/EsdkManifestOptions.dfy b/TestVectors/dafny/TestVectors/src/EsdkManifestOptions.dfy new file mode 100644 index 000000000..cb8c8471a --- /dev/null +++ b/TestVectors/dafny/TestVectors/src/EsdkManifestOptions.dfy @@ -0,0 +1,30 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 + +include "LibraryIndex.dfy" + +module {:options "-functionSyntax:4"} EsdkManifestOptions { + import opened Wrappers + + datatype ManifestOptions = + | Decrypt( + nameonly manifestPath: string, + nameonly testName: Option := None + ) + | Encrypt( + nameonly manifestPath: string, + nameonly manifest: string, + nameonly decryptManifestOutput: string, + nameonly testName: Option := None + ) + | DecryptSingle( + nameonly keysPath: string, + nameonly keyDescription: string, + nameonly base64Bytes: string + ) + | EncryptManifest( + nameonly encryptManifestOutput: string, + nameonly version: nat + ) + +} \ No newline at end of file diff --git a/TestVectors/dafny/TestVectors/src/EsdkTestManifests.dfy b/TestVectors/dafny/TestVectors/src/EsdkTestManifests.dfy new file mode 100644 index 000000000..5d7a3901c --- /dev/null +++ b/TestVectors/dafny/TestVectors/src/EsdkTestManifests.dfy @@ -0,0 +1,297 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 + +include "LibraryIndex.dfy" +include "ParseEsdkJsonManifest.dfy" +include "EsdkTestVectors.dfy" + +module {:options "-functionSyntax:4"} EsdkTestManifests { + import Types = AwsCryptographyEncryptionSdkTypes + import mplTypes = AwsCryptographyMaterialProvidersTypes + import opened Wrappers + import TestVectors + import FileIO + import JSON.API + import JSON.Values + import JSON.Errors + import Seq + import BoundedInts + import opened StandardLibrary.UInt + import opened JSONHelpers + import ParseJsonManifests + import ParseEsdkJsonManifest + import KeyVectors + import KeyVectorsTypes = AwsCryptographyMaterialProvidersTestVectorKeysTypes + import AtomicPrimitives + import UTF8 + + import EsdkManifestOptions + import opened EsdkTestVectors + import WriteVectors + + method StartDecryptVectors( + op: EsdkManifestOptions.ManifestOptions + ) + returns (output: Result, string>) + requires op.Decrypt? + requires 0 < |op.manifestPath| + requires Seq.Last(op.manifestPath) == '/' + { + var decryptManifest :- expect GetManifest(op.manifestPath, "decrypt-manifest.json"); + :- Need(decryptManifest.DecryptManifest?, "Not a decrypt manifest"); + + var decryptVectors :- ParseEsdkJsonManifest.BuildDecryptTestVector( + op, + decryptManifest.version, + decryptManifest.keys, + decryptManifest.jsonTests + ); + + output := TestDecrypts(decryptManifest.keys, decryptVectors); + } + + predicate TestDecryptVector?(v: EsdkDecryptTestVector) + { + && v.decryptionMethod.OneShot? + } + + method TestDecrypts( + keys: KeyVectors.KeyVectorsClient, + vectors: seq + ) + returns (manifest: Result, string>) + requires keys.ValidState() + modifies keys.Modifies + ensures keys.ValidState() + { + print "\n=================== Starting ", |vectors|, " Decrypt Tests =================== \n\n"; + + var hasFailure := false; + var skipped := 0; + + for i := 0 to |vectors| + { + var vector := vectors[i]; + if TestDecryptVector?(vector) { + :- Need(vector.algorithmSuiteId.Some?, "Vector without algorithm suite defined."); + var pass := EsdkTestVectors.TestDecrypt(keys, vector); + if !pass { + hasFailure := true; + } + } else { + skipped := skipped + 1; + print "\nSKIP===> ", vector.name, "\n"; + } + + } + print "\n=================== Completed ", |vectors|, " Decrypt Tests =================== \n\n"; + + if 0 < skipped { + print "Skipped: ", skipped, "\n"; + } + + expect !hasFailure; + + manifest := Success([]); + } + + method {:vcs_split_on_every_assert} StartEncryptVectors( + op: EsdkManifestOptions.ManifestOptions + ) + returns (output: Result<(), string>) + requires op.Encrypt? + requires 0 < |op.manifestPath| + { + var encryptManifest :- GetManifest(op.manifestPath, op.manifest); + :- Need(encryptManifest.EncryptManifest?, "Not a encrypt manifest"); + + var encryptVectors :- ParseEsdkJsonManifest.BuildEncryptTestVector( + op, + encryptManifest.version, + encryptManifest.keys, + encryptManifest.jsonTests + ); + + var p :- expect AtomicPrimitives.AtomicPrimitives(); + var plaintext := map[]; + for i := 0 to |encryptManifest.plaintext| + { + var (name, length) := encryptManifest.plaintext[i]; + var data :- expect p.GenerateRandomBytes( + AtomicPrimitives.Types.GenerateRandomBytesInput( + length := length + )); + // Write the plaintext to disk. + print op.decryptManifestOutput + plaintextPathRoot + name, "\n\n"; + var _ :- WriteVectorsFile(op.decryptManifestOutput + plaintextPathRoot + name, data); + plaintext := plaintext + map[ name := data ]; + } + + var encryptTests? := ToEncryptTests(encryptManifest.keys, encryptVectors); + var encryptTests :- encryptTests?.MapFailure((e: KeyVectorsTypes.Error) => var _ := MplVectorPrintErr(e); "Cmm failure"); + var decryptVectors :- TestEncrypts(plaintext, encryptManifest.keys, encryptTests); + + var _ :- WriteVectors.WriteDecryptManifest(op, encryptManifest.keys, decryptVectors); + + output := Success(()); + } + + + predicate TestEncryptVector?(vector: EsdkEncryptTestVector) + { + && (vector.frameLength.Some? ==> Types.IsValid_FrameLength(vector.frameLength.value)) + } + + method ToEncryptTests(keys: KeyVectors.KeyVectorsClient, vectors: seq) + returns (output: Result, KeyVectorsTypes.Error>) + requires keys.ValidState() + modifies keys.Modifies + ensures keys.ValidState() + ensures output.Success? ==> + && forall t <- output.value :: + && t.ValidState() + && fresh(t.cmm.Modifies) && fresh(t.client.Modifies) + { + var encryptTests: seq := []; + for i := 0 to |vectors| + invariant forall t <- encryptTests :: + && t.ValidState() + && fresh(t.cmm.Modifies) && fresh(t.client.Modifies) + { + var test :- EsdkTestVectors.EncryptVectorToEncryptTest(keys, vectors[i]); + encryptTests := encryptTests + [test]; + } + + return Success(encryptTests); + } + + method TestEncrypts( + plaintexts: map>, + keys: KeyVectors.KeyVectorsClient, + tests: seq + ) + returns (manifest: Result, string>) + requires keys.ValidState() + modifies keys.Modifies + ensures keys.ValidState() + requires forall t <- tests :: t.ValidState() + modifies set t <- tests, o | o in t.cmm.Modifies :: o + modifies set t <- tests, o | o in t.client.Modifies :: o + ensures forall t <- tests :: t.ValidState() + { + print "\n=================== Starting ", |tests|, " Encrypt Tests =================== \n\n"; + + var hasFailure := false; + var decryptVectors := []; + var skipped := []; + + for i := 0 to |tests| + invariant forall t <- tests :: + && t.ValidState() + { + var test := tests[i]; + if TestEncryptVector?(test.vector) { + :- Need( + && test.vector.algorithmSuiteId.Some? + && test.vector.algorithmSuiteId.value.id.ESDK?, + "Vector is using an algorithm suite other than ESDK" + ); + var pass :- EsdkTestVectors.TestEncrypt(plaintexts, keys, test); + if !pass.output { + hasFailure := true; + } else if pass.vector.Some? { + decryptVectors := decryptVectors + [pass.vector.value]; + } + } else { + skipped := skipped + [test.vector.name + "\n"]; + print "\nSKIP===> ", test.vector.name, "\n"; + } + } + print "\n=================== Completed ", |tests|, " Encrypt Tests =================== \n\n"; + + expect !hasFailure; + + manifest := Success(decryptVectors); + } + + datatype ManifestData = + | DecryptManifest( + version: nat, + keys: KeyVectors.KeyVectorsClient, + client: Values.JSON, + jsonTests: seq<(string, Values.JSON)> + ) + | EncryptManifest( + version: nat, + keys: KeyVectors.KeyVectorsClient, + plaintext: seq<(string, AtomicPrimitives.Types.PositiveInteger)>, + jsonTests: seq<(string, Values.JSON)> + ) + + method GetManifest( + manifestPath: string, + manifestFileName: string + ) + returns (manifestData: Result) + + ensures manifestData.Success? ==> + && fresh(manifestData.value.keys.Modifies) + && manifestData.value.keys.ValidState() + ensures manifestData.Success? && manifestData.value.DecryptManifest? + ==> + SupportedDecryptVersion?(manifestData.value.version) + ensures manifestData.Success? && manifestData.value.EncryptManifest? + ==> + SupportedEncryptVersion?(manifestData.value.version) + { + var decryptManifestBv :- FileIO.ReadBytesFromFile(manifestPath + manifestFileName); + var decryptManifestBytes := BvToBytes(decryptManifestBv); + var manifestJson :- API.Deserialize(decryptManifestBytes) + .MapFailure(( e: Errors.DeserializationError ) => e.ToString()); + :- Need(manifestJson.Object?, "Not a JSON object"); + + var manifest :- GetObject("manifest", manifestJson.obj); + var version :- GetNat("version", manifest); + var typ :- GetString("type", manifest); + + var keyManifestUri :- GetString("keys", manifestJson.obj); + :- Need("file://" < keyManifestUri, "Unexpected URI prefix"); + var keyManifestPath := manifestPath + keyManifestUri[7..]; + var keys :- expect KeyVectors.KeyVectors(KeyVectorsTypes.KeyVectorsConfig( + keyManifestPath := keyManifestPath + )); + + var jsonTests :- GetObject("tests", manifestJson.obj); + + match typ + case "awses-decrypt" => + :- Need(SupportedDecryptVersion?(version), "Unsupported manifest version"); + var client :- Get("client", manifestJson.obj); + manifestData := Success(DecryptManifest( + version := version, + keys := keys, + client := client, + jsonTests := jsonTests + )); + + case "awses-encrypt" => + :- Need(SupportedEncryptVersion?(version), "Unsupported manifest version"); + var plaintextsJson :- GetObject("plaintexts", manifestJson.obj); + var plaintextsLength :- Seq.MapWithResult( + (obj: (string, Values.JSON)) => + :- Need(obj.1.Number? && 0 < obj.1.num.n <= BoundedInts.INT32_MAX as nat, + "Size is not a natural number."); + Success((obj.0, obj.1.num.n as int32)), + plaintextsJson + ); + manifestData := Success(EncryptManifest( + version := version, + keys := keys, + plaintext := plaintextsLength, + jsonTests := jsonTests + )); + + case _ => + manifestData := Failure("Unsupported manifest type:" + typ); + } +} diff --git a/TestVectors/dafny/TestVectors/src/EsdkTestVectors.dfy b/TestVectors/dafny/TestVectors/src/EsdkTestVectors.dfy new file mode 100644 index 000000000..f04465086 --- /dev/null +++ b/TestVectors/dafny/TestVectors/src/EsdkTestVectors.dfy @@ -0,0 +1,488 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 + +include "LibraryIndex.dfy" + +module {:options "-functionSyntax:4"} EsdkTestVectors { + import Types = AwsCryptographyEncryptionSdkTypes + import mplTypes = AwsCryptographyMaterialProvidersTypes + import WrappedMaterialProviders + import WrappedESDK + + import opened Wrappers + import opened StandardLibrary.UInt + import UTF8 + import FileIO + import UUID + + import opened JSONHelpers + import KeyVectors + import KeyVectorsTypes = AwsCryptographyMaterialProvidersTestVectorKeysTypes + import TestVectors + import AllAlgorithmSuites + + datatype EncryptTest = EncryptTest( + cmm: mplTypes.ICryptographicMaterialsManager, + client: Types.IAwsEncryptionSdkClient, + vector: EsdkEncryptTestVector + ) + { + ghost predicate ValidState() + { + && cmm.ValidState() + && client.ValidState() + && cmm.Modifies !! {client.History} + } + } + + datatype DecryptTest = DecryptTest( + cmm: mplTypes.ICryptographicMaterialsManager, + client: Types.IAwsEncryptionSdkClient, + vector: EsdkDecryptTestVector + ) + { + ghost predicate ValidState() + { + && cmm.ValidState() + && client.ValidState() + && cmm.Modifies !! {client.History} + } + } + + type SupportedGenerateManifestVersion = v: nat | SupportedGenerateManifestVersion?(v) witness 4 + predicate SupportedGenerateManifestVersion?(v: nat) + { + || v == 4 + } + + type SupportedEncryptVersion = v: nat | SupportedEncryptVersion?(v) witness 1 + predicate SupportedEncryptVersion?(v: nat) + { + || v == 1 + || v == 4 + || v == 5 + } + + + datatype EsdkEncryptTestVector = + | PositiveEncryptTestVector( + name: string, + version: SupportedEncryptVersion, + manifestPath: string, + decryptManifestPath: string, + plaintextPath: string, + encryptDescriptions: KeyVectorsTypes.KeyDescription, + decryptDescriptions: KeyVectorsTypes.KeyDescription, + encryptionContext: Option := None, + requiredEncryptionContextKeys: Option := None, + requiredECDescription: Option := None, + commitmentPolicy: mplTypes.ESDKCommitmentPolicy := mplTypes.FORBID_ENCRYPT_ALLOW_DECRYPT, + frameLength: Option, + algorithmSuiteId: Option, + description: string, + maxEncryptedDataKeys: Option := Some(1) + ) + | PositiveEncryptNegativeDecryptTestVector ( + name: string, + version: SupportedEncryptVersion, + manifestPath: string, + decryptManifestPath: string, + plaintextPath: string, + encryptDescriptions: KeyVectorsTypes.KeyDescription, + decryptDescriptions: KeyVectorsTypes.KeyDescription, + encryptionContext: Option := None, + requiredEncryptionContextKeys: Option := None, + requiredECDescription: Option := None, + commitmentPolicy: mplTypes.ESDKCommitmentPolicy := mplTypes.FORBID_ENCRYPT_ALLOW_DECRYPT, + frameLength: Option, + algorithmSuiteId: Option, + decryptErrorDescription: string, + description: string, + maxEncryptedDataKeys: Option := Some(1) + ) + | NegativeEncryptTestVector( + name: string, + version: SupportedEncryptVersion, + manifestPath: string, + plaintextPath: string, + encryptDescriptions: KeyVectorsTypes.KeyDescription, + encryptionContext: Option := None, + requiredEncryptionContextKeys: Option := None, + requiredECDescription: Option := None, + commitmentPolicy: mplTypes.ESDKCommitmentPolicy := mplTypes.FORBID_ENCRYPT_ALLOW_DECRYPT, + frameLength: Option, + algorithmSuiteId: Option, + errorDescription: string, + description: string, + maxEncryptedDataKeys: Option := Some(1) + ) + + type SupportedDecryptVersion = v: nat | SupportedDecryptVersion?(v) witness 1 + predicate SupportedDecryptVersion?(v: nat) + { + || v == 1 + || v == 2 + || v == 3 + } + + datatype EsdkDecryptTestVector = + | PositiveDecryptTestVector( + name: string, + version: SupportedDecryptVersion, + manifestPath: string, + ciphertextPath: string, + plaintextPath: string, + encryptionContext: Option := None, + requiredEncryptionContextKeys: Option := None, + decryptDescriptions: KeyVectorsTypes.KeyDescription, + commitmentPolicy: mplTypes.ESDKCommitmentPolicy := mplTypes.FORBID_ENCRYPT_ALLOW_DECRYPT, + frameLength: Option, + algorithmSuiteId: Option, + description: string, + decryptionMethod: DecryptionMethod + ) + | NegativeDecryptTestVector( + name: string, + version: SupportedDecryptVersion, + manifestPath: string, + ciphertextPath: string, + errorDescription: string, + encryptionContext: Option := None, + requiredEncryptionContextKeys: Option := None, + decryptDescriptions: KeyVectorsTypes.KeyDescription, + commitmentPolicy: mplTypes.ESDKCommitmentPolicy := mplTypes.FORBID_ENCRYPT_ALLOW_DECRYPT, + frameLength: Option, + algorithmSuiteId: Option, + description: string, + decryptionMethod: DecryptionMethod + ) + + datatype DecryptionMethod = + | StreamingUnsignedOnly + | OneShot + + method {:vcs_split_on_every_assert} TestDecrypt( + keys: KeyVectors.KeyVectorsClient, + vector: EsdkDecryptTestVector + ) + returns (output: bool) + requires keys.ValidState() + modifies keys.Modifies + ensures keys.ValidState() + requires vector.algorithmSuiteId.Some? + { + var id := AllAlgorithmSuites.ToHex(vector.algorithmSuiteId.value); + print "\nTEST-DECRYPT===> ", vector.name, "\n", id, " ", vector.description, "\n"; + + // The decrypt test vectors also test initialization + // This is because they were developed when the MPL + // was still part of the ESDK + var test? := DecryptVectorToDecryptTest(keys, vector); + + if test?.Failure? { + print test?.error, "\n", "\nFAILED! <-----------\n"; + return false; + } + + var test := test?.value; + + var ciphertext :- expect ReadVectorsFile(test.vector.manifestPath + test.vector.ciphertextPath); + var plaintext; + if test.vector.PositiveDecryptTestVector? { + plaintext :- expect ReadVectorsFile(test.vector.manifestPath + test.vector.plaintextPath); + } + + var input := Types.DecryptInput( + ciphertext := ciphertext, + encryptionContext := test.vector.encryptionContext, + materialsManager := Some(test.cmm), + keyring := None + ); + + var result := test.client.Decrypt(input); + + output := match test.vector + case PositiveDecryptTestVector(_,_,_,_,_,_,_,_,_,_,_,_,_) + => + && result.Success? + && result.value.plaintext == plaintext + case NegativeDecryptTestVector(_,_,_,_,_,_,_,_,_,_,_,_,_) + => + && result.Failure?; + if !output { + if test.vector.PositiveDecryptTestVector? && result.Failure? { + print result.error, "\n"; + if + && result.error.AwsCryptographyMaterialProviders? + && result.error.AwsCryptographyMaterialProviders.CollectionOfErrors? + { + print "list:", result.error.AwsCryptographyMaterialProviders.list, "\n"; + } + } + print "\nFAILED! <-----------\n"; + } + } + + method DecryptVectorToDecryptTest( + keys: KeyVectors.KeyVectorsClient, + vector: EsdkDecryptTestVector + ) + returns (output: Result) + requires keys.ValidState() + modifies keys.Modifies + ensures keys.ValidState() + + ensures output.Success? + ==> + && output.value.ValidState() + && fresh(output.value.cmm.Modifies - keys.Modifies) + && fresh(output.value.client.Modifies) + { + var cmm :- keys.CreateWrappedTestVectorCmm( + KeyVectorsTypes.TestVectorCmmInput( + keyDescription := vector.decryptDescriptions, + forOperation := KeyVectorsTypes.DECRYPT + )); + + :- Need(vector.algorithmSuiteId.Some?, KeyVectorsTypes.KeyVectorException(message := "Missing AlgorithmSuiteId in test vector")); + var commitmentPolicy := AllAlgorithmSuites.GetCompatibleCommitmentPolicy(vector.algorithmSuiteId.value); + :- Need(commitmentPolicy.ESDK?, KeyVectorsTypes.KeyVectorException(message := "Compatible commitment policy is not for ESDK")); + + var config := WrappedESDK.WrappedAwsEncryptionSdkConfigWithSuppliedCommitment( + commitmentPolicy := commitmentPolicy.ESDK + ); + + var client :- expect WrappedESDK.WrappedESDK(config := config); + + var test := DecryptTest( + cmm := cmm, + client := client, + vector := vector + ); + + output := Success(test); + } + + const plaintextPathRoot := "plaintexts/" + const ciphertextPathPathRoot := "ciphertexts/" + + datatype EncryptTestOutput = EncryptTestOutput( + output: bool, + vector: Option := None + ) + + method {:vcs_split_on_every_assert} TestEncrypt( + plaintexts: map>, + keys: KeyVectors.KeyVectorsClient, + test: EncryptTest + ) + returns (output: Result) + requires keys.ValidState() && test.ValidState() + modifies keys.Modifies + modifies test.cmm.Modifies + modifies test.client.Modifies + ensures keys.ValidState() && test.ValidState() + + requires test.vector.frameLength.Some? ==> Types.IsValid_FrameLength(test.vector.frameLength.value) + requires test.vector.algorithmSuiteId.Some? && test.vector.algorithmSuiteId.value.id.ESDK? + { + var id := AllAlgorithmSuites.ToHex(test.vector.algorithmSuiteId.value); + print "\nTEST-ENCRYPT===> ", test.vector.name, "\n", id, " ", test.vector.description, "\n"; + + // The encrypt test vectors also test initialization + // This is because they were developed when the MPL + // was still part of the ESDK + var vector := test.vector; + + expect test.vector.plaintextPath in plaintexts; + var plaintext := plaintexts[test.vector.plaintextPath]; + var frameLength: Option := vector.frameLength; + + var input := Types.EncryptInput( + plaintext := plaintext, + encryptionContext := test.vector.encryptionContext, + materialsManager := Some(test.cmm), + keyring := None, + frameLength := frameLength, + algorithmSuiteId := Some(test.vector.algorithmSuiteId.value.id.ESDK) + ); + var result := test.client.Encrypt(input); + + if + && result.Success? + && ( + || test.vector.PositiveEncryptTestVector? + || test.vector.PositiveEncryptNegativeDecryptTestVector? + ) + { + var decryptVector :- EncryptTestToDecryptVector(test, result.value); + output := Success(EncryptTestOutput( + vector := Some(decryptVector), + output := true + )); + } else if result.Failure? && test.vector.NegativeEncryptTestVector? { + output := Success(EncryptTestOutput( output := true )); + } else { + output := Success(EncryptTestOutput( output := false )); + if !test.vector.NegativeEncryptTestVector? && result.Failure? { + print result.error; + } + print "\nFAILED! <-----------\n"; + } + } + + method EncryptVectorToEncryptTest( + keys: KeyVectors.KeyVectorsClient, + vector: EsdkEncryptTestVector + ) + returns (output: Result) + requires keys.ValidState() + modifies keys.Modifies + ensures keys.ValidState() + + ensures output.Success? ==> + && output.value.ValidState() + && fresh(output.value.cmm.Modifies) + && fresh(output.value.client.Modifies) + ensures output.Success? + ==> + output.value.vector == vector + { + var cmm :- keys.CreateWrappedTestVectorCmm( + KeyVectorsTypes.TestVectorCmmInput( + keyDescription := if vector.PositiveEncryptTestVector? then + vector.encryptDescriptions + else if vector.PositiveEncryptNegativeDecryptTestVector? then + vector.encryptDescriptions + else + vector.encryptDescriptions, + forOperation := KeyVectorsTypes.ENCRYPT + )); + + :- Need(vector.algorithmSuiteId.Some?, KeyVectorsTypes.KeyVectorException(message := "Missing AlgorithmSuiteId in test vector")); + var commitmentPolicy := AllAlgorithmSuites.GetCompatibleCommitmentPolicy(vector.algorithmSuiteId.value); + :- Need(commitmentPolicy.ESDK?, KeyVectorsTypes.KeyVectorException(message := "Compatible commitment policy is not for ESDK")); + + var config := WrappedESDK.WrappedAwsEncryptionSdkConfigWithSuppliedCommitment( + commitmentPolicy := commitmentPolicy.ESDK + ); + + var client :- expect WrappedESDK.WrappedESDK(config := config); + + var test := EncryptTest( + cmm := cmm, + client := client, + vector := vector + ); + + output := Success(test); + } + + method EncryptTestToDecryptVector( + test: EncryptTest, + result: Types.EncryptOutput + ) returns (output: Result) + requires + || test.vector.PositiveEncryptTestVector? + || test.vector.PositiveEncryptNegativeDecryptTestVector? + requires test.vector.algorithmSuiteId.Some? + { + output := match test.vector + case PositiveEncryptTestVector(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_) => + Success(PositiveDecryptTestVector( + name := test.vector.name, + version := 3, + manifestPath := test.vector.decryptManifestPath, + ciphertextPath := ciphertextPathPathRoot + test.vector.name, + plaintextPath := plaintextPathRoot + test.vector.plaintextPath, + encryptionContext := test.vector.encryptionContext, + requiredEncryptionContextKeys := test.vector.requiredEncryptionContextKeys, + decryptDescriptions := test.vector.decryptDescriptions, + commitmentPolicy := test.vector.commitmentPolicy, + frameLength := test.vector.frameLength, + algorithmSuiteId := test.vector.algorithmSuiteId, + description := test.vector.description, + decryptionMethod := DecryptionMethod.OneShot + )) + case _ => + Failure("Only postive tests supported"); + + var decryptManifestCiphertext := test.vector.decryptManifestPath + ciphertextPathPathRoot + test.vector.name; + // Side effect, to avoid thousands of ciphertext in memory... + var _ :- expect WriteVectorsFile(decryptManifestCiphertext, result.ciphertext); + } + + + function MplPrintErr(e: mplTypes.Error) : (){()} by method {print e, "\n", "\n"; return ();} + function MplVectorPrintErr(e: KeyVectorsTypes.Error) :(){()} by method {print e, "\n", "\n"; return ();} + + method KeyDescriptionToCmm( + keys: KeyVectors.KeyVectorsClient, + keyDescriptions: seq + ) + returns (output: Result) + + requires keys.ValidState() + modifies keys.Modifies + ensures keys.ValidState() + + ensures output.Success? + ==> + && fresh(output.value.Modifies - keys.Modifies) + && output.value.ValidState() + { + var keyringList: seq := []; + for i := 0 to |keyDescriptions| + invariant forall k | k in keyringList :: + && k.ValidState() && fresh(k.Modifies) + invariant forall k | k in keyringList + :: k.Modifies + <= set m: object, k :mplTypes.IKeyring + | + && k in keyringList + && m in k.Modifies + :: m + { + var keyDescription := keyDescriptions[i]; + var keyring :- keys.CreateWrappedTestVectorKeyring( + KeyVectorsTypes.TestVectorKeyringInput( + keyDescription := keyDescription + )); + keyringList := keyringList + [keyring]; + } + + :- Need(|keyringList| == 1, KeyVectorsTypes.KeyVectorException( message := "Failed to create any keyrings" )); + var mpl :- expect WrappedMaterialProviders.WrappedMaterialProviders(); + var generatorKeyring := keyringList[0]; + var maybeMultiKeyring := mpl.CreateMultiKeyring( + mplTypes.CreateMultiKeyringInput( + generator := Some(generatorKeyring), + childKeyrings := keyringList[1..] + ) + ); + + var keyring :- maybeMultiKeyring + .MapFailure(e => KeyVectorsTypes.AwsCryptographyMaterialProviders(e)); + + var maybeCmm := mpl + .CreateDefaultCryptographicMaterialsManager( + mplTypes.CreateDefaultCryptographicMaterialsManagerInput( keyring := maybeMultiKeyring.value ) + ); + output := maybeCmm + .MapFailure(e => KeyVectorsTypes.AwsCryptographyMaterialProviders(e)); + } + + method ReadVectorsFile(location: string) + returns (output: Result, string>) + { + var fileBv :- FileIO.ReadBytesFromFile(location); + output := Success(BvToBytes(fileBv)); + } + + method WriteVectorsFile(location: string, bytes: seq) + returns (output: Result<(), string>) + { + var bv := BytesBv(bytes); + output := FileIO.WriteBytesToFile(location, bv); + } +} \ No newline at end of file diff --git a/TestVectors/dafny/TestVectors/src/Index.dfy b/TestVectors/dafny/TestVectors/src/Index.dfy new file mode 100644 index 000000000..96b31af04 --- /dev/null +++ b/TestVectors/dafny/TestVectors/src/Index.dfy @@ -0,0 +1,150 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 + +include "WriteVectors.dfy" +include "EsdkTestManifests.dfy" +include "EsdkManifestOptions.dfy" + +module {:options "-functionSyntax:4"} WrappedESDKMain { + import opened Wrappers + import WrappedESDK + import WriteVectors + + import EsdkTestManifests + import EsdkManifestOptions + import Seq + import opened GetOpt + + method Main2(args: seq) { + var vectorOptions := Options("test-vectors", "?", + [ + Param.Command(Options("decrypt", "decrypt command for test-vectors", + [ + Param.Opt("manifest-path", "relative path to the location of the manifest", unused := Required), + Param.Opt("test-name", "id of the test to run") + ])), + Param.Command(Options("encrypt", "encrypt command for test-vectors", + [ + Param.Opt("manifest-path", "relative path to the location of the manifest", unused := Required), + Param.Opt("decrypt-manifest-path", "relative path to the location where the decrypted manifest will be written to.", unused := Required), + Param.Opt("test-name", "id of the test to run") + ])), + Param.Command(Options("encrypt-manifest", "encryp manifest command for test-vectors", + [ + Param.Opt("encrypt-manifest-output", "relative path of where to store the encrypt-manifest produced", unused := Required) + ])) + ]); + // The expectation is that the first argument + // is the filename or runtime + expect 0 < |args|; + var parsedOptions? := GetOptions(vectorOptions, args); + + if parsedOptions?.Success? { + var h := NeedsHelp(vectorOptions, parsedOptions?.value); + if h.Some? { + print h.value; + return; + } + var op? := ParseCommandLineOptions(parsedOptions?.value); + + if op?.Success? { + var op := op?.value; + match op + case Decrypt(_, _) => + var result := EsdkTestManifests.StartDecryptVectors(op); + if result.Failure? { + print result.error; + } + expect result.Success?; + case Encrypt(_, _, _, _) => + var result := EsdkTestManifests.StartEncryptVectors(op); + if result.Failure? { + print result.error; + } + expect result.Success?; + case EncryptManifest(_, _) => + var result := WriteVectors.WritetestVectors(op); + if result.Failure? { + print result.error; + } + expect result.Success?; + } else { + print op?.error + "\n"; + print "help\n"; + } + } else { + print parsedOptions?.error + "\n"; + } + + } + + function ParseCommandLineOptions(parsedOptions: Parsed) + : (output: Result) + { + :- Need(parsedOptions.subcommand.Some?, "Must supply subcommand\n"); + + match parsedOptions.subcommand.value.command + case "decrypt" => ParseDecryptCmd(parsedOptions.subcommand.value.params) + case "encrypt" => ParseEncryptCmd(parsedOptions.subcommand.value.params) + case "encrypt-manifest" => ParseEncryptManifestCmd(parsedOptions.subcommand.value.params) + // GetOpt GetOptions actually takes care of this for us but Dafny doesn't know so we must have default case. + case _ => Failure("Received unknown subcommand") + } + + function ParseDecryptCmd(params: seq) + : (output: Result) + ensures output.Success? ==> output.value.Decrypt? + { + var manifestPath? := OptValue(params, "manifest-path"); + var testName? := OptValue(params, "test-name"); + + var manifestPath := if manifestPath?.Some? then manifestPath?.value else "."; + :- Need(0 < |manifestPath|, "Invalid manifest path length\n"); + + Success(EsdkManifestOptions.Decrypt( + manifestPath := if Seq.Last(manifestPath) == '/' then manifestPath else manifestPath + "/", + testName := if testName?.Some? then testName? else None + )) + } + + function ParseEncryptCmd(params: seq) + : (output: Result) + ensures output.Success? ==> output.value.Encrypt? + { + var manifestPath? := OptValue(params, "manifest-path"); + var manifestName? := OptValue(params, "manifest"); + var decryptManifestPath? := OptValue(params, "decrypt-manifest-path"); + var testName? := OptValue(params, "test-name"); + + var manifestPath := if manifestPath?.Some? then manifestPath?.value else "."; + var manifestName := if manifestName?.Some? then manifestName?.value else "encrypt-manifest.json"; + var decryptManifestPath := if decryptManifestPath?.Some? then decryptManifestPath?.value else "."; + :- Need( + && 0 < |manifestPath| + && 0 < |decryptManifestPath|, + "Invalid manifest or decrypt manifest path length\n" + ); + + Success(EsdkManifestOptions.Encrypt( + manifestPath := if Seq.Last(manifestPath) == '/' then manifestPath else manifestPath + "/", + manifest := manifestName, + decryptManifestOutput := if Seq.Last(decryptManifestPath) == '/' then decryptManifestPath else decryptManifestPath + "/", + testName := if testName?.Some? then testName? else None + )) + } + + function ParseEncryptManifestCmd(params: seq) + : (output: Result) + ensures output.Success? ==> output.value.EncryptManifest? + { + var encryptManifestOutput? := OptValue(params, "encrypt-manifest-output"); + var encryptManifestOutput := if encryptManifestOutput?.Some? then encryptManifestOutput?.value else "."; + :- Need(0 < |encryptManifestOutput|, "Invalid encrypt manifest output length"); + + Success(EsdkManifestOptions.EncryptManifest( + encryptManifestOutput := if Seq.Last(encryptManifestOutput) == '/' then encryptManifestOutput else encryptManifestOutput + "/", + version := 5 + )) + } + +} \ No newline at end of file diff --git a/TestVectors/dafny/TestVectors/src/LibraryIndex.dfy b/TestVectors/dafny/TestVectors/src/LibraryIndex.dfy new file mode 100644 index 000000000..5a1da5c96 --- /dev/null +++ b/TestVectors/dafny/TestVectors/src/LibraryIndex.dfy @@ -0,0 +1,43 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 + +include "../Model/AwsCryptographyEncryptionSdkTypesWrapped.dfy" + +module + {:extern "software.amazon.cryptography.encryptionsdk.internaldafny.wrapped" } + WrappedESDK refines WrappedAbstractAwsCryptographyEncryptionSdkService +{ + import WrappedService = EncryptionSdk + + function method WrappedDefaultAwsEncryptionSdkConfig(): AwsEncryptionSdkConfig + { + AwsEncryptionSdkConfig( + commitmentPolicy := Some(AwsCryptographyMaterialProvidersTypes.ESDKCommitmentPolicy.REQUIRE_ENCRYPT_REQUIRE_DECRYPT), + maxEncryptedDataKeys := None, + netV4_0_0_RetryPolicy := None + ) + } + + function method WrappedAwsEncryptionSdkConfigWithSuppliedCommitment( + commitmentPolicy: AwsCryptographyMaterialProvidersTypes.ESDKCommitmentPolicy + ): AwsEncryptionSdkConfig + { + AwsEncryptionSdkConfig( + commitmentPolicy := Some(commitmentPolicy), + maxEncryptedDataKeys := None, + netV4_0_0_RetryPolicy := None + ) + } + function method WrappedAwsEncryptionSdkConfig( + commitmentPolicy: AwsCryptographyMaterialProvidersTypes.ESDKCommitmentPolicy, + maxEncryptedDataKeys: CountingNumbers, + netV4_0_0_RetryPolicy: NetV4_0_0_RetryPolicy + ) : AwsEncryptionSdkConfig + { + AwsEncryptionSdkConfig( + commitmentPolicy := Some(commitmentPolicy), + maxEncryptedDataKeys := Some(maxEncryptedDataKeys), + netV4_0_0_RetryPolicy := Some(netV4_0_0_RetryPolicy) + ) + } +} \ No newline at end of file diff --git a/TestVectors/dafny/TestVectors/src/ParseEsdkJsonManifest.dfy b/TestVectors/dafny/TestVectors/src/ParseEsdkJsonManifest.dfy new file mode 100644 index 000000000..57987236b --- /dev/null +++ b/TestVectors/dafny/TestVectors/src/ParseEsdkJsonManifest.dfy @@ -0,0 +1,415 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 + +include "LibraryIndex.dfy" +include "EsdkTestVectors.dfy" + +module {:options "-functionSyntax:4"} ParseEsdkJsonManifest { + import mplTypes = AwsCryptographyMaterialProvidersTypes + import JSON.API + import FileIO + import opened JSON.Values + import JSON.Errors + import opened Wrappers + import UTF8 + import Seq + import opened StandardLibrary.UInt + import BoundedInts + import opened JSONHelpers + import opened TestVectors + import HexStrings + import Base64 + import CompleteVectors + import KeyVectors + import KeyVectorsTypes = AwsCryptographyMaterialProvidersTestVectorKeysTypes + import ParseJsonManifests + import AlgorithmSuites + import opened EsdkTestVectors + import EsdkManifestOptions + + const ciphertextJsonKey := "ciphertext" + const masterKeysJsonKey := "master-keys" + const encryptKeyDescription := "encryptKeyDescription" + const decryptKeyDescription := "decryptKeyDescription" + const decryptionMethodJsonKey := "decryption-method" + const plaintextJsonKey := "plaintext" + const frameSizeJsonKey := "frame-size" + const encryptionContextJsonKey := "encryption-context" + + function BuildDecryptTestVector( + op: EsdkManifestOptions.ManifestOptions, + version: SupportedDecryptVersion, + keys: KeyVectors.KeyVectorsClient, + obj: seq<(string, JSON)> + ) : Result, string> + requires op.Decrypt? + { + if |obj| == 0 then + Success([]) + else + var tail :- BuildDecryptTestVector(op, version, keys, obj[1..]); + var encryptVector :- ToDecryptTestVectors(op, version, keys, obj[0].0, obj[0].1); + Success([ encryptVector ] + tail) + } by method { + // This function ideally would be`{:tailrecursion}` + // but it is not simple to here is a method + // so that it does not explode with huge numbers of tests. + var i: nat := |obj|; + var vectors := []; + + while i != 0 + decreases i + invariant Success(vectors) == BuildDecryptTestVector(op, version, keys, obj[i..]) + { + i := i - 1; + var test := ToDecryptTestVectors(op, version, keys, obj[i].0, obj[i].1); + if test.Failure? { + ghost var j := i; + while j != 0 + decreases j + invariant Failure(test.error) == BuildDecryptTestVector(op, version, keys, obj[j..]) + { + j := j - 1; + } + return Failure(test.error); + } + + vectors := [test.value] + vectors; + } + + return Success(vectors); + } + + + function ToDecryptTestVectors( + op: EsdkManifestOptions.ManifestOptions, + version: SupportedDecryptVersion, + keys: KeyVectors.KeyVectorsClient, + name: string, + json: JSON + ) : Result + requires op.Decrypt? + { + :- Need(json.Object?, "Vector is not an object"); + var obj := json.obj; + + match version + case 3 => V3ToDecryptTestVector(op, keys, name, obj, version) + case _ => Failure("Version not supported") + + // case 1 => + // var plaintextPath :- GetPath(ciphertextJsonKey, obj); + // Success(PositiveDecryptTestVector( + // name := name, + // version := version, + // manifestPath := op.manifestPath, + // plaintextPath := plaintextPath, + // ciphertextPath := ciphertextPath, + // decryptDescriptions := decryptDescriptions, + // decryptionMethod := decryptionMethod + // )) + // case 2 => + // var result :- GetObject("result", obj); + // :- Need(|result| == 1 && Result?(result[0].0), "Unexpected result"); + // match result[0].0 + // case "output" => + // var output :- GetObject("output", result); + // var plaintextPath :- GetPath("plaintext", output); + + // Success(PositiveDecryptTestVector( + // name := name, + // version := version, + // manifestPath := op.manifestPath, + // plaintextPath := plaintextPath, + // ciphertextPath := ciphertextPath, + // decryptDescriptions := decryptDescriptions, + // decryptionMethod := decryptionMethod + // )) + // case "error" => + // var output :- GetObject("error", result); + // var errorDescription :- GetString("error-description", output); + + // Success(NegativeDecryptTestVector( + // name := name, + // version := version, + // manifestPath := op.manifestPath, + // errorDescription := errorDescription, + // ciphertextPath := ciphertextPath, + // decryptDescriptions := decryptDescriptions, + // decryptionMethod := decryptionMethod + // )) + + } + + function BuildEncryptTestVector( + op: EsdkManifestOptions.ManifestOptions, + version: SupportedEncryptVersion, + keys: KeyVectors.KeyVectorsClient, + obj: seq<(string, JSON)> + ) : Result, string> + requires op.Encrypt? + { + if |obj| == 0 then + Success([]) + else + var tail :- BuildEncryptTestVector(op, version, keys, obj[1..]); + var encryptVector :- ToEncryptTestVector(op, version, keys, obj[0].0, obj[0].1); + Success([ encryptVector ] + tail) + } by method { + // This function ideally would be`{:tailrecursion}` + // but it is not simple to here is a method + // so that it does not explode with huge numbers of tests. + var i: nat := |obj|; + var vectors := []; + + while i != 0 + decreases i + invariant Success(vectors) == BuildEncryptTestVector(op, version, keys, obj[i..]) + { + i := i - 1; + var test := ToEncryptTestVector(op, version, keys, obj[i].0, obj[i].1); + if test.Failure? { + ghost var j := i; + while j != 0 + decreases j + invariant Failure(test.error) == BuildEncryptTestVector(op, version, keys, obj[j..]) + { + j := j - 1; + } + return Failure(test.error); + } + + vectors := [test.value] + vectors; + } + + return Success(vectors); + } + + + function ToEncryptTestVector( + op: EsdkManifestOptions.ManifestOptions, + version: SupportedEncryptVersion, + keys: KeyVectors.KeyVectorsClient, + name: string, + json: JSON + ) : Result + requires op.Encrypt? + { + :- Need(json.Object?, "EncryptTestVector not an object"); + var obj := json.obj; + + match version + // case 1 => V1ToEncryptTestVector(op, keys, name, obj) + case 5 => V5ToEncryptTestVector(op, keys, name, obj, version) + case _ => Failure("Version not supported") + } + + // function V1ToEncryptTestVector( + // op: EsdkManifestOptions.ManifestOptions, + // keys: KeyVectors.KeyVectorsClient, + // name: string, + // obj: seq<(string, JSON)> + // ) : Result + // requires op.Encrypt? + // { + // var plaintextLoc :- GetString(plaintextJsonKey, obj); + // var algorithmSuite :- ParseJsonManifests.GetAlgorithmSuiteInfo(obj); + // :- Need(algorithmSuite.id.ESDK?, "Unsupported algorithmSuite"); + // var frameLength :- GetOptionalPositiveLong(frameSizeJsonKey, obj); + // var encryptionContext :- SmallObjectToStringStringMap(encryptionContextJsonKey, obj); + // var masterKeyArray :- GetArray(masterKeysJsonKey, obj); + // var keyDescriptions :- GetKeyDescriptions(masterKeyArray, keys); + + // Success(PositiveEncryptTestVector( + // name := name, + // version := 1, + // manifestPath := op.manifestPath, + // decryptManifestPath := op.decryptManifestOutput, + // plaintextPath := plaintextLoc, + // encryptDescriptions := keyDescriptions, + // decryptDescriptions := keyDescriptions, + // frameLength := frameLength, + // algorithmSuiteId := Some(algorithmSuite) + // )) + // } + + function V5ToEncryptTestVector( + op: EsdkManifestOptions.ManifestOptions, + keys: KeyVectors.KeyVectorsClient, + name: string, + obj: seq<(string, JSON)>, + version: SupportedEncryptVersion + ) : Result + requires op.Encrypt? + { + var scenarioString := "encryption-scenario"; + var scenario :- GetObject(scenarioString, obj); + + var typeString := "type"; + var typ :- GetString(typeString, scenario); + + var plaintextLoc :- GetString(plaintextJsonKey, scenario); + var algorithmSuite :- ParseJsonManifests.GetAlgorithmSuiteInfo(scenario); + :- Need(algorithmSuite.id.ESDK?, "Unsupported algorithmSuiteId"); + var frameLength :- GetOptionalPositiveLong(frameSizeJsonKey, scenario); + + var encryptionContextStrings :- SmallObjectToStringStringMap(encryptionContextJsonKey, scenario); + var encryptionContext :- utf8EncodeMap(encryptionContextStrings); + var description :- GetString("description", scenario); + + match typ + case "positive-esdk" => + var encryptKeyDescription :- ParseJsonManifests.GetKeyDescription(keys, encryptKeyDescription, scenario); + var decryptKeyDescription :- ParseJsonManifests.GetKeyDescription(keys, decryptKeyDescription, scenario); + Success(PositiveEncryptTestVector( + name := name, + version := version, + manifestPath := op.manifestPath, + decryptManifestPath := op.decryptManifestOutput, + plaintextPath := plaintextLoc, + encryptDescriptions := encryptKeyDescription, + decryptDescriptions := decryptKeyDescription, + encryptionContext := Some(encryptionContext), + commitmentPolicy := mplTypes.FORBID_ENCRYPT_ALLOW_DECRYPT, + frameLength := frameLength, + algorithmSuiteId := Some(algorithmSuite), + description := description + )) + case _ => Failure("Unsupported ESDK TestVector type: " + typ) + + } + + function V3ToDecryptTestVector( + op: EsdkManifestOptions.ManifestOptions, + keys: KeyVectors.KeyVectorsClient, + name: string, + obj: seq<(string, JSON)>, + version: SupportedDecryptVersion + ) : Result + requires op.Decrypt? + { + var scenarioString := "decryption-scenario"; + var scenario :- GetObject(scenarioString, obj); + + var typeString := "type"; + var typ :- GetString(typeString, scenario); + + var ciphertextLoc :- GetString(ciphertextJsonKey, scenario); + var algorithmSuite :- ParseJsonManifests.GetAlgorithmSuiteInfo(scenario); + :- Need(algorithmSuite.id.ESDK?, "Unsupported algorithmSuiteId"); + var frameLength :- GetOptionalPositiveLong(frameSizeJsonKey, scenario); + + var encryptionContextStrings :- SmallObjectToStringStringMap(encryptionContextJsonKey, scenario); + var encryptionContext :- utf8EncodeMap(encryptionContextStrings); + var description :- GetString("description", scenario); + var result :- GetString("result", scenario); + :- Need( + && "file://" < ciphertextLoc + && "file://" < result, + "Invalid file prefix in test vector" + ); + + match typ + case "positive-esdk" => + var decryptKeyDescription :- ParseJsonManifests.GetKeyDescription(keys, decryptKeyDescription, scenario); + Success(PositiveDecryptTestVector( + name := name, + version := version, + manifestPath := op.manifestPath, + ciphertextPath := ciphertextLoc[|FILE_PREPEND|..], + plaintextPath := result[|FILE_PREPEND|..], + encryptionContext := Some(encryptionContext), + decryptDescriptions := decryptKeyDescription, + frameLength := frameLength, + algorithmSuiteId := Some(algorithmSuite), + description := description, + decryptionMethod := DecryptionMethod.OneShot + )) + case _ => Failure("Unsupported ESDK TestVector type: " + typ) + } + + function GetKeyDescriptions(keyArray: seq, keys: KeyVectors.KeyVectorsClient) + : Result, string> + { + if |keyArray| == 0 then + Success([]) + else + var currKey := keyArray[0]; + :- Need(currKey.Object?, "Not an object"); + var encryptStr :- API.Serialize(currKey).MapFailure((e: Errors.SerializationError) => e.ToString()); + var encryptDecryptKeyDescription :- keys + .GetKeyDescription(KeyVectorsTypes.GetKeyDescriptionInput( + json := encryptStr + )) + .MapFailure(ParseJsonManifests.ErrorToString); + var tail :- GetKeyDescriptions(keyArray[1..], keys); + Success([encryptDecryptKeyDescription.keyDescription] + tail) + } + + function GetPath(key: string, obj: seq<(string, JSON)>) + : Result + { + var path :- GetString(key, obj); + :- Need(FILE_PREPEND < path, "Received Invalid location for plaintext or ciphertext."); + Success(path[|FILE_PREPEND|..]) + } + + const FILE_PREPEND := "file://" + + predicate Result?(key: string) + { + || key == "output" + || key == "error" + } + + // function DecryptVectorToJson( + // keys: KeyVectors.KeyVectorsClient, + // vector: EsdkDecryptTestVector + // ) : Result<(string, Values.JSON), string> + // { + // var optionalElements + // := [] + // + if vector.decryptionMethod.OneShot? then + // [] + // else + // assert vector.decryptionMethod.StreamingUnsignedOnly?; + // [("decryption-method", Values.String("streaming-unsigned-only"))]; + + // var decryptDescriptions :- Seq.MapWithResult( + // d => + // var description :- keys.SerializeKeyDescription( + // KeyVectorsTypes.SerializeKeyDescriptionInput( + // keyDescription := d + // ) + // ).MapFailure(e => "OMFG"); + // API.Deserialize(description.json).MapFailure(( e: Errors.DeserializationError ) => e.ToString()) + // , + // vector.decryptDescriptions + // ); + // Success( + // match vector + // case PositiveDecryptTestVector(_,_,_,_,_,_,_,_,_) => + // (vector.name, Values.Object([ + // ("ciphertext", Values.String(FILE_PREPEND + vector.ciphertextPath)), + // ("master-keys", Values.Array(decryptDescriptions)), + // ("result", Values.Object([ + // ("output", Values.Object([ + // ("plaintext", Values.String(FILE_PREPEND + vector.plaintextPath)) + // ])) + // ])) + // ] + optionalElements + // )) + // case NegativeDecryptTestVector(_,_,_,_,_,_,_,_,_) => + // (vector.name, Values.Object([ + // ("ciphertext", Values.String(FILE_PREPEND + vector.ciphertextPath)), + // ("master-keys", Values.Array(decryptDescriptions)), + // ("result", Values.Object([ + // ("error", Values.Object([ + // ("error-description", Values.String(vector.errorDescription)) + // ])) + // ])) + // ] + optionalElements + // )) + // ) + // } +} diff --git a/TestVectors/dafny/TestVectors/src/VectorsComposition/AllEsdkV4NoReqEc.dfy b/TestVectors/dafny/TestVectors/src/VectorsComposition/AllEsdkV4NoReqEc.dfy new file mode 100644 index 000000000..60567f666 --- /dev/null +++ b/TestVectors/dafny/TestVectors/src/VectorsComposition/AllEsdkV4NoReqEc.dfy @@ -0,0 +1,105 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 + +include "../LibraryIndex.dfy" + +module {:options "/functionSyntax:4" } AllEsdkV4NoReqEc { + import Types = AwsCryptographyEncryptionSdkTypes + import mplTypes = AwsCryptographyMaterialProvidersTypes + import keyVectorKeyTypes = AwsCryptographyMaterialProvidersTestVectorKeysTypes + import EncryptionSdk + import MaterialProviders + import opened CompleteVectors + import opened KeyDescription + import opened Wrappers + import opened StandardLibrary.UInt + import HexStrings + import opened JSON.Values + import JSONHelpers + import EsdkManifestOptions + import EsdkTestVectors + + import AllHierarchy + import AllKms + import AllKmsMrkAware + import AllKmsMrkAwareDiscovery + import AllKmsRsa + import AllKmsEcdh + import AllRawAES + import AllRawRSA + import AllRawECDH + import AllDefaultCmm + import AllRequiredEncryptionContextCmm + import AllMulti + + import UUID + import UTF8 + import JSON.API + import SortedSets + import FileIO + + // This is a HACK! + // This is *ONLY* because this is wrapping the MPL + import AlgorithmSuites + + const frameSize: int64 := 512 + + const AllPositiveKeyringTests + := {} + + AllHierarchy.Tests + + AllKms.Tests + + AllKmsMrkAware.Tests + + AllKmsMrkAwareDiscovery.Tests + + AllRawAES.Tests + + AllRawRSA.Tests + + AllMulti.Tests + + AllRawECDH.Tests + + AllKmsEcdh.Tests + + const AwsKmsRsaTests := AllKmsRsa.Tests + + const esdkAlgorithmSuitesKmsRsa := set suite <- AllAlgorithmSuites.AllAlgorithmSuites + | !suite.signature.ECDSA? && suite.id.ESDK?:: suite + + // All these tests will use a defualt CMM + const AllPostiveKeyringTestsNoDBESuiteNoReqEC := + set + keyringConfig <- AllPositiveKeyringTests, + algorithmSuite <- + AllAlgorithmSuites.ESDKAlgorithmSuites + :: + EsdkTestVectors.PositiveEncryptTestVector( + name := keyringConfig.name, + version := 4, + manifestPath := "", + decryptManifestPath := "", + plaintextPath := "", + encryptDescriptions := keyringConfig.encryptDescription, + decryptDescriptions := keyringConfig.decryptDescription, + frameLength := Some(frameSize), + algorithmSuiteId := Some(algorithmSuite), + description := keyringConfig.name + ) + + const AllPositiveKeyringTestsNoDBEKmsRsa := + set + keyringConfig <- AwsKmsRsaTests, + algorithmSuite <- esdkAlgorithmSuitesKmsRsa + :: + EsdkTestVectors.PositiveEncryptTestVector( + name := keyringConfig.name, + version := 4, + manifestPath := "", + decryptManifestPath := "", + plaintextPath := "", + encryptDescriptions := keyringConfig.encryptDescription, + decryptDescriptions := keyringConfig.decryptDescription, + frameLength := Some(frameSize), + algorithmSuiteId := Some(algorithmSuite), + description := keyringConfig.name + ) + + const Tests := + AllPostiveKeyringTestsNoDBESuiteNoReqEC + + AllPositiveKeyringTestsNoDBEKmsRsa +} \ No newline at end of file diff --git a/TestVectors/dafny/TestVectors/src/VectorsComposition/AllEsdkV4WithReqEc.dfy b/TestVectors/dafny/TestVectors/src/VectorsComposition/AllEsdkV4WithReqEc.dfy new file mode 100644 index 000000000..d2cf8cd31 --- /dev/null +++ b/TestVectors/dafny/TestVectors/src/VectorsComposition/AllEsdkV4WithReqEc.dfy @@ -0,0 +1,100 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 + +include "../LibraryIndex.dfy" + +module {:options "/functionSyntax:4" } AllEsdkV4WithReqEc { + import Types = AwsCryptographyEncryptionSdkTypes + import mplTypes = AwsCryptographyMaterialProvidersTypes + import EncryptionSdk + import MaterialProviders + import opened CompleteVectors + import opened KeyDescription + import opened Wrappers + import opened StandardLibrary.UInt + import HexStrings + import opened JSON.Values + import JSONHelpers + import EsdkManifestOptions + import EsdkTestVectors + import AllEsdkV4NoReqEc + + import UUID + import UTF8 + import JSON.API + import SortedSets + import FileIO + + // This is a HACK! + // This is *ONLY* because this is wrapping the MPL + import AlgorithmSuites + + datatype PositiveESDKDescriptionJSON = PositiveESDKDescriptionJSON( + description: string, + inputEncryptionContext: string, + requiredEncryptionContextKeys: string, + reproducedEncryptionContext: string, + encrypt: JSON, + decrypt: JSON + ) + + datatype SmallEncryptionContextVariation = Empty | A | AB | BA + + const AllSmallEncryptionContextVariants := ["A", "AB", "BA"] + const RequiredEncryptionContextKeys := ["A", "B"] + + const AllReqECCmmInfo := + set + ec <- AllSmallEncryptionContextVariants, + requiredKeys <- RequiredEncryptionContextKeys + :: + var cmmOnEncryptDescription := Object([ + ("type", String("Required Encryption Context CMM")), + ("Input Encryption Context", String(ec)), + ("Required Encryption Context Keys", String(requiredKeys)) + ]); + var cmmOnDecryptDescription := Object([ + ("type", String("Required Encryption Context CMM")), + ("Reproduced Encryption Context", String(ec)), + ("Required Encryption Context Keys", String(requiredKeys)) + ]); + PositiveESDKDescriptionJSON( + description := "Generated with Required Encryption Context Keys " + requiredKeys, + inputEncryptionContext := ec, + requiredEncryptionContextKeys := requiredKeys, + reproducedEncryptionContext := ec, + encrypt := cmmOnEncryptDescription, + decrypt := cmmOnDecryptDescription + ) + + const frameSize: int64 := 512 + + const AllPositiveReqEcTests := AllRequiredEncryptionContextCmm.SuccessTestingRequiredEncryptionContextKeysReproducedEncryptionContext + + // These are only required encryption context vectors with static aes keyrings + const AllPositveReqEcEsdkTests := + set + config <- AllPositiveReqEcTests, + algorithmSuite <- + AllAlgorithmSuites.ESDKAlgorithmSuites + :: + EsdkTestVectors.PositiveEncryptTestVector( + name := config.name, + version := 4, + manifestPath := "", + decryptManifestPath := "", + plaintextPath := "", + encryptDescriptions := config.encryptDescription, + decryptDescriptions := config.decryptDescription, + encryptionContext := Some(config.encryptionContext), + requiredEncryptionContextKeys := config.requiredEncryptionContextKeys, + requiredECDescription := Some(config.name), + frameLength := Some(frameSize), + algorithmSuiteId := Some(algorithmSuite), + description := config.name + ) + + const Tests := + AllPositveReqEcEsdkTests + +} \ No newline at end of file diff --git a/TestVectors/dafny/TestVectors/src/WriteEsdkJsonManifests.dfy b/TestVectors/dafny/TestVectors/src/WriteEsdkJsonManifests.dfy new file mode 100644 index 000000000..b31dbe735 --- /dev/null +++ b/TestVectors/dafny/TestVectors/src/WriteEsdkJsonManifests.dfy @@ -0,0 +1,243 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 + +include "LibraryIndex.dfy" + +module {:options "-functionSyntax:4"} WriteEsdkJsonManifests { + import opened JSON.Values + import AllAlgorithmSuites + import AllAlgorithmSuites.Types + import mplTypes = AwsCryptographyMaterialProvidersTypes + import opened Wrappers + import UTF8 + import SortedSets + import Seq + import StandardLibrary + import StandardLibrary.String + import Base64 + + import TestVectors + import KeyDescription + import EsdkTestVectors + + function EncryptionContextKeysToJson(keys: Option) + : Result, string> + { + if keys.Some? then + + var tmp :- Seq.MapWithResult( + bytes => + var key :- UTF8.Decode(bytes); + Success(String(key)), + keys.value); + + Success([("requiredEncryptionContextKeys", Array(tmp))]) + + else + Success([]) + } + + function EncryptionContextToJson(key: string, m: mplTypes.EncryptionContext) + : Result, string> + { + var keys := SortedSets.ComputeSetToSequence(m.Keys); + var pairsBytes + :- Seq.MapWithResult( + k requires k in m.Keys => + var key :- UTF8.Decode(k); + var value :- UTF8.Decode(m[k]); + Success((key, String(value))), + keys); + Success([(key, Object(pairsBytes))]) + } + + function printJson(j: JSON) : (){()} by method {print j, "\n", "\n"; return ();} + + function {:vcs_split_on_every_assert} EncryptTestVectorToJson( + test: EsdkTestVectors.EsdkEncryptTestVector + ): Result + { + :- Need( + && test.algorithmSuiteId.Some? + && test.frameLength.Some?, + "test is missing algorithmSuite ID, or frameLength" + ); + var id := AllAlgorithmSuites.ToHex(test.algorithmSuiteId.value); + + // var encryptionContext :- EncryptionContextToJson("encryption-context", test.encryptionContext.value); + var encryptionContext + :- if test.encryptionContext.Some? then + EncryptionContextToJson("encryption-context", test.encryptionContext.value) + else + EncryptionContextToJson("encryption-context", map[]); + + :- Need( + |encryptionContext| == 1, + "Error parsing encryption context" + ); + + var requiredEncryptionContextKeys :- EncryptionContextKeysToJson(test.requiredEncryptionContextKeys); + var optionalValues := requiredEncryptionContextKeys + encryptionContext; + + match test + case PositiveEncryptTestVector(_,_,_,_,_,_,_,_,_,_,_,_,_,_,_) => + var encrypt :- KeyDescription.ToJson(test.encryptDescriptions, 3); + var decrypt :- KeyDescription.ToJson(test.decryptDescriptions, 3); + var scenario := Object([ + ("type", String("positive-esdk")), + ("plaintext", String("small")), + ("description", String(test.description)), + ("algorithmSuiteId", String(id)), + ("frame-size", Number(Int(test.frameLength.value as int))), + ("encryptKeyDescription", encrypt), + ("decryptKeyDescription", decrypt) + ] + optionalValues); + Success(Object([ + ("encryption-scenario", scenario) + ])) + case _ => + Failure("Only Positive Tests supported :(") + + // match test + // case PositiveEncryptKeyringVector(_,_,_,_,_,_,_,_,_,_) => + // var encrypt :- KeyDescription.ToJson(test.encryptDescription, 3); + // var decrypt :- KeyDescription.ToJson(test.decryptDescription, 3); + // Success(Object([ + // ("type", String("positive-keyring")), + // ("description", String(description)), + // ("algorithmSuiteId", String(id)), + // ("encryptKeyDescription", encrypt), + // ("decryptKeyDescription", decrypt) + // ] + optionalValues)) + // case PositiveEncryptNegativeDecryptKeyringVector(_,_,_,_,_,_,_,_,_,_,_) => + // var encrypt :- KeyDescription.ToJson(test.encryptDescription, 3); + // var decrypt :- KeyDescription.ToJson(test.decryptDescription, 3); + // Success(Object([ + // ("type", String("negative-decrypt-keyring")), + // ("description", String(description)), + // ("decryptErrorDescription", String(test.decryptErrorDescription)), + // ("algorithmSuiteId", String(id)), + // ("encryptKeyDescription", encrypt), + // ("decryptKeyDescription", decrypt) + // ] + optionalValues)) + // case NegativeEncryptKeyringVector(_,_,_,_,_,_,_,_,_) => + // var keyDescription :- KeyDescription.ToJson(test.keyDescription, 3); + // Success(Object([ + // ("type", String("negative-encrypt-keyring")), + // ("description", String(description)), + // ("errorDescription", String(test.errorDescription)), + // ("algorithmSuiteId", String(id)), + // ("keyDescription", keyDescription) + // ] + optionalValues)) + } + + function OptionalBytes(key: string, secret: Option) + : seq<(string, JSON)> + { + if secret.Some? then + var base64 := Base64.Encode(secret.value); + [(key, String(base64))] + else + [] + } + + function EncryptedDataKey( + encryptedDataKey: Types.EncryptedDataKey + ) + : Result + { + var keyProviderId :- UTF8.Decode(encryptedDataKey.keyProviderId); + Success(Object([ + ("keyProviderId", String(keyProviderId)), + ("keyProviderInfo", String(Base64.Encode(encryptedDataKey.keyProviderInfo))), + ("ciphertext", String(Base64.Encode(encryptedDataKey.ciphertext))) + ])) + } + + // function DecryptTestVectorToJson( + // test: TestVectors.DecryptTestVector + // ): Result + // { + // var id := AllAlgorithmSuites.ToHex(test.algorithmSuite); + // var description := test.name + " " + id; + + // var encryptionContext :- EncryptionContextToJson("encryptionContext", test.encryptionContext); + // var reproducedEc + // :- if test.reproducedEncryptionContext.Some? then + // EncryptionContextToJson("reproducedEncryptionContext", test.reproducedEncryptionContext.value) + // else + // Success([]); + // var keyDescription :- KeyDescription.ToJson(test.keyDescription, 3); + // var encryptedDataKeys :- Seq.MapWithResult(edk => EncryptedDataKey(edk), test.encryptedDataKeys); + + // match test + // case PositiveDecryptKeyringTest(_,_,_,_,_,_,_,_,_) => + // var plaintextDataKey := OptionalBytes("plaintextDataKey", test.expectedResult.plaintextDataKey); + // var symmetricSigningKey := OptionalBytes("symmetricSigningKey", test.expectedResult.symmetricSigningKey); + // var requiredEncryptionContextKeys :- EncryptionContextKeysToJson(Some(test.expectedResult.requiredEncryptionContextKeys)); + // Success(Object([ + // ("type", String("positive-keyring")), + // ("description", String(description)), + // ("algorithmSuiteId", String(id)), + // ("keyDescription", keyDescription), + // ("encryptedDataKeys", Array(encryptedDataKeys)), + // ("result", Object( + // plaintextDataKey + symmetricSigningKey + requiredEncryptionContextKeys + // )) + // ] + reproducedEc + encryptionContext)) + // case NegativeDecryptKeyringTest(_,_,_,_,_,_,_,_,_) => + // Success(Object([ + // ("type", String("negative-keyring")), + // ("description", String(description)), + // ("errorDescription", String(test.errorDescription)), + // ("algorithmSuiteId", String(id)), + // ("keyDescription", keyDescription), + // ("encryptedDataKeys", Array(encryptedDataKeys)) + // ] + reproducedEc + encryptionContext)) + // } + + function {:vcs_split_on_every_assert} DecryptTestVectorToJson( + test: EsdkTestVectors.EsdkDecryptTestVector + ): Result + { + :- Need( + && test.algorithmSuiteId.Some? + && test.frameLength.Some?, + "test is missing algorithmSuite ID, or frameLength" + ); + var id := AllAlgorithmSuites.ToHex(test.algorithmSuiteId.value); + var description := test.name + " " + id; + + var encryptionContext + :- if test.encryptionContext.Some? then + EncryptionContextToJson("encryption-context", test.encryptionContext.value) + else + EncryptionContextToJson("encryption-context", map[]); + + :- Need( + |encryptionContext| == 1, + "Error parsing encryption context" + ); + + var requiredEncryptionContextKeys :- EncryptionContextKeysToJson(test.requiredEncryptionContextKeys); + var optionalValues := requiredEncryptionContextKeys + encryptionContext; + + match test + case PositiveDecryptTestVector(_,_,_,_,_,_,_,_,_,_,_,_,_) => + var decrypt :- KeyDescription.ToJson(test.decryptDescriptions, 3); + var scenario := Object([ + ("type", String("positive-esdk")), + ("ciphertext", String("file://ciphertexts/" + test.name)), + ("result", String("file://" + test.plaintextPath)), + ("algorithmSuiteId", String(id)), + ("frame-size", Number(Int(test.frameLength.value as int))), + ("description", String(test.description)), + ("decryptKeyDescription", decrypt) + ] + optionalValues); + Success(Object([ + ("decryption-scenario", scenario) + ])) + case _ => + Failure("Only Positive Tests supported :(") + } +} diff --git a/TestVectors/dafny/TestVectors/src/WriteVectors.dfy b/TestVectors/dafny/TestVectors/src/WriteVectors.dfy new file mode 100644 index 000000000..b1ab42899 --- /dev/null +++ b/TestVectors/dafny/TestVectors/src/WriteVectors.dfy @@ -0,0 +1,157 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 + +include "LibraryIndex.dfy" +include "VectorsComposition/AllEsdkV4NoReqEc.dfy" +include "VectorsComposition/AllEsdkV4WithReqEc.dfy" +include "WriteEsdkJsonManifests.dfy" + +module {:options "-functionSyntax:4"} WriteVectors { + import Types = AwsCryptographyEncryptionSdkTypes + import mplTypes = AwsCryptographyMaterialProvidersTypes + import EncryptionSdk + import MaterialProviders + import opened CompleteVectors + import opened Wrappers + import opened StandardLibrary.UInt + import HexStrings + import opened JSON.Values + import JSONHelpers + import EsdkManifestOptions + import EsdkTestVectors + import AllEsdkV4NoReqEc + import AllEsdkV4WithReqEc + import WriteEsdkJsonManifests + + import UUID + import UTF8 + import JSON.API + import SortedSets + import FileIO + + // This is a HACK! + // This is *ONLY* because this is wrapping the MPL + import AlgorithmSuites + + function GetCommitmentPolicyString(algorithmSuite: mplTypes.AlgorithmSuiteInfo) + : (commitmentPolicy: string) + { + match algorithmSuite.id + case ESDK(_) => + if algorithmSuite.commitment.None? then + "FORBID_ENCRYPT_ALLOW_DECRYPT" + else + "REQUIRE_ENCRYPT_REQUIRE_DECRYPT" + case DBE(_) => "NOT SUPPORTED FOR UNSTRUCTURED ENCRYPTION" + } + + function GetCommitmentPolicyType(commitmentPolicy: string) + : (commitmentPolicyType: mplTypes.CommitmentPolicy) + { + if commitmentPolicy == "FORBID_ENCRYPT_ALLOW_DECRYPT" then + mplTypes.CommitmentPolicy.ESDK(mplTypes.ESDKCommitmentPolicy.FORBID_ENCRYPT_ALLOW_DECRYPT) + else + mplTypes.CommitmentPolicy.ESDK(mplTypes.ESDKCommitmentPolicy.REQUIRE_ENCRYPT_REQUIRE_DECRYPT) + } + + method {:vcs_split_on_every_assert} WritetestVectors(op: EsdkManifestOptions.ManifestOptions) + returns (output: Result<(), string>) + requires op.EncryptManifest? + { + var version := op.version; + var allTests :- getVersionTests(version); + + var tests := SortedSets.ComputeSetToSequence(allTests); + + var testsJSON: seq<(string, JSON)> := []; + + for i := 0 to |tests| + { + :- Need( + && tests[i].algorithmSuiteId.Some?, + "No algorithm suite defined in test" + ); + + var id := AllAlgorithmSuites.ToHex(tests[i].algorithmSuiteId.value); + var uuid :- expect UUID.GenerateUUID(); + var test :- WriteEsdkJsonManifests.EncryptTestVectorToJson(tests[i]); + testsJSON := testsJSON + [(uuid, test)]; + } + + var manifestJson := Object([ + ("type", String("awses-encrypt")), + ("version", Number(Int(5)))]); + + var plaintexts := Object([("small", Number(Int(10240)))]); + + var esdkEncryptManifests := Object( + [ + ("manifest", manifestJson), + ("keys", String("file://keys.json")), + ("plaintexts", plaintexts), + ("tests", Object(testsJSON)) + ] + ); + + var esdkEncryptManifestBytes :- expect API.Serialize(esdkEncryptManifests); + var esdkEncryptManifestBv := JSONHelpers.BytesBv(esdkEncryptManifestBytes); + + var _ :- expect FileIO.WriteBytesToFile( + op.encryptManifestOutput + "encrypt-manifest.json", + esdkEncryptManifestBv + ); + + output := Success(()); + } + + method {:vcs_split_on_every_assert} WriteDecryptManifest( + op: EsdkManifestOptions.ManifestOptions, + keys: KeyVectors.KeyVectorsClient, + tests: seq + ) + returns (output: Result<(), string>) + requires op.Encrypt? + requires keys.ValidState() + ensures keys.ValidState() + { + var testsJSON: seq<(string, JSON)> := []; + + for i := 0 to |tests| + { + var name := tests[i].name; + var test :- WriteEsdkJsonManifests.DecryptTestVectorToJson(tests[i]); + testsJSON := testsJSON + [(name, test)]; + } + + var manifestJson := Object([ + ("type", String("awses-decrypt")), + ("version", Number(Int(3)))]); + + var esdkDecryptManifest := Object( + [ + ("manifest", manifestJson), + // TODO create an extern that gets that runtimes namespace and latest version + ("client", String("aws-encryption-sdk-dafny")), + ("keys", String("file://keys.json")), + ("tests", Object(testsJSON)) + ] + ); + + var esdkDecryptManifestBytes :- expect API.Serialize(esdkDecryptManifest); + var esdkDecryptManifestBv := JSONHelpers.BytesBv(esdkDecryptManifestBytes); + + var _ :- expect FileIO.WriteBytesToFile( + op.decryptManifestOutput + "decrypt-manifest.json", + esdkDecryptManifestBv + ); + + output := Success(()); + } + + function getVersionTests(version: nat): (ret: Result, string>) + { + match version + case 5 => Success(AllEsdkV4NoReqEc.Tests + AllEsdkV4WithReqEc.Tests) + case _ => Failure("Only version 4 of generate manifest is supported\n") + } +} \ No newline at end of file diff --git a/TestVectors/dafny/TestVectors/test/RunMain.dfy b/TestVectors/dafny/TestVectors/test/RunMain.dfy new file mode 100644 index 000000000..35d3b7a66 --- /dev/null +++ b/TestVectors/dafny/TestVectors/test/RunMain.dfy @@ -0,0 +1,94 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 + +// Test vector projects just run as a CLI +// So all the tests are in the Main. +// By creating a single file here, +// it is easy to kick off a test run. +include "../src/Index.dfy" + +module {:extern} TestWrappedESDKMain { + import WrappedESDKMain + import EsdkTestManifests + import EsdkManifestOptions + import WriteVectors + import opened Wrappers + + + // Test execution directory is different for different runtimes. + // Runtime should define an extern to return the expected test execution directory. + method {:extern} GetTestVectorExecutionDirectory() returns (res: string) + + // method {:test} TestV1Vectors() { + // var _ :- expect EsdkTestManifests.StartV1DecryptVectors( + // "aws-encryption-sdk-test-vectors/vectors/awses-decrypt/python-1.3.5/decrypt_message.json", + // "aws-encryption-sdk-test-vectors/vectors/awses-decrypt/python-1.3.5/keys.json" + // ); + // } + + + // method {:test} TestV2Vectors() { + // var _ :- expect EsdkTestManifests.StartDecryptVectors( + // EsdkManifestOptions.Decrypt( + // manifestPath := "aws-encryption-sdk-test-vectors/vectors/awses-decrypt/python-2.3.0/" + // ) + // ); + // } + + // method {:test} TestV2Vectors() { + // TestEsdkManifests.StartV1Vectors( + // "dafny/ESDK/test/python-2.3.0/manifest.json", + // "dafny/ESDK/test/python-2.3.0/keys.json" + // ); + + // } + + method {:test} RunManifestTests() { + TestGenerateEncryptManifest(); + TestEncryptManifest(); + TestDecryptManifest(); + } + + method TestGenerateEncryptManifest() { + var directory := GetTestVectorExecutionDirectory(); + var result := WriteVectors.WritetestVectors( + EsdkManifestOptions.EncryptManifest( + encryptManifestOutput := directory + "dafny/TestVectors/test/", + version := 5 + )); + if result.Failure? { + print result.error; + } + expect result.Success?; + } + + method TestEncryptManifest() { + var directory := GetTestVectorExecutionDirectory(); + var result := EsdkTestManifests.StartEncryptVectors( + EsdkManifestOptions.Encrypt( + manifestPath := directory + "dafny/TestVectors/test/", + manifest := "encrypt-manifest.json", + decryptManifestOutput := directory + "dafny/TestVectors/test/" + ) + ); + if result.Failure? { + print result.error; + } + expect result.Success?; + } + + method TestDecryptManifest() + { + var directory := GetTestVectorExecutionDirectory(); + var result := EsdkTestManifests.StartDecryptVectors( + EsdkManifestOptions.Decrypt( + manifestPath := directory + "dafny/TestVectors/test/" + ) + ); + + if result.Failure? { + print result.error; + } + expect result.Success?; + } +} diff --git a/TestVectors/dafny/TestVectors/test/encrypt-manifest.json b/TestVectors/dafny/TestVectors/test/encrypt-manifest.json new file mode 100644 index 000000000..9fded2cdf --- /dev/null +++ b/TestVectors/dafny/TestVectors/test/encrypt-manifest.json @@ -0,0 +1 @@ +{"manifest":{"type":"awses-encrypt","version":5},"keys":"file://keys.json","plaintexts":{"small":10240},"tests":{"8b513518-28c5-40ce-9769-ed9bb9df0cb1":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"ec768037-2ae2-439f-b1ee-f83cec99c5fd":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"requiredEncryptionContextKeys":["a"],"encryption-context":{"a":"a","b":"b"}}},"d595625c-5318-4e6f-abf4-307767473372":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-256-ecc discovery","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-256-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"discovery"},"encryption-context":{}}},"d14a9e8a-77bc-4740-9f4e-1a2c06e9e578":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-384-ecc discovery","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-384-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"discovery"},"encryption-context":{}}},"e21fc5e6-3808-42f7-b49d-1075755bf2f0":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-521-ecc discovery","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-521-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"discovery"},"encryption-context":{}}},"289e7fea-34a1-4627-884d-f8a33d063855":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"encryption-context":{}}},"5f41e393-b865-4e2a-9f67-c8d4c07b0ecf":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-256-private","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-256-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-256","ecc-curve":"ecc-256","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"5a9e938a-0d77-40e4-8b82-5efc1add4e72":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-256-ecc us-west-2-256-ecc","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"encryption-context":{}}},"b19bba47-97dc-4b0d-bea8-6f947cf2b9fa":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-384-ecc us-west-2-384-ecc","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"encryption-context":{}}},"99ce3ddc-1dba-4805-817b-256f460660c7":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-521-ecc us-west-2-521-ecc","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"encryption-context":{}}},"5d890c57-cf88-4e8d-a1cc-34e6f8baf3cb":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private Discovery ecc-256-private","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"f9cd0dd0-8a5e-41d1-9425-a41e12f9e0a0":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-256-ecc discovery","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-256-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"discovery"},"encryption-context":{}}},"93ac2998-5c69-407c-90d9-50cec2b524f4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-384-ecc discovery","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-384-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"discovery"},"encryption-context":{}}},"df21cd34-6711-4081-a9f1-bb7183532e2c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-521-ecc discovery","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-521-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"discovery"},"encryption-context":{}}},"3876664e-8b48-4308-940e-a93eb363d109":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private ecc-521-private","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"encryption-context":{}}},"f2e02dc4-22fa-4eb7-85a1-41657cbe4c84":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"encryption-context":{}}},"acad9c79-2ff3-4136-8414-c0fbdfe6006f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"requiredEncryptionContextKeys":["a","b"],"encryption-context":{"a":"a","b":"b"}}},"6fd4d935-f0ee-44d1-b1d4-6c334d2c7563":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"encryption-context":{}}},"c7fd6f3d-58ab-4da0-919b-8fe57c215f8a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"encryption-context":{}}},"abe13f02-9356-4bbd-a8ea-54d297ce62e3":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-west-2-mrk","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"cf301226-3d45-4ab3-9d7e-5d4a13c118e8":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-east-1-mrk","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"16f3dff1-28e5-4294-be92-3cb2f2241f4a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-west-2-mrk","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"15664d21-cd2d-4c57-af7f-cd9bae302067":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-east-1-mrk","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"ccd94f68-1eaa-4564-b4d7-b5d107595821":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"encryption-context":{}}},"55563858-b942-4a11-85f4-85c382564ed5":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private Discovery ecc-384-private","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"b6f19bda-b64b-49a1-8387-3d319f39c6be":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-384-private","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-384-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-384","ecc-curve":"ecc-384","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"f75e734f-ee36-4a8b-b71e-859306a9b7e0":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private ecc-521-private","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"encryption-context":{}}},"ce4eb0b2-fe18-481d-9b4e-f3d6f472db40":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-west-2-mrk","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"f98fc3fe-c217-4691-9914-d0bc93e7ace7":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-east-1-mrk","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"ee226b20-47ae-4bdf-a4bc-1ff080dc3f0b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-west-2-mrk","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"a5fb9244-4e60-467a-bbb1-0f1d6dba5c5c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-east-1-mrk","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"bc1dcbcc-f4b5-44d9-9698-a8852221494e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-256","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"encryption-context":{}}},"43158e2d-66ac-4d51-83da-ae854ed2c694":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-256-private","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-256-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-256","ecc-curve":"ecc-256","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"c6730e0a-860a-4b6e-9a47-daab2b2db207":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"encryption-context":{}}},"11e17f41-1c34-42a1-a41f-a87fa5bbb9fa":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"583758ea-06cf-49f2-b3cb-8eb637df9673":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-256-ecc us-west-2-256-ecc","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"encryption-context":{}}},"efe7ce12-facd-4e9e-b853-6b893331356d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-384-ecc us-west-2-384-ecc","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"encryption-context":{}}},"609e5b20-7dfb-4a4b-8066-74e54d959927":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-521-ecc us-west-2-521-ecc","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"encryption-context":{}}},"3f866d99-9441-4789-b63a-928550401a2b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-384-private","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-384-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-384","ecc-curve":"ecc-384","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"a42620ca-dd10-4ec7-995e-2e601fdf2b00":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"e4f87a61-1af8-4160-8312-b975635ed7e4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-256","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"encryption-context":{}}},"3f127091-f859-4f9c-a61d-ede0659d5fe6":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"encryption-context":{}}},"4ddc84ec-dfa0-44f8-b3ae-b3f1c2e338eb":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->No Filter","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"4cebd369-a4cb-4a2b-8b1a-e51f0832c914":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->No Filter","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"cd474db4-bc52-490f-aebb-8c3d4e8ae602":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-256-ecc discovery","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-256-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"discovery"},"encryption-context":{}}},"4ba00939-ad84-4d20-abe2-f51ef5b5a9c5":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-384-ecc discovery","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-384-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"discovery"},"encryption-context":{}}},"d27c8933-9ab3-4034-8338-401d908eed05":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-521-ecc discovery","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-521-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"discovery"},"encryption-context":{}}},"c7a3df95-b4e8-488d-bc00-554d14ccf7dd":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-mrk","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"encryption-context":{}}},"7e9090f0-aeeb-4f23-be81-7c9dafdd44ad":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"encryption-context":{}}},"2ccba2ad-ee83-4e9a-8d00-10408ccaacd2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Hierarchy KMS static-branch-key-1","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"decryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"encryption-context":{}}},"0e2547ab-47ba-41c3-a55a-992f6fb514b2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-256-private","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-256-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-256","ecc-curve":"ecc-256","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"abede3b4-d265-408d-ad70-33815b1842df":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"baf1d8c7-bff6-4d8c-a348-55d09b7384fb":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-256-ecc us-west-2-256-ecc","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"encryption-context":{}}},"39ace32e-ba9f-4591-9516-ce7df09e4c5f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-384-ecc us-west-2-384-ecc","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"encryption-context":{}}},"690c5dc5-627a-428b-8bac-4683780702dd":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-521-ecc us-west-2-521-ecc","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"encryption-context":{}}},"f67ee898-ec9a-4fa0-b743-aa524ac56d28":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"encryption-context":{}}},"0311d9dc-372c-433d-a071-74818299c417":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"requiredEncryptionContextKeys":["a","b"],"encryption-context":{"a":"a","b":"b"}}},"40def2c4-032d-42e9-a8a1-13f8adafe15b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"requiredEncryptionContextKeys":["a"],"encryption-context":{"a":"a","b":"b"}}},"0b7d9ffd-7e3f-4b7f-8798-d75c90a4306e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"15f14843-3896-4757-8a8c-0aebb0af6ad9":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Hierarchy KMS static-branch-key-1","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"decryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"encryption-context":{}}},"36ec3806-3ad1-4ea7-b29e-48a9d2c0221e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"encryption-context":{}}},"6897e30c-d911-4d42-a8cd-0cb498343d8c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private Discovery ecc-521-private","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"143bd7a3-81a2-461f-b135-ea392c3a4e16":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"encryption-context":{}}},"416ad3b2-2034-4795-afc3-d52852cbb37d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-west-2-mrk","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"0741788c-6e8e-445b-9a67-8a0dd33ce4ec":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-east-1-mrk","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"1141c635-d6c0-46f5-a05e-c0d69f1c7385":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-west-2-mrk","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"38363d0b-06e0-43a4-8774-13943f0cdcba":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-east-1-mrk","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"28f2005f-9324-4c85-8c47-e60bcb19bad2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private Discovery ecc-256-private","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"ba106e46-4466-42db-9caf-eb5eb035e39a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"8ac91028-9690-4ce9-a898-204e518cafcb":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private Discovery ecc-384-private","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"ab5c722d-de60-4905-bfd9-db29dac27a6a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-384-private","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-384-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-384","ecc-curve":"ecc-384","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"5571211c-be2b-448b-8f07-1657b319eadc":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->No Filter","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"bf7508bc-b9fa-461e-ba99-448581a15b59":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->No Filter","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"6655b375-fce5-4cd8-8dda-d744a186ee75":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-256","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"encryption-context":{}}},"8ddfc2d4-eb46-495d-9951-30335142fa8e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"43fde155-d4fa-4d31-9f09-e2fadbc67376":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"45295d99-7468-4412-adb8-67c65a705e0a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"84299c18-eb7f-4ba8-a097-e7b14e693c19":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-256-ecc discovery","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-256-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"discovery"},"encryption-context":{}}},"5f660bd0-6fc9-4909-80bb-c572b73cb46e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-384-ecc discovery","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-384-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"discovery"},"encryption-context":{}}},"68359990-9422-4b97-8c02-e04be5d4ea16":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-521-ecc discovery","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-521-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"discovery"},"encryption-context":{}}},"377fde61-e4f0-41e8-aea2-8847c290ce5d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-mrk","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"encryption-context":{}}},"48ea70e4-0094-4760-8cf0-426d7705cb81":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"encryption-context":{}}},"dd1e726e-531d-42d6-8f88-90fc875a8158":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private ecc-521-private","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"encryption-context":{}}},"d0a3d54e-1b1f-4192-9e57-922be130c82b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->No Filter","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"c7567a18-40c9-4f4c-8d6e-9187f20efdd5":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->No Filter","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"5707d054-7041-4390-beef-6a75c99b860f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private ecc-384-private","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"encryption-context":{}}},"59f7b78b-ff88-4c92-ba84-5988a13f664a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"encryption-context":{}}},"4d472dec-22b4-4ccb-a796-35c717a49ab8":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Hierarchy KMS static-branch-key-1","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"decryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"encryption-context":{}}},"969aaf37-a2f8-4245-8db0-8b1937bfc4c3":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"encryption-context":{}}},"5e11b2a2-19ab-49ca-bce0-68898bf2c914":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"requiredEncryptionContextKeys":["a","b"],"encryption-context":{"a":"a","b":"b"}}},"f1499865-b124-437a-8d82-514b418db3f8":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"requiredEncryptionContextKeys":["a"],"encryption-context":{"a":"a","b":"b"}}},"185d7082-1fee-4909-968d-79a29f73f73d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"b2d5f0c5-f7cd-4b11-b50f-4c1234a4cbcb":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"4b577960-bac2-4ad8-a7b5-d5bc4969be0f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"encryption-context":{}}},"d56e8331-6d1c-4630-b12c-ffb710bb5837":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-decryptable","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"encryption-context":{}}},"bbea1e9d-135f-469e-84a6-67f59b07fe65":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-521-private","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-521-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-521","ecc-curve":"ecc-521","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"00c06e37-2c87-4bbd-8a74-db0373b01a38":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private Discovery ecc-384-private","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"d1744eea-eb68-4d49-b5fb-ca1b489ec542":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-west-2-mrk","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"f9bc2a0d-0593-4f7c-b80e-5380e4e17054":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-east-1-mrk","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"22e5ac89-6e92-448c-9b46-249ec04ddb0f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-west-2-mrk","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"52a6e118-7f69-4f6f-8b13-39566fb2ec00":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-east-1-mrk","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"2fbc57e5-0d6d-4a44-b2fb-e91d2119b0ed":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private Discovery ecc-256-private","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"4ee6cb6c-32fe-450c-afcc-cd81326f02fb":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-256-private","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-256-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-256","ecc-curve":"ecc-256","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"43d591fe-32bb-49aa-8e13-5fdf31a2d4a1":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-256-ecc us-west-2-256-ecc","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"encryption-context":{}}},"0c948e29-4c11-4caf-a505-535d5e0f04d1":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-384-ecc us-west-2-384-ecc","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"encryption-context":{}}},"5cbeeb42-835e-479c-9c53-416558d582af":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-521-ecc us-west-2-521-ecc","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"encryption-context":{}}},"e58a8e18-f35d-40e8-ab95-4e08f4c75b45":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-384-private","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-384-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-384","ecc-curve":"ecc-384","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"5a5dcece-3506-4539-965d-78c13672a09d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"46e8e2c3-73d8-4460-b1c8-0a28434ad056":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-256","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"encryption-context":{}}},"a792332f-666b-4df4-99cd-9d889af3b35a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-256-ecc discovery","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-256-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"discovery"},"encryption-context":{}}},"0315af46-6502-4d25-b389-dcb47c7d7d71":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-384-ecc discovery","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-384-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"discovery"},"encryption-context":{}}},"d8aac4b6-1c8c-441d-a4bb-0f26b7e87fa4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-521-ecc discovery","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-521-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"discovery"},"encryption-context":{}}},"ed49f7b7-e894-45d4-a5c1-8b85cffd2e11":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private ecc-521-private","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"encryption-context":{}}},"4d163b68-f1f6-401d-af08-f25f00b24aa8":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"encryption-context":{}}},"8abf178c-a283-4a00-851a-449fb2346cd6":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Hierarchy KMS static-branch-key-1","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"decryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"encryption-context":{}}},"2341e659-9853-4b14-9313-d2d7ee1069ec":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"encryption-context":{}}},"94d91ce2-e79c-49fb-b16c-9af980ce7492":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private Discovery ecc-521-private","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"e971bede-90ed-4c58-9581-d0f7dab1df40":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"encryption-context":{}}},"7bf07c7f-afaf-40dc-8c1f-5603d828d8fc":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"bb6fe295-e88e-405c-bcc7-89620676c756":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"50bd2280-409a-4c69-b96f-a5710421502a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-west-2-mrk","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"3dc4bed5-d68d-4c75-8b6c-c67d1911f6db":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-east-1-mrk","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"a363c03e-979a-41b6-9552-2a01b92e898c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-west-2-mrk","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"408f935d-2a56-4b64-852e-22891a25ca42":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-east-1-mrk","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"398cafa3-071c-4bec-b4f0-9c00b3c769fe":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->No Filter","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"e48092ac-d488-42f4-a77a-bdce7fc549d9":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->No Filter","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"8d324ecb-e162-427b-a849-8d34d5965f85":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-384-private","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-384-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-384","ecc-curve":"ecc-384","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"80cbbc71-c980-4a20-be53-c55b86a0b652":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-256-private","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-256-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-256","ecc-curve":"ecc-256","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"0f7bd839-e2ea-4e4f-b14c-80f7f3e6c62f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-256","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"encryption-context":{}}},"1519e20f-8b0a-40d3-94fc-bf40d3767529":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-256-ecc us-west-2-256-ecc","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"encryption-context":{}}},"f9cd9faf-d335-47cb-ae62-145824f8ae80":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-384-ecc us-west-2-384-ecc","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"encryption-context":{}}},"e21e451f-b3fd-4f50-b942-b55bed302bda":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-521-ecc us-west-2-521-ecc","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"encryption-context":{}}},"815f01e1-0a68-45a6-ab0f-782ed6b96544":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"da47e0ac-1c9c-4217-8417-549c47ccf849":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"b82d4c08-0fd9-41a5-bad4-5b6199183707":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"9084280c-6e23-4418-86ac-53d6752aae38":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private ecc-384-private","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"encryption-context":{}}},"1291361e-900d-4700-ab3e-dd264539aed7":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private Discovery ecc-521-private","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"3d720f39-c9ca-487e-bdcb-3f0dcc8f9b38":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"encryption-context":{}}},"484e885e-08e3-4710-9605-c2fa241124b4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Hierarchy KMS static-branch-key-1","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"decryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"encryption-context":{}}},"892d31ae-c903-4586-a067-e804a4304c2e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"e0f33e48-1ad1-4e10-b415-a27fd3feaed5":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"3f895faa-fe76-4870-82d6-192cbf81f9cc":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-decryptable","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"encryption-context":{}}},"88f0fb5d-6e1b-4482-971d-ba459cd8e44d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"6b93f52a-59ee-48ba-b169-377036f5ca4e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-521-private","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-521-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-521","ecc-curve":"ecc-521","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"36040986-cd37-43cb-b652-9703014504b3":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"a0ae4270-1c60-4d42-86fd-04ff2a5b6c12":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private Discovery ecc-521-private","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"667f8d8b-a20c-4d82-a86b-20bfe0220f39":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-128","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"encryption-context":{}}},"6860fd22-b100-4e68-80df-b5808e610c48":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"encryption-context":{}}},"e81ba801-f856-4fed-932d-00ff7e7b55d2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->No Filter","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"ab195dca-f2be-4eb3-91ce-4e8c464777f1":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->No Filter","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"78824cde-3389-49e0-8a9c-17abba9a4d79":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-128","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"encryption-context":{}}},"c27efde9-1fe5-4464-8632-5b59ed777ada":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private ecc-384-private","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"encryption-context":{}}},"aa0aeb2e-548a-48d6-bafd-e9ec4690e91c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"2a4b9ba3-92b5-4e08-9685-a1024c538134":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"0cf3b882-42c8-4d52-85fe-bc60b989125a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-decryptable","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"encryption-context":{}}},"f71c370c-90b9-4275-801c-c4e50a36e100":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-521-private","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-521-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-521","ecc-curve":"ecc-521","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"b0b3213a-5fe4-4454-be62-bd9c6e80ca43":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private ecc-384-private","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"encryption-context":{}}},"eb7eb4ab-5aa7-4657-a289-ccb80e22656b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"encryption-context":{}}},"825ceff5-5fe1-4520-b30a-ed73ea4dfc82":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-192","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"encryption-context":{}}},"3c004821-42a3-42c0-b530-2560aabe7254":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"e15a7cee-c331-4d30-9f29-d9ef6d173f51":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"c1bb4089-2e6c-477d-8238-6d1101de9313":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"requiredEncryptionContextKeys":["b"],"encryption-context":{"a":"a","b":"b"}}},"ea2a94f8-6447-4d7a-8409-af4eb6111976":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"2ef56298-5c49-48bd-bf8e-fcffe9131507":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-192","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"encryption-context":{}}},"66e5e313-2051-4593-8aee-c0a3e4fb043e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-decryptable","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"encryption-context":{}}},"a15b4a23-ba3b-44be-b7f3-9d6c4e5f922d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"requiredEncryptionContextKeys":["b"],"encryption-context":{"a":"a","b":"b"}}},"c4a90afe-30a9-40db-a973-f64745ff50b3":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-521-private","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-521-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-521","ecc-curve":"ecc-521","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"e051ec92-4f98-49ad-87b4-2e90f5512ddc":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-128","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"encryption-context":{}}},"067084a4-7c76-4f61-91b6-e2810a2a8f1c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"encryption-context":{}}},"a8d0e782-ea8f-47aa-afaa-306aadc84875":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"requiredEncryptionContextKeys":["a","b"],"encryption-context":{"a":"a","b":"b"}}},"aaa866d3-7de8-4f58-8236-71e60041218b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->Filter aws 658956600833","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"fa821e51-216b-45a7-a2ed-df8b18ea3075":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->Filter aws 658956600833","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"c04d84e5-bf32-4271-bd10-2ab059c4e2c3":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private Discovery ecc-521-private","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"fbf366ad-7a92-4d64-a37a-8fbb2f144831":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private Discovery ecc-384-private","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"e7e3fb29-bb15-4096-88d0-8a1dce09ee99":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private ecc-256-private","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"encryption-context":{}}},"f18cf342-0790-4c94-97c9-ca43568be3d9":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->Filter aws 658956600833","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"de9dcccc-80a1-4d66-98b6-e2b95a6a6848":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->Filter aws 658956600833","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"e57c4bf4-586c-4ef6-9225-568ba3d7251e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"encryption-context":{}}},"05fa3646-881d-43fb-b6d8-e888fb8bf1c1":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"909e1e7e-5cfb-47ce-ad1f-c0fc6657acca":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-192","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"encryption-context":{}}},"563ad342-46dc-4bbd-8f7c-cd130a5f6d5d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"c3ffd923-e90e-442a-8b6d-b39d0368a218":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private ecc-256-private","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"encryption-context":{}}},"456c0861-a6bc-4c36-ad1d-525f4401afa4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"e897c79f-fd8d-4f2c-9457-3ddc0656a5bf":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-256-ecc discovery","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-256-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"discovery"},"encryption-context":{}}},"374b44d2-e35f-4445-8ae7-a7e9f671c85d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-384-ecc discovery","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-384-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"discovery"},"encryption-context":{}}},"d0043fd8-74e1-4b7a-8b47-26875bb60a7c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-521-ecc discovery","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-521-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"discovery"},"encryption-context":{}}},"66a4ab54-01d3-4396-99a8-427918b5b94f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"requiredEncryptionContextKeys":["b"],"encryption-context":{"a":"a","b":"b"}}},"e7e030d7-8deb-44a3-9a69-bd1f95f064d0":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-128","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"encryption-context":{}}},"7288fa10-dadb-478c-9f3a-e83ea4784d19":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private ecc-384-private","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"encryption-context":{}}},"91a74a50-3613-4517-9b5f-ab8ae63c2605":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"encryption-context":{}}},"11675bd8-6d87-4bff-b48a-975cd6ad2c50":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-west-2-mrk","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"7b395dff-9e56-4a67-add9-94e22366453b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-east-1-mrk","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"0643c5ff-c2aa-44b4-af67-5375f366e489":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-west-2-mrk","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"effd0c8f-9f41-46a0-b418-bd149c0f239b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-east-1-mrk","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"2c691b97-ec68-4b94-840f-c2e96ed36b0c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private Discovery ecc-521-private","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"79538c85-8e9c-461d-a63a-6de180f27630":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-decryptable","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"encryption-context":{}}},"58088881-c826-4615-b2ee-546ea5ef9c07":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->Filter aws 658956600833","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"bfa38c23-9cad-4d89-b7b9-62ef8b3f1d1d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->Filter aws 658956600833","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"5846fcaf-dc85-43d1-9a54-e31dd32b6341":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"encryption-context":{}}},"d890aae6-906b-48d9-9bf3-381e1e0b2ef1":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-521-private","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-521-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-521","ecc-curve":"ecc-521","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"cee58501-f7a0-48cb-a2ee-0e72eef05d73":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-384-private","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-384-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-384","ecc-curve":"ecc-384","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"63e9c571-a33c-4127-92a8-97aa87825520":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-256","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"encryption-context":{}}},"ae2c36d1-a063-4040-bfe7-3967a6bfcc23":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private ecc-256-private","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"encryption-context":{}}},"4787d980-7c86-41bb-bb75-426d46b1e5fb":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"ede94639-3d86-454f-8041-408cb1981146":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"2194aca1-d32d-473e-af22-f3092609a080":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-192","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"encryption-context":{}}},"cdeca838-688e-4fa0-8e63-2e078c79806b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"3910a8f5-ecf0-4838-ae6e-08879332a4b2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"requiredEncryptionContextKeys":["b"],"encryption-context":{"a":"a","b":"b"}}},"dd819e7e-3abb-41d3-a326-450a4f956859":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-128","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"encryption-context":{}}},"ae813276-6530-4d05-9d82-b10c32e62556":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"encryption-context":{}}},"035e5528-1eee-49f3-8d25-3639684ef308":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Hierarchy KMS static-branch-key-1","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"decryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"encryption-context":{}}},"179b99b0-3db5-4cf2-94fd-a11485147508":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"requiredEncryptionContextKeys":["a","b"],"encryption-context":{"a":"a","b":"b"}}},"0b7d208f-12a4-4b87-9ff9-68c0bc419aa8":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private ecc-384-private","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"encryption-context":{}}},"e17a9cf7-9b13-4bf0-85fb-9edd5e555bbd":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"f41a810a-80e7-43c0-9fa8-3abdba894ce5":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"6ab68d1d-59d2-41ff-b591-711808af6b3a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private Discovery ecc-384-private","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"8d003786-d4c6-4f42-b313-6445f9fa9c8f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-decryptable","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"encryption-context":{}}},"ec6bd819-dc3f-4265-919b-8e013f660865":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->Filter aws 658956600833","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"7682b705-5cf8-41c1-9c8e-57d7b097336e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->Filter aws 658956600833","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"6ae8d4f5-e252-40f9-ba66-ea7ed9eec6d1":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-521-private","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-521-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-521","ecc-curve":"ecc-521","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"f4e5a86b-f531-4c86-a3a8-228a4e0a4e90":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private ecc-256-private","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"encryption-context":{}}},"c64e02f3-1d05-4104-b391-a9c0d32d98e2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-192","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"encryption-context":{}}},"654971ac-8bbb-42e4-aead-1e1fdf054a55":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-256-ecc discovery","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-256-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"discovery"},"encryption-context":{}}},"aed19935-a73f-4bf8-98af-e4ed86c162e4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-384-ecc discovery","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-384-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"discovery"},"encryption-context":{}}},"b366ea65-5d10-46ac-8dcb-5dcfd51407ba":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-521-ecc discovery","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-521-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"discovery"},"encryption-context":{}}},"0131ef96-9645-488d-8874-26de97696498":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"requiredEncryptionContextKeys":["b"],"encryption-context":{"a":"a","b":"b"}}},"3a27eee7-8805-439d-b13d-2c744902c153":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"encryption-context":{}}},"e9b2e981-98ce-4023-b427-d31701eac629":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"requiredEncryptionContextKeys":["a","b"],"encryption-context":{"a":"a","b":"b"}}},"51ce65f8-68a8-4e37-b1c5-01d37fb2cac7":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"566737a3-56dd-4ef0-92a9-90e47ca1cc63":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"encryption-context":{}}},"db63e3c4-57d4-47f3-b031-a29620240b7d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"encryption-context":{}}},"5c6d1b6c-4165-4ed1-bcc3-63e6e843de61":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private Discovery ecc-384-private","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"7ae145f4-03ab-4787-b936-9be66301b156":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"encryption-context":{}}},"9375ef66-75bb-490a-89ce-3aa798fc69f4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"encryption-context":{}}},"8d169ab3-0db4-41ad-9cab-7e455b62e3e6":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"requiredEncryptionContextKeys":["a","b"],"encryption-context":{"a":"a","b":"b"}}},"1ba013a0-e941-4b1e-9c8c-4017c0c12a90":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-west-2-mrk","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"17895ece-91c6-409c-bafc-02778e9edd57":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-east-1-mrk","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"7cc3ead0-dc27-493e-aba7-a61facd07ac9":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-west-2-mrk","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"986c21cc-66b9-416f-81d9-5f21d70ca132":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-east-1-mrk","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"a4c9ce6d-6db5-41ad-ad8f-4dc6c607a992":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->Filter aws 658956600833","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"dc124df3-50d8-4280-8030-a31149ec0701":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->Filter aws 658956600833","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"36330aff-f73f-41fa-916c-d3746d20c2de":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-384-private","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-384-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-384","ecc-curve":"ecc-384","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"06ea52e4-3847-4891-bca3-74ba20165253":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-256-ecc discovery","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-256-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"discovery"},"encryption-context":{}}},"27b55a80-b83a-42e4-8483-09739a1537e0":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-384-ecc discovery","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-384-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"discovery"},"encryption-context":{}}},"d6561d08-89c6-4faa-b6d1-bc7601ef5d71":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-521-ecc discovery","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-521-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"discovery"},"encryption-context":{}}},"3f35e687-617b-4ee5-8b8a-bfc54fac5c53":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-256","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"encryption-context":{}}},"7e38e2f9-3042-4859-90d3-08cd2ba1c319":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private Discovery ecc-384-private","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"78fc2795-7fca-4981-aee6-422e14f78278":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private ecc-256-private","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"encryption-context":{}}},"9fb875c7-2767-4a8f-b41b-c24bbe42a4f4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"encryption-context":{}}},"5b47739b-5e37-47dc-9392-f13314d6253a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-256-ecc discovery","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-256-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"discovery"},"encryption-context":{}}},"10516a25-a4ce-4848-a882-4e22937baf68":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-384-ecc discovery","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-384-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"discovery"},"encryption-context":{}}},"92dff818-0d55-4cbc-9fa5-e9a5d64451ec":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-521-ecc discovery","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-521-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"discovery"},"encryption-context":{}}},"caabf4cd-acc9-4ee9-8f6d-4c560774535b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"encryption-context":{}}},"95289e7d-a510-49b2-8eea-e86da571bf97":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-mrk","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"encryption-context":{}}},"9678421f-edd6-4dee-8746-e80576e272b0":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"encryption-context":{}}},"9d7f5363-a507-424f-a2c7-bbe70b2c8dc7":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Hierarchy KMS static-branch-key-1","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"decryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"encryption-context":{}}},"4d3ccbb1-bfd1-4f45-a923-a241ca52362c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-west-2-mrk","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"2f90c444-8210-4171-8a63-005213b151cc":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-east-1-mrk","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"fd1a6c18-b0a7-463e-b1c0-cdd2c4b798e6":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-west-2-mrk","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"f32f403c-015f-40e5-9a02-7a1de71c9706":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-east-1-mrk","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"a253b5fc-db34-43ee-aee3-d3d295567bd4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-mrk","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"encryption-context":{}}},"bf9a0883-2e7f-4735-b28c-a140b71bf6d8":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"encryption-context":{}}},"c29880e1-f210-46c8-b387-61acb4286f80":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-384-private","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-384-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-384","ecc-curve":"ecc-384","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"f2a41c8b-89d1-4159-bd05-938aa4e62df6":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"96237cf3-350f-4aac-ba03-e0a13455c8c2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"requiredEncryptionContextKeys":["a"],"encryption-context":{"a":"a","b":"b"}}},"f49ddee0-916e-4fbd-ba76-aa76a828d05a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"8c33bf3f-56cf-41aa-96b9-4ae040099313":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-256","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"encryption-context":{}}},"a29b38de-e6ff-45fa-b296-8f3ef871d73e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"encryption-context":{}}},"9cf37807-0c13-44eb-af61-af3a4fc9ef9b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"requiredEncryptionContextKeys":["a"],"encryption-context":{"a":"a","b":"b"}}},"2f35f2dc-2910-4809-8352-e05e7e3a1078":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private Discovery ecc-256-private","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"1262f0b9-87df-4848-8cd2-96d2b4cc1484":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-west-2-mrk","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"40a872dc-06c2-475c-b5ce-a6222d8b3d6f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-east-1-mrk","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"f14c86e9-dd57-4014-b181-f9d1c109679c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-west-2-mrk","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"da352672-d424-4711-840b-ce2900eb67a9":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-east-1-mrk","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"7500bc0f-8ffa-48a7-b0ce-27a22c50daa6":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-384-private","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-384-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-384","ecc-curve":"ecc-384","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"6ed3013d-0238-4de3-a656-ec16eb721da0":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"encryption-context":{}}},"65dbbfb5-32db-49ad-8caa-1a1bc8d19997":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private Discovery ecc-256-private","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"9244ff35-95ef-467a-81ca-548c0e4d7d1c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"requiredEncryptionContextKeys":["a","b"],"encryption-context":{"a":"a","b":"b"}}},"861f891e-c54a-4a6e-8b7e-22fad24c685b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-256","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"encryption-context":{}}},"dc367cfd-dfa2-44e0-9b24-cfa6c0ffb8bb":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Hierarchy KMS static-branch-key-1","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"decryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"encryption-context":{}}},"b02e385c-b10d-44d9-ba4c-13ef717e4c78":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"encryption-context":{}}},"bebe6f5a-a0fb-4a78-ab16-e9613642e94e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"055e0691-66c9-4552-abd2-617572462fe0":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-mrk","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"encryption-context":{}}},"5a6c7f0c-870a-4596-9c6a-7701ed71fba6":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private ecc-521-private","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"encryption-context":{}}},"91865d07-7f39-4290-abd8-3ac9b47d9a69":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private Discovery ecc-384-private","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"93d1e306-d592-47fd-98c3-8aac47b05da0":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"encryption-context":{}}},"6092b306-d50b-4a71-8d06-eddb7c5c52a9":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"encryption-context":{}}},"196b7f2a-218a-4e05-abe8-d06901c43275":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"encryption-context":{}}},"6eb22e4f-fd26-49c5-8525-9266baa0ae8b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"9f80c72a-f0ce-403f-9d48-9db3aca02a09":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Hierarchy KMS static-branch-key-1","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"decryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"encryption-context":{}}},"8b1ec9ac-0372-4bac-982c-59863b818dbc":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private ecc-521-private","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"encryption-context":{}}},"af406edf-17b3-4603-9fa3-24a039613896":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"a330f0be-7275-43f1-9353-caf1eb56ff56":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"requiredEncryptionContextKeys":["a"],"encryption-context":{"a":"a","b":"b"}}},"cc46dfd2-dacd-49ee-ab42-2e90bf7e97ca":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"encryption-context":{}}},"6f5cb2a7-eda5-4ad3-b2a9-30fecd836fe8":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-256-ecc discovery","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-256-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"discovery"},"encryption-context":{}}},"68396932-6aa5-4ac6-bba6-86c33390de36":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-384-ecc discovery","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-384-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"discovery"},"encryption-context":{}}},"c17bf598-ba2c-44b0-955c-44d831b97d9f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-521-ecc discovery","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-521-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"discovery"},"encryption-context":{}}},"d9451f69-3fff-4c58-a141-fd2c2184c46d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"dbe803dd-8b64-4765-88d7-b1cc0f580da0":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-128","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"encryption-context":{}}},"dd2ae4da-6b89-4bbb-860c-229cd62a0f69":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private Discovery ecc-256-private","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"dbc349a0-411b-4f8f-8447-c5e4e86ae0a4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-256-private","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-256-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-256","ecc-curve":"ecc-256","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"f7cab6f4-dbde-40f0-8aa3-e97b3b7f2dae":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-256-ecc us-west-2-256-ecc","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"encryption-context":{}}},"c1302869-1018-43f0-8863-1a911ce5fc01":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-384-ecc us-west-2-384-ecc","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"encryption-context":{}}},"a9633369-6667-4bb3-8003-d4e76b0534a1":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-521-ecc us-west-2-521-ecc","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"encryption-context":{}}},"b5864403-9c61-4060-bb1f-d84ecad8ecbf":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"encryption-context":{}}},"7dcaa6ba-792a-4f4f-a13d-d2bd88ee6fc2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"requiredEncryptionContextKeys":["a","b"],"encryption-context":{"a":"a","b":"b"}}},"74b5dee8-5de5-4519-b2f1-c0f950041158":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-256-private","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-256-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-256","ecc-curve":"ecc-256","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"3e2c91ba-fb8b-40b1-b40b-f46835ba1940":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"encryption-context":{}}},"2adb54b7-7a4a-4e4c-a750-e080e4fea1b8":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-256-ecc us-west-2-256-ecc","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"encryption-context":{}}},"e9a0565d-3cab-496a-956b-3efb3fe8d881":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-384-ecc us-west-2-384-ecc","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"encryption-context":{}}},"fe9aedfc-4f75-4181-9d73-092db67dfaa6":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-521-ecc us-west-2-521-ecc","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"encryption-context":{}}},"f2c2cd2c-2e9e-43b5-8466-d8e2787a9f01":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"encryption-context":{}}},"34f36842-a7eb-4bff-ad91-bf99c282ee22":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-west-2-mrk","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"0fca7671-fcc2-4815-9023-0a1788af5106":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-east-1-mrk","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"b6cff7ba-8e8d-4aff-bf8c-03b83cd0ffdb":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-west-2-mrk","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"0fe9d687-25ca-4e0d-86e8-af3fa9012dc9":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-east-1-mrk","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"d5a83f5d-3eaf-40bc-a91a-daf59a1663b4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-mrk","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"encryption-context":{}}},"e3d4a59e-c17e-4257-8213-d21900e0f31f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private Discovery ecc-384-private","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"cca531ba-d4f8-4113-ae00-7b382488c68b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private ecc-521-private","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"encryption-context":{}}},"fda86acb-5b78-4bdf-9bdf-1af98194ec80":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"encryption-context":{}}},"f0d400dd-c1da-4b44-b180-64b3e407cf87":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-384-private","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-384-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-384","ecc-curve":"ecc-384","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"f6b8bcad-f036-4c8a-8c25-cf364ea600ec":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-192","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"encryption-context":{}}},"363fea05-7000-476e-ba3d-1d4da5fb52f8":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"encryption-context":{}}},"cb618fa7-fba6-4b3f-af3a-9f38d1bb8bb4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-256","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"encryption-context":{}}},"2edfc08f-7084-4343-a7bd-53fadc4c14f3":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"requiredEncryptionContextKeys":["b"],"encryption-context":{"a":"a","b":"b"}}},"5341268b-a362-4cdb-9072-ab59567aaa99":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"requiredEncryptionContextKeys":["a"],"encryption-context":{"a":"a","b":"b"}}},"4cd66b72-cc9d-49db-a5bd-e9f201018f5d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-256-ecc discovery","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-256-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"discovery"},"encryption-context":{}}},"0fd235a6-eadc-45ee-b5f7-65bec9491592":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-384-ecc discovery","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-384-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"discovery"},"encryption-context":{}}},"85cf3952-6fda-4f44-84bf-0e7495356111":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Discovery us-west-2-521-ecc discovery","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"discovery","recipient":"us-west-2-521-ecc","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"discovery"},"encryption-context":{}}},"6cb88415-3d3a-438d-bdad-d47b9579aea7":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->No Filter","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"fd13c8d9-025f-4ece-b58a-d64e24f25c5d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->No Filter","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"1964f546-3685-4544-8f5b-55d12d3bf1e6":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private Discovery ecc-256-private","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"82420121-fcce-4443-924c-cffd60e30cb4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-256-private","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-256-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-256","ecc-curve":"ecc-256","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"73de96c9-132d-483e-ac15-6d00dc1a2c91":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Hierarchy KMS static-branch-key-1","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"decryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"encryption-context":{}}},"37a74fa1-9f9a-4468-b640-d50809ec723a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-256-ecc us-west-2-256-ecc","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"encryption-context":{}}},"67a0ebae-4692-405a-8754-3e3bbe85e567":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-384-ecc us-west-2-384-ecc","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"encryption-context":{}}},"e60816ee-fb24-43d9-801d-0a0b0ff26df4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-521-ecc us-west-2-521-ecc","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"encryption-context":{}}},"73358302-d1e3-454d-988b-7bcd5f7c143a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->No Filter","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"92c8a3ad-6dc1-4e06-8666-9d1705d8cc3d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->No Filter","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"43b098b6-f78a-4065-9a0a-14f5729839a7":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"78b8c723-5168-482f-bb11-df6cfd250eb2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"9e5ddde9-1ebb-4af5-a8cf-334b123ed98d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha1"},"encryption-context":{}}},"debdbb3c-c6fb-4605-bd37-12c9c76f3d51":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->Filter aws 658956600833","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"68269fc3-e912-4b5a-901e-fb087d864310":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->Filter aws 658956600833","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"c8af8a4f-56d2-4071-b0cb-86beef384eb0":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"c5a72c38-436d-471b-9555-2813c980105a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-mrk","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"encryption-context":{}}},"e04fa443-8af1-4f34-924c-94aad42547ee":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-west-2-mrk","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"5e9e8b47-28ea-45d5-b15f-a40249d3378c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-west-2-mrk->us-east-1-mrk","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"43c99643-b2b7-4649-9066-2b561c20777a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-west-2-mrk","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"encryption-context":{}}},"59ed58af-9c48-45d0-adfa-000fc3a62e65":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS MRK us-east-1-mrk->us-east-1-mrk","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"encryption-context":{}}},"10aea2ef-0de0-4de7-97e2-c7f0d51cc32a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"encryption-context":{}}},"ce199203-4c9c-4c15-9a11-04d89038ca9c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"encryption-context":{}}},"2ed88cf8-7c2e-4ce3-9591-c332128c126d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"7c4c7cad-3c05-4e7e-a154-a0c16534a05d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private ecc-256-private","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"encryption-context":{}}},"2263db25-6bfe-4982-98b5-700b652ff093":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private ecc-521-private","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"encryption-context":{}}},"616d30e8-7b3a-42f6-9988-749a4e61c8af":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-384-private","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-384-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-384","ecc-curve":"ecc-384","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"c4163f89-aa5a-4619-925f-2bc00c3faabc":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-256","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"encryption-context":{}}},"a4e9a29e-bc61-4bec-b639-e537b410649d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"encryption-context":{}}},"9733badf-2b7c-43da-915a-9f4303a734d2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"requiredEncryptionContextKeys":["a"],"encryption-context":{"a":"a","b":"b"}}},"eec6e173-a713-4d8a-88bd-0878837931e5":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-128","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"encryption-context":{}}},"4fe8da32-c7aa-4999-8166-f69fee890c87":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private Discovery ecc-256-private","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"9332efaa-463c-402a-bb13-04968298c715":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->No Filter","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"5badd892-d9de-4c41-9289-a3a4e524c71b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->No Filter","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"e60788e0-9e52-4a62-b408-39900ad29165":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-256-private","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-256-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-256","ecc-curve":"ecc-256","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"de394013-abea-41f8-8a6d-64ccfc8b24a2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Hierarchy KMS static-branch-key-1","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"decryptKeyDescription":{"type":"aws-kms-hierarchy","key":"static-branch-key-1"},"encryption-context":{}}},"ca6d18bc-b228-438e-93e8-5b72de294156":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-256-ecc us-west-2-256-ecc","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"encryption-context":{}}},"08cd577b-2ac7-4ff0-ac64-bc8679c63b27":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-384-ecc us-west-2-384-ecc","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"encryption-context":{}}},"03cae626-93ea-4a4a-9b27-1caed04b090b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-521-ecc us-west-2-521-ecc","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"encryption-context":{}}},"a33d5cd9-3b4f-4354-94fb-41be4b1492b1":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"encryption-context":{}}},"92ebc779-5d72-481b-9562-c8c69c5cd980":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"b969fa29-9fe3-426a-872e-2cfe772d5d26":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"3e002b31-5983-4121-a5f4-1ea4a05c39d4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"8bd2c2be-2d32-4c44-ba07-01e17b283da6":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private ecc-521-private","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"encryption-context":{}}},"fd6fdb84-fedc-45a7-a6a6-1f707b6b9beb":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-192","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"encryption-context":{}}},"3a03581e-30da-44d0-8027-559090b1e858":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"encryption-context":{}}},"64a84f2b-2f84-423e-a7f1-955fb9d2b665":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-128","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"encryption-context":{}}},"a2b068bf-e8fb-41ac-b05e-cec761dc614e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"encryption-context":{}}},"26b46fbc-0685-411d-ad9f-50e67160be28":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"requiredEncryptionContextKeys":["b"],"encryption-context":{"a":"a","b":"b"}}},"d3335bc1-56f6-4423-bd4f-86a1a7339296":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"a5fff269-d475-4fae-94c7-24a065b7b0f2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"972312f5-432e-496e-b3d7-cdcbca3b3420":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"685b9f56-72a1-4f6e-8a2e-9a2391281443":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-256-private","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-256-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-256","ecc-curve":"ecc-256","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"3932de55-3020-4af5-a80f-fc4a668f5e48":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->No Filter","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"6701c107-520c-47b3-b9d7-b5363640eb7f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->No Filter","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"179999de-8f2b-46d9-8b3b-10f7c37189dd":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-128","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"encryption-context":{}}},"856ac5a8-e8fc-4da2-b577-e06113aa095e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-256-ecc us-west-2-256-ecc","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"encryption-context":{}}},"b4a60913-35e9-46c1-a3a2-fe263cbe6f54":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-384-ecc us-west-2-384-ecc","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"encryption-context":{}}},"c84f8353-a484-4adc-990e-2bda5311e207":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-521-ecc us-west-2-521-ecc","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"encryption-context":{}}},"07b89ab6-d823-466a-93da-58a60995958b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"9ceaf59f-c114-4663-b9d2-f5ed03437084":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->Filter aws 658956600833","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"e0a0a387-f34c-4a5d-8c23-dd5a720045f7":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->Filter aws 658956600833","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"144e5483-c373-4bb3-98d2-d75c60109c7d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-192","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"encryption-context":{}}},"7200b5ee-4b94-41c6-839f-f9c116c22874":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private Discovery ecc-521-private","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"d3e1a2c0-920a-45be-9ab5-b8181ca7e547":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"requiredEncryptionContextKeys":["b"],"encryption-context":{"a":"a","b":"b"}}},"912ab406-32f2-46b6-84a8-eb874dc588be":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private ecc-256-private","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"encryption-context":{}}},"9d20e94e-801d-40df-a9e1-5ae37a3cec15":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private Discovery ecc-521-private","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"86c86efa-c6ee-49fc-8190-87a79aa37191":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-192","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"encryption-context":{}}},"20523fa0-f01f-4667-b38a-6ecc099cb141":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"0d691040-e02a-49ca-a8a9-8c907f8ff2c2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"6b623b3a-ab84-45b3-828f-7d8e1eac2d17":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"encryption-context":{}}},"ee1d0d50-3bdc-4e09-bfb1-5e0c6b2e8e07":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"requiredEncryptionContextKeys":["b"],"encryption-context":{"a":"a","b":"b"}}},"e1861731-a3fb-411d-990f-5ec77cd8c20e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->No Filter","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"04adc2dd-2321-4af6-a849-d7bfdc24b87e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->No Filter","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"75a6548f-9296-4982-9962-d6536a6b579c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"90f8b360-09f9-48d0-ae07-1ba8f46b8804":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->Filter aws 658956600833","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"4d565e4a-9c0e-40bf-aaa2-be656d60d890":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->Filter aws 658956600833","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"9ff4709b-a3b9-4a2a-8f37-3705e1ec6c8a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private ecc-384-private","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"encryption-context":{}}},"7ee03083-4ff0-4ccf-8ebf-d2653bc8ae97":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"f8943098-034b-4370-b213-3a852354be72":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"98ce1db3-41f5-4649-a198-ebdd8ba5f1b4":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private ecc-256-private","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"encryption-context":{}}},"6430c78c-ce13-4685-86a9-5bf8d8ddde8f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private ecc-384-private","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"encryption-context":{}}},"2878909e-7230-401c-8136-fe6eae98559c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-decryptable","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"encryption-context":{}}},"b04d0a43-a873-410c-8655-60910bf7219a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private Discovery ecc-521-private","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"ddb87afa-d3c8-4df4-9037-9c657eaffe80":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-521-private","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-521-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-521","ecc-curve":"ecc-521","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"f60db439-176a-4ce6-b4dd-045a17b8f0fe":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->Filter aws 658956600833","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"f2e28ad3-7d46-467c-93bc-749538b0d4e5":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->Filter aws 658956600833","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"4d6eb7d7-9259-4136-b816-194157cd4ad5":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"encryption-context":{}}},"c3e2fbca-5684-4734-be2d-12a0ca0d1287":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-128","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"encryption-context":{}}},"c614ae14-9e60-4a90-b50f-d47751873c7c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-decryptable","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"encryption-context":{}}},"59c50c1d-6e56-443d-ae58-b386a12924ea":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private ecc-256-private","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"encryption-context":{}}},"806427ef-3014-4c74-8f99-d977be42d144":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-521-private","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-521-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-521","ecc-curve":"ecc-521","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"047c4c98-a510-4155-9775-e64f8950dab7":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"7b3b61bc-6178-4b7c-87a1-6b4bd994adee":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"491ba906-9078-4c99-86c9-59f1631199aa":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-mrk","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"encryption-context":{}}},"c8605db9-651d-4014-92bd-2cf24aa02efe":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"encryption-context":{}}},"c78a197e-867e-44f9-8079-d55837daeb29":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private ecc-384-private","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"encryption-context":{}}},"948b9621-6c18-4436-9801-ceb6549bfd42":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_256"},"encryption-context":{}}},"cf947f1d-40d1-4c7b-8f76-dc3340519975":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"ebdbda2e-3e29-4f59-9df8-39ff49fe6f56":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-192","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"encryption-context":{}}},"cd9ae617-19d8-4a3e-b9fb-97485eff4f36":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"requiredEncryptionContextKeys":["a"],"encryption-context":{"a":"a","b":"b"}}},"3b9e0c21-7225-4090-aeb0-7b10949d0ee9":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"requiredEncryptionContextKeys":["b"],"encryption-context":{"a":"a","b":"b"}}},"5efc47aa-54cb-4988-adff-75743edffa05":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private Discovery ecc-256-private","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"c2091f2a-442f-431b-b40a-d0c7141b66b3":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-decryptable","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"encryption-context":{}}},"d0ee6df4-fe8c-4d0f-9ebe-2d447e4eb501":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private Discovery ecc-521-private","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"f20c99d0-e0c1-45b2-b27d-3ded8517151c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-521-private","algorithmSuiteId":"0046","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-521-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-521","ecc-curve":"ecc-521","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"41359116-b291-4222-a318-0ecdc1702b92":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS RSA us-west-2-rsa-mrk","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"decryptKeyDescription":{"type":"aws-kms-rsa","key":"us-west-2-rsa-mrk","encryption-algorithm":"RSAES_OAEP_SHA_1"},"encryption-context":{}}},"0345b211-c8bb-4f4a-b6c4-3d0a84c98560":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-128","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},"encryption-context":{}}},"b2c06954-6936-434f-9c27-12110077a4b5":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"encryption-context":{}}},"f6b9c438-6158-4b34-9fe9-58e03d8e65ec":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"861ae2d7-edd3-447a-bdb7-f718ac543fe3":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"fd73c25b-58af-446a-a6be-13590d8fb77c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->Filter aws 658956600833","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"39896fc9-5d2c-4ae6-be7f-c7eec6522b5c":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->Filter aws 658956600833","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"8a2ff743-aedf-430f-aa0c-092330250f09":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private ecc-521-private","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"encryption-context":{}}},"6655f461-4148-4414-878a-da81bbd47194":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"encryption-context":{}}},"75995058-d1b2-47dd-9138-eee33609a77a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private ecc-256-private","algorithmSuiteId":"0214","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"encryption-context":{}}},"b86a249f-b0a1-4b81-8184-c60a4def4a5e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private ecc-384-private","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"encryption-context":{}}},"f86171a9-8524-4745-b656-b644aa74dad6":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawAES aes-192","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"decryptKeyDescription":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},"encryption-context":{}}},"a3b95111-7ce5-4de5-a379-5db258496439":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["b"]},"requiredEncryptionContextKeys":["b"],"encryption-context":{"a":"a","b":"b"}}},"752c8bb0-c423-4c49-be2f-b75e7a52f714":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private Discovery ecc-521-private","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"4d22b432-8692-4862-95bb-71a7566cd4a2":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"encryption-context":{}}},"97a1c5e7-28c5-4b97-87f4-06a100318681":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-decryptable","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"encryption-context":{}}},"64fdd23d-e3e4-4ea9-b753-0d700d658cc1":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-256-private","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-256-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-256","ecc-curve":"ecc-256","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"958e549d-3aa6-41d0-9e29-52744313cb13":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-521-private","algorithmSuiteId":"0114","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-521-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-521","ecc-curve":"ecc-521","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"74e2e109-d48a-4506-9101-a295cc35d94f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-256-ecc us-west-2-256-ecc","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-256-ecc","recipient":"us-west-2-256-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-256-ecc","schema":"static"},"encryption-context":{}}},"7bca7482-a5ce-42e6-afb8-05fb0fef7e5a":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-384-ecc us-west-2-384-ecc","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-384-ecc","recipient":"us-west-2-384-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-384-ecc","schema":"static"},"encryption-context":{}}},"07ed6ad3-e303-4971-b4fe-820c86a88b19":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"AWS KMS ECDH Static us-west-2-521-ecc us-west-2-521-ecc","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"decryptKeyDescription":{"type":"aws-kms-ecdh","sender":"us-west-2-521-ecc","recipient":"us-west-2-521-ecc","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","ecc-curve":"us-west-2-521-ecc","schema":"static"},"encryption-context":{}}},"789376ab-8b1b-489a-8de6-53e84c439749":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-256","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"},{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}},"encryption-context":{}}},"1170ae2d-7acd-4d26-b714-da2a89b85dc7":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-mrk","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"encryption-context":{}}},"dca7eee7-af52-4440-963c-554721715e1d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"encryption-context":{}}},"58fdc353-0214-4d28-975d-cbac2d18cdd3":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha512"},"encryption-context":{}}},"48774778-cf17-4c9b-b27e-8e13cce25736":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->Filter aws 658956600833","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"6de761d2-cf59-4260-882e-dafa3ccbed7b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->Filter aws 658956600833","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2","aws-kms-discovery-filter":{"partition":"aws","account-ids":["658956600833"]}},"encryption-context":{}}},"49659ce1-d2bc-4eed-802e-93480fba9fff":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private ecc-384-private","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"encryption-context":{}}},"ccdbf370-24db-457f-a282-394c17c29b99":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private ecc-256-private","algorithmSuiteId":"0014","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"encryption-context":{}}},"1cc9dede-1f3c-4c57-a065-78f2d650c17b":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"requiredEncryptionContextKeys":["a"],"encryption-context":{"a":"a","b":"b"}}},"50d45663-73b0-4c93-8932-8dfac00f790e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"43383e73-9fdc-4093-b278-3e650b310386":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private Discovery ecc-256-private","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"7b4102b7-243f-44fe-95a1-b42c4c8e1326":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-decryptable","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-decryptable"},"encryption-context":{}}},"963514b0-88e3-4091-8a41-8f640572b431":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Ephemeral-Discovery ephemeral ecc-521-private","algorithmSuiteId":"0346","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ephemeral","recipient":"ecc-521-private","sender-public-key":"ephemeral","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-ephemeral ecc-521","ecc-curve":"ecc-521","schema":"ephemeral"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-521-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-521","ecc-curve":"ecc-521","schema":"discovery"},"encryption-context":{}}},"096feea7-f3a9-4508-b59f-e27e84c8ece1":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-west-2-mrk->No Filter","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"4529c730-c789-4a39-b29e-0f18476dce31":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated Discovery KMS MRK us-east-1-mrk->No Filter","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"aws-kms-mrk-aware","key":"us-east-1-mrk"},"decryptKeyDescription":{"type":"aws-kms-mrk-aware-discovery","default-mrk-region":"us-west-2"},"encryption-context":{}}},"864520c1-d30a-4f24-8332-b8b552d4d919":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-128","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"},{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"}],"generator":{"type":"raw","key":"aes-128","provider-id":"aws-raw-vectors-persistent-aes-128","encryption-algorithm":"aes"}},"encryption-context":{}}},"cc490453-b421-4dc4-ac15-5d8e8799fbab":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-mrk","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"encryption-context":{}}},"0d4e7137-00b5-4f9c-a0e8-e59762375eae":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"encryption-context":{}}},"eec91f03-b347-4b5a-8df5-8e2a711d3b99":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"encryption-context":{}}},"a2c4e2ee-af21-46f9-ac0b-2248459e1391":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"requiredEncryptionContextKeys":["a","b"],"encryption-context":{"a":"a","b":"b"}}},"a98fe164-b4ed-4eb9-b319-58031ecbf3a6":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"MultiKeyring aes-192","algorithmSuiteId":"0146","frame-size":512,"encryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"decryptKeyDescription":{"type":"multi-keyring","childKeyrings":[],"generator":{"type":"raw","key":"aes-192","provider-id":"aws-raw-vectors-persistent-aes-192","encryption-algorithm":"aes"}},"encryption-context":{}}},"91dc1f4b-c31f-452a-b7d4-41501f6b9da3":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha384"},"encryption-context":{}}},"45817a1d-4312-4eaf-aa79-7a8fd7ea6b1d":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a"]},"requiredEncryptionContextKeys":["a"],"encryption-context":{"a":"a","b":"b"}}},"67755c3c-485c-498d-afb1-99140ebd9dc1":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Success testing requiredEncryptionContextKeys/reproducedEncryptionContext","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"decryptKeyDescription":{"type":"required-encryption-context-cmm","underlying":{"type":"raw","key":"aes-256","provider-id":"aws-raw-vectors-persistent-aes-256","encryption-algorithm":"aes"},"requiredEncryptionContextKeys":["a","b"]},"requiredEncryptionContextKeys":["a","b"],"encryption-context":{"a":"a","b":"b"}}},"625b4067-9a29-43dc-b067-27874dee2199":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-521-private ecc-521-private","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-521-private","recipient":"ecc-521-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-521","ecc-curve":"ecc-521","schema":"static"},"encryption-context":{}}},"7fa61c9a-edf7-4204-aa77-db306ac9ab7f":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private Discovery ecc-384-private","algorithmSuiteId":"0378","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}},"33ea3385-b844-4fb7-890d-3f939ab39c26":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated KMS us-west-2-mrk","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"decryptKeyDescription":{"type":"aws-kms","key":"us-west-2-mrk"},"encryption-context":{}}},"d515304a-7c47-400e-9dbd-8334a42e9668":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0178","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"pkcs1","padding-hash":"sha1"},"encryption-context":{}}},"5319018c-846b-4e56-b778-45c12d315fb0":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawRSA rsa-4096","algorithmSuiteId":"0078","frame-size":512,"encryptKeyDescription":{"type":"raw","key":"rsa-4096-public","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"decryptKeyDescription":{"type":"raw","key":"rsa-4096-private","provider-id":"aws-raw-vectors-persistent-rsa-4096","encryption-algorithm":"rsa","padding-algorithm":"oaep-mgf1","padding-hash":"sha256"},"encryption-context":{}}},"f4d928a0-ebcc-4b3e-abdd-96d976306b83":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-256-private Discovery ecc-256-private","algorithmSuiteId":"0478","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-256-private","recipient":"ecc-256-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-256","ecc-curve":"ecc-256","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-256-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-256","ecc-curve":"ecc-256","schema":"discovery"},"encryption-context":{}}},"ebd9c25e-8eb9-4e3d-95ab-65ec3c7de19e":{"encryption-scenario":{"type":"positive-esdk","plaintext":"small","description":"Generated RawECDH Static ecc-384-private Discovery ecc-384-private","algorithmSuiteId":"0578","frame-size":512,"encryptKeyDescription":{"type":"raw-ecdh","sender":"ecc-384-private","recipient":"ecc-384-private","sender-public-key":"sender-material-public-key","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-static ecc-384","ecc-curve":"ecc-384","schema":"static"},"decryptKeyDescription":{"type":"raw-ecdh","sender":"discovery","recipient":"ecc-384-private","sender-public-key":"discovery","recipient-public-key":"recipient-material-public-key","provider-id":"aws-raw-vectors-persistent-discovery ecc-384","ecc-curve":"ecc-384","schema":"discovery"},"encryption-context":{}}}}} \ No newline at end of file diff --git a/TestVectors/dafny/TestVectors/test/keys.json b/TestVectors/dafny/TestVectors/test/keys.json new file mode 100644 index 000000000..27ee2cd6a --- /dev/null +++ b/TestVectors/dafny/TestVectors/test/keys.json @@ -0,0 +1,220 @@ +{ + "manifest": { + "type": "keys", + "version": 2 + }, + "keys": { + "no-plaintext-data-key": { + "type": "static-material", + "algorithmSuiteId": "0014", + "encryptionContext": {}, + "encryptedDataKeys": [ + { + "keyProviderId": "static-material-keyring", + "keyProviderInfo": "c3RhdGljLXBsYWludGV4dA==", + "ciphertext": "AQEBAQEBAQEBAQEBAQEBAQ==" + } + ], + "requiredEncryptionContextKeys": [] + }, + "static-plaintext-data-key": { + "type": "static-material", + "algorithmSuiteId": "0014", + "encryptionContext": {}, + "encryptedDataKeys": [ + { + "keyProviderId": "static-material-keyring", + "keyProviderInfo": "c3RhdGljLXBsYWludGV4dA==", + "ciphertext": "AQEBAQEBAQEBAQEBAQEBAQ==" + } + ], + "requiredEncryptionContextKeys": [], + "plaintextDataKey": "AQEBAQEBAQEBAQEBAQEBAQ==" + }, + "static-cashable-plaintext-data-key": { + "type": "static-material", + "algorithmSuiteId": "0478", + "encryptionContext": {}, + "encryptedDataKeys": [ + { + "keyProviderId": "static-material-keyring", + "keyProviderInfo": "c3RhdGljLXBsYWludGV4dA==", + "ciphertext": "AQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQE=" + } + ], + "requiredEncryptionContextKeys": [], + "plaintextDataKey": "AQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQEBAQE=" + }, + "static-branch-key-1": { + "type": "static-branch-key", + "encrypt": true, + "decrypt": true, + "key-id": "bd3842ff-3076-4092-9918-4395730050b8", + "branchKeyVersion": "e9ce18a3-edb5-4272-9f86-1cacb7997ff6", + "branchKey": "tJwf65epYvUt5HMiQsl/6jlvLxS0tgdjIuvFy2BLIwg=", + "beaconKey": "RJiXTa/rJf+CLHAVyE652v3uhKreOuYjV+a7SVOugow=" + }, + "aes-128": { + "encrypt": true, + "decrypt": true, + "algorithm": "aes", + "type": "symmetric", + "bits": 128, + "encoding": "base64", + "material": "AAECAwQFBgcICRAREhMUFQ==", + "key-id": "aes-128" + }, + "aes-192": { + "encrypt": true, + "decrypt": true, + "algorithm": "aes", + "type": "symmetric", + "bits": 192, + "encoding": "base64", + "material": "AAECAwQFBgcICRAREhMUFRYXGBkgISIj", + "key-id": "aes-192" + }, + "aes-256": { + "encrypt": true, + "decrypt": true, + "algorithm": "aes", + "type": "symmetric", + "bits": 256, + "encoding": "base64", + "material": "AAECAwQFBgcICRAREhMUFRYXGBkgISIjJCUmJygpMDE=", + "key-id": "aes-256" + }, + "rsa-4096-private": { + "encrypt": true, + "decrypt": true, + "algorithm": "rsa", + "type": "private", + "bits": 4096, + "encoding": "pem", + "material": "-----BEGIN PRIVATE KEY-----\nMIIJQgIBADANBgkqhkiG9w0BAQEFAASCCSwwggkoAgEAAoICAQCztGg1gQ8AjCzz\n1VX6StqtW//jBt2ZQBoApaBa7FmLmdr0YlKaeEKSrItGbvA9tBjgsKhrn8gxTGQc\nuxgM92651jRCbQZyjE6W8kodijhGMXsfKJLfgPp2/I7gZ3dqrSZkejFIYLFb/uF/\nTfAQzNyJUldYdeFojSUPqevMgSAusTgv7dXYt4BCO9mxMp35tgyp5k4vazKJVUgB\nTw87AAYZUGugmi94Wb9JSnqUKI3QzaRN7JADZrHdBO1lIBryfCsjtTnZc7NWZ0yJ\nwmzLY+C5b3y17cy44N0rbjI2QciRhqZ4/9SZ/9ImyFQlB3lr9NSndcT4eE5YC6bH\nba0gOUK9lLXVy6TZ+nRZ4dSddoLX03mpYp+8cQpK6DO3L/PeUY/si0WGsXZfWokd\n4ACwvXWSOjotzjwqwTW8q9udbhUvIHfB02JW+ZQ07b209fBpHRDkZuveOTedTN2Q\nQei4dZDjWW5s4cIIE3dXXeaH8yC02ERIeN+aY6eHngSsP2xoDV3sKNN/yDbCqaMS\nq8ZJbo2rvOFxZHa2nWiV+VLugfO6Xj8jeGeR8vopvbEBZZpAq+Dea2xjY4+XMUQ/\nS1HlRwc9+nkJ5LVfODuE3q9EgJbqbiXe7YckWV3ZqQMybW+dLPxEJs9buOntgHFS\nRYmbKky0bti/ZoZlcZtS0zyjVxlqsQIDAQABAoICAEr3m/GWIXgNAkPGX9PGnmtr\n0dgX6SIhh7d1YOwNZV3DlYAV9HfUa5Fcwc1kQny7QRWbHOepBI7sW2dQ9buTDXIh\nVjPP37yxo6d89EZWfxtpUP+yoXL0D4jL257qCvtJuJZ6E00qaVMDhXbiQKABlo8C\n9sVEiABhwXBDZsctpwtTiykTgv6hrrPy2+H8R8MAm0/VcBCAG9kG5r8FCEmIvQKa\ndgvNxrfiWNZuZ6yfLmpJH54SbhG9Kb4WbCKfvh4ihqyi0btRdSM6fMeLgG9o/zrc\ns54B0kHeLOYNVo0j7FQpZBFeSIbmHfln4RKBh7ntrTke/Ejbh3NbiPvxWSP0P067\nSYWPkQpip2q0ION81wSQZ1haP2GewFFu4IEjG3DlqqpKKGLqXrmjMufnildVFpBx\nir+MgvgQfEBoGEx0aElyO7QuRYaEiXeb/BhMZeC5O65YhJrWSuTVizh3xgJWjgfV\naYwYgxN8SBXBhXLIVvnPhadTqsW1C/aevLOk110eSFWcHf+FCK781ykIzcpXoRGX\nOwWcZzC/fmSABS0yH56ow+I0tjdLIEEMhoa4/kkamioHOJ4yyB+W1DO6/DnMyQlx\ng7y2WsAaIEBoWUARy776k70xPPMtYAxzFXI9KhqRVrPfeaRZ+ojeyLyr3GQGyyoo\ncuGRdMUblsmODv4ixmOxAoIBAQDvkznvVYNdP3Eg5vQeLm/qsP6dLejLijBLeq9i\n7DZH2gRpKcflXZxCkRjsKDDE+fgDcBYEp2zYfRIVvgrxlTQZdaSG+GoDcbjbNQn3\ndjCCtOOACioN/vg2zFlX4Bs6Q+NaV7g5qP5SUaxUBjuHLe7Nc+ZkyheMHuNYVLvk\nHL/IoWyANpZYjMUU3xMbL/J29Gz7CPGr8Si28TihAHGfcNgn8S04OQZhTX+bU805\n/+7B4XW47Mthg/u7hlqFl+YIAaSJYvWkEaVP1A9I7Ve0aMDSMWwzTg9cle2uVaL3\n+PTzWY5coBlHKjqAg9ufhYSDhAqBd/JOSlv8RwcA3PDXJ6C/AoIBAQDABmXXYQky\n7phExXBvkLtJt2TBGjjwulf4R8TC6W5F51jJuoqY/mTqYcLcOn2nYGVwoFvPsy/Q\nCTjfODwJBXzbloXtYFR3PWAeL1Y6+7Cm+koMWIPJyVbD5Fzm+gZStM0GwP8FhDt2\nWt8fWEyXmoLdAy6RAwiEmCagEh8o+13oBfwnBllbz7TxaErsUuR+XVgl/iHwztdv\ncdJKyRgaFfWSh9aiO7EMV2rBGWsoX09SRvprPFAGx8Ffm7YcqIk34QXsQyc45Dyn\nCwkvypxHoaB3ot/48FeFm9IubApb/ctv+EgkBfL4S4bdwRXS1rt+0+QihBoFyP2o\nJ91cdm4hEWCPAoIBAQC6l11hFaYZo0bWDGsHcr2B+dZkzxPoKznQH76n+jeQoLIc\nwgjJkK4afm39yJOrZtEOxGaxu0CgIFFMk9ZsL/wC9EhvQt02z4TdXiLkFK5VrtMd\nr0zv16y06VWQhqBOMf/KJlX6uq9RqADi9HO6pkC+zc0cpPXQEWKaMmygju+kMG2U\nMm/IieMZjWCRJTfgBCE5J88qTsqaKagkZXcZakdAXKwOhQN+F2EStiM6UCZB5PrO\nS8dfrO8ML+ki8Zqck8L1qhiNb5zkXtKExy4u+gNr8khGcT6vqqoSxOoH3mPRgOfL\nJnppne8wlwIf7Vq3H8ka6zPSXEHma999gZcmy9t7AoIBAGbQhiLl79j3a0wXMvZp\nVf5IVYgXFDnAbG2hb7a06bhAAIgyexcjzsC4C2+DWdgOgwHkuoPg+062QV8zauGh\nsJKaa6cHlvIpSJeg3NjD/nfJN3CYzCd0yCIm2Z9Ka6xI5iYhm+pGPNhIG4Na8deS\ngVL46yv1pc/o73VxfoGg5UzgN3xlp97Cva0sHEGguHr4W8Qr59xZw3wGQ4SLW35M\nF6qXVNKUh12GSMCPbZK2RXBWVKqqJmca+WzJoJ6DlsT2lQdFhXCus9L007xlDXxF\nC/hCmw1dEl+VaNo2Ou26W/zdwTKYhNlxBwsg4SB8nPNxXIsmlBBY54froFhriNfn\nx/0CggEAUzz+VMtjoEWw2HSHLOXrO4EmwJniNgiiwfX3DfZE4tMNZgqZwLkq67ns\nT0n3b0XfAOOkLgMZrUoOxPHkxFeyLLf7pAEJe7QNB+Qilw8e2zVqtiJrRk6uDIGJ\nSv+yM52zkImZAe2jOdU3KeUZxSMmb5vIoiPBm+tb2WupAg3YdpKn1/jWTpVmV/+G\nUtTLVE6YpAyFp1gMxhutE9vfIS94ek+vt03AoEOlltt6hqZfv3xmY8vGuAjlnj12\nzHaq+fhCRPsbsZkzJ9nIVdXYnNIEGtMGNnxax7tYRej/UXqyazbxHiJ0iPF4PeDn\ndzxtGxpeTBi+KhKlca8SlCdCqYwG6Q==\n-----END PRIVATE KEY-----", + "key-id": "rsa-4096" + }, + "rsa-4096-public": { + "encrypt": true, + "decrypt": false, + "algorithm": "rsa", + "type": "public", + "bits": 4096, + "encoding": "pem", + "material": "-----BEGIN PUBLIC KEY-----\nMIICIjANBgkqhkiG9w0BAQEFAAOCAg8AMIICCgKCAgEAs7RoNYEPAIws89VV+kra\nrVv/4wbdmUAaAKWgWuxZi5na9GJSmnhCkqyLRm7wPbQY4LCoa5/IMUxkHLsYDPdu\nudY0Qm0GcoxOlvJKHYo4RjF7HyiS34D6dvyO4Gd3aq0mZHoxSGCxW/7hf03wEMzc\niVJXWHXhaI0lD6nrzIEgLrE4L+3V2LeAQjvZsTKd+bYMqeZOL2syiVVIAU8POwAG\nGVBroJoveFm/SUp6lCiN0M2kTeyQA2ax3QTtZSAa8nwrI7U52XOzVmdMicJsy2Pg\nuW98te3MuODdK24yNkHIkYameP/Umf/SJshUJQd5a/TUp3XE+HhOWAumx22tIDlC\nvZS11cuk2fp0WeHUnXaC19N5qWKfvHEKSugzty/z3lGP7ItFhrF2X1qJHeAAsL11\nkjo6Lc48KsE1vKvbnW4VLyB3wdNiVvmUNO29tPXwaR0Q5Gbr3jk3nUzdkEHouHWQ\n41lubOHCCBN3V13mh/MgtNhESHjfmmOnh54ErD9saA1d7CjTf8g2wqmjEqvGSW6N\nq7zhcWR2tp1olflS7oHzul4/I3hnkfL6Kb2xAWWaQKvg3mtsY2OPlzFEP0tR5UcH\nPfp5CeS1Xzg7hN6vRICW6m4l3u2HJFld2akDMm1vnSz8RCbPW7jp7YBxUkWJmypM\ntG7Yv2aGZXGbUtM8o1cZarECAwEAAQ==\n-----END PUBLIC KEY-----", + "key-id": "rsa-4096" + }, + "ecc-256-private":{ + "encrypt": true, + "decrypt": true, + "algorithm": "ecdh", + "type": "ecc-private", + "bits": 256, + "encoding": "pem", + "sender-material": "-----BEGIN PRIVATE KEY-----\nMIGHAgEAMBMGByqGSM49AgEGCCqGSM49AwEHBG0wawIBAQQgw+7YSKEOEAh8/DFZ\n22oSTm/D3jo4nH5tN48IUp0WjyuhRANCAASnUgx7SrlHhPIn3McZfc3cEIs8+XFf\n7JvhcuV1wWELGZ8AjuwnKjE0ielEwSY5HYzWCF773FvJaWGYGYGhSba8\n-----END PRIVATE KEY-----", + "recipient-material": "-----BEGIN PRIVATE KEY-----\nMIGHAgEAMBMGByqGSM49AgEGCCqGSM49AwEHBG0wawIBAQQgYvB/1CVSgfQDrE6A\nDz7pdgxcOb+AHnsaI4LQMY6s8JChRANCAARYxf/AeERu2Z3VtDokplDs/atuGIbW\n7IGhknbK2MP+NV/mbcaxl8Xki9FegBslxCbM66KaoOZR1bCxPpGub2aS\n-----END PRIVATE KEY-----", + "public-key-encoding": "base64-der", + "sender-material-public-key": "MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEp1IMe0q5R4TyJ9zHGX3N3BCLPPlxX+yb4XLldcFhCxmfAI7sJyoxNInpRMEmOR2M1ghe+9xbyWlhmBmBoUm2vA==", + "recipient-material-public-key": "MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEWMX/wHhEbtmd1bQ6JKZQ7P2rbhiG1uyBoZJ2ytjD/jVf5m3GsZfF5IvRXoAbJcQmzOuimqDmUdWwsT6Rrm9mkg==", + "key-id": "ecc-256" + }, + "ecc-384-private":{ + "encrypt": true, + "decrypt": true, + "algorithm": "ecdh", + "type": "ecc-private", + "bits": 384, + "encoding": "pem", + "sender-material": "-----BEGIN PRIVATE KEY-----\nMIG2AgEAMBAGByqGSM49AgEGBSuBBAAiBIGeMIGbAgEBBDAx0jhFAVQX2zykSLO/\n3VvDDaQJspek3404TtDZupcxi2rThfnxh96u8CYD6XfHikehZANiAAR2W/Cc8slJ\ngYSGi3e+38UUW6dFi1mJBNEZEbJ4vljgEzBo7FecTsCOQH8Zu2nX3eQpuboD8Fb7\nARpqq7rug5jKBMQLUbvridjLBRLuFsfaLpZ07ih4/+VduqQom7D31ik=\n-----END PRIVATE KEY-----", + "recipient-material": "-----BEGIN PRIVATE KEY-----\nMIG2AgEAMBAGByqGSM49AgEGBSuBBAAiBIGeMIGbAgEBBDALwMcT5K2IOUK5Ww5o\nqYrYLzKHuAvFs0VLuKvJOCmWa3NK2WXtUIJ2fPYzp2Y9oTShZANiAATXUn2WMiLB\nbf665ikArOEAOFgruhqAwlxy58BP42nodBZFFf4L7cy7vPLpasp3fFroN57tYfjy\nXL5Wc0vb+xJaTZLBTU/tRGvtjHH0hQgMib2ch6akUJAT6zuMgNNdd7A=\n-----END PRIVATE KEY-----", + "public-key-encoding": "base64-der", + "sender-material-public-key": "MHYwEAYHKoZIzj0CAQYFK4EEACIDYgAEdlvwnPLJSYGEhot3vt/FFFunRYtZiQTRGRGyeL5Y4BMwaOxXnE7AjkB/Gbtp193kKbm6A/BW+wEaaqu67oOYygTEC1G764nYywUS7hbH2i6WdO4oeP/lXbqkKJuw99Yp", + "recipient-material-public-key": "MHYwEAYHKoZIzj0CAQYFK4EEACIDYgAE11J9ljIiwW3+uuYpAKzhADhYK7oagMJccufAT+Np6HQWRRX+C+3Mu7zy6WrKd3xa6Dee7WH48ly+VnNL2/sSWk2SwU1P7URr7Yxx9IUIDIm9nIempFCQE+s7jIDTXXew", + "key-id": "ecc-384" + }, + "ecc-521-private":{ + "encrypt": true, + "decrypt": true, + "algorithm": "ecdh", + "type": "ecc-private", + "bits": 521, + "encoding": "pem", + "sender-material": "-----BEGIN PRIVATE KEY-----\nMIHuAgEAMBAGByqGSM49AgEGBSuBBAAjBIHWMIHTAgEBBEIANn8j3pIu1wiwkz7z\niPKuqj2MEVWKe/UW/8NEtvD9tKQmMlAzwY/QN93k+0TNlXpvJTUvjI2NZDKNoQ2b\n0B44YfyhgYkDgYYABAHfgnF9LoYBRWwXKKEFQa+Xfg+ztDRdTVTqNZ8roUYmNvLL\nLz2F8oEOhDbMJZ5r1B1C9w5uJqeF6tE8a3yzm47R/wAs0k6dY3wfDKD013Wnn+6e\nNw1mtrvTi6+Pej/ukYOuCjCwm8B0AvxBzdHk8Q/nCcspO9pIsRl/I4qNz4tPaGjJ\nTA==\n-----END PRIVATE KEY-----", + "recipient-material": "-----BEGIN PRIVATE KEY-----\nMIHuAgEAMBAGByqGSM49AgEGBSuBBAAjBIHWMIHTAgEBBEIBjhdIxb49QXi4OsOH\n5PNWnp/KePiuICqC+fxJJ6ceUgPr5SMlLxhHcfHSVZBCkGLP0Rjd1D9gi7Va1oxe\nIHmWRu2hgYkDgYYABAAmg0dilFc6FiO9OE8t1el92KdPo9WYu1hXYnjGYT7OuGj3\nbD9lr0KMNCm3wTPCiLjPb4Iqnk+g0SgrsQ4NvU7nygFBlgz8xXLzIXPqVICthcHX\nRWRB8HnXmyzeF0iCs12F/6vYn/uZfxp3IV/KCR4LwSzbiFzxsV9GYoCoUE30LDVb\nXg==\n-----END PRIVATE KEY-----", + "public-key-encoding": "base64-der", + "sender-material-public-key": "MIGbMBAGByqGSM49AgEGBSuBBAAjA4GGAAQB34JxfS6GAUVsFyihBUGvl34Ps7Q0XU1U6jWfK6FGJjbyyy89hfKBDoQ2zCWea9QdQvcObianherRPGt8s5uO0f8ALNJOnWN8Hwyg9Nd1p5/unjcNZra704uvj3o/7pGDrgowsJvAdAL8Qc3R5PEP5wnLKTvaSLEZfyOKjc+LT2hoyUw=", + "recipient-material-public-key": "MIGbMBAGByqGSM49AgEGBSuBBAAjA4GGAAQAJoNHYpRXOhYjvThPLdXpfdinT6PVmLtYV2J4xmE+zrho92w/Za9CjDQpt8Ezwoi4z2+CKp5PoNEoK7EODb1O58oBQZYM/MVy8yFz6lSArYXB10VkQfB515ss3hdIgrNdhf+r2J/7mX8adyFfygkeC8Es24hc8bFfRmKAqFBN9Cw1W14=", + "key-id": "ecc-521" + }, + "us-west-2-decryptable": { + "encrypt": true, + "decrypt": true, + "type": "aws-kms", + "key-id": "arn:aws:kms:us-west-2:658956600833:key/b3537ef1-d8dc-4780-9f5a-55776cbb2f7f" + }, + "us-west-2-encrypt-only": { + "encrypt": true, + "decrypt": false, + "type": "aws-kms", + "key-id": "arn:aws:kms:us-west-2:658956600833:key/590fd781-ddde-4036-abec-3e1ab5a5d2ad" + }, + "us-west-2-mrk": { + "encrypt": true, + "decrypt": true, + "type": "aws-kms", + "key-id": "arn:aws:kms:us-west-2:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7" + }, + "us-east-1-mrk": { + "encrypt": true, + "decrypt": true, + "type": "aws-kms", + "key-id": "arn:aws:kms:us-east-1:658956600833:key/mrk-80bd8ecdcd4342aebd84b7dc9da498a7" + }, + "us-west-2-rsa-mrk": { + "encrypt": true, + "decrypt": true, + "algorithm": "rsa", + "type": "aws-kms-rsa", + "key-id": "arn:aws:kms:us-west-2:370957321024:key/mrk-63d386cb70614ea59b32ad65c9315297", + "bits": 2048, + "encoding": "pem", + "material": "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA27Uc/fBaMVhxCE/SpCMQ\noSBRSzQJw+o2hBaA+FiPGtiJ/aPy7sn18aCkelaSj4kwoC79b/arNHlkjc7OJFsN\n/GoFKgNvaiY4lOeJqEiWQGSSgHtsJLdbO2u4OOSxh8qIRAMKbMgQDVX4FR/PLKeK\nfc2aCDvcNSpAM++8NlNmv7+xQBJydr5ce91eISbHkFRkK3/bAM+1iddupoRw4Wo2\nr3avzrg5xBHmzR7u1FTab22Op3Hgb2dBLZH43wNKAceVwKqKA8UNAxashFON7xK9\nyy4kfOL0Z/nhxRKe4jRZ/5v508qIzgzCksYy7Y3QbMejAtiYnr7s5/d5KWw0swou\ntwIDAQAB\n-----END PUBLIC KEY-----" + }, + "us-west-2-256-ecc": { + "encrypt": true, + "decrypt": true, + "algorithm": "ecdh", + "type": "aws-kms-ecdh", + "sender-material": "arn:aws:kms:us-west-2:370957321024:key/eabdf483-6be2-4d2d-8ee4-8c2583d416e9", + "recipient-material": "arn:aws:kms:us-west-2:370957321024:key/0265c8e9-5b6a-4055-8f70-63719e09fda5", + "encoding": "base64-der", + "sender-material-public-key": "MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE18m54QsLUnhWU7gT8hkAceNbZ/WBGNUUSPCeIKqOyX5psiqyC1TXPOJXqKKaVv5Mg91WV9UjpboblOhNU35nRw==", + "recipient-material-public-key": "MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAE9istdPCuX9nF8EmA4tioe/k0TCa2M9VeBW1N9n0sxPA6uPVOfLtE4+KuYxAGT0dYoK6CY93nowUy1yS+R7A+wA==", + "key-id": "ecc-256" + }, + "us-west-2-384-ecc": { + "encrypt": true, + "decrypt": true, + "algorithm": "ecdh", + "type": "aws-kms-ecdh", + "sender-material": "arn:aws:kms:us-west-2:370957321024:key/7f35a704-f4fb-469d-98b1-62a1fa2cc44e", + "recipient-material": "arn:aws:kms:us-west-2:370957321024:key/29f0bef9-1677-4e74-b67e-acefab1295ff", + "encoding": "base64-der", + "sender-material-public-key": "MHYwEAYHKoZIzj0CAQYFK4EEACIDYgAEfQ0OHFvwskFVjQwfqV7jpo62I6uyGY+5SPRZb6CuJ96bVreLZXh485BcPv09O/DWnpTBm8LL+YcfsqM3ECvi2ee3bDGpH6xIdr28uvyG75t5wqBjYYtZQFDf/ydfG9mm", + "recipient-material-public-key": "MHYwEAYHKoZIzj0CAQYFK4EEACIDYgAEWgGNWQ+vEwlMxyMQkSsOAYGfT6IlgEkcanEOSjbeEpEnh8JHEiBHQ6QaROxJ7c3nEkbjbi0m+7ejBEGtkiqaY5Dsv5u1iV4fc/2v1RzPba1ZtudEmM16Eyy9LHswdJ7v", + "key-id": "ecc-384" + }, + "us-west-2-521-ecc": { + "encrypt": true, + "decrypt": true, + "algorithm": "ecdh", + "type": "aws-kms-ecdh", + "sender-material": "arn:aws:kms:us-west-2:370957321024:key/41b502e3-cc9d-442f-bd7b-d67faed0f22e", + "recipient-material": "arn:aws:kms:us-west-2:370957321024:key/c45f1043-53bb-4f37-adc5-4d25d4a84f9d", + "encoding": "base64-der", + "sender-material-public-key": "MIGbMBAGByqGSM49AgEGBSuBBAAjA4GGAAQAz86qnfp3s0cl+73PQhlUstfdg9EZDA/jtLjBTWYp/1EB7RHNm8q5hMg5kBfjRDUFhbRBMlUV1xBOTgqzoSWj4oAABnQKiXXGGyu6PMN4D9nVMDsOpJ1pWU7rQexWDahBrK+5hx3beFXUpvvFRQrGAt2icUXm18VO6Qwbp0da9jyGDSY=", + "recipient-material-public-key": "MIGbMBAGByqGSM49AgEGBSuBBAAjA4GGAAQAxLxcjtYfqc4+4oJZY0gGv2Ehu++CnVFea6uwXgEgLifq4eDSSVmQYvU8majsufpBXQwVjnDlQ7pGRw1j6K4FaLAAgYuMrmrwKtx/ZZtkbXzCwrqJY+sfCk8U5m89DX331cdBAhR2uVSPL2d5hp8up5v+EBpNArtdC5lZMx2ZrwKKYuQ=", + "key-id": "ecc-521" + } + } +} diff --git a/TestVectors/project.properties b/TestVectors/project.properties new file mode 100644 index 000000000..f5e8cdf0b --- /dev/null +++ b/TestVectors/project.properties @@ -0,0 +1,4 @@ +# This file stores the top level dafny version information. +# All elements of the project need to agree on this version. +dafnyVersion=4.8.1 +dafnyRuntimeJavaVersion=4.8.1 diff --git a/TestVectors/runtimes/java/.gitattributes b/TestVectors/runtimes/java/.gitattributes new file mode 100644 index 000000000..097f9f98d --- /dev/null +++ b/TestVectors/runtimes/java/.gitattributes @@ -0,0 +1,9 @@ +# +# https://help.github.com/articles/dealing-with-line-endings/ +# +# Linux start script should use lf +/gradlew text eol=lf + +# These are Windows script files and should use crlf +*.bat text eol=crlf + diff --git a/TestVectors/runtimes/java/.gitignore b/TestVectors/runtimes/java/.gitignore new file mode 100644 index 000000000..3eb69ad71 --- /dev/null +++ b/TestVectors/runtimes/java/.gitignore @@ -0,0 +1,21 @@ +# Ignore Gradle project-specific cache directory +.gradle +# For TestMPL, the build.gradle.kts define's the gradle wrapper version. +# This prevents having ANOTHER copy of gradle in the repo +gradlew +gradlew.bat +gradle/wrapper/gradle-wrapper.jar + +# Ignore Gradle build output directory +build + +# JetBrains +.idea/* +*.iml + +# Mac OS X +.DS_Store + +# Dafny Generated Java +src/main/dafny-generated/ +src/test/dafny-generated/ diff --git a/TestVectors/runtimes/java/build.gradle.kts b/TestVectors/runtimes/java/build.gradle.kts new file mode 100644 index 000000000..449254ba5 --- /dev/null +++ b/TestVectors/runtimes/java/build.gradle.kts @@ -0,0 +1,64 @@ +tasks.wrapper { + gradleVersion = "7.6" +} + +plugins { + `java-library` + `maven-publish` + `application` +} + +group = "software.amazon.cryptography" +version = "1.0.0-SNAPSHOT" +description = "AwsEncryptionSDKJavaTestVectors" + +java { + toolchain.languageVersion.set(JavaLanguageVersion.of(8)) + sourceSets["main"].java { + srcDir("src/main/java") + srcDir("src/main/dafny-generated") + srcDir("src/main/smithy-generated") + } + sourceSets["test"].java { + srcDir("src/test/dafny-generated") + srcDir("src/test/java") + } +} + +repositories { + // Use Maven Central for resolving dependencies. + mavenCentral() + mavenLocal() +} +dependencies { + implementation("org.dafny:DafnyRuntime:4.8.0") + implementation("software.amazon.smithy.dafny:conversion:0.1") + implementation("software.amazon.cryptography:aws-cryptographic-material-providers:1.7.0") + implementation("software.amazon.cryptography:TestAwsCryptographicMaterialProviders:1.7.2-SNAPSHOT") + implementation("software.amazon.cryptography:aws-encryption-sdk:1.0.0-SNAPSHOT") + implementation("com.amazonaws:aws-encryption-sdk-java:3.0.1") + implementation(platform("software.amazon.awssdk:bom:2.25.1")) + implementation("software.amazon.awssdk:dynamodb") + implementation("software.amazon.awssdk:dynamodb-enhanced") + implementation("software.amazon.awssdk:kms") +} + +tasks.register("runTests") { + dependsOn("copyKeysJSON") + mainClass.set("TestsFromDafny") + classpath = sourceSets["test"].runtimeClasspath +} + +tasks.register("copyKeysJSON") { + from(layout.projectDirectory.file("../../dafny/TestVectors/test/keys.json")) + into(layout.projectDirectory.dir("dafny/TestVectors/test")) +} + +tasks.register("copyKeysJSONCurr") { + from(layout.projectDirectory.file("../../dafny/TestVectors/test/keys.json")) + into(layout.projectDirectory.dir(".")) +} + +application { + mainClass.set("ImplementationFromDafny") +} diff --git a/TestVectors/runtimes/java/gradle/wrapper/gradle-wrapper.properties b/TestVectors/runtimes/java/gradle/wrapper/gradle-wrapper.properties new file mode 100644 index 000000000..c7d437bbb --- /dev/null +++ b/TestVectors/runtimes/java/gradle/wrapper/gradle-wrapper.properties @@ -0,0 +1,6 @@ +distributionBase=GRADLE_USER_HOME +distributionPath=wrapper/dists +distributionUrl=https\://services.gradle.org/distributions/gradle-7.6.4-bin.zip +networkTimeout=10000 +zipStoreBase=GRADLE_USER_HOME +zipStorePath=wrapper/dists diff --git a/TestVectors/runtimes/java/settings.gradle.kts b/TestVectors/runtimes/java/settings.gradle.kts new file mode 100644 index 000000000..55f998b34 --- /dev/null +++ b/TestVectors/runtimes/java/settings.gradle.kts @@ -0,0 +1,11 @@ +/* + * This file was generated by the Gradle 'init' task. + * + * The settings file is used to specify which projects to include in your build. + * + * Detailed information about configuring a multi-project build in Gradle can be found + * in the user manual at https://docs.gradle.org/7.6.4/userguide/multi_project_builds.html + */ + +rootProject.name = "TestVectors" +include("lib") diff --git a/TestVectors/runtimes/java/src/main/java/software/amazon/cryptography/encryptionsdk/internaldafny/wrapped/__default.java b/TestVectors/runtimes/java/src/main/java/software/amazon/cryptography/encryptionsdk/internaldafny/wrapped/__default.java new file mode 100644 index 000000000..4243b5842 --- /dev/null +++ b/TestVectors/runtimes/java/src/main/java/software/amazon/cryptography/encryptionsdk/internaldafny/wrapped/__default.java @@ -0,0 +1,54 @@ +package software.amazon.cryptography.encryptionsdk.internaldafny.wrapped; + +import Wrappers_Compile.Result; +import com.amazonaws.encryptionsdk.AwsCrypto; +import com.amazonaws.encryptionsdk.CommitmentPolicy; +import com.amazonaws.encryptionsdk.CryptoAlgorithm; +import software.amazon.cryptography.encryptionsdk.ToNative; +import software.amazon.cryptography.encryptionsdk.internaldafny.types.AwsEncryptionSdkConfig; +import software.amazon.cryptography.encryptionsdk.internaldafny.types.IAwsEncryptionSdkClient; +import software.amazon.cryptography.encryptionsdk.internaldafny.types.Error; +import software.amazon.cryptography.encryptionsdk.model.NetV4_0_0_RetryPolicy; +import software.amazon.cryptography.encryptionsdk.wrapped.TestESDK; +import software.amazon.cryptography.materialproviders.model.ESDKCommitmentPolicy; + +public class __default extends _ExternBase___default { + + + public static Result WrappedESDK(AwsEncryptionSdkConfig config) { + software.amazon.cryptography.encryptionsdk.model.AwsEncryptionSdkConfig wrappedConfig = ToNative.AwsEncryptionSdkConfig(config); + if (wrappedConfig.netV4_0_0_RetryPolicy() == NetV4_0_0_RetryPolicy.ALLOW_RETRY) { + throw new IllegalArgumentException("Native AWS Encryption SDK for Java does not support NetV4_0_0_RetryPolicy.ALLOW_RETRY"); + } + CommitmentPolicy commitmentPolicy = _esdkDafnyCommitmentPolicyToNative(wrappedConfig.commitmentPolicy()); + + int maxEncryptedDataKeys = wrappedConfig.maxEncryptedDataKeys() == 0 ? 1 : (int) wrappedConfig.maxEncryptedDataKeys(); + final AwsCrypto awsCrypto; + + if (wrappedConfig.maxEncryptedDataKeys() == 0) { + awsCrypto = AwsCrypto.builder() + .withCommitmentPolicy(commitmentPolicy) + .build(); + } else { + awsCrypto = AwsCrypto.builder() + .withCommitmentPolicy(commitmentPolicy) + .withMaxEncryptedDataKeys(maxEncryptedDataKeys) + .build(); + } + TestESDK wrappedEsdk = TestESDK.builder().impl(awsCrypto).build(); + return software.amazon.cryptography.encryptionsdk.internaldafny._ExternBase___default.CreateSuccessOfClient(wrappedEsdk); + } + + private static CommitmentPolicy _esdkDafnyCommitmentPolicyToNative(ESDKCommitmentPolicy esdkCommitmentPolicy) { + switch (esdkCommitmentPolicy) { + case FORBID_ENCRYPT_ALLOW_DECRYPT: + return CommitmentPolicy.ForbidEncryptAllowDecrypt; + case REQUIRE_ENCRYPT_ALLOW_DECRYPT: + return CommitmentPolicy.RequireEncryptAllowDecrypt; + case REQUIRE_ENCRYPT_REQUIRE_DECRYPT: + return CommitmentPolicy.RequireEncryptRequireDecrypt; + default: + throw new IllegalArgumentException("Unsupported CommitmentPolicy: " + esdkCommitmentPolicy); + } + } +} diff --git a/TestVectors/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/wrapped/TestESDK.java b/TestVectors/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/wrapped/TestESDK.java new file mode 100644 index 000000000..262bb6227 --- /dev/null +++ b/TestVectors/runtimes/java/src/main/smithy-generated/software/amazon/cryptography/encryptionsdk/wrapped/TestESDK.java @@ -0,0 +1,191 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 +// Do not modify this file. This file is machine generated, and any changes to it will be overwritten. +package software.amazon.cryptography.encryptionsdk.wrapped; + +import Wrappers_Compile.Result; +import com.amazonaws.encryptionsdk.CryptoAlgorithm; +import com.amazonaws.encryptionsdk.CryptoResult; +import dafny.DafnyMap; +import dafny.DafnySequence; +import java.lang.IllegalArgumentException; +import java.lang.RuntimeException; +import java.nio.ByteBuffer; +import java.util.Map; +import java.util.Objects; +import com.amazonaws.encryptionsdk.AwsCrypto; +import software.amazon.cryptography.encryptionsdk.ESDK; +import software.amazon.cryptography.encryptionsdk.ToDafny; +import software.amazon.cryptography.encryptionsdk.ToNative; +import software.amazon.cryptography.encryptionsdk.internaldafny.types.DecryptInput; +import software.amazon.cryptography.encryptionsdk.internaldafny.types.DecryptOutput; +import software.amazon.cryptography.encryptionsdk.internaldafny.types.EncryptInput; +import software.amazon.cryptography.encryptionsdk.internaldafny.types.EncryptOutput; +import software.amazon.cryptography.encryptionsdk.internaldafny.types.Error; +import software.amazon.cryptography.encryptionsdk.internaldafny.types.IAwsEncryptionSdkClient; +import software.amazon.cryptography.materialproviders.internaldafny.types.ESDKAlgorithmSuiteId; +import software.amazon.smithy.dafny.conversion.ToDafny.Simple; + +public class TestESDK implements IAwsEncryptionSdkClient { + + private final AwsCrypto _impl; + + protected TestESDK(BuilderImpl builder) { + this._impl = builder.impl(); + } + + public static Builder builder() { + return new BuilderImpl(); + } + + public Result Decrypt(DecryptInput dafnyInput) { + try { + software.amazon.cryptography.encryptionsdk.model.DecryptInput nativeInput = + ToNative.DecryptInput(dafnyInput); + final CryptoResult decryptResult; + + if (Objects.isNull(nativeInput.materialsManager())) { + // Call decrypt with keyring + if (Objects.isNull(nativeInput.encryptionContext())) { + decryptResult = this._impl.decryptData(nativeInput.keyring(), nativeInput.ciphertext().array()); + } else { + decryptResult = this._impl.decryptData(nativeInput.keyring(), nativeInput.ciphertext().array(), nativeInput.encryptionContext()); + } + } else { + if (Objects.isNull(nativeInput.encryptionContext())) { + decryptResult = this._impl.decryptData(nativeInput.materialsManager(), nativeInput.ciphertext().array()); + } else { + decryptResult = this._impl.decryptData(nativeInput.materialsManager(), nativeInput.ciphertext().array(), nativeInput.encryptionContext()); + } + } + DafnySequence plaintext = Simple.ByteSequence(decryptResult.getResult()); + DafnyMap, ? extends DafnySequence> encryptionContext = + software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext(decryptResult.getEncryptionContext()); + ESDKAlgorithmSuiteId algorithmSuiteId = software.amazon.cryptography.materialproviders.ToDafny.ESDKAlgorithmSuiteId( + decryptResult.getCryptoAlgorithm().getAlgorithmSuiteId().ESDK() + ); + DecryptOutput dafnyOutput = new DecryptOutput(plaintext, encryptionContext, algorithmSuiteId); + + return Result.create_Success( + DecryptOutput._typeDescriptor(), + Error._typeDescriptor(), + dafnyOutput + ); + } catch (RuntimeException ex) { + return Result.create_Failure( + DecryptOutput._typeDescriptor(), + Error._typeDescriptor(), + ToDafny.Error(ex) + ); + } + } + + public Result Encrypt(EncryptInput dafnyInput) { + try { + software.amazon.cryptography.encryptionsdk.model.EncryptInput nativeInput = + ToNative.EncryptInput(dafnyInput); + final CryptoResult encryptResult; + + // Java ESDK is special and you have to set the algorithm suite both in the keyring which the + // test vectors do, but also in the client itself. + CryptoAlgorithm cryptoAlgorithm = _getAlgorithmSuite(nativeInput.algorithmSuiteId()); + this._impl.setEncryptionAlgorithm(cryptoAlgorithm); + + if (Objects.isNull(nativeInput.materialsManager())) { + // Call decrypt with keyring + if (Objects.isNull(nativeInput.encryptionContext())) { + encryptResult = this._impl.encryptData(nativeInput.keyring(), nativeInput.plaintext().array()); + } else { + encryptResult = this._impl.encryptData(nativeInput.keyring(), nativeInput.plaintext().array(), nativeInput.encryptionContext()); + } + } else { + if (Objects.isNull(nativeInput.encryptionContext())) { + encryptResult = this._impl.encryptData(nativeInput.materialsManager(), nativeInput.plaintext().array()); + } else { + encryptResult = this._impl.encryptData(nativeInput.materialsManager(), nativeInput.plaintext().array(), nativeInput.encryptionContext()); + } + } + dafny.DafnySequence ciphertext = Simple.ByteSequence(encryptResult.getResult()); + DafnyMap, ? extends DafnySequence> encryptionContext = + software.amazon.cryptography.materialproviders.ToDafny.EncryptionContext(encryptResult.getEncryptionContext()); + ESDKAlgorithmSuiteId algorithmSuiteId = software.amazon.cryptography.materialproviders.ToDafny.ESDKAlgorithmSuiteId( + encryptResult.getCryptoAlgorithm().getAlgorithmSuiteId().ESDK() + ); + + EncryptOutput dafnyOutput = new EncryptOutput(ciphertext, encryptionContext, algorithmSuiteId); + return Result.create_Success( + EncryptOutput._typeDescriptor(), + Error._typeDescriptor(), + dafnyOutput + ); + } catch (RuntimeException ex) { + return Result.create_Failure( + EncryptOutput._typeDescriptor(), + Error._typeDescriptor(), + ToDafny.Error(ex) + ); + } + } + + private CryptoAlgorithm _getAlgorithmSuite(software.amazon.cryptography.materialproviders.model.ESDKAlgorithmSuiteId esdkAlgorithmSuiteId) { + switch (esdkAlgorithmSuiteId) { + case ALG_AES_128_GCM_IV12_TAG16_NO_KDF: + return CryptoAlgorithm.ALG_AES_128_GCM_IV12_TAG16_NO_KDF; + case ALG_AES_192_GCM_IV12_TAG16_NO_KDF: + return CryptoAlgorithm.ALG_AES_192_GCM_IV12_TAG16_NO_KDF; + case ALG_AES_256_GCM_IV12_TAG16_NO_KDF: + return CryptoAlgorithm.ALG_AES_256_GCM_IV12_TAG16_NO_KDF; + case ALG_AES_128_GCM_IV12_TAG16_HKDF_SHA256: + return CryptoAlgorithm.ALG_AES_128_GCM_IV12_TAG16_HKDF_SHA256; + case ALG_AES_192_GCM_IV12_TAG16_HKDF_SHA256: + return CryptoAlgorithm.ALG_AES_192_GCM_IV12_TAG16_HKDF_SHA256; + case ALG_AES_256_GCM_IV12_TAG16_HKDF_SHA256: + return CryptoAlgorithm.ALG_AES_256_GCM_IV12_TAG16_HKDF_SHA256; + case ALG_AES_128_GCM_IV12_TAG16_HKDF_SHA256_ECDSA_P256: + return CryptoAlgorithm.ALG_AES_128_GCM_IV12_TAG16_HKDF_SHA256_ECDSA_P256; + case ALG_AES_192_GCM_IV12_TAG16_HKDF_SHA384_ECDSA_P384: + return CryptoAlgorithm.ALG_AES_192_GCM_IV12_TAG16_HKDF_SHA384_ECDSA_P384; + case ALG_AES_256_GCM_IV12_TAG16_HKDF_SHA384_ECDSA_P384: + return CryptoAlgorithm.ALG_AES_256_GCM_IV12_TAG16_HKDF_SHA384_ECDSA_P384; + case ALG_AES_256_GCM_HKDF_SHA512_COMMIT_KEY: + return CryptoAlgorithm.ALG_AES_256_GCM_HKDF_SHA512_COMMIT_KEY; + case ALG_AES_256_GCM_HKDF_SHA512_COMMIT_KEY_ECDSA_P384: + return CryptoAlgorithm.ALG_AES_256_GCM_HKDF_SHA512_COMMIT_KEY_ECDSA_P384; + default: + throw new IllegalArgumentException("Unrecognized ESDK algorithmSuiteId: " + esdkAlgorithmSuiteId); + } + } + + public interface Builder { + Builder impl(AwsCrypto impl); + + AwsCrypto impl(); + + TestESDK build(); + } + + static class BuilderImpl implements Builder { + + protected AwsCrypto impl; + + protected BuilderImpl() {} + + public Builder impl(AwsCrypto impl) { + this.impl = impl; + return this; + } + + public AwsCrypto impl() { + return this.impl; + } + + public TestESDK build() { + if (Objects.isNull(this.impl())) { + throw new IllegalArgumentException( + "Missing value for required field `impl`" + ); + } + return new TestESDK(this); + } + } +} diff --git a/TestVectors/runtimes/java/src/test/java/TestWrappedESDKMain/__default.java b/TestVectors/runtimes/java/src/test/java/TestWrappedESDKMain/__default.java new file mode 100644 index 000000000..ce798166d --- /dev/null +++ b/TestVectors/runtimes/java/src/test/java/TestWrappedESDKMain/__default.java @@ -0,0 +1,12 @@ +package TestWrappedESDKMain_Compile; + +import dafny.DafnySequence; + +public class __default extends _ExternBase___default { + + public static dafny.DafnySequence< + ? extends Character + > GetTestVectorExecutionDirectory() { + return DafnySequence.asString(""); + } +} diff --git a/TestVectors/runtimes/net/ESDKTestVectors.csproj b/TestVectors/runtimes/net/ESDKTestVectors.csproj new file mode 100644 index 000000000..ba1a57559 --- /dev/null +++ b/TestVectors/runtimes/net/ESDKTestVectors.csproj @@ -0,0 +1,42 @@ + + + + Test Vectors for AWS Encryption SDK Library + enable + disable + 10 + net6.0;net48 + false + Exe + + + + + + + + + + + + + + + + + + + + + + + diff --git a/TestVectors/runtimes/net/Extern/WrappedESDK.cs b/TestVectors/runtimes/net/Extern/WrappedESDK.cs new file mode 100644 index 000000000..33ddf818d --- /dev/null +++ b/TestVectors/runtimes/net/Extern/WrappedESDK.cs @@ -0,0 +1,25 @@ +using AwsArnParsing_Compile; +using Wrappers_Compile; + +namespace software.amazon.cryptography.encryptionsdk.internaldafny.wrapped +{ + public partial class __default + { + public static + _IResult< + types.IAwsEncryptionSdkClient, + types.Error + > + WrappedESDK( + types._IAwsEncryptionSdkConfig config) + { + var wrappedConfig = AWS.Cryptography.EncryptionSDK.Wrapped.TypeConversion + .FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig(config); + var impl = new AWS.Cryptography.EncryptionSDK.ESDK(wrappedConfig); + var wrappedClient = new AWS.Cryptography.EncryptionSDK.Wrapped.AwsEncryptionSdkShim(impl); + + return Result.create_Success(wrappedClient); + } + } +} \ No newline at end of file diff --git a/TestVectors/runtimes/net/Generated/TestVectors/AwsEncryptionSdkShim.cs b/TestVectors/runtimes/net/Generated/TestVectors/AwsEncryptionSdkShim.cs new file mode 100644 index 000000000..8a0269503 --- /dev/null +++ b/TestVectors/runtimes/net/Generated/TestVectors/AwsEncryptionSdkShim.cs @@ -0,0 +1,76 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 +// Do not modify this file. This file is machine generated, and any changes to it will be overwritten. +using System; +using System.Collections.Generic; +using System.IO; +using System.Linq; +namespace AWS.Cryptography.EncryptionSDK.Wrapped +{ + public class AwsEncryptionSdkShim : software.amazon.cryptography.encryptionsdk.internaldafny.types.IAwsEncryptionSdkClient + { + public AWS.Cryptography.EncryptionSDK.ESDK _impl; + public AwsEncryptionSdkShim(AWS.Cryptography.EncryptionSDK.ESDK impl) + { + this._impl = impl; + } + public Wrappers_Compile._IResult Encrypt(software.amazon.cryptography.encryptionsdk.internaldafny.types._IEncryptInput request) + { + try + { + AWS.Cryptography.EncryptionSDK.EncryptInput unWrappedRequest = TypeConversion.FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput(request); + AWS.Cryptography.EncryptionSDK.EncryptOutput wrappedResponse = + this._impl.Encrypt(unWrappedRequest); + return Wrappers_Compile.Result.create_Success(TypeConversion.ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput(wrappedResponse)); + } + catch (System.Exception ex) + { + return Wrappers_Compile.Result.create_Failure(this.ConvertError(ex)); + } + + } + public Wrappers_Compile._IResult Decrypt(software.amazon.cryptography.encryptionsdk.internaldafny.types._IDecryptInput request) + { + try + { + AWS.Cryptography.EncryptionSDK.DecryptInput unWrappedRequest = TypeConversion.FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput(request); + AWS.Cryptography.EncryptionSDK.DecryptOutput wrappedResponse = + this._impl.Decrypt(unWrappedRequest); + return Wrappers_Compile.Result.create_Success(TypeConversion.ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput(wrappedResponse)); + } + catch (System.Exception ex) + { + return Wrappers_Compile.Result.create_Failure(this.ConvertError(ex)); + } + + } + private software.amazon.cryptography.encryptionsdk.internaldafny.types._IError ConvertError(System.Exception error) + { + switch (error.GetType().Namespace) + { + case "AWS.Cryptography.MaterialProviders": + return software.amazon.cryptography.encryptionsdk.internaldafny.types.Error.create_AwsCryptographyMaterialProviders( + AWS.Cryptography.MaterialProviders.TypeConversion.ToDafny_CommonError(error) + ); + } + switch (error) + { + case AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkException e: + return TypeConversion.ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException(e); + + case CollectionOfErrors collectionOfErrors: + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_CollectionOfErrors( + Dafny.Sequence + .FromArray( + collectionOfErrors.list.Select + (x => TypeConversion.ToDafny_CommonError(x)) + .ToArray()), + Dafny.Sequence.FromString(collectionOfErrors.Message) + ); + default: + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_Opaque(error, Dafny.Sequence.FromString(error.ToString())); + + } + } + } +} diff --git a/TestVectors/runtimes/net/Generated/TestVectors/TypeConversion.cs b/TestVectors/runtimes/net/Generated/TestVectors/TypeConversion.cs new file mode 100644 index 000000000..d647a6ee5 --- /dev/null +++ b/TestVectors/runtimes/net/Generated/TestVectors/TypeConversion.cs @@ -0,0 +1,471 @@ +// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved. +// SPDX-License-Identifier: Apache-2.0 +// Do not modify this file. This file is machine generated, and any changes to it will be overwritten. +using System.Linq; +using System; +namespace AWS.Cryptography.EncryptionSDK.Wrapped +{ + public static class TypeConversion + { + private const string ISO8601DateFormat = "yyyy-MM-dd\\THH:mm:ss.fff\\Z"; + + private const string ISO8601DateFormatNoMS = "yyyy-MM-dd\\THH:mm:ss\\Z"; + + public static AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkConfig FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig(software.amazon.cryptography.encryptionsdk.internaldafny.types._IAwsEncryptionSdkConfig value) + { + software.amazon.cryptography.encryptionsdk.internaldafny.types.AwsEncryptionSdkConfig concrete = (software.amazon.cryptography.encryptionsdk.internaldafny.types.AwsEncryptionSdkConfig)value; AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkConfig converted = new AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkConfig(); if (concrete._commitmentPolicy.is_Some) converted.CommitmentPolicy = (AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M16_commitmentPolicy(concrete._commitmentPolicy); + if (concrete._maxEncryptedDataKeys.is_Some) converted.MaxEncryptedDataKeys = (long)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M20_maxEncryptedDataKeys(concrete._maxEncryptedDataKeys); + if (concrete._netV4__0__0__RetryPolicy.is_Some) converted.NetV4_0_0_RetryPolicy = (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(concrete._netV4__0__0__RetryPolicy); return converted; + } + public static software.amazon.cryptography.encryptionsdk.internaldafny.types._IAwsEncryptionSdkConfig ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig(AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkConfig value) + { + value.Validate(); + AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy var_commitmentPolicy = value.IsSetCommitmentPolicy() ? value.CommitmentPolicy : (AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy)null; + long? var_maxEncryptedDataKeys = value.IsSetMaxEncryptedDataKeys() ? value.MaxEncryptedDataKeys : (long?)null; + AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy var_netV4_0_0_RetryPolicy = value.IsSetNetV4__0__0__RetryPolicy() ? value.NetV4_0_0_RetryPolicy : (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)null; + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.AwsEncryptionSdkConfig(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M16_commitmentPolicy(var_commitmentPolicy), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M20_maxEncryptedDataKeys(var_maxEncryptedDataKeys), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(var_netV4_0_0_RetryPolicy)); + } + public static AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkException FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException(software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_AwsEncryptionSdkException value) + { + return new AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkException( + FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException__M7_message(value._message) + ); + } + public static software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_AwsEncryptionSdkException ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException(AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkException value) + { + + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_AwsEncryptionSdkException( + ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException__M7_message(value.Message) + ); + } + public static AWS.Cryptography.EncryptionSDK.DecryptInput FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput(software.amazon.cryptography.encryptionsdk.internaldafny.types._IDecryptInput value) + { + software.amazon.cryptography.encryptionsdk.internaldafny.types.DecryptInput concrete = (software.amazon.cryptography.encryptionsdk.internaldafny.types.DecryptInput)value; AWS.Cryptography.EncryptionSDK.DecryptInput converted = new AWS.Cryptography.EncryptionSDK.DecryptInput(); converted.Ciphertext = (System.IO.MemoryStream)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M10_ciphertext(concrete._ciphertext); + if (concrete._materialsManager.is_Some) converted.MaterialsManager = (AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M16_materialsManager(concrete._materialsManager); + if (concrete._keyring.is_Some) converted.Keyring = (AWS.Cryptography.MaterialProviders.IKeyring)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M7_keyring(concrete._keyring); + if (concrete._encryptionContext.is_Some) converted.EncryptionContext = (System.Collections.Generic.Dictionary)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M17_encryptionContext(concrete._encryptionContext); return converted; + } + public static software.amazon.cryptography.encryptionsdk.internaldafny.types._IDecryptInput ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput(AWS.Cryptography.EncryptionSDK.DecryptInput value) + { + value.Validate(); + AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager var_materialsManager = value.IsSetMaterialsManager() ? value.MaterialsManager : (AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager)null; + AWS.Cryptography.MaterialProviders.IKeyring var_keyring = value.IsSetKeyring() ? value.Keyring : (AWS.Cryptography.MaterialProviders.IKeyring)null; + System.Collections.Generic.Dictionary var_encryptionContext = value.IsSetEncryptionContext() ? value.EncryptionContext : (System.Collections.Generic.Dictionary)null; + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.DecryptInput(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M10_ciphertext(value.Ciphertext), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M16_materialsManager(var_materialsManager), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M7_keyring(var_keyring), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M17_encryptionContext(var_encryptionContext)); + } + public static AWS.Cryptography.EncryptionSDK.DecryptOutput FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput(software.amazon.cryptography.encryptionsdk.internaldafny.types._IDecryptOutput value) + { + software.amazon.cryptography.encryptionsdk.internaldafny.types.DecryptOutput concrete = (software.amazon.cryptography.encryptionsdk.internaldafny.types.DecryptOutput)value; AWS.Cryptography.EncryptionSDK.DecryptOutput converted = new AWS.Cryptography.EncryptionSDK.DecryptOutput(); converted.Plaintext = (System.IO.MemoryStream)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput__M9_plaintext(concrete._plaintext); + converted.EncryptionContext = (System.Collections.Generic.Dictionary)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput__M17_encryptionContext(concrete._encryptionContext); + converted.AlgorithmSuiteId = (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput__M16_algorithmSuiteId(concrete._algorithmSuiteId); return converted; + } + public static software.amazon.cryptography.encryptionsdk.internaldafny.types._IDecryptOutput ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput(AWS.Cryptography.EncryptionSDK.DecryptOutput value) + { + value.Validate(); + + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.DecryptOutput(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput__M9_plaintext(value.Plaintext), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput__M17_encryptionContext(value.EncryptionContext), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput__M16_algorithmSuiteId(value.AlgorithmSuiteId)); + } + public static AWS.Cryptography.EncryptionSDK.EncryptInput FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput(software.amazon.cryptography.encryptionsdk.internaldafny.types._IEncryptInput value) + { + software.amazon.cryptography.encryptionsdk.internaldafny.types.EncryptInput concrete = (software.amazon.cryptography.encryptionsdk.internaldafny.types.EncryptInput)value; AWS.Cryptography.EncryptionSDK.EncryptInput converted = new AWS.Cryptography.EncryptionSDK.EncryptInput(); converted.Plaintext = (System.IO.MemoryStream)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M9_plaintext(concrete._plaintext); + if (concrete._encryptionContext.is_Some) converted.EncryptionContext = (System.Collections.Generic.Dictionary)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M17_encryptionContext(concrete._encryptionContext); + if (concrete._materialsManager.is_Some) converted.MaterialsManager = (AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M16_materialsManager(concrete._materialsManager); + if (concrete._keyring.is_Some) converted.Keyring = (AWS.Cryptography.MaterialProviders.IKeyring)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M7_keyring(concrete._keyring); + if (concrete._algorithmSuiteId.is_Some) converted.AlgorithmSuiteId = (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M16_algorithmSuiteId(concrete._algorithmSuiteId); + if (concrete._frameLength.is_Some) converted.FrameLength = (long)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M11_frameLength(concrete._frameLength); return converted; + } + public static software.amazon.cryptography.encryptionsdk.internaldafny.types._IEncryptInput ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput(AWS.Cryptography.EncryptionSDK.EncryptInput value) + { + value.Validate(); + System.Collections.Generic.Dictionary var_encryptionContext = value.IsSetEncryptionContext() ? value.EncryptionContext : (System.Collections.Generic.Dictionary)null; + AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager var_materialsManager = value.IsSetMaterialsManager() ? value.MaterialsManager : (AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager)null; + AWS.Cryptography.MaterialProviders.IKeyring var_keyring = value.IsSetKeyring() ? value.Keyring : (AWS.Cryptography.MaterialProviders.IKeyring)null; + AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId var_algorithmSuiteId = value.IsSetAlgorithmSuiteId() ? value.AlgorithmSuiteId : (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId)null; + long? var_frameLength = value.IsSetFrameLength() ? value.FrameLength : (long?)null; + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.EncryptInput(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M9_plaintext(value.Plaintext), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M17_encryptionContext(var_encryptionContext), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M16_materialsManager(var_materialsManager), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M7_keyring(var_keyring), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M16_algorithmSuiteId(var_algorithmSuiteId), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M11_frameLength(var_frameLength)); + } + public static AWS.Cryptography.EncryptionSDK.EncryptOutput FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput(software.amazon.cryptography.encryptionsdk.internaldafny.types._IEncryptOutput value) + { + software.amazon.cryptography.encryptionsdk.internaldafny.types.EncryptOutput concrete = (software.amazon.cryptography.encryptionsdk.internaldafny.types.EncryptOutput)value; AWS.Cryptography.EncryptionSDK.EncryptOutput converted = new AWS.Cryptography.EncryptionSDK.EncryptOutput(); converted.Ciphertext = (System.IO.MemoryStream)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M10_ciphertext(concrete._ciphertext); + converted.EncryptionContext = (System.Collections.Generic.Dictionary)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M17_encryptionContext(concrete._encryptionContext); + converted.AlgorithmSuiteId = (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId)FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M16_algorithmSuiteId(concrete._algorithmSuiteId); return converted; + } + public static software.amazon.cryptography.encryptionsdk.internaldafny.types._IEncryptOutput ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput(AWS.Cryptography.EncryptionSDK.EncryptOutput value) + { + value.Validate(); + + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.EncryptOutput(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M10_ciphertext(value.Ciphertext), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M17_encryptionContext(value.EncryptionContext), ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M16_algorithmSuiteId(value.AlgorithmSuiteId)); + } + public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(software.amazon.cryptography.encryptionsdk.internaldafny.types._INetV4__0__0__RetryPolicy value) + { + if (value.is_FORBID__RETRY) return AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.FORBID_RETRY; + if (value.is_ALLOW__RETRY) return AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.ALLOW_RETRY; + throw new System.ArgumentException("Invalid AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value"); + } + public static software.amazon.cryptography.encryptionsdk.internaldafny.types._INetV4__0__0__RetryPolicy ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) + { + if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.FORBID_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4__0__0__RetryPolicy.create_FORBID__RETRY(); + if (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy.ALLOW_RETRY.Equals(value)) return software.amazon.cryptography.encryptionsdk.internaldafny.types.NetV4__0__0__RetryPolicy.create_ALLOW__RETRY(); + throw new System.ArgumentException("Invalid AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value"); + } + public static AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M16_commitmentPolicy(Wrappers_Compile._IOption value) + { + return value.is_None ? (AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy)null : FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S20_ESDKCommitmentPolicy(value.Extract()); + } + public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M16_commitmentPolicy(AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy value) + { + return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S20_ESDKCommitmentPolicy((AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy)value)); + } + public static long? FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M20_maxEncryptedDataKeys(Wrappers_Compile._IOption value) + { + return value.is_None ? (long?)null : FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S15_CountingNumbers(value.Extract()); + } + public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M20_maxEncryptedDataKeys(long? value) + { + return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S15_CountingNumbers((long)value)); + } + public static AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(Wrappers_Compile._IOption value) + { + return value.is_None ? (AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)null : FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy(value.Extract()); + } + public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S22_AwsEncryptionSdkConfig__M21_netV4_0_0_RetryPolicy(AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy value) + { + return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S21_NetV4_0_0_RetryPolicy((AWS.Cryptography.EncryptionSDK.NetV4_0_0_RetryPolicy)value)); + } + public static string FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException__M7_message(Dafny.ISequence value) + { + return FromDafny_N6_smithy__N3_api__S6_String(value); + } + public static Dafny.ISequence ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException__M7_message(string value) + { + return ToDafny_N6_smithy__N3_api__S6_String(value); + } + public static System.IO.MemoryStream FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M10_ciphertext(Dafny.ISequence value) + { + return FromDafny_N6_smithy__N3_api__S4_Blob(value); + } + public static Dafny.ISequence ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M10_ciphertext(System.IO.MemoryStream value) + { + return ToDafny_N6_smithy__N3_api__S4_Blob(value); + } + public static AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M16_materialsManager(Wrappers_Compile._IOption value) + { + return value.is_None ? (AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager)null : FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S38_CryptographicMaterialsManagerReference(value.Extract()); + } + public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M16_materialsManager(AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager value) + { + return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S38_CryptographicMaterialsManagerReference((AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager)value)); + } + public static AWS.Cryptography.MaterialProviders.IKeyring FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M7_keyring(Wrappers_Compile._IOption value) + { + return value.is_None ? (AWS.Cryptography.MaterialProviders.IKeyring)null : FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S16_KeyringReference(value.Extract()); + } + public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M7_keyring(AWS.Cryptography.MaterialProviders.IKeyring value) + { + return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S16_KeyringReference((AWS.Cryptography.MaterialProviders.IKeyring)value)); + } + public static System.Collections.Generic.Dictionary FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M17_encryptionContext(Wrappers_Compile._IOption, Dafny.ISequence>> value) + { + return value.is_None ? (System.Collections.Generic.Dictionary)null : FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext(value.Extract()); + } + public static Wrappers_Compile._IOption, Dafny.ISequence>> ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_DecryptInput__M17_encryptionContext(System.Collections.Generic.Dictionary value) + { + return value == null ? Wrappers_Compile.Option, Dafny.ISequence>>.create_None() : Wrappers_Compile.Option, Dafny.ISequence>>.create_Some(ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext((System.Collections.Generic.Dictionary)value)); + } + public static System.IO.MemoryStream FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput__M9_plaintext(Dafny.ISequence value) + { + return FromDafny_N6_smithy__N3_api__S4_Blob(value); + } + public static Dafny.ISequence ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput__M9_plaintext(System.IO.MemoryStream value) + { + return ToDafny_N6_smithy__N3_api__S4_Blob(value); + } + public static System.Collections.Generic.Dictionary FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput__M17_encryptionContext(Dafny.IMap, Dafny.ISequence> value) + { + return FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext(value); + } + public static Dafny.IMap, Dafny.ISequence> ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput__M17_encryptionContext(System.Collections.Generic.Dictionary value) + { + return ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext(value); + } + public static AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput__M16_algorithmSuiteId(software.amazon.cryptography.materialproviders.internaldafny.types._IESDKAlgorithmSuiteId value) + { + return FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S20_ESDKAlgorithmSuiteId(value); + } + public static software.amazon.cryptography.materialproviders.internaldafny.types._IESDKAlgorithmSuiteId ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_DecryptOutput__M16_algorithmSuiteId(AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId value) + { + return ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S20_ESDKAlgorithmSuiteId(value); + } + public static System.IO.MemoryStream FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M9_plaintext(Dafny.ISequence value) + { + return FromDafny_N6_smithy__N3_api__S4_Blob(value); + } + public static Dafny.ISequence ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M9_plaintext(System.IO.MemoryStream value) + { + return ToDafny_N6_smithy__N3_api__S4_Blob(value); + } + public static System.Collections.Generic.Dictionary FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M17_encryptionContext(Wrappers_Compile._IOption, Dafny.ISequence>> value) + { + return value.is_None ? (System.Collections.Generic.Dictionary)null : FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext(value.Extract()); + } + public static Wrappers_Compile._IOption, Dafny.ISequence>> ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M17_encryptionContext(System.Collections.Generic.Dictionary value) + { + return value == null ? Wrappers_Compile.Option, Dafny.ISequence>>.create_None() : Wrappers_Compile.Option, Dafny.ISequence>>.create_Some(ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext((System.Collections.Generic.Dictionary)value)); + } + public static AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M16_materialsManager(Wrappers_Compile._IOption value) + { + return value.is_None ? (AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager)null : FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S38_CryptographicMaterialsManagerReference(value.Extract()); + } + public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M16_materialsManager(AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager value) + { + return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S38_CryptographicMaterialsManagerReference((AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager)value)); + } + public static AWS.Cryptography.MaterialProviders.IKeyring FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M7_keyring(Wrappers_Compile._IOption value) + { + return value.is_None ? (AWS.Cryptography.MaterialProviders.IKeyring)null : FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S16_KeyringReference(value.Extract()); + } + public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M7_keyring(AWS.Cryptography.MaterialProviders.IKeyring value) + { + return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S16_KeyringReference((AWS.Cryptography.MaterialProviders.IKeyring)value)); + } + public static AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M16_algorithmSuiteId(Wrappers_Compile._IOption value) + { + return value.is_None ? (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId)null : FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S20_ESDKAlgorithmSuiteId(value.Extract()); + } + public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M16_algorithmSuiteId(AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId value) + { + return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S20_ESDKAlgorithmSuiteId((AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId)value)); + } + public static long? FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M11_frameLength(Wrappers_Compile._IOption value) + { + return value.is_None ? (long?)null : FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S11_FrameLength(value.Extract()); + } + public static Wrappers_Compile._IOption ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S12_EncryptInput__M11_frameLength(long? value) + { + return value == null ? Wrappers_Compile.Option.create_None() : Wrappers_Compile.Option.create_Some(ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S11_FrameLength((long)value)); + } + public static System.IO.MemoryStream FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M10_ciphertext(Dafny.ISequence value) + { + return FromDafny_N6_smithy__N3_api__S4_Blob(value); + } + public static Dafny.ISequence ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M10_ciphertext(System.IO.MemoryStream value) + { + return ToDafny_N6_smithy__N3_api__S4_Blob(value); + } + public static System.Collections.Generic.Dictionary FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M17_encryptionContext(Dafny.IMap, Dafny.ISequence> value) + { + return FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext(value); + } + public static Dafny.IMap, Dafny.ISequence> ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M17_encryptionContext(System.Collections.Generic.Dictionary value) + { + return ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext(value); + } + public static AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M16_algorithmSuiteId(software.amazon.cryptography.materialproviders.internaldafny.types._IESDKAlgorithmSuiteId value) + { + return FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S20_ESDKAlgorithmSuiteId(value); + } + public static software.amazon.cryptography.materialproviders.internaldafny.types._IESDKAlgorithmSuiteId ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S13_EncryptOutput__M16_algorithmSuiteId(AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId value) + { + return ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S20_ESDKAlgorithmSuiteId(value); + } + public static AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S20_ESDKCommitmentPolicy(software.amazon.cryptography.materialproviders.internaldafny.types._IESDKCommitmentPolicy value) + { + if (value.is_FORBID__ENCRYPT__ALLOW__DECRYPT) return AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy.FORBID_ENCRYPT_ALLOW_DECRYPT; + if (value.is_REQUIRE__ENCRYPT__ALLOW__DECRYPT) return AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy.REQUIRE_ENCRYPT_ALLOW_DECRYPT; + if (value.is_REQUIRE__ENCRYPT__REQUIRE__DECRYPT) return AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy.REQUIRE_ENCRYPT_REQUIRE_DECRYPT; + throw new System.ArgumentException("Invalid AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy value"); + } + public static software.amazon.cryptography.materialproviders.internaldafny.types._IESDKCommitmentPolicy ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S20_ESDKCommitmentPolicy(AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy value) + { + if (AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy.FORBID_ENCRYPT_ALLOW_DECRYPT.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKCommitmentPolicy.create_FORBID__ENCRYPT__ALLOW__DECRYPT(); + if (AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy.REQUIRE_ENCRYPT_ALLOW_DECRYPT.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKCommitmentPolicy.create_REQUIRE__ENCRYPT__ALLOW__DECRYPT(); + if (AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy.REQUIRE_ENCRYPT_REQUIRE_DECRYPT.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKCommitmentPolicy.create_REQUIRE__ENCRYPT__REQUIRE__DECRYPT(); + throw new System.ArgumentException("Invalid AWS.Cryptography.MaterialProviders.ESDKCommitmentPolicy value"); + } + public static long FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S15_CountingNumbers(long value) + { + return value; + } + public static long ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S15_CountingNumbers(long value) + { + return value; + } + public static string FromDafny_N6_smithy__N3_api__S6_String(Dafny.ISequence value) + { + return new string(value.Elements); + } + public static Dafny.ISequence ToDafny_N6_smithy__N3_api__S6_String(string value) + { + return Dafny.Sequence.FromString(value); + } + public static System.IO.MemoryStream FromDafny_N6_smithy__N3_api__S4_Blob(Dafny.ISequence value) + { + return new System.IO.MemoryStream(value.Elements); + } + public static Dafny.ISequence ToDafny_N6_smithy__N3_api__S4_Blob(System.IO.MemoryStream value) + { + if (value.ToArray().Length == 0 && value.Length > 0) + { + throw new System.ArgumentException("Fatal Error: MemoryStream instance not backed by an array!"); + } + return Dafny.Sequence.FromArray(value.ToArray()); + + } + public static AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S38_CryptographicMaterialsManagerReference(software.amazon.cryptography.materialproviders.internaldafny.types.ICryptographicMaterialsManager value) + { + // This is converting a reference type in a dependant module. + // Therefore it defers to the dependant module for conversion + return AWS.Cryptography.MaterialProviders.TypeConversion.FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S38_CryptographicMaterialsManagerReference(value); + } + public static software.amazon.cryptography.materialproviders.internaldafny.types.ICryptographicMaterialsManager ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S38_CryptographicMaterialsManagerReference(AWS.Cryptography.MaterialProviders.ICryptographicMaterialsManager value) + { + // This is converting a reference type in a dependant module. + // Therefore it defers to the dependant module for conversion + return AWS.Cryptography.MaterialProviders.TypeConversion.ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S38_CryptographicMaterialsManagerReference(value); + } + public static AWS.Cryptography.MaterialProviders.IKeyring FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S16_KeyringReference(software.amazon.cryptography.materialproviders.internaldafny.types.IKeyring value) + { + // This is converting a reference type in a dependant module. + // Therefore it defers to the dependant module for conversion + return AWS.Cryptography.MaterialProviders.TypeConversion.FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S16_KeyringReference(value); + } + public static software.amazon.cryptography.materialproviders.internaldafny.types.IKeyring ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S16_KeyringReference(AWS.Cryptography.MaterialProviders.IKeyring value) + { + // This is converting a reference type in a dependant module. + // Therefore it defers to the dependant module for conversion + return AWS.Cryptography.MaterialProviders.TypeConversion.ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S16_KeyringReference(value); + } + public static System.Collections.Generic.Dictionary FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext(Dafny.IMap, Dafny.ISequence> value) + { + return value.ItemEnumerable.ToDictionary(pair => FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext__M3_key(pair.Car), pair => FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext__M5_value(pair.Cdr)); + } + public static Dafny.IMap, Dafny.ISequence> ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext(System.Collections.Generic.Dictionary value) + { + return Dafny.Map, Dafny.ISequence>.FromCollection(value.Select(pair => + new Dafny.Pair, Dafny.ISequence>(ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext__M3_key(pair.Key), ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext__M5_value(pair.Value)) + )); + } + public static AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S20_ESDKAlgorithmSuiteId(software.amazon.cryptography.materialproviders.internaldafny.types._IESDKAlgorithmSuiteId value) + { + if (value.is_ALG__AES__128__GCM__IV12__TAG16__NO__KDF) return AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_128_GCM_IV12_TAG16_NO_KDF; + if (value.is_ALG__AES__192__GCM__IV12__TAG16__NO__KDF) return AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_192_GCM_IV12_TAG16_NO_KDF; + if (value.is_ALG__AES__256__GCM__IV12__TAG16__NO__KDF) return AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_256_GCM_IV12_TAG16_NO_KDF; + if (value.is_ALG__AES__128__GCM__IV12__TAG16__HKDF__SHA256) return AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_128_GCM_IV12_TAG16_HKDF_SHA256; + if (value.is_ALG__AES__192__GCM__IV12__TAG16__HKDF__SHA256) return AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_192_GCM_IV12_TAG16_HKDF_SHA256; + if (value.is_ALG__AES__256__GCM__IV12__TAG16__HKDF__SHA256) return AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_256_GCM_IV12_TAG16_HKDF_SHA256; + if (value.is_ALG__AES__128__GCM__IV12__TAG16__HKDF__SHA256__ECDSA__P256) return AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_128_GCM_IV12_TAG16_HKDF_SHA256_ECDSA_P256; + if (value.is_ALG__AES__192__GCM__IV12__TAG16__HKDF__SHA384__ECDSA__P384) return AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_192_GCM_IV12_TAG16_HKDF_SHA384_ECDSA_P384; + if (value.is_ALG__AES__256__GCM__IV12__TAG16__HKDF__SHA384__ECDSA__P384) return AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_256_GCM_IV12_TAG16_HKDF_SHA384_ECDSA_P384; + if (value.is_ALG__AES__256__GCM__HKDF__SHA512__COMMIT__KEY) return AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_256_GCM_HKDF_SHA512_COMMIT_KEY; + if (value.is_ALG__AES__256__GCM__HKDF__SHA512__COMMIT__KEY__ECDSA__P384) return AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_256_GCM_HKDF_SHA512_COMMIT_KEY_ECDSA_P384; + throw new System.ArgumentException("Invalid AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId value"); + } + public static software.amazon.cryptography.materialproviders.internaldafny.types._IESDKAlgorithmSuiteId ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S20_ESDKAlgorithmSuiteId(AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId value) + { + if (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_128_GCM_IV12_TAG16_NO_KDF.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKAlgorithmSuiteId.create_ALG__AES__128__GCM__IV12__TAG16__NO__KDF(); + if (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_192_GCM_IV12_TAG16_NO_KDF.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKAlgorithmSuiteId.create_ALG__AES__192__GCM__IV12__TAG16__NO__KDF(); + if (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_256_GCM_IV12_TAG16_NO_KDF.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKAlgorithmSuiteId.create_ALG__AES__256__GCM__IV12__TAG16__NO__KDF(); + if (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_128_GCM_IV12_TAG16_HKDF_SHA256.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKAlgorithmSuiteId.create_ALG__AES__128__GCM__IV12__TAG16__HKDF__SHA256(); + if (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_192_GCM_IV12_TAG16_HKDF_SHA256.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKAlgorithmSuiteId.create_ALG__AES__192__GCM__IV12__TAG16__HKDF__SHA256(); + if (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_256_GCM_IV12_TAG16_HKDF_SHA256.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKAlgorithmSuiteId.create_ALG__AES__256__GCM__IV12__TAG16__HKDF__SHA256(); + if (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_128_GCM_IV12_TAG16_HKDF_SHA256_ECDSA_P256.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKAlgorithmSuiteId.create_ALG__AES__128__GCM__IV12__TAG16__HKDF__SHA256__ECDSA__P256(); + if (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_192_GCM_IV12_TAG16_HKDF_SHA384_ECDSA_P384.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKAlgorithmSuiteId.create_ALG__AES__192__GCM__IV12__TAG16__HKDF__SHA384__ECDSA__P384(); + if (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_256_GCM_IV12_TAG16_HKDF_SHA384_ECDSA_P384.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKAlgorithmSuiteId.create_ALG__AES__256__GCM__IV12__TAG16__HKDF__SHA384__ECDSA__P384(); + if (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_256_GCM_HKDF_SHA512_COMMIT_KEY.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKAlgorithmSuiteId.create_ALG__AES__256__GCM__HKDF__SHA512__COMMIT__KEY(); + if (AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId.ALG_AES_256_GCM_HKDF_SHA512_COMMIT_KEY_ECDSA_P384.Equals(value)) return software.amazon.cryptography.materialproviders.internaldafny.types.ESDKAlgorithmSuiteId.create_ALG__AES__256__GCM__HKDF__SHA512__COMMIT__KEY__ECDSA__P384(); + throw new System.ArgumentException("Invalid AWS.Cryptography.MaterialProviders.ESDKAlgorithmSuiteId value"); + } + public static long FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S11_FrameLength(long value) + { + return value; + } + public static long ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S11_FrameLength(long value) + { + return value; + } + public static string FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext__M3_key(Dafny.ISequence value) + { + return FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S9_Utf8Bytes(value); + } + public static Dafny.ISequence ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext__M3_key(string value) + { + return ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S9_Utf8Bytes(value); + } + public static string FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext__M5_value(Dafny.ISequence value) + { + return FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S9_Utf8Bytes(value); + } + public static Dafny.ISequence ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S17_EncryptionContext__M5_value(string value) + { + return ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S9_Utf8Bytes(value); + } + public static string FromDafny_N3_aws__N12_cryptography__N17_materialProviders__S9_Utf8Bytes(Dafny.ISequence value) + { + System.Text.UTF8Encoding utf8 = new System.Text.UTF8Encoding(false, true); + return utf8.GetString(value.Elements); + } + public static Dafny.ISequence ToDafny_N3_aws__N12_cryptography__N17_materialProviders__S9_Utf8Bytes(string value) + { + System.Text.UTF8Encoding utf8 = new System.Text.UTF8Encoding(false, true); + return Dafny.Sequence.FromArray(utf8.GetBytes(value)); + } + public static System.Exception FromDafny_CommonError(software.amazon.cryptography.encryptionsdk.internaldafny.types._IError value) + { + switch (value) + { + case software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_AwsCryptographyMaterialProviders dafnyVal: + return AWS.Cryptography.MaterialProviders.TypeConversion.FromDafny_CommonError( + dafnyVal._AwsCryptographyMaterialProviders + ); + case software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_AwsCryptographyPrimitives dafnyVal: + return AWS.Cryptography.Primitives.TypeConversion.FromDafny_CommonError( + dafnyVal._AwsCryptographyPrimitives + ); + case software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_AwsEncryptionSdkException dafnyVal: + return FromDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException(dafnyVal); + case software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_CollectionOfErrors dafnyVal: + return new CollectionOfErrors( + new System.Collections.Generic.List(dafnyVal.dtor_list.CloneAsArray() + .Select(x => TypeConversion.FromDafny_CommonError(x))), + new string(dafnyVal.dtor_message.Elements)); + case software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_Opaque dafnyVal: + return new OpaqueError(dafnyVal._obj); + default: + // The switch MUST be complete for _IError, so `value` MUST NOT be an _IError. (How did you get here?) + return new OpaqueError(); + } + } + public static software.amazon.cryptography.encryptionsdk.internaldafny.types._IError ToDafny_CommonError(System.Exception value) + { + switch (value.GetType().Namespace) + { + case "AWS.Cryptography.MaterialProviders": + return software.amazon.cryptography.encryptionsdk.internaldafny.types.Error.create_AwsCryptographyMaterialProviders( + AWS.Cryptography.MaterialProviders.TypeConversion.ToDafny_CommonError(value) + ); + } + switch (value) + { + case AWS.Cryptography.EncryptionSDK.AwsEncryptionSdkException exception: + return ToDafny_N3_aws__N12_cryptography__N13_encryptionSdk__S25_AwsEncryptionSdkException(exception); + case CollectionOfErrors collectionOfErrors: + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_CollectionOfErrors( + Dafny.Sequence + .FromArray( + collectionOfErrors.list.Select + (x => TypeConversion.ToDafny_CommonError(x)) + .ToArray()), + Dafny.Sequence.FromString(collectionOfErrors.Message) + ); + // OpaqueError is redundant, but listed for completeness. + case OpaqueError exception: + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_Opaque(exception, Dafny.Sequence.FromString(exception.ToString())); + case System.Exception exception: + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_Opaque(exception, Dafny.Sequence.FromString(exception.ToString())); + default: + // The switch MUST be complete for System.Exception, so `value` MUST NOT be an System.Exception. (How did you get here?) + return new software.amazon.cryptography.encryptionsdk.internaldafny.types.Error_Opaque(value, Dafny.Sequence.FromString(value.ToString())); + } + } + } +} diff --git a/TestVectors/runtimes/net/tests/Extern/GetTestDirectoryExtern.cs b/TestVectors/runtimes/net/tests/Extern/GetTestDirectoryExtern.cs new file mode 100644 index 000000000..ab7f4256b --- /dev/null +++ b/TestVectors/runtimes/net/tests/Extern/GetTestDirectoryExtern.cs @@ -0,0 +1,9 @@ +using byteseq = Dafny.Sequence; + +namespace TestWrappedESDKMain_Compile { + public partial class __default { + public static Dafny.ISequence GetTestVectorExecutionDirectory() { + return byteseq.FromString(""); + } + } +} diff --git a/TestVectors/runtimes/net/tests/TestVectors-Tests.csproj b/TestVectors/runtimes/net/tests/TestVectors-Tests.csproj new file mode 100644 index 000000000..962166e20 --- /dev/null +++ b/TestVectors/runtimes/net/tests/TestVectors-Tests.csproj @@ -0,0 +1,36 @@ + + + + TEST_AWS Encryption SDK Library + enable + disable + net6.0;net48 + 10 + Exe + false + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/cfn/CI.yaml b/cfn/CI.yaml index f449b9d4a..abeca4f7a 100644 --- a/cfn/CI.yaml +++ b/cfn/CI.yaml @@ -30,6 +30,7 @@ Resources: - "arn:aws:iam::370957321024:policy/Hierarchical-GitHub-KMS-Key-Policy" - "arn:aws:iam::370957321024:policy/KMS-Public-CMK-EncryptDecrypt-Key-Access" - "arn:aws:iam::370957321024:policy/RSA-GitHub-KMS-Key-Policy" + - "arn:aws:iam::370957321024:policy/Github-ECDH-KMS" AssumeRolePolicyDocument: !Sub | { "Version": "2012-10-17", diff --git a/mpl b/mpl index 4f7e715d2..587b2cc27 160000 --- a/mpl +++ b/mpl @@ -1 +1 @@ -Subproject commit 4f7e715d29459b0e637067066c0fec321e00cd9b +Subproject commit 587b2cc2774db194e96685fe169ccdb32dd64add diff --git a/smithy-dafny b/smithy-dafny deleted file mode 160000 index 98939e130..000000000 --- a/smithy-dafny +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 98939e130695095386059967509a19299dfac320