mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 02:32:09 -04:00
netfilter: x_tables: use pr ratelimiting in all remaining spots
Signed-off-by: Florian Westphal <[email protected]> Signed-off-by: Pablo Neira Ayuso <[email protected]>
This commit is contained in:
parent
c08e5e1ee6
commit
b26066447b
34 changed files with 116 additions and 104 deletions
|
|
@ -85,14 +85,14 @@ static int reject_tg6_check(const struct xt_tgchk_param *par)
|
|||
const struct ip6t_entry *e = par->entryinfo;
|
||||
|
||||
if (rejinfo->with == IP6T_ICMP6_ECHOREPLY) {
|
||||
pr_info("ECHOREPLY is not supported.\n");
|
||||
pr_info_ratelimited("ECHOREPLY is not supported\n");
|
||||
return -EINVAL;
|
||||
} else if (rejinfo->with == IP6T_TCP_RESET) {
|
||||
/* Must specify that it's a TCP packet */
|
||||
if (!(e->ipv6.flags & IP6T_F_PROTO) ||
|
||||
e->ipv6.proto != IPPROTO_TCP ||
|
||||
(e->ipv6.invflags & XT_INV_PROTO)) {
|
||||
pr_info("TCP_RESET illegal for non-tcp\n");
|
||||
pr_info_ratelimited("TCP_RESET illegal for non-tcp\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -103,7 +103,7 @@ static int rpfilter_check(const struct xt_mtchk_param *par)
|
|||
unsigned int options = ~XT_RPFILTER_OPTION_MASK;
|
||||
|
||||
if (info->flags & options) {
|
||||
pr_info("unknown options encountered");
|
||||
pr_info_ratelimited("unknown options\n");
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -122,12 +122,14 @@ static int srh_mt6_check(const struct xt_mtchk_param *par)
|
|||
const struct ip6t_srh *srhinfo = par->matchinfo;
|
||||
|
||||
if (srhinfo->mt_flags & ~IP6T_SRH_MASK) {
|
||||
pr_err("unknown srh match flags %X\n", srhinfo->mt_flags);
|
||||
pr_info_ratelimited("unknown srh match flags %X\n",
|
||||
srhinfo->mt_flags);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
if (srhinfo->mt_invflags & ~IP6T_SRH_INV_MASK) {
|
||||
pr_err("unknown srh invflags %X\n", srhinfo->mt_invflags);
|
||||
pr_info_ratelimited("unknown srh invflags %X\n",
|
||||
srhinfo->mt_invflags);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue