lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu, 25 Feb 2010 16:11:49 -0300
From:	Reinaldo de Carvalho <reinaldoc@...il.com>
To:	hadi@...erus.ca
Cc:	Andrew Morton <akpm@...ux-foundation.org>, netdev@...r.kernel.org,
	bugzilla-daemon@...zilla.kernel.org,
	bugme-daemon@...zilla.kernel.org
Subject: Re: [Bugme-new] [Bug 15379] New: u32 classifier port range 
	calculation error

On Thu, Feb 25, 2010 at 10:24 AM, jamal <hadi@...erus.ca> wrote:
> On Thu, 2010-02-25 at 08:25 -0300, Reinaldo de Carvalho wrote:
>> Then u32 mask is useless. Or exist a correct mask to match with especific range?
>
> Ranges and masks typically dont mix well generally - this has nothing to
> do with u32; try doing subnet ranges for example. It is hard to describe
> port range 10->20 using masks..
>
> If i read your email correctly: you are trying to get the first 32 ports
> after 6880. It would seem to me the mask should be 0xFFE0, no? i.e your
> bc calculation should be:
> echo "obase=16;(2^16)-32" | bc
>

No.

Testing with mask 0xFFE0... (1 port match)

# Stats...
# tc -s filter show dev eth0
filter parent 1: protocol ip pref 1 u32
filter parent 1: protocol ip pref 1 u32 fh 800: ht divisor 1
filter parent 1: protocol ip pref 1 u32 fh 800::800 order 2048 key ht
800 bkt 0 flowid 1:1200  (rule hit 13 success 0)
  match 00001ae0/0000ffe0 at 20 (success 0 )

# Sending packets...
# nmap example.ufpa.br -p 1-65535

# Stats...
# tc -s filter show dev eth0
filter parent 1: protocol ip pref 1 u32
filter parent 1: protocol ip pref 1 u32 fh 800: ht divisor 1
filter parent 1: protocol ip pref 1 u32 fh 800::800 order 2048 key ht
800 bkt 0 flowid 1:1200  (rule hit 65459 success 1)
  match 00001ae0/0000ffe0 at 20 (success 1 )




-- 
Reinaldo de Carvalho
http://korreio.sf.net
http://python-cyrus.sf.net

"Don't try to adapt the software to the way you work, but rather
yourself to the way the software works" (myself)
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