projects
/
GitHub
/
MotorolaMobilityLLC
/
kernel-slsi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
85fbaa7
)
ipv6: fix leaking uninitialized port number of offender sockaddr
author
Hannes Frederic Sowa
<hannes@stressinduktion.org>
Sat, 23 Nov 2013 06:22:33 +0000
(07:22 +0100)
committer
David S. Miller
<davem@davemloft.net>
Sat, 23 Nov 2013 22:46:23 +0000
(14:46 -0800)
Offenders don't have port numbers, so set it to 0.
Signed-off-by: Hannes Frederic Sowa <hannes@stressinduktion.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv6/datagram.c
patch
|
blob
|
blame
|
history
diff --git
a/net/ipv6/datagram.c
b/net/ipv6/datagram.c
index d690204a0275cd0d0f659e8efd15c3f3889c9184..8dfe1f4d3c1a4e5f1e90be1603a2c84311f3a95b 100644
(file)
--- a/
net/ipv6/datagram.c
+++ b/
net/ipv6/datagram.c
@@
-378,6
+378,7
@@
int ipv6_recv_error(struct sock *sk, struct msghdr *msg, int len, int *addr_len)
if (serr->ee.ee_origin != SO_EE_ORIGIN_LOCAL) {
sin->sin6_family = AF_INET6;
sin->sin6_flowinfo = 0;
+ sin->sin6_port = 0;
if (skb->protocol == htons(ETH_P_IPV6)) {
sin->sin6_addr = ipv6_hdr(skb)->saddr;
if (np->rxopt.all)