Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ TryDecryptCfbCore()

override bool Internal.Cryptography.AesImplementation.TryDecryptCfbCore ( ReadOnlySpan< byte > ciphertext,
ReadOnlySpan< byte > iv,
Span< byte > destination,
PaddingMode paddingMode,
int feedbackSizeInBits,
out int bytesWritten )
inlineprotectedvirtual

Reimplemented from System.Security.Cryptography.SymmetricAlgorithm.

Definition at line 80 of file AesImplementation.cs.

81 {
82 ValidateCFBFeedbackSize(feedbackSizeInBits);
83 UniversalCryptoTransform universalCryptoTransform = CreateTransformCore(CipherMode.CFB, paddingMode, Key, iv.ToArray(), BlockSize / 8, feedbackSizeInBits / 8, feedbackSizeInBits / 8, encrypting: false);
84 using (universalCryptoTransform)
85 {
86 return universalCryptoTransform.TransformOneShot(ciphertext, destination, out bytesWritten);
87 }
88 }
static void ValidateCFBFeedbackSize(int feedback)
static UniversalCryptoTransform CreateTransformCore(CipherMode cipherMode, PaddingMode paddingMode, byte[] key, byte[] iv, int blockSize, int paddingSize, int feedbackSize, bool encrypting)

References System.Security.Cryptography.SymmetricAlgorithm.BlockSize, Internal.Cryptography.AesImplementation.CreateTransformCore(), System.destination, System.Security.Cryptography.SymmetricAlgorithm.Key, System.ReadOnlySpan< T >.ToArray(), Internal.Cryptography.UniversalCryptoTransform.TransformOneShot(), and Internal.Cryptography.AesImplementation.ValidateCFBFeedbackSize().