From f03976f1101f539a2782cd9e87d640fc32a022db Mon Sep 17 00:00:00 2001 From: NIIBE Yutaka Date: Fri, 4 Dec 2015 14:37:05 +0900 Subject: scd: Fix for removing the prefix. * scd/app-openopg.c (do_decipher): Fix the condition. --- scd/app-openpgp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scd/app-openpgp.c b/scd/app-openpgp.c index d204740a0..581c5dd17 100644 --- a/scd/app-openpgp.c +++ b/scd/app-openpgp.c @@ -4179,7 +4179,7 @@ do_decipher (app_t app, const char *keyidstr, if (app->app_local->keyattr[1].ecc.flags) { - if (indatalen > 32 + 1) + if (indatalen > 32 && (indatalen % 2)) { /* * Skip the prefix. It may be 0x40 (in new format), or MPI * head of 0x00 (in old format). -- cgit v1.2.3