Skip to content

Commit

Permalink
Deny empty password without request to vpn server
Browse files Browse the repository at this point in the history
  • Loading branch information
Jānis Mezītis committed Mar 3, 2016
1 parent 2f6ba9f commit 4c12cee
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions jvpn.pl
Original file line number Diff line number Diff line change
Expand Up @@ -141,9 +141,11 @@
}

if ($cfgpass eq "interactive") {
print "Enter PIN+password: ";
$password=read_input("password");
print "\n";
do {
print "Enter PIN+password: ";
$password=read_input("password");
print "\n";
} while ( $password eq "" );
}
elsif ($cfgpass =~ /^plaintext:(.+)/) {
print "Using user-defined password\n";
Expand Down Expand Up @@ -192,9 +194,11 @@
elsif ($cfgpass eq "interactive" || $cfgpass =~ /^plaintext:/) {
print "To continue, wait for the token code to change and ".
"then enter the new pin and code.\n";
print "Enter PIN+password: ";
$password=read_input("password");
print "\n";
do {
print "Enter PIN+password: ";
$password=read_input("password");
print "\n";
} while ( $password eq "" );
}
elsif ($cfgpass =~ /^helper:(.+)/) {
print "Using user-defined script to get second password\n";
Expand Down

0 comments on commit 4c12cee

Please sign in to comment.