Home | History | Annotate | Download | only in policydb
      1 /* Authors: Jason Tang <jtang (at) tresys.com>
      2  *
      3  * Copyright (C) 2005 Tresys Technology, LLC
      4  *
      5  *  This library is free software; you can redistribute it and/or
      6  *  modify it under the terms of the GNU Lesser General Public
      7  *  License as published by the Free Software Foundation; either
      8  *  version 2.1 of the License, or (at your option) any later version.
      9  *
     10  *  This library is distributed in the hope that it will be useful,
     11  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
     12  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
     13  *  Lesser General Public License for more details.
     14  *
     15  *  You should have received a copy of the GNU Lesser General Public
     16  *  License along with this library; if not, write to the Free Software
     17  *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
     18  */
     19 
     20 #ifndef _SEPOL_AVRULE_BLOCK_H_
     21 #define _SEPOL_AVRULE_BLOCK_H_
     22 
     23 #include <sepol/policydb/policydb.h>
     24 
     25 extern avrule_block_t *avrule_block_create(void);
     26 extern void avrule_block_destroy(avrule_block_t * x);
     27 extern avrule_decl_t *avrule_decl_create(uint32_t decl_id);
     28 extern void avrule_decl_destroy(avrule_decl_t * x);
     29 extern void avrule_block_list_destroy(avrule_block_t * x);
     30 extern avrule_decl_t *get_avrule_decl(policydb_t * p, uint32_t decl_id);
     31 extern cond_list_t *get_decl_cond_list(policydb_t * p,
     32 				       avrule_decl_t * decl,
     33 				       cond_list_t * cond);
     34 extern int is_id_enabled(char *id, policydb_t * p, int symbol_table);
     35 extern int is_perm_enabled(char *class_id, char *perm_id, policydb_t * p);
     36 
     37 #endif
     38