Inhaltsverzeichnis

WvdS.System.Security.Cryptography.X509Certificates Namespace

Contains extension methods for X.509 certificate operations with PQ support.


Classes

Class Description
CertificateRequestExtensions Extensions for CertificateRequest
X509Certificate2Extensions Extensions for X509Certificate2
X509ChainExtensions Extensions for X509Chain
X509Certificate2ExportExtensions PFX export/import with PQ keys
X509StoreExtensions Store operations with PQ key persistence
CertificateRevocationListExtensions CRL creation with PQ signatures
RevocationExtensions Revocation checking (CRL/OCSP)
TrustStoreExtensions & PqTrustStore Custom trust store management

Extended Types

These classes extend the following .NET types:

.NET Type Extension Class
System.Security.Cryptography.X509Certificates.CertificateRequest1) CertificateRequestExtensions
System.Security.Cryptography.X509Certificates.X509Certificate22) X509Certificate2Extensions, RevocationExtensions
System.Security.Cryptography.X509Certificates.X509Chain3) X509ChainExtensions
System.Security.Cryptography.X509Certificates.X509Store4) X509StoreExtensions
System.Security.Cryptography.X509Certificates.CertificateRevocationListBuilder5) CertificateRevocationListExtensions

Example

using System.Security.Cryptography;
using System.Security.Cryptography.X509Certificates;
using WvdS.System.Security.Cryptography;
using WvdS.System.Security.Cryptography.X509Certificates;
 
CryptoConfig.DefaultMode = CryptoMode.Hybrid;
 
using var rsa = RSA.Create(2048);
var request = new CertificateRequest("CN=Test", rsa,
    HashAlgorithmName.SHA256, RSASignaturePadding.Pkcs1);
 
// Extension method is used automatically
var cert = request.CreateSelfSigned(
    DateTimeOffset.Now,
    DateTimeOffset.Now.AddYears(1));
 
// Check PQ status
bool hasPq = cert.HasPqSignature();  // true

See Also


Wolfgang van der Stille @ EMSR DATA d.o.o. - Post-Quantum Cryptography Professional