Java 类org.bouncycastle.asn1.dvcs.TargetEtcChain 实例源码

项目:ipack    文件:VPKCRequestData.java   
VPKCRequestData(Data data)
    throws DVCSConstructionException
{
    super(data);

    TargetEtcChain[] certs = data.getCerts();

    if (certs == null)
    {
        throw new DVCSConstructionException("DVCSRequest.data.certs should be specified for VPKC service");
    }

    chains = new ArrayList(certs.length);

    for (int i = 0; i != certs.length; i++)
    {
        chains.add(new TargetChain(certs[i]));
    }
}
项目:gwt-crypto    文件:VPKCRequestData.java   
VPKCRequestData(Data data)
    throws DVCSConstructionException
{
    super(data);

    TargetEtcChain[] certs = data.getCerts();

    if (certs == null)
    {
        throw new DVCSConstructionException("DVCSRequest.data.certs should be specified for VPKC service");
    }

    chains = new ArrayList(certs.length);

    for (int i = 0; i != certs.length; i++)
    {
        chains.add(new TargetChain(certs[i]));
    }
}
项目:Aki-SSL    文件:VPKCRequestData.java   
VPKCRequestData(Data data)
    throws DVCSConstructionException
{
    super(data);

    TargetEtcChain[] certs = data.getCerts();

    if (certs == null)
    {
        throw new DVCSConstructionException("DVCSRequest.data.certs should be specified for VPKC service");
    }

    chains = new ArrayList(certs.length);

    for (int i = 0; i != certs.length; i++)
    {
        chains.add(new TargetChain(certs[i]));
    }
}
项目:irma_future_id    文件:VPKCRequestData.java   
VPKCRequestData(Data data)
    throws DVCSConstructionException
{
    super(data);

    TargetEtcChain[] certs = data.getCerts();

    if (certs == null)
    {
        throw new DVCSConstructionException("DVCSRequest.data.certs should be specified for VPKC service");
    }

    chains = new ArrayList(certs.length);

    for (int i = 0; i != certs.length; i++)
    {
        chains.add(new TargetChain(certs[i]));
    }
}
项目:irma_future_id    文件:AllTests.java   
public void testVPKCRequest()
    throws Exception
{
    SignedDVCSMessageGenerator gen = getSignedDVCSMessageGenerator();

    VPKCRequestBuilder reqBuilder = new VPKCRequestBuilder();

    reqBuilder.addTargetChain(new JcaX509CertificateHolder(signCert));

    CMSSignedData reqMsg = gen.build(reqBuilder.build());

    assertTrue(reqMsg.verifySignatures(new SignerInformationVerifierProvider()
    {
        public SignerInformationVerifier get(SignerId sid)
            throws OperatorCreationException
        {
            return new JcaSimpleSignerInfoVerifierBuilder().setProvider(BC).build(signCert);
        }
    }));

    DVCSRequest request = new DVCSRequest(reqMsg);

    VPKCRequestData reqData = (VPKCRequestData)request.getData();

    assertEquals(new TargetEtcChain(new CertEtcToken(CertEtcToken.TAG_CERTIFICATE, new JcaX509CertificateHolder(signCert).toASN1Structure())), ((TargetChain)reqData.getCerts().get(0)).toASN1Structure());
}
项目:bc-java    文件:VPKCRequestData.java   
VPKCRequestData(Data data)
    throws DVCSConstructionException
{
    super(data);

    TargetEtcChain[] certs = data.getCerts();

    if (certs == null)
    {
        throw new DVCSConstructionException("DVCSRequest.data.certs should be specified for VPKC service");
    }

    chains = new ArrayList(certs.length);

    for (int i = 0; i != certs.length; i++)
    {
        chains.add(new TargetChain(certs[i]));
    }
}
项目:bc-java    文件:AllTests.java   
public void testVPKCRequest()
    throws Exception
{
    SignedDVCSMessageGenerator gen = getSignedDVCSMessageGenerator();

    VPKCRequestBuilder reqBuilder = new VPKCRequestBuilder();

    reqBuilder.addTargetChain(new JcaX509CertificateHolder(signCert));

    CMSSignedData reqMsg = gen.build(reqBuilder.build());

    assertTrue(reqMsg.verifySignatures(new SignerInformationVerifierProvider()
    {
        public SignerInformationVerifier get(SignerId sid)
            throws OperatorCreationException
        {
            return new JcaSimpleSignerInfoVerifierBuilder().setProvider(BC).build(signCert);
        }
    }));

    DVCSRequest request = new DVCSRequest(reqMsg);

    VPKCRequestData reqData = (VPKCRequestData)request.getData();

    assertEquals(new TargetEtcChain(new CertEtcToken(CertEtcToken.TAG_CERTIFICATE, new JcaX509CertificateHolder(signCert).toASN1Structure())), ((TargetChain)reqData.getCerts().get(0)).toASN1Structure());
}
项目:ipack    文件:VPKCRequestBuilder.java   
/**
 * Build DVCS request to VPKC service.
 *
 * @throws DVCSException
 */
