Class Ssh.JLineUserInteraction

java.lang.Object
org.jline.builtins.ssh.Ssh.JLineUserInteraction
All Implemented Interfaces:
org.apache.sshd.client.auth.keyboard.UserInteraction, org.apache.sshd.common.config.keys.FilePasswordProvider
Enclosing class:
Ssh

private static class Ssh.JLineUserInteraction extends Object implements org.apache.sshd.client.auth.keyboard.UserInteraction, org.apache.sshd.common.config.keys.FilePasswordProvider
  • Nested Class Summary

    Nested classes/interfaces inherited from interface org.apache.sshd.common.config.keys.FilePasswordProvider

    org.apache.sshd.common.config.keys.FilePasswordProvider.Decoder<T>, org.apache.sshd.common.config.keys.FilePasswordProvider.ResourceDecodeResult
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private final LineReader
     
    private final PrintStream
     
    private final Terminal
     

    Fields inherited from interface org.apache.sshd.common.config.keys.FilePasswordProvider

    EMPTY

    Fields inherited from interface org.apache.sshd.client.auth.keyboard.UserInteraction

    AUTO_DETECT_PASSWORD_PROMPT, CHECK_INTERACTIVE_PASSWORD_DELIM, DEFAULT_AUTO_DETECT_PASSWORD_PROMPT, DEFAULT_CHECK_INTERACTIVE_PASSWORD_DELIM, DEFAULT_INTERACTIVE_PASSWORD_PROMPT, INTERACTIVE_PASSWORD_PROMPT, NONE
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    getPassword(org.apache.sshd.common.session.SessionContext session, org.apache.sshd.common.NamedResource resourceKey, int retryIndex)
     
    getUpdatedPassword(org.apache.sshd.client.session.ClientSession session, String prompt, String lang)
     
    interactive(org.apache.sshd.client.session.ClientSession s, String name, String instruction, String lang, String[] prompt, boolean[] echo)
     
    boolean
    isInteractionAllowed(org.apache.sshd.client.session.ClientSession session)
     
    private String
    readLine(String prompt, boolean echo)
     
    void
    serverVersionInfo(org.apache.sshd.client.session.ClientSession session, List<String> lines)
     
    void
    welcome(org.apache.sshd.client.session.ClientSession session, String banner, String lang)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

    Methods inherited from interface org.apache.sshd.common.config.keys.FilePasswordProvider

    decode, handleDecodeAttemptResult

    Methods inherited from interface org.apache.sshd.client.auth.keyboard.UserInteraction

    resolveAuthPasswordAttempt, resolveAuthPublicKeyIdentityAttempt
  • Field Details

  • Constructor Details

  • Method Details

    • getPassword

      public String getPassword(org.apache.sshd.common.session.SessionContext session, org.apache.sshd.common.NamedResource resourceKey, int retryIndex) throws IOException
      Specified by:
      getPassword in interface org.apache.sshd.common.config.keys.FilePasswordProvider
      Throws:
      IOException
    • welcome

      public void welcome(org.apache.sshd.client.session.ClientSession session, String banner, String lang)
      Specified by:
      welcome in interface org.apache.sshd.client.auth.keyboard.UserInteraction
    • interactive

      public String[] interactive(org.apache.sshd.client.session.ClientSession s, String name, String instruction, String lang, String[] prompt, boolean[] echo)
      Specified by:
      interactive in interface org.apache.sshd.client.auth.keyboard.UserInteraction
    • isInteractionAllowed

      public boolean isInteractionAllowed(org.apache.sshd.client.session.ClientSession session)
      Specified by:
      isInteractionAllowed in interface org.apache.sshd.client.auth.keyboard.UserInteraction
    • serverVersionInfo

      public void serverVersionInfo(org.apache.sshd.client.session.ClientSession session, List<String> lines)
      Specified by:
      serverVersionInfo in interface org.apache.sshd.client.auth.keyboard.UserInteraction
    • getUpdatedPassword

      public String getUpdatedPassword(org.apache.sshd.client.session.ClientSession session, String prompt, String lang)
      Specified by:
      getUpdatedPassword in interface org.apache.sshd.client.auth.keyboard.UserInteraction
    • readLine

      private String readLine(String prompt, boolean echo)