Open
Description
This behavior was un-expected, and I think is a bug. However maybe I don't fully understand the intent.
func (c *aesCipher) NewGCM(nonceSize, tagSize int) (cipher.AEAD, error) {
if !ExecutingTest() || IsStrictFips() {
if nonceSize != gcmStandardNonceSize {
return nil, errors.New("crypto/aes: GCM nonce size can't be non-standard")
}
if tagSize != gcmTagSize {
return nil, errors.New("crypto/aes: GCM tag size can't be non-standard")
}
I believe the || should be an &&. As this stands now, anytime we're not running _test code, we're enforcing strict checking of the default nonce size..
Metadata
Metadata
Assignees
Labels
No labels