From ce29ecfd44613e4f3bae98418add1cc4d0ed59ab Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Fri, 23 Nov 2012 14:55:48 +0100 Subject: ntlm_auth4: Use new samba_getpass() function. Reviewed-by: Jelmer Vernooij --- source4/utils/ntlm_auth.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/source4/utils/ntlm_auth.c b/source4/utils/ntlm_auth.c index cc92c170b6..c363c9d5b6 100644 --- a/source4/utils/ntlm_auth.c +++ b/source4/utils/ntlm_auth.c @@ -1137,7 +1137,13 @@ int main(int argc, const char **argv) } if (!opt_password) { - opt_password = getpass("password: "); + char pwd[256] = {0}; + int rc; + + rc = samba_getpass("Password: ", pwd, sizeof(pwd), false, false); + if (rc == 0) { + opt_password = smb_xstrdup(pwd); + } } { -- cgit