diff --git a/.github/workflows/ci_examples_java.yml b/.github/workflows/ci_examples_java.yml index dfa810c16..a38b5a24a 100644 --- a/.github/workflows/ci_examples_java.yml +++ b/.github/workflows/ci_examples_java.yml @@ -63,7 +63,7 @@ jobs: uses: dafny-lang/setup-dafny-action@v1.6.1 with: # A && B || C is the closest thing to an if .. then ... else ... or ?: expression the GitHub Actions syntax supports. - dafny-version: ${{ (github.event_name == 'schedule' || inputs.nightly) && 'nightly-latest' || '4.1.0' }} + dafny-version: ${{ (github.event_name == 'schedule' || inputs.nightly) && 'nightly-latest' || '4.2.0' }} - name: Build and locally deploy dependencies for examples shell: bash diff --git a/.github/workflows/ci_test_java.yml b/.github/workflows/ci_test_java.yml index 91eb11700..ab085970a 100644 --- a/.github/workflows/ci_test_java.yml +++ b/.github/workflows/ci_test_java.yml @@ -59,7 +59,7 @@ jobs: uses: dafny-lang/setup-dafny-action@v1.6.1 with: # A && B || C is the closest thing to an if .. then ... else ... or ?: expression the GitHub Actions syntax supports. - dafny-version: ${{ (github.event_name == 'schedule' || inputs.nightly) && 'nightly-latest' || '4.1.0' }} + dafny-version: ${{ (github.event_name == 'schedule' || inputs.nightly) && 'nightly-latest' || '4.2.0' }} - name: Setup Java ${{ matrix.java-version }} uses: actions/setup-java@v3 diff --git a/.github/workflows/ci_test_net.yml b/.github/workflows/ci_test_net.yml index 4063ede6c..b464e602b 100644 --- a/.github/workflows/ci_test_net.yml +++ b/.github/workflows/ci_test_net.yml @@ -60,7 +60,7 @@ jobs: uses: dafny-lang/setup-dafny-action@v1.6.1 with: # A && B || C is the closest thing to an if .. then ... else ... or ?: expression the GitHub Actions syntax supports. - dafny-version: ${{ (github.event_name == 'schedule' || inputs.nightly) && 'nightly-latest' || '4.1.0' }} + dafny-version: ${{ (github.event_name == 'schedule' || inputs.nightly) && 'nightly-latest' || '4.2.0' }} - name: Download Dependencies working-directory: ./${{ matrix.library }} diff --git a/.github/workflows/ci_test_vector_java.yml b/.github/workflows/ci_test_vector_java.yml index 19917495e..c550898bc 100644 --- a/.github/workflows/ci_test_vector_java.yml +++ b/.github/workflows/ci_test_vector_java.yml @@ -41,7 +41,7 @@ jobs: - name: Setup Dafny uses: dafny-lang/setup-dafny-action@v1.6.1 with: - dafny-version: '4.1.0' + dafny-version: '4.2.0' - name: Setup Java ${{ matrix.java-version }} uses: actions/setup-java@v3 diff --git a/.github/workflows/ci_verification.yml b/.github/workflows/ci_verification.yml index 0ee2efad7..98963b88b 100644 --- a/.github/workflows/ci_verification.yml +++ b/.github/workflows/ci_verification.yml @@ -50,7 +50,7 @@ jobs: uses: dafny-lang/setup-dafny-action@v1.6.1 with: # A && B || C is the closest thing to an if .. then ... else ... or ?: expression the GitHub Actions syntax supports. - dafny-version: ${{ (github.event_name == 'schedule' || inputs.nightly) && 'nightly-latest' || '4.1.0' }} + dafny-version: ${{ (github.event_name == 'schedule' || inputs.nightly) && 'nightly-latest' || '4.2.0' }} - name: Verify ${{ matrix.library }} Dafny code shell: bash diff --git a/.gitmodules b/.gitmodules index 894ca5e35..b872bcbda 100644 --- a/.gitmodules +++ b/.gitmodules @@ -1,6 +1,6 @@ [submodule "submodules/MaterialProviders"] path = submodules/MaterialProviders - url = https://github.com/aws/aws-cryptographic-material-providers-library-java.git + url = https://github.com/aws/aws-cryptographic-material-providers-library-dafny.git [submodule "submodules/smithy-dafny"] path = submodules/smithy-dafny url = https://github.com/awslabs/smithy-dafny.git diff --git a/DynamoDbEncryption/dafny/DynamoDbEncryptionTransforms/src/ExecuteTransactionTransform.dfy b/DynamoDbEncryption/dafny/DynamoDbEncryptionTransforms/src/ExecuteTransactionTransform.dfy index eec751d3d..2c85c6b8e 100644 --- a/DynamoDbEncryption/dafny/DynamoDbEncryptionTransforms/src/ExecuteTransactionTransform.dfy +++ b/DynamoDbEncryption/dafny/DynamoDbEncryptionTransforms/src/ExecuteTransactionTransform.dfy @@ -41,12 +41,15 @@ module ExecuteTransactionTransform { { for i := 0 to |input.sdkInput.TransactStatements| invariant forall x : nat | 0 <= x < i :: - var statement := DdbStatement.TableFromStatement(input.sdkInput.TransactStatements[x].Statement); - statement.Success? && statement.value !in config.tableEncryptionConfigs; + var tableName := DdbStatement.TableFromStatement(input.sdkInput.TransactStatements[x].Statement); + tableName.Success? && tableName.value !in config.tableEncryptionConfigs { var statement := input.sdkInput.TransactStatements[i].Statement; - var tableName :- MapString(DdbStatement.TableFromStatement(statement)); - if tableName in config.tableEncryptionConfigs { + var tableName := DdbStatement.TableFromStatement(statement); + if tableName.Failure? { + return Failure(Error.DynamoDbEncryptionTransformsException(message := tableName.error)); + } + if tableName.value in config.tableEncryptionConfigs { return MakeError("ExecuteTransaction not Supported on encrypted tables."); } } diff --git a/DynamoDbEncryption/runtimes/net/DynamoDbEncryption.csproj b/DynamoDbEncryption/runtimes/net/DynamoDbEncryption.csproj index 06ca3fb03..bd507ea0b 100644 --- a/DynamoDbEncryption/runtimes/net/DynamoDbEncryption.csproj +++ b/DynamoDbEncryption/runtimes/net/DynamoDbEncryption.csproj @@ -5,14 +5,14 @@ enable disable 10 - net6.0 + net6.0;net48 false - +