[4595] in bugtraq

home help back first fref pref prev next nref lref last post

Linux and SIOCSIFHWADDR

daemon@ATHENA.MIT.EDU (Alan Cox)
Tue May 27 18:28:08 1997

Date: 	Tue, 27 May 1997 18:31:23 +0100
Reply-To: Alan Cox <alan@DIAMONDAGE.CYMRU.NET>
From: Alan Cox <alan@DIAMONDAGE.CYMRU.NET>
X-To:         bugtraq@crimelab.com
To: BUGTRAQ@NETSPACE.ORG

The following patch should nicely fix the problem allowing all users to
reconfigure downed interfaces mac addresses. Fortunately most setups
make this very hard to attack. The patch is v 2.0.30 but should apply
cleanly to all 2.0.x kernels and most 1.3 kernels. 1.2 also has this
problem. The patch won't apply directly but the change is identical.

--- net/core/dev.c~     Tue Apr  8 16:47:47 1997
+++ net/core/dev.c      Tue May 27 18:16:03 1997
@@ -1427,7 +1427,6 @@
                case SIOCGIFMTU:
                case SIOCGIFMEM:
                case SIOCGIFHWADDR:
-               case SIOCSIFHWADDR:
                case SIOCGIFSLAVE:
                case SIOCGIFMAP:
                        return dev_ifsioc(arg, cmd);
@@ -1444,6 +1443,7 @@
                case SIOCSIFMETRIC:
                case SIOCSIFMTU:
                case SIOCSIFMEM:
+               case SIOCSIFHWADDR:
                case SIOCSIFMAP:
                case SIOCSIFSLAVE:
                case SIOCADDMULTI:

Alan

home help back first fref pref prev next nref lref last post