Bugzilla – Attachment 1874 Details for
Bug 1542
Send echo on/off flag to SSH_ASKPASS
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
/home/djm/askpass-env-echo.diff
askpass-env-echo.diff (text/plain), 1.17 KB, created by
Damien Miller
on 2010-06-18 15:06:56 AEST
(
hide
)
Description:
/home/djm/askpass-env-echo.diff
Filename:
MIME Type:
Creator:
Damien Miller
Created:
2010-06-18 15:06:56 AEST
Size:
1.17 KB
patch
obsolete
>Index: readpass.c >=================================================================== >RCS file: /cvs/src/usr.bin/ssh/readpass.c,v >retrieving revision 1.47 >diff -u -p -r1.47 readpass.c >--- readpass.c 3 Aug 2006 03:34:42 -0000 1.47 >+++ readpass.c 18 Jun 2010 05:06:21 -0000 >@@ -44,7 +44,7 @@ > #include "uidswap.h" > > static char * >-ssh_askpass(char *askpass, const char *msg) >+ssh_askpass(char *askpass, const char *msg, int echo_on) > { > pid_t pid; > size_t len; >@@ -69,6 +69,10 @@ ssh_askpass(char *askpass, const char *m > close(p[0]); > if (dup2(p[1], STDOUT_FILENO) < 0) > fatal("ssh_askpass: dup2: %s", strerror(errno)); >+ if (echo_on) >+ setenv("SSH_ASKPASS_ECHO", "1", 1); >+ else >+ unsetenv("SSH_ASKPASS_ECHO"); > execlp(askpass, askpass, msg, (char *) 0); > fatal("ssh_askpass: exec(%s): %s", askpass, strerror(errno)); > } >@@ -141,7 +145,8 @@ read_passphrase(const char *prompt, int > askpass = getenv(SSH_ASKPASS_ENV); > else > askpass = _PATH_SSH_ASKPASS_DEFAULT; >- if ((ret = ssh_askpass(askpass, prompt)) == NULL) >+ if ((ret = ssh_askpass(askpass, prompt, >+ flags & RP_ECHO)) == NULL) > if (!(flags & RP_ALLOW_EOF)) > return xstrdup(""); > return ret;
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
wittayahom5
:
ok+
Actions:
View
|
Diff
Attachments on
bug 1542
: 1874