70 references to CAPISafe
System.Security (70)
system\security\cryptography\cryptoapi.cs (13)
2326
bool result =
CAPISafe
.CryptDecodeObject(X509_ASN_ENCODING | PKCS_7_ASN_ENCODING,
2337
result =
CAPISafe
.CryptDecodeObject(X509_ASN_ENCODING | PKCS_7_ASN_ENCODING,
2367
if (!
CAPISafe
.CryptDecodeObject(X509_ASN_ENCODING | PKCS_7_ASN_ENCODING,
2377
if (!
CAPISafe
.CryptDecodeObject(X509_ASN_ENCODING | PKCS_7_ASN_ENCODING,
2404
if (!
CAPISafe
.CryptEncodeObject(X509_ASN_ENCODING | PKCS_7_ASN_ENCODING,
2412
if (!
CAPISafe
.CryptEncodeObject(X509_ASN_ENCODING | PKCS_7_ASN_ENCODING,
2438
if (!
CAPISafe
.CryptEncodeObject(X509_ASN_ENCODING | PKCS_7_ASN_ENCODING,
2446
if (!
CAPISafe
.CryptEncodeObject(X509_ASN_ENCODING | PKCS_7_ASN_ENCODING,
2471
SafeLocalAllocHandle safeLocalAllocHandle =
CAPISafe
.LocalAlloc(uFlags, sizetdwBytes);
2554
IntPtr pv =
CAPISafe
.CryptFindOIDInfo(dwKeyType,
2576
IntPtr pv =
CAPISafe
.CryptFindOIDInfo(dwKeyType,
2677
return
CAPISafe
.CertDuplicateCertificateContext(pCertContext);
2699
CAPISafe
.CertFreeCertificateContext(handle);
system\security\cryptography\dataprotection.cs (6)
106
CAPI.
CAPISafe
.ZeroMemory(blob.pbData, blob.cbData);
107
CAPI.
CAPISafe
.LocalFree(blob.pbData);
169
CAPI.
CAPISafe
.ZeroMemory(userData.pbData, userData.cbData);
170
CAPI.
CAPISafe
.LocalFree(userData.pbData);
202
throw new CryptographicException(CAPI.
CAPISafe
.LsaNtStatusToWinError(status));
233
throw new CryptographicException(CAPI.
CAPISafe
.LsaNtStatusToWinError(status));
system\security\cryptography\pkcs\envelopedpkcs7.cs (7)
478
if (!CAPI.
CAPISafe
.CryptMsgUpdate(m_safeCryptMsgHandle, encodedContent, (uint) encodedContent.Length, true))
497
safeCryptMsgHandle = CAPI.
CAPISafe
.CryptMsgOpenToDecode(CAPI.X509_ASN_ENCODING | CAPI.PKCS_7_ASN_ENCODING,
507
if (!CAPI.
CAPISafe
.CryptMsgUpdate(safeCryptMsgHandle, encodedMessage, (uint) encodedMessage.Length, true))
751
if (!CAPI.
CAPISafe
.CertGetCertificateContextProperty(X509Utils.GetCertContext(certificate),
759
if (!CAPI.
CAPISafe
.CertGetCertificateContextProperty(X509Utils.GetCertContext(certificate),
937
if (!CAPI.
CAPISafe
.CertGetCertificateContextProperty(X509Utils.GetCertContext(certificate),
944
if (!CAPI.
CAPISafe
.CertGetCertificateContextProperty(X509Utils.GetCertContext(certificate),
system\security\cryptography\pkcs\pkcsmisc.cs (3)
323
int keyLength = (int) CAPI.
CAPISafe
.CertGetPublicKeyLength(CAPI.X509_ASN_ENCODING | CAPI.PKCS_7_ASN_ENCODING, pKeyInfo.DangerousGetHandle());
537
SafeCryptMsgHandle safeCryptMsgHandle = CAPI.
CAPISafe
.CryptMsgOpenToDecode(
547
if (!CAPI.
CAPISafe
.CryptMsgUpdate(safeCryptMsgHandle, encodedMessage, (uint) encodedMessage.Length, true))
system\security\cryptography\pkcs\pkcsutils.cs (24)
42
using(SafeLibraryHandle hModule = CAPI.
CAPISafe
.LoadLibrary("Crypt32.dll")) {
44
IntPtr pFunc = CAPI.
CAPISafe
.GetProcAddress(hModule, "CryptMsgVerifyCountersignatureEncodedEx");
80
while (CAPI.
CAPISafe
.CryptGetProvParam(safeCryptProvHandle, CAPI.PP_ENUMALGS_EX, pPeex.DangerousGetHandle(), new IntPtr(&cbPeex), enumFlag)) {
97
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
111
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
126
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
135
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
160
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
170
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
190
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
201
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
218
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
231
SafeCertContextHandle safeCertContextHandle = CAPI.
CAPISafe
.CertCreateCertificateContext(CAPI.X509_ASN_ENCODING | CAPI.PKCS_7_ASN_ENCODING,
283
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCrytpMsgHandle,
293
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCrytpMsgHandle,
303
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCrytpMsgHandle,
337
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
349
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
365
uint cbSize = CAPI.
CAPISafe
.CertNameToStrW(CAPI.X509_ASN_ENCODING | CAPI.PKCS_7_ASN_ENCODING,
374
cbSize = CAPI.
CAPISafe
.CertNameToStrW(CAPI.X509_ASN_ENCODING | CAPI.PKCS_7_ASN_ENCODING,
801
if (!CAPI.
CAPISafe
.CertGetCertificateContextProperty(safeCertContextHandle,
810
if (!CAPI.
CAPISafe
.CertGetCertificateContextProperty(safeCertContextHandle,
837
if (CAPI.
CAPISafe
.CertGetCertificateContextProperty(
886
if (CAPI.
CAPISafe
.CryptAcquireCertificatePrivateKey(safeCertContextHandle,
system\security\cryptography\pkcs\recipientinfo.cs (2)
397
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
406
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
system\security\cryptography\pkcs\signedpkcs7.cs (5)
224
if (!CAPI.
CAPISafe
.CryptMsgGetParam(m_safeCryptMsgHandle,
340
if (!CAPI.
CAPISafe
.CryptMsgUpdate(safeCryptMsgHandle, this.ContentInfo.pContent, (uint) this.ContentInfo.Content.Length, true))
412
SafeCryptMsgHandle safeCryptMsgHandle = CAPI.
CAPISafe
.CryptMsgOpenToDecode(
423
if (!CAPI.
CAPISafe
.CryptMsgUpdate(safeCryptMsgHandle, encodedMessage, (uint) encodedMessage.Length, true))
435
if (!CAPI.
CAPISafe
.CryptMsgUpdate(safeCryptMsgHandle, content, (uint) content.Length, true))
system\security\cryptography\pkcs\signerinfo.cs (6)
410
if (!CAPI.
CAPISafe
.CertGetCertificateContextProperty(X509Utils.GetCertContext(certificate),
418
if (!CAPI.
CAPISafe
.CertGetCertificateContextProperty(X509Utils.GetCertContext(certificate),
481
if (!CAPI.
CAPISafe
.CryptMsgVerifyCountersignatureEncoded(IntPtr.Zero,
731
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
741
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
750
if (!CAPI.
CAPISafe
.CryptMsgGetParam(safeCryptMsgHandle,
system\security\cryptography\x509\x509utils.cs (4)
146
if (!CAPI.
CAPISafe
.CertGetCertificateContextProperty(safeCertContext,
158
if (!CAPI.
CAPISafe
.CertGetCertificateContextProperty(safeCertContext,
340
if (!CAPI.
CAPISafe
.CertGetCertificateChain(hChainEngine,
396
if (CAPI.
CAPISafe
.CertVerifyCertificateChainPolicy(pszPolicy, pChainContext, ref PolicyPara, ref PolicyStatus)) {