{"id":3435,"date":"2022-12-20T17:02:40","date_gmt":"2022-12-20T20:02:40","guid":{"rendered":"http:\/\/lode.uno\/linux-man\/index.php\/2022\/12\/20\/sefcontext_compile-man8\/"},"modified":"2022-12-20T17:02:40","modified_gmt":"2022-12-20T20:02:40","slug":"sefcontext_compile-man8","status":"publish","type":"post","link":"https:\/\/lode.uno\/linux-man\/2022\/12\/20\/sefcontext_compile-man8\/","title":{"rendered":"sefcontext_compile (man8)"},"content":{"rendered":"<h1 align=\"center\">sefcontext_compile<\/h1>\n<p> <a href=\"#NAME\">NAME<\/a><br \/> <a href=\"#SYNOPSIS\">SYNOPSIS<\/a><br \/> <a href=\"#DESCRIPTION\">DESCRIPTION<\/a><br \/> <a href=\"#OPTIONS\">OPTIONS<\/a><br \/> <a href=\"#RETURN VALUE\">RETURN VALUE<\/a><br \/> <a href=\"#EXAMPLES\">EXAMPLES<\/a><br \/> <a href=\"#AUTHOR\">AUTHOR<\/a><br \/> <a href=\"#SEE ALSO\">SEE ALSO<\/a> <\/p>\n<hr>\n<h2>NAME <a name=\"NAME\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">sefcontext_compile \u2212 compile file context regular expression files<\/p>\n<h2>SYNOPSIS <a name=\"SYNOPSIS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>sefcontext_compile<\/b> [<b>\u2212o<\/b> <i>outputfile<\/i>] [<b>\u2212p<\/b> <i>policyfile<\/i>] <i>inputfile<\/i><\/p>\n<h2>DESCRIPTION <a name=\"DESCRIPTION\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><i><b>sefcontext_compile<\/b><\/i> is used to compile file context regular expressions into <b>pcre<\/b>(3) format.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">The compiled file is used by libselinux file labeling functions.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">By default <b>sefcontext_compile<\/b> writes the compiled pcre file with the <b>.bin<\/b> suffix appended (e.g. <i>inputfile<\/i><b>.bin<\/b>).<\/p>\n<h2>OPTIONS <a name=\"OPTIONS\"><\/a> <\/h2>\n<table width=\"100%\" border=\"0\" rules=\"none\" frame=\"void\" cellspacing=\"0\" cellpadding=\"0\">\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"3%\">\n<p style=\"margin-top: 1em\"><b>\u2212o<\/b><\/p>\n<\/td>\n<td width=\"8%\"><\/td>\n<td width=\"78%\">\n<p style=\"margin-top: 1em\">Specify an <i>outputfile<\/i> that must be a fully qualified file name as the <b>.bin<\/b> suffix is not automatically added.<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"3%\">\n<p><b>\u2212p<\/b><\/p>\n<\/td>\n<td width=\"8%\"><\/td>\n<td width=\"78%\">\n<p>Specify a binary <i>policyfile<\/i> that will be used to validate the context entries in the <i>inputfile<\/i><\/p>\n<\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:22%;\">If an invalid context is found the pcre formatted file will not be written and an error will be returned.<\/p>\n<h2>RETURN VALUE <a name=\"RETURN VALUE\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">On error -1 is returned. On success 0 is returned.<\/p>\n<h2>EXAMPLES <a name=\"EXAMPLES\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>Example 1:<\/b> <br \/> sefcontext_compile \/etc\/selinux\/targeted\/contexts\/files\/file_contexts<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">Results in the following file being generated:<\/p>\n<p style=\"margin-left:22%;\">\/etc\/selinux\/targeted\/contexts\/files\/file_contexts.bin<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>Example 2:<\/b> <br \/> sefcontext_compile -o new_fc.bin \/etc\/selinux\/targeted\/contexts\/files\/file_contexts<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">Results in the following file being generated in the cwd:<\/p>\n<p style=\"margin-left:22%;\">new_fc.bin<\/p>\n<h2>AUTHOR <a name=\"AUTHOR\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\">Dan Walsh, <dwalsh@redhat.com><\/p>\n<h2>SEE ALSO <a name=\"SEE ALSO\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>selinux<\/b>(8), <b>semanage<\/b>(8),<\/p>\n<hr>\n","protected":false},"excerpt":{"rendered":"<p>  sefcontext_compile \u2212 compile file context regular expression files <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2],"tags":[5,52,4,561],"class_list":["post-3435","post","type-post","status-publish","format-standard","hentry","category-8-administracion-del-sistema","tag-5","tag-administracion","tag-man8","tag-sefcontext_compile"],"gutentor_comment":0,"_links":{"self":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/3435","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/comments?post=3435"}],"version-history":[{"count":0,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/3435\/revisions"}],"wp:attachment":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/media?parent=3435"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/categories?post=3435"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/tags?post=3435"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}