auditreduce.h revision 293161
1117397Skan/*- 2117397Skan * Copyright (c) 2004 Apple Inc. 3169691Skan * All rights reserved. 4117397Skan * 5117397Skan * Redistribution and use in source and binary forms, with or without 6117397Skan * modification, are permitted provided that the following conditions 7117397Skan * are met: 8117397Skan * 1. Redistributions of source code must retain the above copyright 9117397Skan * notice, this list of conditions and the following disclaimer. 10117397Skan * 2. Redistributions in binary form must reproduce the above copyright 11117397Skan * notice, this list of conditions and the following disclaimer in the 12117397Skan * documentation and/or other materials provided with the distribution. 13117397Skan * 3. Neither the name of Apple Inc. ("Apple") nor the names of 14117397Skan * its contributors may be used to endorse or promote products derived 15117397Skan * from this software without specific prior written permission. 16117397Skan * 17117397Skan * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND 18169691Skan * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 19117397Skan * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 20117397Skan * ARE DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR 21117397Skan * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22117397Skan * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 23117397Skan * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24117397Skan * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 25117397Skan * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING 26117397Skan * IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 27117397Skan * POSSIBILITY OF SUCH DAMAGE. 28117397Skan */ 29117397Skan 30169691Skan#ifndef _AUDITREDUCE_H_ 31169691Skan#define _AUDITREDUCE_H_ 32169691Skan 33169691Skan 34169691Skanstruct re_entry { 35117397Skan char *re_pattern; 36117397Skan int re_negate; 37117397Skan regex_t re_regexp; 38117397Skan TAILQ_ENTRY(re_entry) re_glue; 39117397Skan}; 40117397Skan 41117397Skan#define OPT_a 0x00000001 42169691Skan#define OPT_b 0x00000002 43169691Skan#define OPT_c 0x00000004 44117397Skan#define OPT_d (OPT_a | OPT_b) 45117397Skan#define OPT_e 0x00000010 46117397Skan#define OPT_f 0x00000020 47169691Skan#define OPT_g 0x00000040 48117397Skan#define OPT_j 0x00000080 49117397Skan#define OPT_m 0x00000100 50117397Skan#define OPT_of 0x00000200 51117397Skan#define OPT_om 0x00000400 52117397Skan#define OPT_op 0x00000800 53117397Skan#define OPT_ose 0x00001000 54117397Skan#define OPT_osh 0x00002000 55117397Skan#define OPT_oso 0x00004000 56117397Skan#define OPT_r 0x00008000 57117397Skan#define OPT_u 0x00010000 58117397Skan#define OPT_A 0x00020000 59117397Skan#define OPT_v 0x00040000 60117397Skan 61117397Skan#define FILEOBJ "file" 62169691Skan#define MSGQIDOBJ "msgqid" 63169691Skan#define PIDOBJ "pid" 64117397Skan#define SEMIDOBJ "semid" 65117397Skan#define SHMIDOBJ "shmid" 66117397Skan#define SOCKOBJ "sock" 67117397Skan 68117397Skan 69117397Skan#define SETOPT(optmask, bit) (optmask |= bit) 70117397Skan#define ISOPTSET(optmask, bit) (optmask & bit) 71117397Skan 72169691Skan 73169691Skan#endif /* !_AUDITREDUCE_H_ */ 74117397Skan