8[UnsupportedOSPlatform(
"browser")]
9[UnsupportedOSPlatform(
"ios")]
10[UnsupportedOSPlatform(
"tvos")]
41 public void Encrypt(
byte[] nonce,
byte[] plaintext,
byte[] ciphertext,
byte[] tag,
byte[]? associatedData =
null)
50 EncryptCore(nonce, plaintext, ciphertext, tag, associatedData);
53 public void Decrypt(
byte[] nonce,
byte[] ciphertext,
byte[] tag,
byte[] plaintext,
byte[]? associatedData =
null)
62 DecryptCore(nonce, ciphertext, tag, plaintext, associatedData);
88 [MemberNotNull(
"_keyHandle")]
static SafeAlgorithmHandle AesGcm
static string Cryptography_InvalidNonceLength
static string Cryptography_PlaintextCiphertextLengthMismatch
static string Cryptography_InvalidTagLength
static void CheckArgumentsForNull(byte[] nonce, byte[] plaintext, byte[] ciphertext, byte[] tag)
static unsafe void Decrypt(SafeKeyHandle keyHandle, ReadOnlySpan< byte > nonce, ReadOnlySpan< byte > associatedData, ReadOnlySpan< byte > ciphertext, ReadOnlySpan< byte > tag, Span< byte > plaintext, bool clearPlaintextOnFailure)
static unsafe void Encrypt(SafeKeyHandle keyHandle, ReadOnlySpan< byte > nonce, ReadOnlySpan< byte > associatedData, ReadOnlySpan< byte > plaintext, Span< byte > ciphertext, Span< byte > tag)
static void CheckKeySize(int keySizeInBytes)
AesGcm(ReadOnlySpan< byte > key)
void EncryptCore(ReadOnlySpan< byte > nonce, ReadOnlySpan< byte > plaintext, Span< byte > ciphertext, Span< byte > tag, ReadOnlySpan< byte > associatedData=default(ReadOnlySpan< byte >))
void Decrypt(ReadOnlySpan< byte > nonce, ReadOnlySpan< byte > ciphertext, ReadOnlySpan< byte > tag, Span< byte > plaintext, ReadOnlySpan< byte > associatedData=default(ReadOnlySpan< byte >))
static KeySizes TagByteSizes
void Decrypt(byte[] nonce, byte[] ciphertext, byte[] tag, byte[] plaintext, byte[]? associatedData=null)
void Encrypt(ReadOnlySpan< byte > nonce, ReadOnlySpan< byte > plaintext, Span< byte > ciphertext, Span< byte > tag, ReadOnlySpan< byte > associatedData=default(ReadOnlySpan< byte >))
void Encrypt(byte[] nonce, byte[] plaintext, byte[] ciphertext, byte[] tag, byte[]? associatedData=null)
static void ThrowIfNotSupported()
static void CheckParameters(ReadOnlySpan< byte > plaintext, ReadOnlySpan< byte > ciphertext, ReadOnlySpan< byte > nonce, ReadOnlySpan< byte > tag)
static KeySizes NonceByteSizes
void DecryptCore(ReadOnlySpan< byte > nonce, ReadOnlySpan< byte > ciphertext, ReadOnlySpan< byte > tag, Span< byte > plaintext, ReadOnlySpan< byte > associatedData=default(ReadOnlySpan< byte >))
void ImportKey(ReadOnlySpan< byte > key)
override void Dispose(bool disposing)