Skip to content

AES GCM: BouncyCastle vs. C# AesGCM (BCryptDcrypt) - nonces uneven (longer) of the recommended 12 bytes #585

Closed Answered by peterdettman
flankendiskriminator asked this question in Q&A
Discussion options

You must be logged in to vote

Unfortunately It's not possible to convert a non-96-bit nonce to a 96-bit one externally. The nonce is used to derive the 128-bit value J0 and there is no way to initialize GCM directly with a J0 value (except in the trivial case where the final 32 bits of J0 happen to == 1).

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Answer selected by flankendiskriminator
Comment options

You must be logged in to vote
2 replies
@peterdettman
Comment options

@flankendiskriminator
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
question Further information is requested
2 participants