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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 16 Feb 2011 13:51:33 +0100
From:	richard -rw- weinberger <richard.weinberger@...il.com>
To:	Phil Karn <karn@...q.net>
Cc:	kaber@...sh.net, netdev@...r.kernel.org
Subject: Re: Off-by-one error in net/8021q/vlan.c

On Wed, Feb 16, 2011 at 11:58 AM, Phil Karn <karn@...q.net> wrote:
> The range check on vlan_id in register_vlan_device is off by one, and it
> prevents the creation of a vlan interface for vlan ID 4095. (OSX allows
> this, I checked.)

Then OSX should fix their code. 4095 is reserved.

//richard

> Here's the trivial patch:
>
> --- linux-2.6.37/net/8021q/vlan.c~      2011-01-04 16:50:19.000000000 -0800
> +++ linux-2.6.37/net/8021q/vlan.c       2011-02-16 02:43:13.988812958 -0800
> @@ -239,7 +239,7 @@
>        char name[IFNAMSIZ];
>        int err;
>
> -       if (vlan_id >= VLAN_VID_MASK)
> +       if (vlan_id > VLAN_VID_MASK)
>                return -ERANGE;
>
>        err = vlan_check_real_dev(real_dev, vlan_id);
> --
> 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
>



-- 
Thanks,
//richard
--
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