projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c268199
)
crypto: algif_aead - Fix kernel panic on list_del
author
Harsh Jain
<
[email protected]
>
Wed, 1 Feb 2017 15:40:28 +0000
(21:10 +0530)
committer
Herbert Xu
<
[email protected]
>
Fri, 3 Feb 2017 09:45:48 +0000
(17:45 +0800)
Kernel panics when userspace program try to access AEAD interface.
Remove node from Linked List before freeing its memory.
Cc: <
[email protected]
>
Signed-off-by: Harsh Jain <
[email protected]
>
Reviewed-by: Stephan Müller <
[email protected]
>
Signed-off-by: Herbert Xu <
[email protected]
>
crypto/algif_aead.c
patch
|
blob
|
history
diff --git
a/crypto/algif_aead.c
b/crypto/algif_aead.c
index f849311e9fd4c94e57d81ba97279ec5fb0cb0ded..533265f110e0297b9fc1e14a7a215a54d634b8d8 100644
(file)
--- a/
crypto/algif_aead.c
+++ b/
crypto/algif_aead.c
@@
-661,9
+661,9
@@
static int aead_recvmsg_sync(struct socket *sock, struct msghdr *msg, int flags)
unlock:
list_for_each_entry_safe(rsgl, tmp, &ctx->list, list) {
af_alg_free_sg(&rsgl->sgl);
+ list_del(&rsgl->list);
if (rsgl != &ctx->first_rsgl)
sock_kfree_s(sk, rsgl, sizeof(*rsgl));
- list_del(&rsgl->list);
}
INIT_LIST_HEAD(&ctx->list);
aead_wmem_wakeup(sk);