long lastModified = keyStoreSource.getKeyStoreLastModified(); if (keyStore == null || keyStoreLastModified < lastModified) { KeyStore keyStore; keyStore.load(new ByteArrayInputStream(keyStoreSource.getKeyStoreBytes()), toCharArray(password)); } catch (CertificateException e) { LogRecord lr = new LogRecord(Level.WARNING, "Credentials ID {0}: Could not load keystore from {1}");
if (credentials instanceof CertificateCredentialsImpl) { final KeyStoreSource keyStoreSource = ((CertificateCredentialsImpl) credentials).getKeyStoreSource(); if (keyStoreSource.isSnapshotSource()) { return credentials; new UploadedKeyStoreSource(SecretBytes.fromBytes(keyStoreSource.getKeyStoreBytes())));
if (credentials instanceof CertificateCredentialsImpl) { final KeyStoreSource keyStoreSource = ((CertificateCredentialsImpl) credentials).getKeyStoreSource(); if (keyStoreSource.isSnapshotSource()) { return credentials; new UploadedKeyStoreSource(SecretBytes.fromBytes(keyStoreSource.getKeyStoreBytes())));
long lastModified = keyStoreSource.getKeyStoreLastModified(); if (keyStore == null || keyStoreLastModified < lastModified) { KeyStore keyStore; keyStore.load(new ByteArrayInputStream(keyStoreSource.getKeyStoreBytes()), toCharArray(password)); } catch (CertificateException e) { LogRecord lr = new LogRecord(Level.WARNING, "Credentials ID {0}: Could not load keystore from {1}");
/** * When serializing over a {@link Channel} ensure that we send a self-contained version. * * @return the object instance to write to the stream. */ private Object writeReplace() { if (/* XStream */Channel.current() == null || /* already safe to serialize */ keyStoreSource .isSnapshotSource()) { return this; } return CredentialsProvider.snapshot(this); }
/** * When serializing over a {@link Channel} ensure that we send a self-contained version. * * @return the object instance to write to the stream. */ private Object writeReplace() { if (/* XStream */Channel.current() == null || /* already safe to serialize */ keyStoreSource .isSnapshotSource()) { return this; } return CredentialsProvider.snapshot(this); }