Package org.jscep.transaction

Examples of org.jscep.transaction.TransactionId


    @Parameters
    public static Collection<Object[]> getParameters() throws Exception {
  List<Object[]> params = new ArrayList<Object[]>();

  KeyPair pair = KeyPairGenerator.getInstance("RSA").generateKeyPair();
  TransactionId transId = TransactionId.createTransactionId();
  Nonce recipientNonce = Nonce.nextNonce();
  Nonce senderNonce = recipientNonce;
  X500Name issuer = new X500Name("CN=CA");
  X500Name subject = new X500Name("CN=Client");
  IssuerAndSubject ias = new IssuerAndSubject(issuer, subject);
View Full Code Here


    private CertRep pkiFailureResponse;
    private CertRep pkiPendingResponse;

    @Before
    public void setUp() {
  TransactionId transId = TransactionId.createTransactionId();
  Nonce nonce = Nonce.nextNonce();
  IssuerAndSerialNumber iasn = mock(IssuerAndSerialNumber.class);
  pkiMessage = new GetCert(transId, nonce, iasn);
  pkiFailureResponse = new CertRep(transId, nonce, nonce,
    FailInfo.badRequest);
View Full Code Here

  PkcsPkiEnvelopeEncoder envEnc = new PkcsPkiEnvelopeEncoder(
    getCertificate(keyPair), "DES");
  PkiMessageEncoder enc = new PkiMessageEncoder(keyPair.getPrivate(),
    getCertificate(keyPair), envEnc);

  TransactionId transId = TransactionId.createTransactionId();
  Nonce senderNonce = Nonce.nextNonce();
  X500Name name = new X500Name("CN=jscep.org");
  BigInteger serialNumber = BigInteger.ONE;
  IssuerAndSerialNumber iasn = new IssuerAndSerialNumber(name,
    serialNumber);
View Full Code Here

      MessageType msgType = msg.getMessageType();
      Object msgData = msg.getMessageData();

      Nonce senderNonce = Nonce.nextNonce();
      TransactionId transId = msg.getTransactionId();
      Nonce recipientNonce = msg.getSenderNonce();
      CertRep certRep;

      if (msgType == MessageType.GET_CERT) {
    final IssuerAndSerialNumber iasn = (IssuerAndSerialNumber) msgData;
View Full Code Here

  }

  MessageType messageType = toMessageType(attrTable
    .get(toOid(MESSAGE_TYPE)));
  Nonce senderNonce = toNonce(attrTable.get(toOid(SENDER_NONCE)));
  TransactionId transId = toTransactionId(attrTable.get(toOid(TRANS_ID)));

  if (messageType == MessageType.CERT_REP) {
      PkiStatus pkiStatus = toPkiStatus(attrTable.get(toOid(PKI_STATUS)));
      Nonce recipientNonce = toNonce(attrTable
        .get(toOid(RECIPIENT_NONCE)));
View Full Code Here

    private TransactionId toTransactionId(Attribute attr) {
  final DERPrintableString string = (DERPrintableString) attr
    .getAttrValues().getObjectAt(0);

  return new TransactionId(string.getOctets());
    }
View Full Code Here

TOP

Related Classes of org.jscep.transaction.TransactionId

Copyright © 2018 www.massapicom. 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.