Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ELY-1118 Non-existing alias for SSL in Elytron Client configuration f… #794

Merged
merged 1 commit into from
May 4, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -630,6 +630,10 @@ public interface ElytronMessages extends BasicLogger {

@Message(id = 1158, value = "Unable to create kerberos GSS credential")
SecurityException unableToCreateKerberosCredential(@Cause Exception e);

@Message(id = 1159, value = "Key store entry for alias \"%s\" is missing.")
ConfigXMLParseException keyStoreEntryMissing(@Param Location location, String alias);

/* keystore package */

@Message(id = 2001, value = "Invalid key store entry password for alias \"%s\"")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2396,6 +2396,9 @@ static final class PrivateKeyKeyStoreEntryCredentialFactory implements Exception

public X509CertificateChainPrivateCredential get() throws ConfigXMLParseException {
final KeyStore.Entry entry = entrySupplier.get();
if (entry == null) {
throw xmlLog.keyStoreEntryMissing(location, "unknown");
}
if (entry instanceof KeyStore.PrivateKeyEntry) {
final KeyStore.PrivateKeyEntry privateKeyEntry = (KeyStore.PrivateKeyEntry) entry;
final X509Certificate[] certificateChain = X500.asX509CertificateArray(privateKeyEntry.getCertificateChain());
Expand Down