1 // Licensed to the .NET Foundation under one or more agreements.
2 // The .NET Foundation licenses this file to you under the MIT license.
3 // See the LICENSE file in the project root for more information.
4 
5 using System;
6 using System.Runtime.InteropServices;
7 
8 using Microsoft.Win32.SafeHandles;
9 
10 internal static partial class Interop
11 {
12     internal static partial class Crypt32
13     {
14         [DllImport(Interop.Libraries.Crypt32, CharSet = CharSet.Unicode, SetLastError = true)]
15         [return: MarshalAs(UnmanagedType.Bool)]
CertFreeCertificateContext(IntPtr pCertContext)16         internal static extern bool CertFreeCertificateContext(IntPtr pCertContext);
17 
18         [DllImport(Interop.Libraries.Crypt32, CharSet = CharSet.Unicode, SetLastError = true)]
19         [return: MarshalAs(UnmanagedType.Bool)]
CertVerifyCertificateChainPolicy( IntPtr pszPolicyOID, SafeX509ChainHandle pChainContext, [In] ref CERT_CHAIN_POLICY_PARA pPolicyPara, [In, Out] ref CERT_CHAIN_POLICY_STATUS pPolicyStatus)20         internal static extern bool CertVerifyCertificateChainPolicy(
21             IntPtr pszPolicyOID,
22             SafeX509ChainHandle pChainContext,
23             [In] ref CERT_CHAIN_POLICY_PARA pPolicyPara,
24             [In, Out] ref CERT_CHAIN_POLICY_STATUS pPolicyStatus);
25     }
26 }
27