Hide "gets" method output, for passwords..

B

Brian Wallace

[Note: parts of this message were removed to make it a legal post.]

HI All,

I'm trying to find a platform independent way of hiding the STDOUT when a
password is being entered via the gets method...
I was able to hide all output in Linux by using Termios , but as you know
this doesn't work on Windows..

What would be nice , is a simple implementation of asterisks replacing the
actual characters displayed to STDOUT ...

Does anyone know if this is possible in Ruby?

Thanks,

draygen
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,982
Messages
2,570,185
Members
46,736
Latest member
AdolphBig6

Latest Threads

Top