public SetCertificateVerifier ( CertificateVerifier certificateVerifier ) : void | ||
certificateVerifier | CertificateVerifier | the certificateVerifier to set |
Результат | void |
private SignatureExtension GetExtensionProfile(SignatureParameters parameters) { //jbonilla SignatureFormat signFormat = parameters.SignatureFormat; if (signFormat.Equals(SignatureFormat.XAdES_BES) || signFormat.Equals(SignatureFormat .XAdES_EPES)) { return(null); } else if (signFormat.Equals(SignatureFormat.XAdES_T)) { XAdESProfileT extensionT = new XAdESProfileT(); extensionT.SetTspSource(TspSource); return(extensionT); } else if (signFormat.Equals(SignatureFormat.XAdES_C)) { XAdESProfileC extensionC = new XAdESProfileC(); extensionC.SetTspSource(TspSource); extensionC.SetCertificateVerifier(Verifier); return(extensionC); } else if (signFormat.Equals(SignatureFormat.XAdES_X)) { XAdESProfileX extensionX = new XAdESProfileX(); extensionX.SetTspSource(TspSource); extensionX.SetCertificateVerifier(Verifier); return(extensionX); } else if (signFormat.Equals(SignatureFormat.XAdES_XL)) { XAdESProfileXL extensionXL = new XAdESProfileXL(); extensionXL.SetTspSource(TspSource); extensionXL.SetCertificateVerifier(Verifier); return(extensionXL); } // else // { // if (signFormat.Equals(SignatureFormat.XAdES_A)) // { // throw new NotImplementedException(); // //XAdESProfileA extensionA = new XAdESProfileA(); // //extensionA.SetTspSource(tspSource); // //extensionA.SetCertificateVerifier(certificateVerifier); // //return extensionA; // } // } // } // } // } //} throw new ArgumentException("Unsupported signature format " + parameters.SignatureFormat); }
private SignatureExtension GetExtensionProfile(SignatureParameters parameters) { //jbonilla SignatureFormat signFormat = parameters.SignatureFormat; if (signFormat.Equals(SignatureFormat.XAdES_BES) || signFormat.Equals(SignatureFormat .XAdES_EPES)) { return null; } else if (signFormat.Equals(SignatureFormat.XAdES_T)) { XAdESProfileT extensionT = new XAdESProfileT(); extensionT.SetTspSource(TspSource); return extensionT; } else if (signFormat.Equals(SignatureFormat.XAdES_C)) { XAdESProfileC extensionC = new XAdESProfileC(); extensionC.SetTspSource(TspSource); extensionC.SetCertificateVerifier(Verifier); return extensionC; } else if (signFormat.Equals(SignatureFormat.XAdES_X)) { XAdESProfileX extensionX = new XAdESProfileX(); extensionX.SetTspSource(TspSource); extensionX.SetCertificateVerifier(Verifier); return extensionX; } else if (signFormat.Equals(SignatureFormat.XAdES_XL)) { XAdESProfileXL extensionXL = new XAdESProfileXL(); extensionXL.SetTspSource(TspSource); extensionXL.SetCertificateVerifier(Verifier); return extensionXL; } // else // { // if (signFormat.Equals(SignatureFormat.XAdES_A)) // { // throw new NotImplementedException(); // //XAdESProfileA extensionA = new XAdESProfileA(); // //extensionA.SetTspSource(tspSource); // //extensionA.SetCertificateVerifier(certificateVerifier); // //return extensionA; // } // } // } // } // } //} throw new ArgumentException("Unsupported signature format " + parameters.SignatureFormat); }