File tree 1 file changed +2
-2
lines changed
1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -1295,7 +1295,7 @@ fn aes_gcm_no_aad() -> TestResult {
1295
1295
Attribute :: Encrypt ( true ) ,
1296
1296
] ;
1297
1297
let key_handle = session. create_object ( & template) ?;
1298
- let mechanism = Mechanism :: AesGcm ( GcmParams :: new ( & mut iv, & aad, 96 . into ( ) ) ) ;
1298
+ let mechanism = Mechanism :: AesGcm ( GcmParams :: new ( & mut iv, & aad, 96 . into ( ) ) . unwrap ( ) ) ;
1299
1299
let cipher_and_tag = session. encrypt ( & mechanism, key_handle, & plain) ?;
1300
1300
assert_eq ! ( expected_cipher_and_tag[ ..] , cipher_and_tag[ ..] ) ;
1301
1301
Ok ( ( ) )
@@ -1326,7 +1326,7 @@ fn aes_gcm_with_aad() -> TestResult {
1326
1326
Attribute :: Encrypt ( true ) ,
1327
1327
] ;
1328
1328
let key_handle = session. create_object ( & template) ?;
1329
- let mechanism = Mechanism :: AesGcm ( GcmParams :: new ( & mut iv, & aad, 96 . into ( ) ) ) ;
1329
+ let mechanism = Mechanism :: AesGcm ( GcmParams :: new ( & mut iv, & aad, 96 . into ( ) ) . unwrap ( ) ) ;
1330
1330
let cipher_and_tag = session. encrypt ( & mechanism, key_handle, & plain) ?;
1331
1331
assert_eq ! ( expected_cipher_and_tag[ ..] , cipher_and_tag[ ..] ) ;
1332
1332
Ok ( ( ) )
You can’t perform that action at this time.
0 commit comments