Re: [Linux-decnet-user] dnprogs password security
Brought to you by:
chrissie_c,
ph3-der-loewe
|
From: Raimund H. <ra...@ba...> - 2001-03-14 17:41:09
|
On Wed, Mar 14, 2001 at 09:39:04AM +0000, Patrick Caulfield wrote: > Though it would be easy...try this patch. Entering a password of "-" will then > prompt you. > > eg: > > dncopy 'trisha"patrick -"::login.com' mylogin.com [Modification of libdap/connection.cc] > + /* If the password is "-" and fd 0 is a tty then > + prompt for a password */ > + if (password[0] == '-' && password[1] == '\0' && isatty(0)) > + { > + password = getpass("Password: "); > + if (password == NULL || strlen(password) > (unsigned int)MAX_PASSWORD) > + { > + strcpy(errstring, "Password input cancelled"); > + lasterror = errstring; > + return false; > + } > + > + } > + It works perfectly for dndir, dnprint, dncopy, dntype :-) Thank you very much. The exception is dntask. Dntask prompts not for Password and send a "connection refused", if I set "-" for Password. Greetings Raimund -- Life's too short to read boring signatures |