Examples of KeyNotFoundException


Examples of org.apache.geronimo.management.geronimo.KeyNotFoundException

    public Certificate getCertificate(String alias, char[] storePassword) throws KeystoreIsLocked, KeyNotFoundException, KeystoreException {
        ensureLoaded(storePassword);
        try {
            Certificate cert = keystore.getCertificate(alias);
            if (cert == null) {
                throw new KeyNotFoundException("Keystore '"+keystoreName+"' does not contain a certificate with alias'"+alias+"'.");
            }
            return cert;
        } catch (KeyStoreException e) {
            throw new KeystoreException("Unable to retrieve certificate from keystore", e);
        }
View Full Code Here

Examples of org.apache.geronimo.management.geronimo.KeyNotFoundException

    public String getCertificateAlias(Certificate cert, char[] storePassword) throws KeystoreException {
        ensureLoaded(storePassword);
        try {
            String alias = keystore.getCertificateAlias(cert);
            if (alias == null) {
                throw new KeyNotFoundException("Keystore '"+keystoreName+"' does not contain an alias corresponding to the given certificate.");
            }
            return alias;
        } catch (KeyStoreException e) {
            throw new KeystoreException("Unable to read certificate alias from keystore", e);
        }
View Full Code Here

Examples of org.apache.geronimo.management.geronimo.KeyNotFoundException

    public Certificate[] getCertificateChain(String alias, char[] storePassword) throws KeystoreException {
        ensureLoaded(storePassword);
        try {
            Certificate[] certs = keystore.getCertificateChain(alias);
            if (certs == null) {
                throw new KeyNotFoundException("Keystore '"+keystoreName+"' does not contain a certificate chain with alias'"+alias+"'.");
            }
            return certs;
        } catch (KeyStoreException e) {
            throw new KeystoreException("Unable to read certificate chain from keystore", e);
        }
View Full Code Here

Examples of org.apache.geronimo.management.geronimo.KeyNotFoundException

    public PrivateKey getPrivateKey(String alias, char[] storePassword, char[] keyPasswordthrows KeyNotFoundException, KeystoreException, KeystoreIsLocked {
        ensureLoaded(storePassword);
        try {
            PrivateKey key = (PrivateKey) keystore.getKey(alias, keyPassword);
            if (key == null) {
                throw new KeyNotFoundException("Keystore '"+keystoreName+"' does not contain a private key with alias'"+alias+"'.");
            }
            return key;
        } catch (KeyStoreException e) {
            throw new KeystoreException("Unable to retrieve private key from keystore", e);
        } catch (NoSuchAlgorithmException e) {
View Full Code Here

Examples of org.apache.geronimo.management.geronimo.KeyNotFoundException

    public Certificate getCertificate(String alias, char[] storePassword) throws KeystoreIsLocked, KeyNotFoundException, KeystoreException {
        ensureLoaded(storePassword);
        try {
            Certificate cert = keystore.getCertificate(alias);
            if (cert == null) {
                throw new KeyNotFoundException("Keystore '"+keystoreName+"' does not contain a certificate with alias'"+alias+"'.");
            }
            return cert;
        } catch (KeyStoreException e) {
            throw new KeystoreException("Unable to retrieve certificate from keystore", e);
        }
View Full Code Here

Examples of org.apache.geronimo.management.geronimo.KeyNotFoundException

    public String getCertificateAlias(Certificate cert, char[] storePassword) throws KeystoreException {
        ensureLoaded(storePassword);
        try {
            String alias = keystore.getCertificateAlias(cert);
            if (alias == null) {
                throw new KeyNotFoundException("Keystore '"+keystoreName+"' does not contain an alias corresponding to the given certificate.");
            }
            return alias;
        } catch (KeyStoreException e) {
            throw new KeystoreException("Unable to read certificate alias from keystore", e);
        }
View Full Code Here

Examples of org.apache.geronimo.management.geronimo.KeyNotFoundException

    public Certificate[] getCertificateChain(String alias, char[] storePassword) throws KeystoreException {
        ensureLoaded(storePassword);
        try {
            Certificate[] certs = keystore.getCertificateChain(alias);
            if (certs == null) {
                throw new KeyNotFoundException("Keystore '"+keystoreName+"' does not contain a certificate chain with alias'"+alias+"'.");
            }
            return certs;
        } catch (KeyStoreException e) {
            throw new KeystoreException("Unable to read certificate chain from keystore", e);
        }
View Full Code Here

Examples of org.apache.geronimo.management.geronimo.KeyNotFoundException

    public PrivateKey getPrivateKey(String alias, char[] storePassword, char[] keyPasswordthrows KeyNotFoundException, KeystoreException, KeystoreIsLocked {
        ensureLoaded(storePassword);
        try {
            PrivateKey key = (PrivateKey) keystore.getKey(alias, keyPassword);
            if (key == null) {
                throw new KeyNotFoundException("Keystore '"+keystoreName+"' does not contain a private key with alias'"+alias+"'.");
            }
            return key;
        } catch (KeyStoreException e) {
            throw new KeystoreException("Unable to retrieve private key from keystore", e);
        } catch (NoSuchAlgorithmException e) {
View Full Code Here

Examples of org.helidb.lang.KeyNotFoundException

  public Pair<P> update(K key, V value)
  {
    P pos = find(key);
    if (pos == null)
    {
      throw new KeyNotFoundException("The key " + key + " does not exist in the database");
    }
    return new Pair<P>(pos, updateAt(pos, key, value));
  }
View Full Code Here

Examples of org.helidb.lang.KeyNotFoundException

    assertNotClosed();
    assertNotReadOnly();
    Long pos = find(key);
    if (pos == null)
    {
      throw new KeyNotFoundException("The key " + key + " was not found in the database");
    }
    return new Pair<Long>(pos, updateAt(pos, key, value));
  }
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.