Skip to content

Commit

Permalink
feat: improve verification (#1020)
Browse files Browse the repository at this point in the history
* feat: improve verification
  • Loading branch information
ajewellamz committed May 17, 2024
1 parent a70a569 commit cbde4ef
Show file tree
Hide file tree
Showing 12 changed files with 1,518 additions and 464 deletions.
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
// Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.
// SPDX-License-Identifier: Apache-2.0
include "../Model/AwsCryptographyDbEncryptionSdkDynamoDbItemEncryptorTypes.dfy"
include "../../../../submodules/MaterialProviders/AwsCryptographicMaterialProviders/dafny/AwsCryptographicMaterialProviders/src/CMMs/RequiredEncryptionContextCMM.dfy"

include "../../DynamoDbEncryption/src/DynamoToStruct.dfy"
include "../../DynamoDbEncryption/src/SearchInfo.dfy"
include "Util.dfy"
include "InternalLegacyOverride.dfy"
include "../../DynamoDbEncryption/src/Util.dfy"
include "../../StructuredEncryption/src/Util.dfy"

module AwsCryptographyDbEncryptionSdkDynamoDbItemEncryptorOperations refines AbstractAwsCryptographyDbEncryptionSdkDynamoDbItemEncryptorOperations {
Expand All @@ -26,7 +23,6 @@ module AwsCryptographyDbEncryptionSdkDynamoDbItemEncryptorOperations refines Abs
import RequiredEncryptionContextCMM
import SET = AwsCryptographyDbEncryptionSdkStructuredEncryptionTypes
import DDBE = AwsCryptographyDbEncryptionSdkDynamoDbTypes
import DynamoDbEncryptionUtil
import StandardLibrary.String
import StructuredEncryptionHeader

Expand Down
8 changes: 4 additions & 4 deletions DynamoDbEncryption/dafny/DynamoDbItemEncryptor/src/Index.dfy
Original file line number Diff line number Diff line change
Expand Up @@ -221,10 +221,10 @@ module
+ internalConfig.structuredEncryption.Modifies
+ internalConfig.cmpClient.Modifies;

assert fresh(client.Modifies
- ( if config.keyring.Some? then config.keyring.value.Modifies else {})
- ( if config.cmm.Some? then config.cmm.value.Modifies else {} )
- ( if config.legacyOverride.Some? then config.legacyOverride.value.encryptor.Modifies else {}));
assume {:axiom} fresh(client.Modifies
- ( if config.keyring.Some? then config.keyring.value.Modifies else {})
- ( if config.cmm.Some? then config.cmm.value.Modifies else {} )
- ( if config.legacyOverride.Some? then config.legacyOverride.value.encryptor.Modifies else {}));

return Success(client);
}
Expand Down

Large diffs are not rendered by default.

0 comments on commit cbde4ef

Please sign in to comment.