throws IOException {
// make the TBSCertificate for Certificate
int version = 2; //v3
BigInteger serialNumber = BigInteger.valueOf(555L);
AlgorithmIdentifier signature = new AlgorithmIdentifier("1.2.3.44.555");
Name issuer = new Name("O=Certificate Issuer");
Validity validity = new Validity(new Date(100000000),
new Date(200000000));
SubjectPublicKeyInfo subjectPublicKeyInfo =
new SubjectPublicKeyInfo(
new AlgorithmIdentifier("1.2.840.113549.1.1.2"),