public static X509EncryptingCredentials GetEncryptingCredentials(this CertificateReferenceElement reference) { var cert = reference?.GetCertificate(); if (cert == null) { return(null); } return(new X509EncryptingCredentials(cert)); }
public static X509SigningCredentials GetSigningCredentials(this CertificateReferenceElement reference) { if (reference == null) { return(null); } var cert = reference.GetCertificate(); if (cert == null) { return(null); } return(new X509SigningCredentials(cert)); }