From 1cbd1554d2b8673d64f4f3836e5ae350ade9b89a Mon Sep 17 00:00:00 2001 From: Aaron Campbell Date: Sun, 18 Jun 2000 03:56:08 +0000 Subject: Thou shalt not bequeath to mere mortals the ability to change the configuration of an Aironet device. --- sys/dev/ic/an.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'sys/dev/ic/an.c') diff --git a/sys/dev/ic/an.c b/sys/dev/ic/an.c index 7a24e2d0c94..cc96358e5b9 100644 --- a/sys/dev/ic/an.c +++ b/sys/dev/ic/an.c @@ -1,4 +1,4 @@ -/* $OpenBSD: an.c,v 1.3 2000/06/18 03:26:51 aaron Exp $ */ +/* $OpenBSD: an.c,v 1.4 2000/06/18 03:56:07 aaron Exp $ */ /* * Copyright (c) 1997, 1998, 1999 @@ -97,6 +97,7 @@ #include #include #include +#include #include #include #ifdef ANCACHE @@ -879,6 +880,7 @@ int an_ioctl(ifp, command, data) struct an_softc *sc; struct an_req areq; struct ifreq *ifr; + struct proc *p = curproc; struct ifaddr *ifa = (struct ifaddr *)data; s = splimp(); @@ -960,6 +962,9 @@ int an_ioctl(ifp, command, data) error = copyout(&areq, ifr->ifr_data, sizeof(areq)); break; case SIOCSAIRONET: + error = suser(p->p_ucred, &p->p_acflag); + if (error) + break; error = copyin(ifr->ifr_data, &areq, sizeof(areq)); if (error) break; -- cgit v1.2.3