projects
/
GitHub
/
LineageOS
/
android_kernel_samsung_universal7580.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
9886e83
)
ipv4: make ip_append_data() handle NULL routing table
author
Julien TINNES
<julien@cr0.org>
Thu, 27 Aug 2009 13:26:58 +0000
(15:26 +0200)
committer
Linus Torvalds
<torvalds@linux-foundation.org>
Thu, 27 Aug 2009 19:23:43 +0000
(12:23 -0700)
Add a check in ip_append_data() for NULL *rtp to prevent future bugs in
callers from being exploitable.
Signed-off-by: Julien Tinnes <julien@cr0.org>
Signed-off-by: Tavis Ormandy <taviso@sdf.lonestar.org>
Acked-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
net/ipv4/ip_output.c
patch
|
blob
|
blame
|
history
diff --git
a/net/ipv4/ip_output.c
b/net/ipv4/ip_output.c
index 7d08210547291b74bc15d001e55eacdb8dd34281..7ffcd96fe591921bd139a1de925991b97f9a74f0 100644
(file)
--- a/
net/ipv4/ip_output.c
+++ b/
net/ipv4/ip_output.c
@@
-813,6
+813,8
@@
int ip_append_data(struct sock *sk,
inet->cork.addr = ipc->addr;
}
rt = *rtp;
+ if (unlikely(!rt))
+ return -EFAULT;
/*
* We steal reference to this route, caller should not release it
*/