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

◆ TrimLargeIV()

static byte[] Internal.Cryptography.Helpers.TrimLargeIV ( byte[] currentIV,
int blockSizeInBits )
inlinestatic

Definition at line 27 of file Helpers.cs.

28 {
29 int num = checked(blockSizeInBits + 7) / 8;
30 if (currentIV != null && currentIV.Length > num)
31 {
32 byte[] array = new byte[num];
33 Buffer.BlockCopy(currentIV, 0, array, 0, array.Length);
34 return array;
35 }
36 return currentIV;
37 }
static void BlockCopy(Array src, int srcOffset, Array dst, int dstOffset, int count)
Definition Buffer.cs:102

References System.array, and System.Buffer.BlockCopy().

Referenced by System.Security.Cryptography.TripleDESCryptoServiceProvider.CreateDecryptor(), and System.Security.Cryptography.TripleDESCryptoServiceProvider.CreateEncryptor().