Package org.bouncycastle.cms

Examples of org.bouncycastle.cms.SignerInfoGeneratorBuilder.build()


    CMSAttributeTableGenerator attrGen = new DefaultSignedAttributeTableGenerator(at);
    SignerInfoGeneratorBuilder genBuild =
       new SignerInfoGeneratorBuilder(new BcDigestCalculatorProvider());
    genBuild.setSignedAttributeGenerator(attrGen);
    SignerInfoGenerator sifGen =
       genBuild.build(sigGen, new X509CertificateHolder(userCertificate.getEncoded()));

    gen.addSignerInfoGenerator(sifGen);

    /**
     * Popolo la "catena di certificazione" (certificate chain)
View Full Code Here


        digestProvider);
      X509CertificateHolder certHolder = new X509CertificateHolder(
        getRecipient().getEncoded());
      ContentSigner contentSigner = new JcaContentSignerBuilder(
        "SHA1withRSA").build(getRecipientKey());
      SignerInfoGenerator infoGen = infoGenBuilder.build(contentSigner,
        certHolder);
      generator.addSignerInfoGenerator(infoGen);

      CMSSignedData degenerateSd = generator
        .generate(new CMSAbsentContent());
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.