|
enum | SecretAgreementFlags { None = 0
, UseSecretAsHmacKey = 1
, None = 0
, UseSecretAsHmacKey = 1
} |
|
enum | BufferType {
KdfHashAlgorithm = 0
, KdfSecretPrepend = 1
, KdfSecretAppend = 2
, KdfHmacKey = 3
,
KdfTlsLabel = 4
, KdfTlsSeed = 5
, PkcsAlgOid = 41
, PkcsAlgParam = 42
,
PkcsSecret = 46
, KdfHashAlgorithm = 0
, KdfSecretPrepend = 1
, KdfSecretAppend = 2
,
KdfHmacKey = 3
, KdfTlsLabel = 4
, KdfTlsSeed = 5
, PkcsAlgOid = 41
,
PkcsAlgParam = 42
, PkcsSecret = 46
} |
|
enum | AsymmetricPaddingMode {
None = 0
, NCRYPT_NO_PADDING_FLAG = 1
, NCRYPT_PAD_PKCS1_FLAG = 2
, NCRYPT_PAD_OAEP_FLAG = 4
,
NCRYPT_PAD_PSS_FLAG = 8
, None = 0
, NCRYPT_NO_PADDING_FLAG = 1
, NCRYPT_PAD_PKCS1_FLAG = 2
,
NCRYPT_PAD_OAEP_FLAG = 4
, NCRYPT_PAD_PSS_FLAG = 8
} |
|
enum | ErrorCode {
ERROR_SUCCESS = 0
, NTE_BAD_SIGNATURE = -2146893818
, NTE_NOT_FOUND = -2146893807
, NTE_BAD_KEYSET = -2146893802
,
NTE_INVALID_PARAMETER = -2146893785
, NTE_BUFFER_TOO_SMALL = -2146893784
, NTE_NOT_SUPPORTED = -2146893783
, NTE_NO_MORE_ITEMS = -2146893782
,
E_FAIL = -2147467259
, STATUS_UNSUCCESSFUL = -1073741823
, ERROR_SUCCESS = 0
, NTE_BAD_SIGNATURE = -2146893818
,
NTE_NOT_FOUND = -2146893807
, NTE_BAD_KEYSET = -2146893802
, NTE_INVALID_PARAMETER = -2146893785
, NTE_BUFFER_TOO_SMALL = -2146893784
,
NTE_NOT_SUPPORTED = -2146893783
, NTE_NO_MORE_ITEMS = -2146893782
, E_FAIL = -2147467259
, STATUS_UNSUCCESSFUL = -1073741823
} |
|
enum | AsymmetricPaddingMode {
None = 0
, NCRYPT_NO_PADDING_FLAG = 1
, NCRYPT_PAD_PKCS1_FLAG = 2
, NCRYPT_PAD_OAEP_FLAG = 4
,
NCRYPT_PAD_PSS_FLAG = 8
, None = 0
, NCRYPT_NO_PADDING_FLAG = 1
, NCRYPT_PAD_PKCS1_FLAG = 2
,
NCRYPT_PAD_OAEP_FLAG = 4
, NCRYPT_PAD_PSS_FLAG = 8
} |
|
enum | ErrorCode {
ERROR_SUCCESS = 0
, NTE_BAD_SIGNATURE = -2146893818
, NTE_NOT_FOUND = -2146893807
, NTE_BAD_KEYSET = -2146893802
,
NTE_INVALID_PARAMETER = -2146893785
, NTE_BUFFER_TOO_SMALL = -2146893784
, NTE_NOT_SUPPORTED = -2146893783
, NTE_NO_MORE_ITEMS = -2146893782
,
E_FAIL = -2147467259
, STATUS_UNSUCCESSFUL = -1073741823
, ERROR_SUCCESS = 0
, NTE_BAD_SIGNATURE = -2146893818
,
NTE_NOT_FOUND = -2146893807
, NTE_BAD_KEYSET = -2146893802
, NTE_INVALID_PARAMETER = -2146893785
, NTE_BUFFER_TOO_SMALL = -2146893784
,
NTE_NOT_SUPPORTED = -2146893783
, NTE_NO_MORE_ITEMS = -2146893782
, E_FAIL = -2147467259
, STATUS_UNSUCCESSFUL = -1073741823
} |
|
enum | SecretAgreementFlags { None = 0
, UseSecretAsHmacKey = 1
, None = 0
, UseSecretAsHmacKey = 1
} |
|
enum | BufferType {
KdfHashAlgorithm = 0
, KdfSecretPrepend = 1
, KdfSecretAppend = 2
, KdfHmacKey = 3
,
KdfTlsLabel = 4
, KdfTlsSeed = 5
, PkcsAlgOid = 41
, PkcsAlgParam = 42
,
PkcsSecret = 46
, KdfHashAlgorithm = 0
, KdfSecretPrepend = 1
, KdfSecretAppend = 2
,
KdfHmacKey = 3
, KdfTlsLabel = 4
, KdfTlsSeed = 5
, PkcsAlgOid = 41
,
PkcsAlgParam = 42
, PkcsSecret = 46
} |
|
|
static ErrorCode | NCryptImportKey (SafeNCryptProviderHandle hProvider, IntPtr hImportKey, string pszBlobType, IntPtr pParameterList, out SafeNCryptKeyHandle phKey, ref byte pbData, int cbData, int dwFlags) |
|
static ErrorCode | NCryptImportKey (SafeNCryptProviderHandle hProvider, IntPtr hImportKey, string pszBlobType, ref NCryptBufferDesc pParameterList, out SafeNCryptKeyHandle phKey, ref byte pbData, int cbData, int dwFlags) |
|
static ErrorCode | NCryptExportKey (SafeNCryptKeyHandle hKey, IntPtr hExportKey, string pszBlobType, IntPtr pParameterList, [Out] byte[] pbOutput, int cbOutput, out int pcbResult, int dwFlags) |
|
static ErrorCode | NCryptExportKey (SafeNCryptKeyHandle hKey, IntPtr hExportKey, string pszBlobType, IntPtr pParameterList, ref byte pbOutput, int cbOutput, out int pcbResult, int dwFlags) |
|
static ErrorCode | NCryptExportKey (SafeNCryptKeyHandle hKey, IntPtr hExportKey, string pszBlobType, ref NCryptBufferDesc pParameterList, ref byte pbOutput, int cbOutput, out int pcbResult, int dwFlags) |
|
static ErrorCode | NCryptCreatePersistedKey (SafeNCryptProviderHandle hProvider, out SafeNCryptKeyHandle phKey, string pszAlgId, string pszKeyName, int dwLegacyKeySpec, CngKeyCreationOptions dwFlags) |
|
static ErrorCode | NCryptFinalizeKey (SafeNCryptKeyHandle hKey, int dwFlags) |
|
static ErrorCode | NCryptFreeObject (IntPtr hObject) |
|
static ErrorCode | NCryptOpenStorageProvider (out SafeNCryptProviderHandle phProvider, string pszProviderName, int dwFlags) |
|
static unsafe ErrorCode | NCryptGetProperty (SafeNCryptHandle hObject, string pszProperty, [Out] void *pbOutput, int cbOutput, out int pcbResult, CngPropertyOptions dwFlags) |
|
static unsafe ErrorCode | NCryptSetProperty (SafeNCryptHandle hObject, string pszProperty, [In] void *pbInput, int cbInput, CngPropertyOptions dwFlags) |
|
static ErrorCode | NCryptOpenKey (SafeNCryptProviderHandle hProvider, out SafeNCryptKeyHandle phKey, string pszKeyName, int dwLegacyKeySpec, CngKeyOpenOptions dwFlags) |
|
static ErrorCode | NCryptImportKey (SafeNCryptProviderHandle hProvider, IntPtr hImportKey, string pszBlobType, IntPtr pParameterList, out SafeNCryptKeyHandle phKey, ref byte pbData, int cbData, int dwFlags) |
|
static ErrorCode | NCryptImportKey (SafeNCryptProviderHandle hProvider, IntPtr hImportKey, string pszBlobType, ref NCryptBufferDesc pParameterList, out SafeNCryptKeyHandle phKey, ref byte pbData, int cbData, int dwFlags) |
|
static ErrorCode | NCryptExportKey (SafeNCryptKeyHandle hKey, IntPtr hExportKey, string pszBlobType, IntPtr pParameterList, [Out] byte[] pbOutput, int cbOutput, out int pcbResult, int dwFlags) |
|
static ErrorCode | NCryptExportKey (SafeNCryptKeyHandle hKey, IntPtr hExportKey, string pszBlobType, IntPtr pParameterList, ref byte pbOutput, int cbOutput, out int pcbResult, int dwFlags) |
|
static ErrorCode | NCryptExportKey (SafeNCryptKeyHandle hKey, IntPtr hExportKey, string pszBlobType, ref NCryptBufferDesc pParameterList, ref byte pbOutput, int cbOutput, out int pcbResult, int dwFlags) |
|
static ErrorCode | NCryptDeleteKey (SafeNCryptKeyHandle hKey, int dwFlags) |
|
static ErrorCode | NCryptCreatePersistedKey (SafeNCryptProviderHandle hProvider, out SafeNCryptKeyHandle phKey, string pszAlgId, string pszKeyName, int dwLegacyKeySpec, CngKeyCreationOptions dwFlags) |
|
static ErrorCode | NCryptFinalizeKey (SafeNCryptKeyHandle hKey, int dwFlags) |
|
static ErrorCode | NCryptFreeObject (IntPtr hObject) |
|
static ErrorCode | NCryptOpenStorageProvider (out SafeNCryptProviderHandle phProvider, string pszProviderName, int dwFlags) |
|
static unsafe ErrorCode | NCryptGetProperty (SafeNCryptHandle hObject, string pszProperty, [Out] void *pbOutput, int cbOutput, out int pcbResult, CngPropertyOptions dwFlags) |
|
static unsafe ErrorCode | NCryptSetProperty (SafeNCryptHandle hObject, string pszProperty, [In] void *pbInput, int cbInput, CngPropertyOptions dwFlags) |
|
|
static byte[] | DeriveKeyMaterialHash (SafeNCryptSecretHandle secretAgreement, string hashAlgorithm, byte[] secretPrepend, byte[] secretAppend, SecretAgreementFlags flags) |
|
static byte[] | DeriveKeyMaterialHmac (SafeNCryptSecretHandle secretAgreement, string hashAlgorithm, byte[] hmacKey, byte[] secretPrepend, byte[] secretAppend, SecretAgreementFlags flags) |
|
static unsafe byte[] | DeriveKeyMaterialTls (SafeNCryptSecretHandle secretAgreement, byte[] label, byte[] seed, SecretAgreementFlags flags) |
|
static SafeNCryptSecretHandle | DeriveSecretAgreement (SafeNCryptKeyHandle privateKey, SafeNCryptKeyHandle otherPartyPublicKey) |
|
static unsafe ErrorCode | NCryptEncrypt (SafeNCryptKeyHandle hKey, ReadOnlySpan< byte > pbInput, int cbInput, void *pPaddingInfo, Span< byte > pbOutput, int cbOutput, out int pcbResult, AsymmetricPaddingMode dwFlags) |
|
static unsafe ErrorCode | NCryptDecrypt (SafeNCryptKeyHandle hKey, ReadOnlySpan< byte > pbInput, int cbInput, void *pPaddingInfo, Span< byte > pbOutput, int cbOutput, out int pcbResult, AsymmetricPaddingMode dwFlags) |
|
static unsafe ErrorCode | NCryptGetIntProperty (SafeNCryptHandle hObject, string pszProperty, ref int result) |
|
static unsafe ErrorCode | NCryptSignHash (SafeNCryptKeyHandle hKey, void *pPaddingInfo, ReadOnlySpan< byte > pbHashValue, int cbHashValue, Span< byte > pbSignature, int cbSignature, out int pcbResult, AsymmetricPaddingMode dwFlags) |
|
static unsafe ErrorCode | NCryptVerifySignature (SafeNCryptKeyHandle hKey, void *pPaddingInfo, ReadOnlySpan< byte > pbHashValue, int cbHashValue, ReadOnlySpan< byte > pbSignature, int cbSignature, AsymmetricPaddingMode dwFlags) |
|
static unsafe ErrorCode | NCryptEncrypt (SafeNCryptKeyHandle hKey, ReadOnlySpan< byte > pbInput, int cbInput, void *pPaddingInfo, Span< byte > pbOutput, int cbOutput, out int pcbResult, AsymmetricPaddingMode dwFlags) |
|
static unsafe ErrorCode | NCryptDecrypt (SafeNCryptKeyHandle hKey, ReadOnlySpan< byte > pbInput, int cbInput, void *pPaddingInfo, Span< byte > pbOutput, int cbOutput, out int pcbResult, AsymmetricPaddingMode dwFlags) |
|
static byte[] | DeriveKeyMaterialHash (SafeNCryptSecretHandle secretAgreement, string hashAlgorithm, byte[] secretPrepend, byte[] secretAppend, SecretAgreementFlags flags) |
|
static byte[] | DeriveKeyMaterialHmac (SafeNCryptSecretHandle secretAgreement, string hashAlgorithm, byte[] hmacKey, byte[] secretPrepend, byte[] secretAppend, SecretAgreementFlags flags) |
|
static unsafe byte[] | DeriveKeyMaterialTls (SafeNCryptSecretHandle secretAgreement, byte[] label, byte[] seed, SecretAgreementFlags flags) |
|
static SafeNCryptSecretHandle | DeriveSecretAgreement (SafeNCryptKeyHandle privateKey, SafeNCryptKeyHandle otherPartyPublicKey) |
|
static unsafe ErrorCode | NCryptGetIntProperty (SafeNCryptHandle hObject, string pszProperty, ref int result) |
|
static unsafe ErrorCode | NCryptSignHash (SafeNCryptKeyHandle hKey, void *pPaddingInfo, ReadOnlySpan< byte > pbHashValue, int cbHashValue, Span< byte > pbSignature, int cbSignature, out int pcbResult, AsymmetricPaddingMode dwFlags) |
|
static unsafe ErrorCode | NCryptVerifySignature (SafeNCryptKeyHandle hKey, void *pPaddingInfo, ReadOnlySpan< byte > pbHashValue, int cbHashValue, ReadOnlySpan< byte > pbSignature, int cbSignature, AsymmetricPaddingMode dwFlags) |
|
|
static ErrorCode | NCryptDeriveKey (SafeNCryptSecretHandle hSharedSecret, string pwszKDF, [In] ref NCryptBufferDesc pParameterList, [Out][MarshalAs(UnmanagedType.LPArray)] byte[] pbDerivedKey, int cbDerivedKey, out int pcbResult, SecretAgreementFlags dwFlags) |
|
static ErrorCode | NCryptSecretAgreement (SafeNCryptKeyHandle hPrivKey, SafeNCryptKeyHandle hPubKey, out SafeNCryptSecretHandle phSecret, int dwFlags) |
|
static unsafe ErrorCode | NCryptEncrypt (SafeNCryptKeyHandle hKey, ref byte pbInput, int cbInput, void *pPaddingInfo, ref byte pbOutput, int cbOutput, out int pcbResult, AsymmetricPaddingMode dwFlags) |
|
static unsafe ErrorCode | NCryptDecrypt (SafeNCryptKeyHandle hKey, ref byte pbInput, int cbInput, void *pPaddingInfo, ref byte pbOutput, int cbOutput, out int pcbResult, AsymmetricPaddingMode dwFlags) |
|
static unsafe ErrorCode | NCryptSignHash (SafeNCryptKeyHandle hKey, void *pPaddingInfo, ref byte pbHashValue, int cbHashValue, ref byte pbSignature, int cbSignature, out int pcbResult, AsymmetricPaddingMode dwFlags) |
|
static unsafe ErrorCode | NCryptVerifySignature (SafeNCryptKeyHandle hKey, void *pPaddingInfo, ref byte pbHashValue, int cbHashValue, ref byte pbSignature, int cbSignature, AsymmetricPaddingMode dwFlags) |
|
static unsafe ErrorCode | NCryptEncrypt (SafeNCryptKeyHandle hKey, ref byte pbInput, int cbInput, void *pPaddingInfo, ref byte pbOutput, int cbOutput, out int pcbResult, AsymmetricPaddingMode dwFlags) |
|
static unsafe ErrorCode | NCryptDecrypt (SafeNCryptKeyHandle hKey, ref byte pbInput, int cbInput, void *pPaddingInfo, ref byte pbOutput, int cbOutput, out int pcbResult, AsymmetricPaddingMode dwFlags) |
|
static ErrorCode | NCryptDeriveKey (SafeNCryptSecretHandle hSharedSecret, string pwszKDF, [In] ref NCryptBufferDesc pParameterList, [Out][MarshalAs(UnmanagedType.LPArray)] byte[] pbDerivedKey, int cbDerivedKey, out int pcbResult, SecretAgreementFlags dwFlags) |
|
static ErrorCode | NCryptSecretAgreement (SafeNCryptKeyHandle hPrivKey, SafeNCryptKeyHandle hPubKey, out SafeNCryptSecretHandle phSecret, int dwFlags) |
|
static unsafe ErrorCode | NCryptSignHash (SafeNCryptKeyHandle hKey, void *pPaddingInfo, ref byte pbHashValue, int cbHashValue, ref byte pbSignature, int cbSignature, out int pcbResult, AsymmetricPaddingMode dwFlags) |
|
static unsafe ErrorCode | NCryptVerifySignature (SafeNCryptKeyHandle hKey, void *pPaddingInfo, ref byte pbHashValue, int cbHashValue, ref byte pbSignature, int cbSignature, AsymmetricPaddingMode dwFlags) |
|
Definition at line 537 of file Interop.cs.