Package br.net.woodstock.rockframework.security

Examples of br.net.woodstock.rockframework.security.Identity


        Certificate certificate = entry.getValue();
        this.addCertificateElement(certificates, alias, certificate);
      }
      for (Entry<String, Identity> entry : this.getPrivateKeyMap().entrySet()) {
        String alias = entry.getKey();
        Identity identity = entry.getValue();
        this.addPrivateKeyElement(privateKeys, alias, identity);
      }
      for (Entry<String, PublicKey> entry : this.getPublicKeyMap().entrySet()) {
        String alias = entry.getKey();
        PublicKey publicKey = entry.getValue();
View Full Code Here


    if (chainList.size() > 0) {
      chain = Collections.toArray(chainList, Certificate.class);
    }

    Identity identity = new Identity(privateKey, chain);
    return identity;
  }
View Full Code Here

  public String getSignAlgorithm() {
    return this.getSignType().getAlgorithm();
  }

  public PrivateKey getIssuerPrivateKey() {
    Identity identity = this.getIssuer();
    if (identity != null) {
      return identity.getPrivateKey();
    }
    return null;
  }
View Full Code Here

    }
    return null;
  }

  public X509Certificate getIssuerCertificate() {
    Identity identity = this.getIssuer();
    if (identity != null) {
      Certificate[] chain = identity.getChain();
      if (Conditions.isNotEmpty(chain)) {
        return (X509Certificate) chain[0];
      }
    }
    return null;
View Full Code Here

    }
    return null;
  }

  public X500Name getIssuerX500Name() {
    Identity identity = this.getIssuer();
    if (identity != null) {
      Certificate[] chain = identity.getChain();
      if (Conditions.isNotEmpty(chain)) {
        X509Certificate certificate = (X509Certificate) chain[0];
        return BouncyCastleProviderHelper.toX500Name(certificate.getIssuerX500Principal());
      }
    }
View Full Code Here

  public StoreEntryType getType() {
    return StoreEntryType.PRIVATE_KEY;
  }

  public Identity toIdentity() {
    return new Identity(this.getValue(), this.getChain());
  }
View Full Code Here

  public StoreEntryType getType() {
    return StoreEntryType.PRIVATE_KEY;
  }

  public Identity toIdentity() {
    return new Identity(this.getValue(), this.getChain());
  }
View Full Code Here

  public String getSignAlgorithm() {
    return this.getSignType().getAlgorithm();
  }

  public PrivateKey getIssuerPrivateKey() {
    Identity identity = this.getIssuer();
    if (identity != null) {
      return identity.getPrivateKey();
    }
    return null;
  }
View Full Code Here

    }
    return null;
  }

  public X509Certificate getIssuerCertificate() {
    Identity identity = this.getIssuer();
    if (identity != null) {
      Certificate[] chain = identity.getChain();
      if (ConditionUtils.isNotEmpty(chain)) {
        return (X509Certificate) chain[0];
      }
    }
    return null;
View Full Code Here

    }
    return null;
  }

  public X500Name getIssuerX500Name() {
    Identity identity = this.getIssuer();
    if (identity != null) {
      Certificate[] chain = identity.getChain();
      if (ConditionUtils.isNotEmpty(chain)) {
        X509Certificate certificate = (X509Certificate) chain[0];
        return BouncyCastleProviderHelper.toX500Name(certificate.getIssuerX500Principal());
      }
    }
View Full Code Here

TOP

Related Classes of br.net.woodstock.rockframework.security.Identity

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.