git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [JGIT RFC PATCH] Add a stdio prompt for SSH connection information.

From
Shawn O. Pearce <spearce@spearce.org>
Date
Jun 22, 2008, 23:13 UTC
Message-ID
<20080622231355.GH11793@spearce.org>
In-Reply-To
<200806222306.25434.robin.rosenberg.lists@dewire.com>
Robin Rosenberg <robin.rosenberg.lists@dewire.com> wrote:
Show 7 quoted lines
> Starting a command line utility like jgit and getting a graphical prompt is almost
> an insult. The problem here is that Java 5, which we support, does not have a
> portable way of disabling echoing of characters. Java 6 (and anythung newr)
> does. There are several solutions involving non-portable tricks. Should we 
> support an insecure practice of echoing passwords, or as I do here, only support
> it if one is using Java 6. A downside of supporting it at all is that one needs a
> JavaSE 6 compiler to build the thing.
We really shouldn't support insecure entry of the password.  But I'm
also not ready to give up on Java 5 support either.  I wonder if
we shouldn't hide the console reading/writing into a class in our
util package and use reflection to access it, like we do for the
executable flag of java.io.File.
 
> btw, does anyone know if console() yields null when runnings as a Windows
> service? I tentatively assume that it does without explicily setting the headless
> property.

I think that services on Windows have no console, and also can't talk to the desktop UI, so its both headless and without a console.

> I'm also a little unsure about how to invoke the promptKeyboardInteractive method.
I think you implemented this method correctly.  Its a confusing API,
but it does seem to make sense.
 
-- 
Shawn.
Previous: Robin RosenbergNext: Robin Rosenberg
Message 2 of 4 in “Add a stdio prompt for SSH connection information.”
  1. Add a stdio prompt for SSH connection information.Robin Rosenberg, Jun 22, 2008
  2. Shawn O. PearceJun 22, 2008
  3. Robin RosenbergJun 23, 2008
  4. Shawn O. PearceJun 23, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.