Skip to contentSkip to conversation

must-fix list for 2.6.0

DISCUSSION Florian Weimer 4 participants 8 messages Apr 30, 2003 – May 2, 2003 1 message not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

#1 lore raw
Quoted 2 lines · Andrew Morton

net/
----

What about the dst cache DoS attack?

#2 lore raw
Quoted 4 lines
Quoted 2 lines

net/
----

What about the dst cache DoS attack?

What about IPv6 SYN attacks?
tcp_ipv6.c: static int tcp_v6_conn_request(...)
...

        /*
         *      There are no SYN attacks on IPv6, yet...
         */

Nmap is ip6 enabled and is getting its razor sharpened.

Regards,
Maciej

#4 lore raw
Quoted 10 lines · David S. Miller
Quoted 6 lines · Florian Weimer
Quoted 2 lines · Andrew Morton

net/
----

What about the dst cache DoS attack?

Thanks for the lack of detailed description of the problem. Without it nobody can help you.

Shall I post the exploit?

#5 lore raw
Quoted 14 lines · Florian Weimer
Quoted 10 lines · David S. Miller
Quoted 6 lines · Florian Weimer
Quoted 2 lines · Andrew Morton

net/
----

What about the dst cache DoS attack?

Thanks for the lack of detailed description of the problem. Without it nobody can help you.

Shall I post the exploit?

Signature · 1 line
David S. Miller <[email protected]>
#6 lore raw
In reply to Florian Weimer
Quoted 8 lines · Florian Weimer
Quoted 6 lines · David S. Miller
Quoted 5 lines · Florian Weimer
Quoted 2 lines · Andrew Morton

net/
----

Quoted 6 lines
Quoted 4 lines
Quoted 1 line

What about the dst cache DoS attack?

Thanks for the lack of detailed description of the problem. Without it nobody can help you.

Shall I post the exploit?

Don't let me stop you.

You can't expect us to act on anything based upon vague references to "dst cache DoS" and things like that.

I also would appreciate it if you'd actually at least add the networking maintainers to the CC: list when asking/discussing such problems. Bringing it up on places like linux-net and [email protected] would be a good idea too.

Random blather on linux-kernel tends to get ignored.

Signature · 1 line
David S. Miller <[email protected]>
#7 lore raw
Quoted 14 lines · David S. Miller
Quoted 12 lines · Florian Weimer
Quoted 10 lines · David S. Miller
Quoted 7 lines · Florian Weimer
Quoted 2 lines · Andrew Morton

net/
----

What about the dst cache DoS attack?

Quoted 7 lines
Quoted 4 lines
Quoted 2 lines

Thanks for the lack of detailed description of the problem. Without it nobody can help you.

Shall I post the exploit?

You can't expect us to act on anything based upon vague references to "dst cache DoS" and things like that.

http://marc.theaimsgroup.com/?l=linux-kernel&m=104956079213417

Regards,
Carl-Daniel

#8 lore raw

From: Carl-Daniel Hailfinger <[email protected]>
Date: Fri, 02 May 2003 18:28:56 +0200

Quoted 4 lines · David S. Miller
Quoted 1 line

Shall I post the exploit?

You can't expect us to act on anything based upon vague references to "dst cache DoS" and things like that.

http://marc.theaimsgroup.com/?l=linux-kernel&m=104956079213417

Yes, that thing. We're working on a fix.

And, please, don't be silly wrt. exploit posting. One exists publicly for some time, just google for juno-z.101f.c All the script kiddies know where this thing is and what it does. So if you have something better, just post it.

Current patch looks something like this (there will be changes):

ipv4/route.c renamed from ipv4/route.c.~1~ +36 -6
@@ -194,19 +194,46 @@ struct rt_hash_bucket {
 static struct rt_hash_bucket 	*rt_hash_table;
 static unsigned			rt_hash_mask;
 static int			rt_hash_log;
+static unsigned int		rt_hash_rnd;
 
 struct rt_cache_stat rt_cache_stat[NR_CPUS];
 
 static int rt_intern_hash(unsigned hash, struct rtable *rth,
 				struct rtable **res);
 
-static __inline__ unsigned rt_hash_code(u32 daddr, u32 saddr, u8 tos)
+/* This bit mixing code is by Bob Jenkins.  He has a great set of documents
+ * about hash function analysis at:
+ *
+ * http://burtleburtle.net/bob/hash/
+ */
+
+#define __mix(a, b, c) \
+{ \
+  a -= b; a -= c; a ^= (c>>13); \
+  b -= c; b -= a; b ^= (a<<8); \
+  c -= a; c -= b; c ^= (b>>13); \
+  a -= b; a -= c; a ^= (c>>12);  \
+  b -= c; b -= a; b ^= (a<<16); \
+  c -= a; c -= b; c ^= (b>>5); \
+  a -= b; a -= c; a ^= (c>>3);  \
+  b -= c; b -= a; b ^= (a<<10); \
+  c -= a; c -= b; c ^= (b>>15); \
+}
+
+static unsigned int rt_hash_code(u32 daddr, u32 saddr, u8 tos)
 {
-	unsigned hash = ((daddr & 0xF0F0F0F0) >> 4) |
-			((daddr & 0x0F0F0F0F) << 4);
-	hash ^= saddr ^ tos;
-	hash ^= (hash >> 16);
-	return (hash ^ (hash >> 8)) & rt_hash_mask;
+	u32 a, b, c;
+
+	a = b = 0x9e3779b9;
+	c = rt_hash_rnd;
+
+	a += daddr;
+	b += saddr;
+	c += (u32) tos;
+
+	__mix(a, b, c);
+
+	return (c & rt_hash_mask);
 }
 
 static int rt_cache_get_info(char *buffer, char **start, off_t offset,
@@ -2461,6 +2488,9 @@ static int ip_rt_acct_read(char *buffer,
 void __init ip_rt_init(void)
 {
 	int i, order, goal;
+
+	rt_hash_rnd = (int) ((num_physpages ^ (num_physpages>>8)) ^
+			     (jiffies ^ (jiffies >> 7)));
 
 #ifdef CONFIG_NET_CLS_ROUTE
 	for (order = 0;
ipv4/netfilter/ip_conntrack_core.c renamed from ipv4/netfilter/ip_conntrack_core.c.~1~ +37 -9

63 lines not on this page · raw message