13 references to BitsToBytes
System.Security.Cryptography (13)
src\runtime\src\libraries\Common\src\System\Security\Cryptography\AsymmetricAlgorithmHelpers.Der.cs (3)
51
int fieldSizeBytes =
BitsToBytes
(fieldSizeBits);
61
int fieldSizeBytes =
BitsToBytes
(fieldSizeBits);
128
int paddedFieldSizeBytes =
BitsToBytes
(fieldSizeBits + 1);
System\Security\Cryptography\AesCng.Windows.cs (1)
291
KeyValue ??= RandomNumberGenerator.GetBytes(AsymmetricAlgorithmHelpers.
BitsToBytes
(KeySizeValue));
System\Security\Cryptography\CngSymmetricAlgorithmCore.cs (8)
112
byte[] key = RandomNumberGenerator.GetBytes(AsymmetricAlgorithmHelpers.
BitsToBytes
(_outer.BaseKeySize));
118
byte[] iv = RandomNumberGenerator.GetBytes(AsymmetricAlgorithmHelpers.
BitsToBytes
(_outer.BlockSize));
171
if (!iv.IsEmpty && iv.Length != AsymmetricAlgorithmHelpers.
BitsToBytes
(_outer.BlockSize))
182
int blockSizeInBytes = AsymmetricAlgorithmHelpers.
BitsToBytes
(_outer.BlockSize);
202
if (rgbIV != null && rgbIV.Length != AsymmetricAlgorithmHelpers.
BitsToBytes
(_outer.BlockSize))
216
int blockSizeInBytes = AsymmetricAlgorithmHelpers.
BitsToBytes
(_outer.BlockSize);
241
int blockSizeInBytes = AsymmetricAlgorithmHelpers.
BitsToBytes
(_outer.BlockSize);
259
int blockSizeInBytes = AsymmetricAlgorithmHelpers.
BitsToBytes
(_outer.BlockSize);
System\Security\Cryptography\ECDsa.cs (1)
1269
return AsymmetricAlgorithmHelpers.
BitsToBytes
(fieldSizeBits) * 2;