dazuko_freebsd.h

Go to the documentation of this file.
00001 /* Dazuko FreeBSD. Allow FreeBSD file access control for 3rd-party applications.
00002    Written by John Ogness <jogness@antivir.de>
00003 
00004    Copyright (c) 2003, 2004 H+BEDV Datentechnik GmbH
00005    All rights reserved.
00006 
00007    Redistribution and use in source and binary forms, with or without
00008    modification, are permitted provided that the following conditions
00009    are met:
00010 
00011    1. Redistributions of source code must retain the above copyright notice,
00012    this list of conditions and the following disclaimer.
00013 
00014    2. Redistributions in binary form must reproduce the above copyright notice,
00015    this list of conditions and the following disclaimer in the documentation
00016    and/or other materials provided with the distribution.
00017 
00018    3. Neither the name of Dazuko nor the names of its contributors may be used
00019    to endorse or promote products derived from this software without specific
00020    prior written permission.
00021 
00022    THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
00023    AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
00024    IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
00025    ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
00026    LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
00027    CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
00028    SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
00029    INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
00030    CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
00031    ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
00032    POSSIBILITY OF SUCH DAMAGE.
00033 */
00034 
00035 #ifndef DAZUKO_FREEBSD_H
00036 #define DAZUKO_FREEBSD_H
00037 
00038 #include <sys/param.h>
00039 #include <sys/libkern.h>
00040 #include <sys/lock.h>
00041 #include <machine/stdarg.h>
00042 
00043 
00044 #define inline          __inline
00045 #define DEVICE_NAME     "dazuko"
00046 
00047 #define XP_ERROR_PERMISSION     EPERM;
00048 #define XP_ERROR_INTERRUPT      EINTR;
00049 #define XP_ERROR_BUSY           EBUSY;
00050 #define XP_ERROR_FAULT          EFAULT;
00051 #define XP_ERROR_INVALID        EINVAL;
00052 
00053 
00054 struct xp_daemon_id
00055 {
00056         int     pid;
00057 };
00058 
00059 struct xp_file
00060 {
00061         struct file     *file;
00062 };
00063 
00064 struct xp_mutex
00065 {
00066         struct simplelock       lock;
00067 };
00068 
00069 struct xp_atomic
00070 {
00071         int     value;
00072 };
00073 
00074 struct xp_file_struct
00075 {
00076         const char      *user_filename;
00077         struct proc     *p;
00078 };
00079 
00080 struct xp_queue
00081 {
00082         char    c;
00083 };
00084 
00085 struct xp_rwlock
00086 {
00087         struct lock     lock;
00088 };
00089 
00090 #endif

Generated on Fri Jun 17 09:45:19 2005 for RSBAC by  doxygen 1.4.2