public DVCSRequest build()
    throws DVCSException
{
    Data data = new Data((TargetEtcChain[])chains.toArray(new TargetEtcChain[chains.size()]));

    return createDVCRequest(data);
}
项目:gwt-crypto    文件:VPKCRequestBuilder.java   
/**
 * Build DVCS request to VPKC service.
 *
 * @return a new DVCSRequest based on the state of this builder.
 * @throws DVCSException if an issue occurs during construction.
 */
public DVCSRequest build()
    throws DVCSException
{
    Data data = new Data((TargetEtcChain[])chains.toArray(new TargetEtcChain[chains.size()]));

    return createDVCRequest(data);
}
项目:Aki-SSL    文件:VPKCRequestBuilder.java   
/**
 * Build DVCS request to VPKC service.
 *
 * @return a new DVCSRequest based on the state of this builder.
 * @throws DVCSException if an issue occurs during construction.
 */
public DVCSRequest build()
    throws DVCSException
{
    Data data = new Data((TargetEtcChain[])chains.toArray(new TargetEtcChain[chains.size()]));

    return createDVCRequest(data);
}
项目:irma_future_id    文件:VPKCRequestBuilder.java   
/**
 * Build DVCS request to VPKC service.
 *
 * @throws DVCSException
 */
public DVCSRequest build()
    throws DVCSException
{
    Data data = new Data((TargetEtcChain[])chains.toArray(new TargetEtcChain[chains.size()]));

    return createDVCRequest(data);
}
项目:bc-java    文件:VPKCRequestBuilder.java   
/**
 * Build DVCS request to VPKC service.
 *
 * @throws DVCSException
 */
public DVCSRequest build()
    throws DVCSException
{
    Data data = new Data((TargetEtcChain[])chains.toArray(new TargetEtcChain[chains.size()]));

    return createDVCRequest(data);
}
项目:ipack    文件:TargetChain.java   
public TargetChain(TargetEtcChain certs)
{
    this.certs = certs;
}
项目:ipack    文件:TargetChain.java   
public TargetEtcChain toASN1Structure()
{
    return certs;
}
项目:gwt-crypto    文件:TargetChain.java   
public TargetChain(TargetEtcChain certs)
{
    this.certs = certs;
}
项目:gwt-crypto    文件:TargetChain.java   
public TargetEtcChain toASN1Structure()
{
    return certs;
}
项目:Aki-SSL    文件:TargetChain.java   
public TargetChain(TargetEtcChain certs)
{
    this.certs = certs;
}
项目:Aki-SSL    文件:TargetChain.java   
public TargetEtcChain toASN1Structure()
{
    return certs;
}
项目:irma_future_id    文件:TargetChain.java   
public TargetChain(TargetEtcChain certs)
{
    this.certs = certs;
}
项目:irma_future_id    文件:TargetChain.java   
public TargetEtcChain toASN1Structure()
{
    return certs;
}
项目:bc-java    文件:TargetChain.java   
public TargetChain(TargetEtcChain certs)
{
    this.certs = certs;
}
项目:bc-java    文件:TargetChain.java   
public TargetEtcChain toASN1Structure()
{
    return certs;
}
项目:ipack    文件:VPKCRequestBuilder.java   
/**
 * Adds a TargetChain representing a X.509 certificate to the request.
 *
 * @param cert the certificate to be added
 */
