ip_fil.c (33f2fefd) | ip_fil.c (af5f29dd) |
---|---|
1/* 2 * Copyright (C) 1993-2001, 2003 by Darren Reed. 3 * 4 * See the IPFILTER.LICENCE file for details on licencing. 5 * 6 * Copyright 2009 Sun Microsystems, Inc. All rights reserved. 7 * Use is subject to license terms. 8 */ 9 | 1/* 2 * Copyright (C) 1993-2001, 2003 by Darren Reed. 3 * 4 * See the IPFILTER.LICENCE file for details on licencing. 5 * 6 * Copyright 2009 Sun Microsystems, Inc. All rights reserved. 7 * Use is subject to license terms. 8 */ 9 |
10#if !defined(lint) 11static const char sccsid[] = "@(#)ip_fil.c 2.41 6/5/96 (C) 1993-2000 Darren Reed"; 12static const char rcsid[] = "@(#)$Id: ip_fil.c,v 2.133.2.9 2005/01/08 14:22:18 darrenr Exp $"; 13#endif 14 | |
15#ifndef SOLARIS 16#define SOLARIS (defined(sun) && (defined(__svr4__) || defined(__SVR4))) 17#endif 18 19#include <sys/param.h> 20#if defined(__FreeBSD__) && !defined(__FreeBSD_version) 21# if defined(IPFILTER_LKM) 22# ifndef __FreeBSD_cc_version --- 19 unchanged lines hidden (view full) --- 42#undef _KERNEL 43#undef KERNEL 44#include <sys/file.h> 45#include <sys/ioctl.h> 46#ifdef __sgi 47# include <sys/ptimers.h> 48#endif 49#include <sys/time.h> | 10#ifndef SOLARIS 11#define SOLARIS (defined(sun) && (defined(__svr4__) || defined(__SVR4))) 12#endif 13 14#include <sys/param.h> 15#if defined(__FreeBSD__) && !defined(__FreeBSD_version) 16# if defined(IPFILTER_LKM) 17# ifndef __FreeBSD_cc_version --- 19 unchanged lines hidden (view full) --- 37#undef _KERNEL 38#undef KERNEL 39#include <sys/file.h> 40#include <sys/ioctl.h> 41#ifdef __sgi 42# include <sys/ptimers.h> 43#endif 44#include <sys/time.h> |
50#if !SOLARIS | 45#if !defined(SOLARIS) |
51# if (NetBSD > 199609) || (OpenBSD > 199603) || (__FreeBSD_version >= 300000) 52# include <sys/dirent.h> 53# else 54# include <sys/dir.h> 55# endif 56#else 57# include <sys/filio.h> 58#endif --- 255 unchanged lines hidden (view full) --- 314 error = ipldetach(ifs); 315 } 316 break; 317 case SIOCIPFSET : 318 if (!(mode & FWRITE)) { 319 error = EPERM; 320 break; 321 } | 46# if (NetBSD > 199609) || (OpenBSD > 199603) || (__FreeBSD_version >= 300000) 47# include <sys/dirent.h> 48# else 49# include <sys/dir.h> 50# endif 51#else 52# include <sys/filio.h> 53#endif --- 255 unchanged lines hidden (view full) --- 309 error = ipldetach(ifs); 310 } 311 break; 312 case SIOCIPFSET : 313 if (!(mode & FWRITE)) { 314 error = EPERM; 315 break; 316 } |
317 /* FALLTHROUGH */ |
|
322 case SIOCIPFGETNEXT : 323 case SIOCIPFGET : 324 error = fr_ipftune(cmd, (void *)data, ifs); 325 break; 326 case SIOCSETFF : 327 if (!(mode & FWRITE)) 328 error = EPERM; 329 else --- 742 unchanged lines hidden --- | 318 case SIOCIPFGETNEXT : 319 case SIOCIPFGET : 320 error = fr_ipftune(cmd, (void *)data, ifs); 321 break; 322 case SIOCSETFF : 323 if (!(mode & FWRITE)) 324 error = EPERM; 325 else --- 742 unchanged lines hidden --- |