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]
Message-Id: <20111220.151809.1704705119739851376.davem@davemloft.net>
Date:	Tue, 20 Dec 2011 15:18:09 -0500 (EST)
From:	David Miller <davem@...emloft.net>
To:	subramanian.vijay@...il.com
Cc:	David.Laight@...lab.com, netdev@...r.kernel.org,
	eric.dumazet@...il.com, ilpo.jarvinen@...sinki.fi, hkchu@...gle.com
Subject: Re: [PATCH 1/1] tcp: Replace constants with #define macros

From: Vijay Subramanian <subramanian.vijay@...il.com>
Date: Tue, 20 Dec 2011 12:02:52 -0800

> I assume you are talking about collision with userspace.  These
> definitions are already protected by #ifdef  __KERNEL__.
> That should be enough to protect against collisions with userspace I think.

Within the kernel he means, please put a TCP_* prefix onto these
values.

>>
>>> -     tcp_opt->sack_ok = (options >> 4) & 0x1;
>>> +     tcp_opt->sack_ok = (options >> 4) & SACK_SEEN;
>>
>> Looks to me like that 0x1 isn't SAC_SEEK! So this is now misleading.
> 
> Can you please elaborate? Are you saying this is wrong or that it
> could be done better?

I think he's saying it could be done better.  Probably something
like:

	tcp_opt->sack_ok = (options & (1 << 4)) ? SACK_SEEN : 0;
--
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