* src/pam/auth-support/getpin-cb.c (query_user): Remove checking of digits.
authorNIIBE Yutaka <gniibe@fsij.org>
Wed, 30 Apr 2014 08:07:44 +0000 (17:07 +0900)
committerNIIBE Yutaka <gniibe@fsij.org>
Wed, 30 Apr 2014 08:07:44 +0000 (17:07 +0900)
Change error message when it's too short.

src/pam/auth-support/getpin-cb.c

index 10acbe7..5dfba9a 100644 (file)
@@ -81,9 +81,10 @@ query_user (poldi_ctx_t ctx, const char *info, char *pin, size_t pin_size)
         Shouldn't they be done in scdaemon itself?  -mo */
 
       if (strlen (buffer) < 6) /* FIXME? is it really minimum of 6 bytes? */
-       log_msg_error (ctx->loghandle, _("invalid PIN"));
-      else if (!all_digitsp (buffer))
-       log_msg_error (ctx->loghandle, _("invalid characters in PIN"));
+       {
+         log_msg_error (ctx->loghandle, _("PIN too short"));
+         conv_tell (ctx->conv, "%s", _("PIN too short"));
+       }
       else
        break;
     }