예제 #1
0
        /// <summary>Generates an OCSP request using BouncyCastle.</summary>
        /// <param name="issuerCert">certificate of the issues</param>
        /// <param name="serialNumber">serial number</param>
        /// <returns>an OCSP request</returns>
        private static OcspReq GenerateOCSPRequest(X509Certificate issuerCert, BigInteger serialNumber)
        {
            //Add provider BC
            // Generate the id for the certificate we are looking for
            CertificateID id = SignUtils.GenerateCertificateId(issuerCert, serialNumber, Org.BouncyCastle.Ocsp.CertificateID.HashSha1
                                                               );

            // basic request generation with nonce
            return(SignUtils.GenerateOcspRequestWithNonce(id));
        }