@@ -33,6 +33,8 @@ module {:options "-functionSyntax:4"} JsonConfig {
3333 import DynamoDbItemEncryptor
3434
3535
36+ const DEFAULT_KEYS := ".. / .. / .. / submodules/ MaterialProviders/ TestVectorsAwsCryptographicMaterialProviders/ dafny/ TestVectorsAwsCryptographicMaterialProviders/ test/ keys. json"
37+
3638 predicate IsValidInt32 (x: int ) { - 0x8000_0000 <= x < 0x8000_0000}
3739 type ConfigName = string
3840
@@ -296,7 +298,7 @@ module {:options "-functionSyntax:4"} JsonConfig {
296298
297299 var keys :- expect KeyVectors. KeyVectors (
298300 KeyVectorsTypes.KeyVectorsConfig(
299- keyManifiestPath := "../../../submodules/MaterialProviders/TestVectorsAwsCryptographicMaterialProviders/dafny/TestVectorsAwsCryptographicMaterialProviders/test/keys.json"
301+ keyManifiestPath := DEFAULT_KEYS
300302 )
301303 );
302304 var keyDescription :-
@@ -398,7 +400,7 @@ module {:options "-functionSyntax:4"} JsonConfig {
398400
399401 var keys :- expect KeyVectors. KeyVectors (
400402 KeyVectorsTypes.KeyVectorsConfig(
401- keyManifiestPath := "../../../submodules/MaterialProviders/TestVectorsAwsCryptographicMaterialProviders/dafny/TestVectorsAwsCryptographicMaterialProviders/test/keys.json"
403+ keyManifiestPath := DEFAULT_KEYS
402404 )
403405 );
404406 var keyDescription :-
@@ -545,7 +547,7 @@ module {:options "-functionSyntax:4"} JsonConfig {
545547 case "ENCRYPT_AND_SIGN" => return Success (SE.ENCRYPT_AND_SIGN);
546548 case "SIGN_ONLY" => return Success (SE.SIGN_ONLY);
547549 case "DO_NOTHING" => return Success (SE.DO_NOTHING);
548- case _ => return Failure (data.str + " is not a value CryptoAction.");
550+ case _ => return Failure (data.str + " is not a valid CryptoAction.");
549551 }
550552 }
551553
@@ -922,9 +924,6 @@ module {:options "-functionSyntax:4"} JsonConfig {
922924 return Success (Types.CompoundBeacon(name := name, split := split, encrypted := OptSeq(Encrypted), signed := OptSeq (Signed), constructors := OptSeq (constructors)));
923925 }
924926
925- // datatype Type = Type
926- // method JsonToType(data : JSON) returns (output : Result<Type, string>)
927-
928927 method GetConstructors (data : JSON ) returns (output : Result< seq < Types. Constructor> , string > )
929928 {
930929 :- Need (data.Array?, "Constructor list must be an array.");
0 commit comments