{"id":5593,"date":"2019-11-25T18:06:39","date_gmt":"2019-11-25T10:06:39","guid":{"rendered":"https:\/\/www.linuxcool.com\/?p=5593"},"modified":"2019-11-25T18:06:40","modified_gmt":"2019-11-25T10:06:40","slug":"sesearch","status":"publish","type":"post","link":"https:\/\/www.linuxcool.com\/sesearch","title":{"rendered":"sesearch\u547d\u4ee4 – \u67e5\u770bSElinux\u7b56\u7565"},"content":{"rendered":"\n

\u4f7f\u7528seinfo\u547d\u4ee4\u53ef\u4ee5\u67e5\u8be2SELinux\u7684\u7b56\u7565\u63d0\u4f9b\u591a\u5c11\u76f8\u5173\u89c4\u5219\uff0c\u5982\u679c\u67e5\u5230\u7684\u76f8\u5173\u7c7b\u578b\u6216\u8005\u5e03\u5c14\u503c\uff0c\u60f3\u8981\u77e5\u9053\u8be6\u7ec6\u89c4\u5219\u65f6\uff0c\u4f7f\u7528sesearch\u547d\u4ee4\u67e5\u8be2\u3002<\/p>\n\n\n\n

\u8bed\u6cd5\u683c\u5f0f\uff1a<\/strong> sesearch [\u53c2\u6570] <\/p>\n\n\n\n

\u5e38\u7528\u53c2\u6570\uff1a<\/strong> <\/p>\n\n\n\n

-a<\/td>\u5217\u51fa\u8be5\u7c7b\u578b\u6216\u5e03\u5c14\u503c\u7684\u6240\u6709\u76f8\u5173\u4fe1\u606f<\/td><\/tr>
-t<\/td>\u540e\u9762\u8fd8\u8981\u63a5\u7c7b\u578b\uff0c\u4f8b\u5982 -t httpd_t<\/td><\/tr>
-b<\/td>\u540e\u9762\u8fd8\u8981\u63a5\u5e03\u5c14\u503c\u7684\u89c4\u5219\uff0c\u4f8b\u5982 -b httpd_enable_ftp_server<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n

\u53c2\u8003\u5b9e\u4f8b<\/strong> <\/p>\n\n\n\n

\u627e\u51fa\u76ee\u6807\u6587\u4ef6\u8d44\u6e90\u7c7b\u578b\u4e3ahttpd_sys_content_t\u7684\u6709\u5173\u4fe1\u606f\uff1a<\/p>\n\n\n\n

[root@linuxcool ~]# sesearch -a -t httpd_sys_content_t<\/pre>\n\n\n\n

\u627e\u51fa\u4e3b\u4f53\u8fdb\u7a0b\u4e3ahttpd_t\u4e14\u76ee\u6807\u6587\u4ef6\u7c7b\u578b\u4e3ahttpd\u76f8\u5173\u7684\u6240\u6709\u4fe1\u606f\uff1a<\/p>\n\n\n\n

[root@linuxcool ~]# sesearch -s httpd_t -t httpd_* -a <\/pre>\n\n\n\n

\u67e5\u770b\u5e03\u5c14\u503chttpd_enable_homedirs\u8bbe\u7f6e\u4e86\u591a\u5c11\u89c4\u5219:<\/p>\n\n\n\n

[root@linuxcool ~]# sesearch -b httpd_enable_homedirs -a <\/pre>\n","protected":false},"excerpt":{"rendered":"

\u4f7f\u7528seinfo\u547d\u4ee4\u53ef\u4ee5\u67e5\u8be2SELinux\u7684\u7b56\u7565\u63d0\u4f9b\u591a\u5c11\u76f8\u5173\u89c4\u5219\uff0c\u5982\u679c\u67e5\u5230\u7684\u76f8\u5173\u7c7b\u578b\u6216\u8005\u5e03\u5c14\u503c\uff0c\u60f3\u8981\u77e5\u9053\u8be6\u7ec6\u89c4 […]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":[],"categories":[7],"tags":[],"_links":{"self":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/5593"}],"collection":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/comments?post=5593"}],"version-history":[{"count":2,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/5593\/revisions"}],"predecessor-version":[{"id":5633,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/posts\/5593\/revisions\/5633"}],"wp:attachment":[{"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/media?parent=5593"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/categories?post=5593"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.linuxcool.com\/wp-json\/wp\/v2\/tags?post=5593"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}