Method | Description | |
---|---|---|
AddPkcs7Padding ( byte data, int paddingLength ) : byte[] |
Fill up an array with Pkcs7 padding.
|
|
GetChecksum ( byte array ) : string |
Returns a SHA256 byte[] checksum.
|
|
GetChecksum ( string path ) : string |
Returns a SHA256 file checksum.
|
|
GetEphemeralEncryptionKey ( byte ephemeralKey ) : byte[] |
Extract the encryption key from the ephemeralKey.
|
|
GetEphemeralHashKey ( byte ephemeralKey ) : byte[] |
Extract the hash key from the ephemeralKey.
|
|
GetRandomFileName ( int length, string fileExtension ) : string |
Generates a random filename of given length.
|
|
IntegerToLittleEndian ( int data ) : byte[] |
Converts an integer to a little endian byte array.
|
|
PaddedByteArrayToString ( byte paddedByteArray ) : string |
Converts a padded byte array to a unpadded string.
|
|
RemovePkcs7Padding ( byte paddedByteArray ) : byte[] |
Removes the Pkcs7 padding of an array.
|
Method | Description | |
---|---|---|
StringToPaddedByteArray ( string str, int paddingLength ) : byte[] |
public static AddPkcs7Padding ( byte data, int paddingLength ) : byte[] | ||
data | byte | The source array. |
paddingLength | int | The length of the padding. |
return | byte[] |
public static GetChecksum ( byte array ) : string | ||
array | byte | A byte array. |
return | string |
public static GetChecksum ( string path ) : string | ||
path | string | The full path. |
return | string |
public static GetEphemeralEncryptionKey ( byte ephemeralKey ) : byte[] | ||
ephemeralKey | byte | The 64 byte ephemeralKey. |
return | byte[] |
public static GetEphemeralHashKey ( byte ephemeralKey ) : byte[] | ||
ephemeralKey | byte | The 64 byte ephemeralKey. |
return | byte[] |
public static GetRandomFileName ( int length, string fileExtension ) : string | ||
length | int | length of the random string. |
fileExtension | string | a file extension |
return | string |
public static IntegerToLittleEndian ( int data ) : byte[] | ||
data | int | An integer. |
return | byte[] |
public static PaddedByteArrayToString ( byte paddedByteArray ) : string | ||
paddedByteArray | byte | The padded byte array. |
return | string |
public static RemovePkcs7Padding ( byte paddedByteArray ) : byte[] | ||
paddedByteArray | byte | The padded array. |
return | byte[] |