I did notice something along those lines. I have some special characters in my 
encryption keys. They work fine when entered in the main OpenBSD shell, and 
work fine when run out of an XTerm. They don't work if I try to use them from a 
KDE Konsole.

Woodchuck <[EMAIL PROTECTED]> wrote:  
A problem here is that evidently getpass() is reading the terminal
in "cooked" mode. Unfortunately, the characters that are consumed
in "cooking" can vary depending on user settings (man stty). This
can lead to surprises if you get too loose about what control (and
high ascii, maybe) characters you use in input to getpass(). An
svnd device you mount one day from an xterm might be mysteriously
unreadable when you mount it from a text console during a single-user
session.

The source for getpass() is in /usr/src/lib/libc/gen/readpassphrase.c
You might wish to analyze that routine with respect to what state of
"cooking" it places /dev/tty or STDIN into. 

You're one step away from "hexadecimal armor" or whatever the PGP
folks call it. ;) Considerations like the preceding paragraph as
well as internationalization issues are why PGP keeps its various
things as ascii-hex characters. They also simplify storage on paper in
the bank deposit box.

Dave
-- 
"I believe that banking institutions are more dangerous to our
liberties than standing armies." -- T. Jefferson


 
---------------------------------
Bored stiff? Loosen up...
Download and play hundreds of games for free on Yahoo! Games.

Reply via email to