ntlm_auth4: Use new samba_getpass() function.
[kai/samba.git] / source4 / utils / ntlm_auth.c
index cc92c170b6511a38efd890aee99d9d93a9c25404..c363c9d5b657ab2f7f4a5901c9fe626ba1edbed5 100644 (file)
@@ -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);
+               }
        }
 
        {