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, 15 Aug 2013 13:51:02 -0700 (PDT)
From:	David Miller <davem@...emloft.net>
To:	ffusco@...hat.com
Cc:	netdev@...r.kernel.org
Subject: Re: [PATCH net-next 1/2] ipv4: IP_TOS and IP_TTL can be specified
 as ancillary data

From: Francesco Fusco <ffusco@...hat.com>
Date: Wed, 14 Aug 2013 17:48:38 +0200

> +	__s16			ttl;
> +	__s16			tos;

You're range validating these values to make sure they are always
between 1 and 255, inclusive.

Why use a 16-bit value, and in particular a signed one?  That makes
absolutely no sense at all.

These fit perfectly in a "u8" so use that instead.
--
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