Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ipv6: remove printk

ipv6_find_hdr() prints a non-rate limited error message
when it cannot find an ipv6 header at a specific offset.
This could be used as a DoS, so just remove it.

Signed-off-by: Jonathan Lemon <jonathan.lemon@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>

authored by

Jonathan Lemon and committed by
David S. Miller
280b0b8e edcde3ee

+1 -3
+1 -3
net/ipv6/exthdrs_core.c
··· 197 197 struct ipv6hdr _ip6, *ip6; 198 198 199 199 ip6 = skb_header_pointer(skb, *offset, sizeof(_ip6), &_ip6); 200 - if (!ip6 || (ip6->version != 6)) { 201 - printk(KERN_ERR "IPv6 header not found\n"); 200 + if (!ip6 || (ip6->version != 6)) 202 201 return -EBADMSG; 203 - } 204 202 start = *offset + sizeof(struct ipv6hdr); 205 203 nexthdr = ip6->nexthdr; 206 204 }