net: restore ip source validation
[...]
include/linux/sysctl.h enum · line 496
Quoted 10 lines
include/linux/sysctl.h +1
-0@@ -490,6 +490,7 @@ enumNET_IPV4_CONF_PROMOTE_SECONDARIES =20 ,NET_IPV4_CONF_ARP_ACCEPT =21 ,NET_IPV4_CONF_ARP_NOTIFY =22 , +NET_IPV4_CONF_SRC_VMARK =24 , __NET_IPV4_CONF_MAX };
Must these be contiguous, i.e. 23?
R.
Signature · 2 lines
Jetzt kostenlos herunterladen: Internet Explorer 8 und Mozilla Firefox 3.5 - sicherer, schneller und einfacher! http://portal.gmx.net/de/go/atbrowser
Quoted 14 lines · Randolf Pohl
[...]
include/linux/sysctl.h enum · line 496
Quoted 10 lines
include/linux/sysctl.h +1
-0@@ -490,6 +490,7 @@ enumNET_IPV4_CONF_PROMOTE_SECONDARIES =20 ,NET_IPV4_CONF_ARP_ACCEPT =21 ,NET_IPV4_CONF_ARP_NOTIFY =22 , +NET_IPV4_CONF_SRC_VMARK =24 , __NET_IPV4_CONF_MAX };Must these be contiguous, i.e. 23?
The problem is elsewhere. Here's the fix.
--
kernel/sysctl_check.c +0 -0
@@ -220,6 +220,7 @@ static const struct trans_ctl_table
trans_net_ipv4_conf_vars_table[] = {
{ NET_IPV4_CONF_PROMOTE_SECONDARIES, "promote_secondaries" },
{ NET_IPV4_CONF_ARP_ACCEPT, "arp_accept" },
{ NET_IPV4_CONF_ARP_NOTIFY, "arp_notify" },
+ { NET_IPV4_CONF_SRC_VMARK, "src_valid_mark" },
{} };
---
cheers,
jamal
Quoted 8 lines · jamal
The problem is elsewhere. Here's the fix.
--
kernel/sysctl_check.c +0
-0
kernel/sysctl_check.c static const struct trans_ctl_table
Quoted 8 lines
kernel/sysctl_check.c +1
-1@@ -220,6 +220,7 @@ static const struct trans_ctl_table trans_net_ipv4_conf_vars_table[] = { {NET_IPV4_CONF_PROMOTE_SECONDARIES ,"promote_secondaries" }, {NET_IPV4_CONF_ARP_ACCEPT ,"arp_accept" }, {NET_IPV4_CONF_ARP_NOTIFY ,"arp_notify" }, + {NET_IPV4_CONF_SRC_VMARK ,"src_valid_mark" }, {} }; ---
Well spotted, that fixes it. Your mailer is broken however, it converted tabs into spaces, so I had to add the changed line manually.
Sven
Quoted 13 lines · Sven Joachim
Quoted 11 lines · jamal
The problem is elsewhere. Here's the fix.
--
kernel/sysctl_check.c +0
-0@@ -220,6 +220,7 @@ static const struct trans_ctl_table trans_net_ipv4_conf_vars_table[] = { { NET_IPV4_CONF_PROMOTE_SECONDARIES, "promote_secondaries" }, { NET_IPV4_CONF_ARP_ACCEPT, "arp_accept" },
Quoted 8 lines
kernel/sysctl_check.c static const struct trans_ctl_table
Quoted 5 lines
kernel/sysctl_check.c +1
-1{ NET_IPV4_CONF_ARP_NOTIFY, "arp_notify" }, + { NET_IPV4_CONF_SRC_VMARK, "src_valid_mark" }, {} }; ---Well spotted, that fixes it. Your mailer is broken however, it converted tabs into spaces, so I had to add the changed line manually.
Bah. That DEVINET_SYSCTL_ENTRY requires having a binary sysctl assigned, just to use as an index.
Which of course trips over all of the fine checks in sysctl_check.c to keep people from assigning new binary sysctls by accident.
That is the only place in the kernel where he have that problem, I wonder how much work it will be to finish untangling.
Eric
Quoted 8 lines · Eric W. Biederman
Bah. That
DEVINET_SYSCTL_ENTRYrequires having a binary sysctl assigned, just to use as an index.Which of course trips over all of the fine checks in
sysctl_check.cto keep people from assigning new binary sysctls by accident.That is the only place in the kernel where he have that problem, I wonder how much work it will be to finish untangling.
Isn't that already done in 2.6.33, looking at commit 83ac201b ? Forgive my ignorance, I am a layman.
Sen
Quoted 5 lines · Sven Joachim
Quoted 3 lines · Eric W. Biederman
Bah. That
DEVINET_SYSCTL_ENTRYrequires having a binary sysctl assigned, just to use as an index.
Quoted 8 lines
Quoted 5 lines
Which of course trips over all of the fine checks in
sysctl_check.cto keep people from assigning new binary sysctls by accident.That is the only place in the kernel where he have that problem, I wonder how much work it will be to finish untangling.
Isn't that already done in 2.6.33, looking at commit
83ac201b? Forgive my ignorance, I am a layman.
In 2.6.33 the enumeration in sysctl.h still serves double duty as an index into a per network device bitmap and as the binary sysctl number. You are correct that the rest of the binary sysctl code is decoupled in 2.6.33.
In 2.6.32 the implementation is also still coupled and that difference is what caused problems for the backport.
I just wince whenever I noticed we have touched sysctl.h.
Eric
Quoted 5 lines · Sven Joachim
Quoted 3 lines · Eric W. Biederman
Bah. That
DEVINET_SYSCTL_ENTRYrequires having a binary sysctl assigned, just to use as an index.
Quoted 8 lines
Quoted 5 lines
Which of course trips over all of the fine checks in
sysctl_check.cto keep people from assigning new binary sysctls by accident.That is the only place in the kernel where he have that problem, I wonder how much work it will be to finish untangling.
Isn't that already done in 2.6.33, looking at commit
83ac201b? Forgive my ignorance, I am a layman.
In 2.6.33 the enumeration in sysctl.h still serves double duty as an index into a per network device bitmap and as the binary sysctl number. You are correct that the rest of the binary sysctl code is decoupled in 2.6.33.
In 2.6.32 the implementation is also still coupled and that difference is what caused problems for the backport.
I just wince whenever I noticed we have touched sysctl.h.
Eric