]> git.ipfire.org Git - people/ms/strongswan.git/commitdiff
pki: Stop prompting for password when entering empty string
authorMartin Willi <martin@revosec.ch>
Mon, 10 Mar 2014 16:35:06 +0000 (17:35 +0100)
committerMartin Willi <martin@revosec.ch>
Wed, 4 Jun 2014 13:53:11 +0000 (15:53 +0200)
src/pki/pki.c

index 8d880f066fa8cc1aad2df87013d4874963fc2091..55b300e1aabf1d8cf168d5559fae8e3994759090 100644 (file)
@@ -182,7 +182,7 @@ static shared_key_t* cb(void *data, shared_key_type_t type,
 #ifdef HAVE_GETPASS
        secret = getpass(buf);
 #endif
-       if (secret)
+       if (secret && strlen(secret))
        {
                if (match_me)
                {