From: David Miller <davem@davemloft.net>
To: johnpol@2ka.mipt.ru
Cc: draghuram@rocketmail.com, linux-kernel@vger.kernel.org,
netdev@vger.kernel.org
Subject: Re: Question about tcp hash function tcp_hashfn()
Date: Wed, 31 May 2006 02:12:43 -0700 (PDT) [thread overview]
Message-ID: <20060531.021243.122061524.davem@davemloft.net> (raw)
In-Reply-To: <20060531090301.GA26782@2ka.mipt.ru>
From: Evgeniy Polyakov <johnpol@2ka.mipt.ru>
Date: Wed, 31 May 2006 13:03:02 +0400
> Current simple XOR hash used in socket selection code is just bloody
> good! Jenkins hash unfortunately has _significant_ artefacts which
> were found in netchannel [1] hash selection analysis [2]. And
> Jenkins hash is far too slower.
Yes, it wins from a simplicity standpoint and it performs quite well.
It was tuned from real socket data sets, but from systems running many
many years ago :)
FreeBSD even adopted this hash into their PCB hashing code at one
point.
I think it will need to be changed nevertheless. Even though this
hash works on established sockets, it is attackable just like the
routing hash used to be. If an attacker has sufficient resources, he
can make hash chains in the TCP established hash table very long. As
the years pass, it becomes easier and easier for one to have enough
computing power at their disposal to carry out this kind of attack.
So something like Jenkins with a random hash input become more and
more critical. And this requires some kind of way to rehash, RCU
table locking opens the door for that. Current locking scheme is
too tightly bound for that kind of flexibility.
I wish Ben L. would resubmit the TCP hash locking stuff he said he'd
work on. :)
next prev parent reply other threads:[~2006-05-31 9:12 UTC|newest]
Thread overview: 40+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-05-31 4:29 Raghuram
2006-05-31 5:55 ` Brian F. G. Bidulock
2006-05-31 7:10 ` David Miller
2006-05-31 7:45 ` Brian F. G. Bidulock
2006-05-31 7:49 ` David Miller
2006-05-31 8:00 ` Brian F. G. Bidulock
2006-05-31 9:03 ` Evgeniy Polyakov
2006-05-31 9:12 ` David Miller [this message]
2006-05-31 9:44 ` Evgeniy Polyakov
2006-05-31 9:51 ` Brian F. G. Bidulock
2006-05-31 10:58 ` Evgeniy Polyakov
2006-05-31 11:04 ` Evgeniy Polyakov
2006-05-31 13:06 ` Evgeniy Polyakov
2006-05-31 18:29 ` Brian F. G. Bidulock
2006-06-01 6:12 ` Evgeniy Polyakov
2006-06-01 6:18 ` David Miller
2006-06-01 6:22 ` Brian F. G. Bidulock
2006-06-01 6:24 ` David Miller
2006-05-31 18:41 ` David Miller
2006-06-01 6:04 ` Evgeniy Polyakov
2006-06-01 6:18 ` Brian F. G. Bidulock
2006-06-01 6:30 ` Evgeniy Polyakov
2006-06-01 6:46 ` Brian F. G. Bidulock
2006-06-01 7:01 ` Evgeniy Polyakov
2006-06-01 7:11 ` Brian F. G. Bidulock
2006-06-01 8:38 ` Evgeniy Polyakov
2006-06-01 10:24 ` Brian F. G. Bidulock
2006-06-01 11:06 ` Evgeniy Polyakov
2006-06-01 18:40 ` Brian F. G. Bidulock
2006-06-01 20:21 ` David Miller
2006-06-02 7:01 ` Evgeniy Polyakov
2006-06-02 5:40 ` Florian Weimer
2006-06-02 7:48 ` Evgeniy Polyakov
2006-06-02 15:10 ` Brian F. G. Bidulock
2006-06-02 17:26 ` Florian Weimer
2006-06-02 17:37 ` Brian F. G. Bidulock
2006-05-31 9:52 ` Brian F. G. Bidulock
2006-05-31 8:49 ` Brian F. G. Bidulock
2006-05-31 9:02 ` David Miller
2006-05-31 9:39 ` Brian F. G. Bidulock
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20060531.021243.122061524.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=draghuram@rocketmail.com \
--cc=johnpol@2ka.mipt.ru \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®