fragaLY opened a new issue, #622:
URL: https://github.com/apache/mina-sshd/issues/622

   ### Version
   
   2.14.0
   
   ### Bug description
   
   During the client#connect invocation, I am facing the parsing problem that 
provides me with identity in format
   "~/.ssh/sftp.pem",  but Tilda is expected to be the first token.
   
   ```java
   public class Main {
   
       private static final int DEFAULT_SFTP_SESSION_TIMEOUT = 1500;
   
       public static void main(String[] args) throws IOException {
           SshClient client = null;
           ClientSession session = null;
           try {
               client = SshClient.setUpDefaultClient();
               client.setServerKeyVerifier(AcceptAllServerKeyVerifier.INSTANCE);
               client.start();
               session = client.connect("user, "host", 
port).verify(DEFAULT_SFTP_SESSION_TIMEOUT, TimeUnit.MILLISECONDS).getSession();
               session.addPasswordIdentity("password");
               session.auth().verify(DEFAULT_SFTP_SESSION_TIMEOUT, 
TimeUnit.MILLISECONDS);
               System.out.println(session);
           } catch (Exception e) {
               var message = "Failed to create SSHClient Session:" + 
e.getMessage();
               System.out.println(message);
           } finally {
               Objects.requireNonNull(session).close();
               Objects.requireNonNull(client).close();
           }
       }
   }```
   
   ### Actual behavior
   
   Home tilde must be first: "~/.ssh/sftp.pem"
   
   ### Expected behavior
   
   Connection established.
   
   ### Relevant log output
   
   _No response_
   
   ### Other information
   
   _No response_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscr...@mina.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@mina.apache.org
For additional commands, e-mail: dev-h...@mina.apache.org

Reply via email to