github.com/hyperledger/aries-framework-go@v0.3.2/pkg/crypto/tinkcrypto/primitive/aead/subtle/subtle.go (about) 1 /* 2 Copyright SecureKey Technologies Inc. All Rights Reserved. 3 4 SPDX-License-Identifier: Apache-2.0 5 */ 6 7 // Package subtle provides subtle implementations of the AEAD primitive. 8 package subtle 9 10 import ( 11 "github.com/hyperledger/aries-framework-go/component/kmscrypto/crypto/tinkcrypto/primitive/aead/subtle" 12 ) 13 14 const ( 15 // AES128Size value in number of bytes. 16 AES128Size = subtle.AES128Size 17 // AES192Size value in number of bytes. 18 AES192Size = subtle.AES192Size 19 // AES256Size value in number of bytes. 20 AES256Size = subtle.AES256Size 21 ) 22 23 // ValidateAESKeySize checks if the given key size is a valid AES key size. 24 func ValidateAESKeySize(sizeInBytes uint32) error { 25 return subtle.ValidateAESKeySize(sizeInBytes) 26 } 27 28 // ValidateAESKeySizeForGoJose checks if the given key size is a valid AES key size. 29 func ValidateAESKeySizeForGoJose(sizeInBytes uint32) error { 30 return subtle.ValidateAESKeySizeForGoJose(sizeInBytes) 31 }