Console.readPassword does not save/restore tty settings

XMLWordPrintable

    • Type: Bug
    • Resolution: Fixed
    • Priority: P3
    • 11
    • Affects Version/s: None
    • Component/s: core-libs
    • None
    • b10

      After calling "System.console().readPassword()", my tty echo setting is unconditionally turned on (sorry, I like "stty -echo").
      Of course, java should save and restore the tty settings (see e.g. stty -g)

      Linux demo:

       $ stty -echo
       $ echo ---; stty | grep echo; echo ---; jver 11 keytool -list -cacerts; echo ---; stty | grep echo; echo ---
      ---
      -echo
      ---
      Enter keystore password:
      [snip]
      ---
      ---

            Assignee:
            Xueming Shen
            Reporter:
            Martin Buchholz
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: