If 1) regular Unix passwords not permitted and 2) skey database
for this user not activated, there no correct password exist, so don't bother ask for it and return "" immediately
This commit is contained in:
parent
b7ccf90470
commit
76fa87e93d
@ -11,7 +11,7 @@ int pwok;
|
||||
{
|
||||
static char buf[128];
|
||||
struct skey skey;
|
||||
char *pass;
|
||||
char *pass = "";
|
||||
char *username = pwd ? pwd->pw_name : "nope";
|
||||
int sflag;
|
||||
|
||||
@ -20,8 +20,11 @@ int pwok;
|
||||
if (!sflag)
|
||||
printf("%s\n", buf);
|
||||
|
||||
if (!pwok)
|
||||
if (!pwok) {
|
||||
printf("(s/key required)\n");
|
||||
if (sflag)
|
||||
return (pass);
|
||||
}
|
||||
|
||||
pass = getpass(prompt);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user