diff options
author | Zhang Yunkai <zhang.yunkai@zte.com.cn> | 2022-02-14 04:27:21 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2022-02-15 15:30:48 +0100 |
commit | 9d2d38c35e7a3de96340c446f3b0fde7b2e7348e (patch) | |
tree | 8cef4734bc5e2f9aa24771891c279597bf87ea41 /net | |
parent | crypto: af_alg - get rid of alg_memory_allocated (diff) | |
download | linux-9d2d38c35e7a3de96340c446f3b0fde7b2e7348e.tar.xz linux-9d2d38c35e7a3de96340c446f3b0fde7b2e7348e.zip |
ipv4: add description about martian source
When multiple containers are running in the environment and multiple
macvlan network port are configured in each container, a lot of martian
source prints will appear after martian_log is enabled. they are almost
the same, and printed by net_warn_ratelimited. Each arp message will
trigger this print on each network port.
Such as:
IPv4: martian source 173.254.95.16 from 173.254.100.109,
on dev eth0
ll header: 00000000: ff ff ff ff ff ff 40 00 ad fe 64 6d
08 06 ......@...dm..
IPv4: martian source 173.254.95.16 from 173.254.100.109,
on dev eth1
ll header: 00000000: ff ff ff ff ff ff 40 00 ad fe 64 6d
08 06 ......@...dm..
There is no description of this kind of source in the RFC1812.
Signed-off-by: Zhang Yunkai <zhang.yunkai@zte.com.cn>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net')
-rw-r--r-- | net/ipv4/fib_frontend.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/net/ipv4/fib_frontend.c b/net/ipv4/fib_frontend.c index 4d61ddd8a0ec..85117b45216d 100644 --- a/net/ipv4/fib_frontend.c +++ b/net/ipv4/fib_frontend.c @@ -436,6 +436,9 @@ int fib_validate_source(struct sk_buff *skb, __be32 src, __be32 dst, if (net->ipv4.fib_has_custom_local_routes || fib4_has_custom_rules(net)) goto full_check; + /* Within the same container, it is regarded as a martian source, + * and the same host but different containers are not. + */ if (inet_lookup_ifaddr_rcu(net, src)) return -EINVAL; |