OSDN Git Service
(root)
/
sagit-ice-cold
/
kernel_xiaomi_msm8998.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
88b62b9
)
digsig: Fix memory leakage in digsig_verify_rsa()
author
YOSHIFUJI Hideaki
<yoshfuji@linux-ipv6.org>
Fri, 25 Jan 2013 14:54:20 +0000
(16:54 +0200)
committer
James Morris
<james.l.morris@oracle.com>
Fri, 1 Feb 2013 04:59:33 +0000
(15:59 +1100)
digsig_verify_rsa() does not free kmalloc'ed buffer returned by
mpi_get_buffer().
Signed-off-by: YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Signed-off-by: Dmitry Kasatkin <dmitry.kasatkin@intel.com>
Cc: stable@vger.kernel.org
Signed-off-by: James Morris <james.l.morris@oracle.com>
lib/digsig.c
patch
|
blob
|
history
diff --git
a/lib/digsig.c
b/lib/digsig.c
index
8c0e629
..
dc2be7e
100644
(file)
--- a/
lib/digsig.c
+++ b/
lib/digsig.c
@@
-162,6
+162,8
@@
static int digsig_verify_rsa(struct key *key,
memset(out1, 0, head);
memcpy(out1 + head, p, l);
+ kfree(p);
+
err = pkcs_1_v1_5_decode_emsa(out1, len, mblen, out2, &len);
if (err)
goto err;