Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ GetPropertyAsString()

static unsafe string System.Security.Cryptography.CngKeyLite.GetPropertyAsString ( SafeNCryptHandle ncryptHandle,
string propertyName,
CngPropertyOptions options )
inlinestaticpackage

Definition at line 297 of file CngKeyLite.cs.

298 {
299 byte[] property = GetProperty(ncryptHandle, propertyName, options);
300 if (property == null)
301 {
302 return null;
303 }
304 if (property.Length == 0)
305 {
306 return string.Empty;
307 }
308 fixed (byte* ptr = &property[0])
309 {
310 return Marshal.PtrToStringUni((IntPtr)ptr);
311 }
312 }
static unsafe? string PtrToStringUni(IntPtr ptr)
Definition Marshal.cs:652
static unsafe byte[] GetProperty(SafeNCryptHandle ncryptHandle, string propertyName, CngPropertyOptions options)

References System.Security.Cryptography.CngKeyLite.GetProperty(), System.options, and System.Runtime.InteropServices.Marshal.PtrToStringUni().

Referenced by System.Security.Cryptography.ECDiffieHellmanImplementation.ECDiffieHellmanCng.AcceptImport(), System.Security.Cryptography.ECDsaImplementation.ECDsaCng.AcceptImport(), System.Security.Cryptography.ECDiffieHellmanImplementation.ECDiffieHellmanCng.DeriveSecretAgreementHandle(), System.Security.Cryptography.CngPkcs8.Pkcs8Response.GetAlgorithmGroup(), and System.Security.Cryptography.CngKeyLite.GetCurveName().