资源简介
barnyard2-1.9.tar.gz
代码片段和文件信息
/* $Id$ */
/*
** Copyright (C) 2002-2009 Sourcefire Inc.
** Copyright (C) 1998-2002 Martin Roesch
**
** This program is free software; you can redistribute it and/or modify
** it under the terms of the GNU General Public License Version 2 as
** published by the Free Software Foundation. You may not use modify or
** distribute this program under any other version of the GNU General
** Public License.
**
** This program is distributed in the hope that it will be useful
** but WITHOUT ANY WARRANTY; without even the implied warranty of
** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
** GNU General Public License for more details.
**
** You should have received a copy of the GNU General Public License
** along with this program; if not write to the Free Software
** Foundation Inc. 59 Temple Place - Suite 330 Boston MA 02111-1307 USA.
*/
/*
*
* Program: Snort
*
* Purpose: Check out the README file for info on what you can do
* with Snort.
*
* Author: Martin Roesch (roesch@clark.net)
*
* Comments: Ideas and code stolen liberally from Mike Borella‘s IP Grab
* program. Check out his stuff at http://www.borella.net. I
* also have ripped some util functions from TCPdump plus Mike‘s
* prog is derived from it as well. All hail TCPdump....
*
*/
#ifdef HAVE_CONFIG_H
# include “config.h“
#endif
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#ifndef WIN32
#include
#endif
#ifdef HAVE_GETOPT_LONG
//#define _GNU_SOURCE
/* A GPL copy of getopt & getopt_long src code is now in sfutil */
# undef HAVE_GETOPT_LONG
#endif
#include
#ifdef TIMESTATS
# include /* added for new time stats function in util.c */
#endif
#ifdef HAVE_STRINGS_H
# include
#endif
#ifndef WIN32
# include
# include
# include
# include
# include
#endif /* !WIN32 */
#if !defined(CATCH_SEGV) && !defined(WIN32)
# include
#endif
#include “decode.h“
#include “barnyard2.h“
#include “rules.h“
#include “plugbase.h“
#include “debug.h“
#include “util.h“
#include “parser.h“
#include “log.h“
#include “map.h“
#include “mstring.h“
#include “strlcpyu.h“
#include “output-plugins/spo_log_tcpdump.h“
#ifdef HAVE_LIBPRELUDE
# include “output-plugins/spo_alert_prelude.h“
#endif
/* Macros *********************************************************************/
#ifndef DLT_LANE8023
/*
* Old OPEN BSD Log format is 17.
* Define DLT_OLDPFLOG unless DLT_LANE8023 (Suse 6.3) is already
* defined in bpf.h.
*/
# define DLT_OLDPFLOG 17
#endif
/* Data types *****************************************************************/
typedef enum _GetOptArgType
{
LONGOPT_ARG_NONE = 0
- 上一篇:操作系统实验--进程调度 作业调度 内存分配 文件系统
- 下一篇:呼吸灯源程序
评论
共有 条评论