Terraria
v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches
◆
ChainElements
unsafe
X509ChainElement
[] Internal.Cryptography.Pal.ChainPal.ChainElements
get
Implements
Internal.Cryptography.Pal.IChainPal
.
Definition at line
60
of file
ChainPal.cs
.
61
{
62
get
63
{
64
CERT_CHAIN_CONTEXT
* ptr = (
CERT_CHAIN_CONTEXT
*)(
void
*)
_chain
.
DangerousGetHandle
();
65
CERT_SIMPLE_CHAIN
* rgpChain = *ptr->
rgpChain
;
66
X509ChainElement
[]
array
=
new
X509ChainElement
[rgpChain->
cElement
];
67
for
(
int
i = 0;
i
< rgpChain->
cElement
;
i
++)
68
{
69
CERT_CHAIN_ELEMENT
* ptr2 = rgpChain->
rgpElement
[
i
];
70
X509Certificate2
certificate =
new
X509Certificate2
((
IntPtr
)ptr2->
pCertContext
);
71
X509ChainStatus
[] chainStatusInformation =
GetChainStatusInformation
(ptr2->
TrustStatus
.
dwErrorStatus
);
72
string
information =
Marshal
.
PtrToStringUni
(ptr2->
pwszExtendedErrorInfo
);
73
X509ChainElement
x509ChainElement =
new
X509ChainElement
(certificate, chainStatusInformation, information);
74
array
[
i
] = x509ChainElement;
75
}
76
GC
.
KeepAlive
(
this
);
77
return
array
;
78
}
79
}
Internal.Cryptography.Pal.ChainPal._chain
SafeX509ChainHandle _chain
Definition
ChainPal.cs:31
Internal.Cryptography.Pal.ChainPal.GetChainStatusInformation
static X509ChainStatus[] GetChainStatusInformation(CertTrustErrorStatus dwStatus)
Definition
ChainPal.cs:219
System.GC.KeepAlive
static void KeepAlive(object? obj)
Definition
GC.cs:180
System.GC
Definition
GC.cs:8
System.Runtime.InteropServices.Marshal.PtrToStringUni
static unsafe? string PtrToStringUni(IntPtr ptr)
Definition
Marshal.cs:652
System.Runtime.InteropServices.Marshal
Definition
Marshal.cs:14
System.Runtime.InteropServices.SafeHandle.DangerousGetHandle
IntPtr DangerousGetHandle()
Definition
SafeHandle.cs:47
System.Security.Cryptography.X509Certificates.X509Certificate2
Definition
X509Certificate2.cs:13
System.Security.Cryptography.X509Certificates.X509ChainElement
Definition
X509ChainElement.cs:4
System.Text.RegularExpressions.ExceptionArgument.i
@ i
System.ExceptionArgument.array
@ array
Internal.Cryptography.Pal.Native.CERT_CHAIN_CONTEXT.rgpChain
unsafe CERT_SIMPLE_CHAIN ** rgpChain
Definition
CERT_CHAIN_CONTEXT.cs:13
Internal.Cryptography.Pal.Native.CERT_CHAIN_CONTEXT
Definition
CERT_CHAIN_CONTEXT.cs:6
Internal.Cryptography.Pal.Native.CERT_CHAIN_ELEMENT.pCertContext
unsafe CERT_CONTEXT * pCertContext
Definition
CERT_CHAIN_ELEMENT.cs:9
Internal.Cryptography.Pal.Native.CERT_CHAIN_ELEMENT.TrustStatus
CERT_TRUST_STATUS TrustStatus
Definition
CERT_CHAIN_ELEMENT.cs:11
Internal.Cryptography.Pal.Native.CERT_CHAIN_ELEMENT.pwszExtendedErrorInfo
IntPtr pwszExtendedErrorInfo
Definition
CERT_CHAIN_ELEMENT.cs:19
Internal.Cryptography.Pal.Native.CERT_CHAIN_ELEMENT
Definition
CERT_CHAIN_ELEMENT.cs:6
Internal.Cryptography.Pal.Native.CERT_SIMPLE_CHAIN.cElement
int cElement
Definition
CERT_SIMPLE_CHAIN.cs:11
Internal.Cryptography.Pal.Native.CERT_SIMPLE_CHAIN.rgpElement
unsafe CERT_CHAIN_ELEMENT ** rgpElement
Definition
CERT_SIMPLE_CHAIN.cs:13
Internal.Cryptography.Pal.Native.CERT_SIMPLE_CHAIN
Definition
CERT_SIMPLE_CHAIN.cs:6
Internal.Cryptography.Pal.Native.CERT_TRUST_STATUS.dwErrorStatus
CertTrustErrorStatus dwErrorStatus
Definition
CERT_TRUST_STATUS.cs:5
System.IntPtr
Definition
IntPtr.cs:14
System.Security.Cryptography.X509Certificates.X509ChainStatus
Definition
X509ChainStatus.cs:6
Internal
Cryptography
Pal
ChainPal
Generated by
1.10.0