3
0

load_policy.c 557 B

12345678910111213141516171819202122232425262728
  1. /*
  2. * load_policy
  3. * Author: Yuichi Nakamura <ynakam@hitachisoft.jp>
  4. *
  5. * Licensed under GPLv2, see file LICENSE in this source tree.
  6. */
  7. //usage:#define load_policy_trivial_usage NOUSAGE_STR
  8. //usage:#define load_policy_full_usage ""
  9. #include "libbb.h"
  10. int load_policy_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
  11. int load_policy_main(int argc UNUSED_PARAM, char **argv UNUSED_PARAM)
  12. {
  13. int rc;
  14. if (argv[1]) {
  15. bb_show_usage();
  16. }
  17. rc = selinux_mkload_policy(1);
  18. if (rc < 0) {
  19. bb_perror_msg_and_die("can't load policy");
  20. }
  21. return 0;
  22. }