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

◆ GetSharedHandle()

static SafeAlgorithmHandle Internal.Cryptography.DesBCryptModes.GetSharedHandle ( CipherMode cipherMode,
int feedback )
inlinestaticpackage

Definition at line 15 of file DesBCryptModes.cs.

16 {
17 switch (cipherMode)
18 {
19 case CipherMode.CFB:
20 if (feedback != 1)
21 {
22 break;
23 }
24 return s_hAlgCfb8.Value;
25 case CipherMode.CBC:
26 return s_hAlgCbc.Value;
27 case CipherMode.ECB:
28 return s_hAlgEcb.Value;
29 }
30 throw new NotSupportedException();
31 }
static readonly Lazy< SafeAlgorithmHandle > s_hAlgEcb
static readonly Lazy< SafeAlgorithmHandle > s_hAlgCfb8
static readonly Lazy< SafeAlgorithmHandle > s_hAlgCbc

References Internal.Cryptography.DesBCryptModes.s_hAlgCbc, Internal.Cryptography.DesBCryptModes.s_hAlgCfb8, and Internal.Cryptography.DesBCryptModes.s_hAlgEcb.

Referenced by Internal.Cryptography.DesImplementation.CreateTransformCore().