handle.h 976 B

12345678910111213141516171819202122232425262728
  1. #ifndef _SEPOL_HANDLE_H_
  2. #define _SEPOL_HANDLE_H_
  3. struct sepol_handle;
  4. typedef struct sepol_handle sepol_handle_t;
  5. /* Create and return a sepol handle. */
  6. sepol_handle_t *sepol_handle_create(void);
  7. /* Get whether or not dontaudits will be disabled, same values as
  8. * specified by set_disable_dontaudit. This value reflects the state
  9. * your system will be set to upon commit, not necessarily its
  10. * current state.*/
  11. int sepol_get_disable_dontaudit(sepol_handle_t * sh);
  12. /* Set whether or not to disable dontaudits, 0 is default and does
  13. * not disable dontaudits, 1 disables them */
  14. void sepol_set_disable_dontaudit(sepol_handle_t * sh, int disable_dontaudit);
  15. /* Set whether module_expand() should consume the base policy passed in.
  16. * This should reduce the amount of memory required to expand the policy. */
  17. void sepol_set_expand_consume_base(sepol_handle_t * sh, int consume_base);
  18. /* Destroy a sepol handle. */
  19. void sepol_handle_destroy(sepol_handle_t *);
  20. #endif