public void addTargetChain(X509CertificateHolder cert)
{
    chains.add(new TargetEtcChain(new CertEtcToken(CertEtcToken.TAG_CERTIFICATE, cert.toASN1Structure())));
}
项目:ipack    文件:VPKCRequestBuilder.java   
/**
 * Adds a TargetChain representing a single X.509 Extension to the request
 *
 * @param extension the extension to be added.
 */
public void addTargetChain(Extension extension)
{
    chains.add(new TargetEtcChain(new CertEtcToken(extension)));
}
项目:gwt-crypto    文件:VPKCRequestBuilder.java   
/**
 * Adds a TargetChain representing a X.509 certificate to the request.
 *
 * @param cert the certificate to be added
 */
public void addTargetChain(X509CertificateHolder cert)
{
    chains.add(new TargetEtcChain(new CertEtcToken(CertEtcToken.TAG_CERTIFICATE, cert.toASN1Structure())));
}
项目:gwt-crypto    文件:VPKCRequestBuilder.java   
/**
 * Adds a TargetChain representing a single X.509 Extension to the request
 *
 * @param extension the extension to be added.
 */
public void addTargetChain(Extension extension)
{
    chains.add(new TargetEtcChain(new CertEtcToken(extension)));
}
项目:Aki-SSL    文件:VPKCRequestBuilder.java   
/**
 * Adds a TargetChain representing a X.509 certificate to the request.
 *
 * @param cert the certificate to be added
 */
public void addTargetChain(X509CertificateHolder cert)
{
    chains.add(new TargetEtcChain(new CertEtcToken(CertEtcToken.TAG_CERTIFICATE, cert.toASN1Structure())));
}
项目:Aki-SSL    文件:VPKCRequestBuilder.java   
/**
 * Adds a TargetChain representing a single X.509 Extension to the request
 *
 * @param extension the extension to be added.
 */
public void addTargetChain(Extension extension)
{
    chains.add(new TargetEtcChain(new CertEtcToken(extension)));
}
项目:irma_future_id    文件:VPKCRequestBuilder.java   
/**
 * Adds a TargetChain representing a X.509 certificate to the request.
 *
 * @param cert the certificate to be added
 */
public void addTargetChain(X509CertificateHolder cert)
{
    chains.add(new TargetEtcChain(new CertEtcToken(CertEtcToken.TAG_CERTIFICATE, cert.toASN1Structure())));
}
项目:irma_future_id    文件:VPKCRequestBuilder.java   
/**
 * Adds a TargetChain representing a single X.509 Extension to the request
 *
 * @param extension the extension to be added.
 */
public void addTargetChain(Extension extension)
{
    chains.add(new TargetEtcChain(new CertEtcToken(extension)));
}
项目:bc-java    文件:VPKCRequestBuilder.java   
/**
 * Adds a TargetChain representing a X.509 certificate to the request.
 *
 * @param cert the certificate to be added
 */
public void addTargetChain(X509CertificateHolder cert)
{
    chains.add(new TargetEtcChain(new CertEtcToken(CertEtcToken.TAG_CERTIFICATE, cert.toASN1Structure())));
}
项目:bc-java    文件:VPKCRequestBuilder.java   
/**
 * Adds a TargetChain representing a single X.509 Extension to the request
 *
 * @param extension the extension to be added.
 */
public void addTargetChain(Extension extension)
{
    chains.add(new TargetEtcChain(new CertEtcToken(extension)));
}