id-ce-basicConstraints OBJECT IDENTIFIER ::= { id-ce 19 } BasicConstraints ::= SEQUENCE { cA BOOLEAN DEFAULT FALSE, pathLenConstraint INTEGER (0..MAX) OPTIONAL }
613614615616617618619620621622623
buf.append(" critical(" + ext.isCritical() + ") "); try { if (oid.equals(X509Extensions.BasicConstraints)) { buf.append(new BasicConstraints((ASN1Sequence)dIn.readObject()) + nl); } else if (oid.equals(X509Extensions.KeyUsage)) { buf.append(new KeyUsage((DERBitString)dIn.readObject()) + nl); }
627628629630631632633634635636637
435436437438439440441442443444445
if (version == 1 || version == 2) { // generate extensions extensions = new Extensions(Collections .singletonList(new Extension("2.5.29.19", false, new BasicConstraints(isCA, Integer.MAX_VALUE)))); } // generate the TBSCertificate to put it into the X.509 cert TBSCertificate tbsCertificate = new TBSCertificate( // version version,