Skip to content
This repository was archived by the owner on Jan 23, 2023. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

using System;
using System.Runtime.InteropServices;
using System.Security.Cryptography.X509Certificates;

using Microsoft.Win32.SafeHandles;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@

using System;
using System.Runtime.InteropServices;
using System.Security.Cryptography.X509Certificates;

using Microsoft.Win32.SafeHandles;

internal static partial class Interop
{
Expand All @@ -16,12 +13,12 @@ internal static partial class AuthType
internal const uint AUTHTYPE_CLIENT = 1;
internal const uint AUTHTYPE_SERVER = 2;
}

internal static partial class CertChainPolicyIgnoreFlags
{
internal const uint CERT_CHAIN_POLICY_IGNORE_NOT_TIME_VALID_FLAG = 0x00000001;
internal const uint CERT_CHAIN_POLICY_IGNORE_CTL_NOT_TIME_VALID_FLAG = 0x00000002;
internal const uint CERT_CHAIN_POLICY_IGNORE_NOT_TIME_NESTED_FLAG = 0x00000004;
internal const uint CERT_CHAIN_POLICY_IGNORE_CTL_NOT_TIME_VALID_FLAG = 0x00000002;
internal const uint CERT_CHAIN_POLICY_IGNORE_NOT_TIME_NESTED_FLAG = 0x00000004;
internal const uint CERT_CHAIN_POLICY_IGNORE_INVALID_BASIC_CONSTRAINTS_FLAG = 0x00000008;
internal const uint CERT_CHAIN_POLICY_ALLOW_UNKNOWN_CA_FLAG = 0x00000010;
internal const uint CERT_CHAIN_POLICY_IGNORE_WRONG_USAGE_FLAG = 0x00000020;
Expand All @@ -34,8 +31,8 @@ internal static partial class CertChainPolicyIgnoreFlags

internal const uint CERT_CHAIN_POLICY_IGNORE_ALL =
CERT_CHAIN_POLICY_IGNORE_NOT_TIME_VALID_FLAG |
CERT_CHAIN_POLICY_IGNORE_CTL_NOT_TIME_VALID_FLAG |
CERT_CHAIN_POLICY_IGNORE_NOT_TIME_NESTED_FLAG |
CERT_CHAIN_POLICY_IGNORE_CTL_NOT_TIME_VALID_FLAG |
CERT_CHAIN_POLICY_IGNORE_NOT_TIME_NESTED_FLAG |
CERT_CHAIN_POLICY_IGNORE_INVALID_BASIC_CONSTRAINTS_FLAG |
CERT_CHAIN_POLICY_ALLOW_UNKNOWN_CA_FLAG |
CERT_CHAIN_POLICY_IGNORE_WRONG_USAGE_FLAG |
Expand All @@ -58,7 +55,7 @@ internal static partial class CertChainPolicy
internal const int CERT_CHAIN_POLICY_MICROSOFT_ROOT = 7;
internal const int CERT_CHAIN_POLICY_EV = 8;
}

internal static partial class CertChainPolicyErrors
{
// Base Policy errors (CERT_CHAIN_POLICY_BASE).
Expand All @@ -74,7 +71,7 @@ internal static partial class CertChainPolicyErrors

// Basic Constraints Policy errors (CERT_CHAIN_POLICY_BASIC_CONSTRAINTS).
internal const uint TRUST_E_BASIC_CONSTRAINTS = 0x80096019;

// Authenticode Policy errors (CERT_CHAIN_POLICY_AUTHENTICODE and CERT_CHAIN_POLICY_AUTHENTICODE_TS).
internal const uint CERT_E_CRITICAL = 0x800B0105;
internal const uint CERT_E_VALIDITYPERIODNESTING = 0x800B0102;
Expand All @@ -83,12 +80,12 @@ internal static partial class CertChainPolicyErrors
internal const uint CERT_E_PURPOSE = 0x800B0106;
internal const uint CERT_E_REVOKED = 0x800B010C;
internal const uint CERT_E_REVOCATION_FAILURE = 0x800B010E;

// SSL Policy errors (CERT_CHAIN_POLICY_SSL).
internal const uint CERT_E_CN_NO_MATCH = 0x800B010F;
internal const uint CERT_E_ROLE = 0x800B0103;
}

[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
internal struct CERT_CONTEXT
{
Expand All @@ -115,7 +112,7 @@ internal unsafe struct CERT_CHAIN_POLICY_PARA
public uint dwFlags;
public SSL_EXTRA_CERT_CHAIN_POLICY_PARA* pvExtraPolicyPara;
}

[StructLayout(LayoutKind.Sequential, CharSet = CharSet.Unicode)]
internal unsafe struct CERT_CHAIN_POLICY_STATUS
{
Expand Down
1 change: 1 addition & 0 deletions src/Common/src/Interop/Windows/Interop.Libraries.cs
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ internal static class Libraries
internal const string Psapi_Obsolete = "api-ms-win-core-psapi-obsolete-l1-1-0.dll";
internal const string Registry_L1 = "api-ms-win-core-registry-l1-1-0.dll";
internal const string Registry_L2 = "api-ms-win-core-registry-l2-1-0.dll";
internal const string Secur32 = "Secur32.dll";
internal const string SecurityBase = "api-ms-win-security-base-l1-1-0.dll";
internal const string SecurityCpwl = "api-ms-win-security-cpwl-l1-1-0.dll";
internal const string SecurityLsa = "api-ms-win-security-lsalookup-l2-1-0.dll";
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
// Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.

using System;

internal static partial class Interop
{
internal static partial class SChannel
Expand Down
Loading