Examples of TBSCertList


Examples of org.apache.harmony.security.x509.TBSCertList

    protected void setUp() throws java.lang.Exception {
        try {
            Name issuer = new Name(issuerName);

            tbscertlist =
                new TBSCertList(2, signature, issuer, thisUpdate,
                    nextUpdate, revokedCertificates, crlExtensions);
           
            certificateList =
                new CertificateList(tbscertlist, signature, signatureValue);
View Full Code Here

Examples of org.apache.harmony.security.x509.TBSCertList

    public void testCertificateList() {
        try {
            AlgorithmIdentifier signature =
                new AlgorithmIdentifier(algOID, algParams);
            Name issuer = new Name(issuerName);
            TBSCertList tbscl =
                new TBSCertList(signature, issuer, thisUpdate);
            CertificateList cl =
                new CertificateList(tbscl, signature, new byte[] {0});
           
            byte[] encoding = CertificateList.ASN1.encode(cl);
            CertificateList.ASN1.decode(encoding);

            tbscl = new TBSCertList(2, signature, issuer, thisUpdate,
                    nextUpdate, revokedCertificates, crlExtensions);
           
            cl = new CertificateList(tbscl, signature, new byte[] {0});

            encoding = CertificateList.ASN1.encode(cl);
View Full Code Here

Examples of org.apache.harmony.security.x509.TBSCertList

    protected void setUp() throws java.lang.Exception {
        try {
            Name issuer = new Name(issuerName);

            tbscertlist =
                new TBSCertList(2, signature, issuer, thisUpdate,
                    nextUpdate, revokedCertificates, crlExtensions);
           
            certificateList =
                new CertificateList(tbscertlist, signature, signatureValue);
View Full Code Here

Examples of org.apache.harmony.security.x509.TBSCertList

    public void testCertificateList() {
        try {
            AlgorithmIdentifier signature =
                new AlgorithmIdentifier(algOID, algParams);
            Name issuer = new Name(issuerName);
            TBSCertList tbscl =
                new TBSCertList(signature, issuer, thisUpdate);
            CertificateList cl =
                new CertificateList(tbscl, signature, new byte[] {0});
           
            byte[] encoding = CertificateList.ASN1.encode(cl);
            CertificateList.ASN1.decode(encoding);

            tbscl = new TBSCertList(2, signature, issuer, thisUpdate,
                    nextUpdate, revokedCertificates, crlExtensions);
           
            cl = new CertificateList(tbscl, signature, new byte[] {0});

            encoding = CertificateList.ASN1.encode(cl);
View Full Code Here

Examples of org.bouncycastle.asn1.x509.TBSCertList

        if (extensions != null)
        {
            tbsGen.setExtensions(new X509Extensions(extOrdering, extensions));
        }

        TBSCertList tbsCrl = tbsGen.generateTBSCertList();

        try
        {
            ByteArrayOutputStream   bOut = new ByteArrayOutputStream();
            DEROutputStream         dOut = new DEROutputStream(bOut);
View Full Code Here

Examples of org.bouncycastle.asn1.x509.TBSCertList

        X509CRL crl)
        throws CRLException
    {
        try
        {
            TBSCertList tbsCertList = TBSCertList.getInstance(
                ASN1Primitive.fromByteArray(crl.getTBSCertList()));

            return new X509Principal(X509Name.getInstance(tbsCertList.getIssuer()));
        }
        catch (IOException e)
        {
            throw new CRLException(e.toString());
        }
View Full Code Here

Examples of org.bouncycastle.asn1.x509.TBSCertList

    public X509CRL generate(
        PrivateKey      key,
        SecureRandom    random)
        throws CRLException, IllegalStateException, NoSuchAlgorithmException, SignatureException, InvalidKeyException
    {
        TBSCertList tbsCrl = generateCertList();
        byte[] signature;

        try
        {
            signature = X509Util.calculateSignature(sigOID, signatureAlgorithm, key, random, tbsCrl);
View Full Code Here

Examples of org.bouncycastle.asn1.x509.TBSCertList

        PrivateKey      key,
        String          provider,
        SecureRandom    random)
        throws CRLException, IllegalStateException, NoSuchProviderException, NoSuchAlgorithmException, SignatureException, InvalidKeyException
    {
        TBSCertList tbsCrl = generateCertList();
        byte[] signature;

        try
        {
            signature = X509Util.calculateSignature(sigOID, signatureAlgorithm, provider, key, random, tbsCrl);
View Full Code Here

Examples of org.bouncycastle.asn1.x509.TBSCertList

    public X509CRL generate(
        PrivateKey      key,
        SecureRandom    random)
        throws CRLException, IllegalStateException, NoSuchAlgorithmException, SignatureException, InvalidKeyException
    {
        TBSCertList tbsCrl = generateCertList();
        byte[] signature;

        try
        {
            signature = X509Util.calculateSignature(sigOID, signatureAlgorithm, key, random, tbsCrl);
View Full Code Here

Examples of org.bouncycastle.asn1.x509.TBSCertList

        PrivateKey      key,
        String          provider,
        SecureRandom    random)
        throws CRLException, IllegalStateException, NoSuchProviderException, NoSuchAlgorithmException, SignatureException, InvalidKeyException
    {
        TBSCertList tbsCrl = generateCertList();
        byte[] signature;

        try
        {
            signature = X509Util.calculateSignature(sigOID, signatureAlgorithm, provider, key, random, tbsCrl);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.