11 references to NONCE_SIZE_IN_BYTES
Microsoft.AspNetCore.DataProtection (11)
Cng\CngGcmAuthenticatedEncryptor.cs (11)
74
BitHelpers.WriteTo(ref ptr,
NONCE_SIZE_IN_BYTES
);
97
byte* pbNonce = stackalloc byte[(int)
NONCE_SIZE_IN_BYTES
];
98
UnsafeBufferUtil.SecureZeroMemory(pbNonce,
NONCE_SIZE_IN_BYTES
);
120
if (cbCiphertext < KEY_MODIFIER_SIZE_IN_BYTES +
NONCE_SIZE_IN_BYTES
+ TAG_SIZE_IN_BYTES)
127
var cbPlaintext = checked(cbCiphertext - (KEY_MODIFIER_SIZE_IN_BYTES +
NONCE_SIZE_IN_BYTES
+ TAG_SIZE_IN_BYTES));
135
byte* pbEncryptedData = &pbNonce[
NONCE_SIZE_IN_BYTES
];
161
authInfo.cbNonce =
NONCE_SIZE_IN_BYTES
;
210
authCipherInfo.cbNonce =
NONCE_SIZE_IN_BYTES
;
237
var retVal = new byte[checked(cbPreBuffer + KEY_MODIFIER_SIZE_IN_BYTES +
NONCE_SIZE_IN_BYTES
+ cbPlaintext + TAG_SIZE_IN_BYTES + cbPostBuffer)];
243
byte* pbEncryptedData = &pbNonce[
NONCE_SIZE_IN_BYTES
];
247
_genRandom.GenRandom(pbKeyModifier, KEY_MODIFIER_SIZE_IN_BYTES +
NONCE_SIZE_IN_BYTES
);