From d823292c4f13b2972875cdb37f86b2b1fbf5a4fb Mon Sep 17 00:00:00 2001 From: David Kocher Date: Tue, 10 Oct 2023 14:55:00 +0200 Subject: [PATCH] Fix #15183. --- .../cyberduck/core/sftp/auth/SFTPPublicKeyAuthentication.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ssh/src/main/java/ch/cyberduck/core/sftp/auth/SFTPPublicKeyAuthentication.java b/ssh/src/main/java/ch/cyberduck/core/sftp/auth/SFTPPublicKeyAuthentication.java index e8307a75f7f..5eb45d8a745 100644 --- a/ssh/src/main/java/ch/cyberduck/core/sftp/auth/SFTPPublicKeyAuthentication.java +++ b/ssh/src/main/java/ch/cyberduck/core/sftp/auth/SFTPPublicKeyAuthentication.java @@ -32,6 +32,7 @@ import org.apache.logging.log4j.LogManager; import org.apache.logging.log4j.Logger; +import java.io.File; import java.io.IOException; import java.io.InputStreamReader; import java.nio.charset.StandardCharsets; @@ -90,7 +91,7 @@ public Boolean authenticate(final Host bookmark, final LoginCallback prompt, fin default: throw new InteroperabilityException(String.format("Unknown key format for file %s", identity.getName())); } - provider.init(new InputStreamReader(identity.getInputStream(), StandardCharsets.UTF_8), new PasswordFinder() { + provider.init(new File(identity.getAbsolute()), new PasswordFinder() { @Override public char[] reqPassword(Resource resource) { if(StringUtils.isEmpty(credentials.getIdentityPassphrase())) {