Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  package org.bouncycastle.asn1.cms;
  
  
RFC 5652: IssuerAndSerialNumber object.

 IssuerAndSerialNumber ::= SEQUENCE {
     issuer Name,
     serialNumber CertificateSerialNumber
 }

 CertificateSerialNumber ::= INTEGER  -- See RFC 5280
 
 
 public class IssuerAndSerialNumber
     extends ASN1Object
 {
     private X500Name    name;
     private ASN1Integer  serialNumber;

    
Return an IssuerAndSerialNumber object from the given object.

Accepted inputs:

  • null → null
  • IssuerAndSerialNumber object
  • ASN1Sequence input formats with IssuerAndSerialNumber structure inside

Parameters:
obj the object we want converted.
Throws:
java.lang.IllegalArgumentException if the object cannot be converted.
 
     public static IssuerAndSerialNumber getInstance(
         Object  obj)
     {
         if (obj instanceof IssuerAndSerialNumber)
         {
             return (IssuerAndSerialNumber)obj;
         }
         else if (obj != null)
         {
             return new IssuerAndSerialNumber(ASN1Sequence.getInstance(obj));
         }
 
         return null;
     }

    

Deprecated:
use getInstance() method.
 
     public IssuerAndSerialNumber(
         ASN1Sequence    seq)
     {
         this. = X500Name.getInstance(seq.getObjectAt(0));
         this. = (ASN1Integer)seq.getObjectAt(1);
     }
 
     public IssuerAndSerialNumber(
         Certificate certificate)
     {
         this. = certificate.getIssuer();
         this. = certificate.getSerialNumber();
     }

    

Deprecated:
use constructor taking Certificate
 
     public IssuerAndSerialNumber(
         X509CertificateStructure certificate)
     {
         this. = certificate.getIssuer();
         this. = certificate.getSerialNumber();
     }
 
     public IssuerAndSerialNumber(
         X500Name name,
         BigInteger  serialNumber)
     {
         this. = name;
         this. = new ASN1Integer(serialNumber);
     }

    

Deprecated:
use X500Name constructor
 
    public IssuerAndSerialNumber(
        X509Name    name,
        BigInteger  serialNumber)
    {
        this. = X500Name.getInstance(name);
        this. = new ASN1Integer(serialNumber);
    }

    

Deprecated:
use X500Name constructor
    public IssuerAndSerialNumber(
        X509Name    name,
        ASN1Integer  serialNumber)
    {
        this. = X500Name.getInstance(name);
        this. = serialNumber;
    }
    public X500Name getName()
    {
        return ;
    }
    public ASN1Integer getSerialNumber()
    {
        return ;
    }
    {
        ASN1EncodableVector    v = new ASN1EncodableVector();
        v.add();
        v.add();
        return new DERSequence(v);
    }
New to GrepCode? Check out our FAQ X