{"id":2817,"date":"2022-12-20T15:17:23","date_gmt":"2022-12-20T18:17:23","guid":{"rendered":"http:\/\/lode.uno\/linux-man\/index.php\/2022\/12\/20\/restorecon_xattr-man8\/"},"modified":"2022-12-20T15:17:23","modified_gmt":"2022-12-20T18:17:23","slug":"restorecon_xattr-man8","status":"publish","type":"post","link":"https:\/\/lode.uno\/linux-man\/2022\/12\/20\/restorecon_xattr-man8\/","title":{"rendered":"restorecon_xattr (man8)"},"content":{"rendered":"<h1 align=\"center\">restorecon_xattr<\/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=\"#ARGUMENTS\">ARGUMENTS<\/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\">restorecon_xattr \u2212 manage <i>security.sehash<\/i> extended attribute entries added by <b>setfiles<\/b>(8) or <b>restorecon<\/b>(8).<\/p>\n<h2>SYNOPSIS <a name=\"SYNOPSIS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>restorecon_xattr<\/b> [<b>\u2212d<\/b>] [<b>\u2212D<\/b>] [<b>\u2212m<\/b>] [<b>\u2212n<\/b>] [<b>\u2212r<\/b>] [<b>\u2212v<\/b>] [<b>\u2212e<\/b> <i>directory<\/i>] [<b>\u2212f<\/b> <i>specfile<\/i>] <i>pathname<\/i><\/p>\n<h2>DESCRIPTION <a name=\"DESCRIPTION\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><i><b>restorecon_xattr<\/b><\/i> will display the SHA1 digests added to extended attributes <i>security.sehash<\/i> or delete the attribute completely. These attributes are set by <b>restorecon<\/b>(8) or <b>setfiles<\/b>(8) to specified directories when relabeling recursively.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>restorecon_xattr<\/b> is useful for managing the extended attribute entries particularly when users forget what directories they ran <b>restorecon<\/b>(8) or <b>setfiles<\/b>(8) from.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>RAMFS<\/b> and <b>TMPFS<\/b> filesystems do not support the <i>security.sehash<\/i> extended attribute and are automatically excluded from searches.<\/p>\n<p style=\"margin-left:11%; margin-top: 1em\">By default <b>restorecon_xattr<\/b> will display the SHA1 digests with &#8220;Match&#8221; appended if they match the default specfile set or the <i>specfile<\/i> set used with the <b>\u2212f<\/b> option. Non-matching SHA1 digests will be displayed with &#8220;No Match&#8221; appended. This feature can be disabled by the <b>\u2212n<\/b> option.<\/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>\u2212d<\/b><\/p>\n<\/td>\n<td width=\"8%\"><\/td>\n<td width=\"78%\">\n<p style=\"margin-top: 1em\">delete all non-matching <i>security.sehash<\/i> directory digest entries.<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"3%\">\n<p><b>\u2212D<\/b><\/p>\n<\/td>\n<td width=\"8%\"><\/td>\n<td width=\"78%\">\n<p>delete all <i>security.sehash<\/i> directory digest entries.<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"3%\">\n<p><b>\u2212m<\/b><\/p>\n<\/td>\n<td width=\"8%\"><\/td>\n<td width=\"78%\">\n<p>do not read <b>\/proc\/mounts<\/b> to obtain a list of non-seclabel mounts to be excluded from relabeling checks.<\/p>\n<\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:22%;\">Setting <b>\u2212m<\/b> is useful where there is a non-seclabel fs mounted with a seclabel fs mounted on a directory below this.<\/p>\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>\u2212n<\/b><\/p>\n<\/td>\n<td width=\"8%\"><\/td>\n<td width=\"78%\">\n<p style=\"margin-top: 1em\">Do not append &#8220;Match&#8221; or &#8220;No Match&#8221; to displayed digests.<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"3%\">\n<p><b>\u2212r<\/b><\/p>\n<\/td>\n<td width=\"8%\"><\/td>\n<td width=\"78%\">\n<p>recursively descend directories.<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"3%\">\n<p><b>\u2212v<\/b><\/p>\n<\/td>\n<td width=\"8%\"><\/td>\n<td width=\"78%\">\n<p>display SHA1 digest generated by specfile set (Note that this digest is not used to match the <i>security.sehash<\/i> directory digest entries, and is shown for reference only).<\/p>\n<\/td>\n<\/tr>\n<tr valign=\"top\" align=\"left\">\n<td width=\"11%\"><\/td>\n<td width=\"3%\">\n<p><b>\u2212e<\/b><\/p>\n<\/td>\n<td width=\"8%\"><\/td>\n<td width=\"78%\">\n<p><i>directory<\/i><\/p>\n<\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:22%;\">directory to exclude (repeat option for more than one directory).<\/p>\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>\u2212f<\/b><\/p>\n<\/td>\n<td width=\"8%\"><\/td>\n<td width=\"12%\">\n<p style=\"margin-top: 1em\"><i>specfile<\/i><\/p>\n<\/td>\n<td width=\"66%\"> <\/td>\n<\/tr>\n<\/table>\n<p style=\"margin-left:22%;\">an optional <i>specfile<\/i> containing file context entries as described in <b>file_contexts<\/b>(5). If the option is not specified, then the default file_contexts will be used.<\/p>\n<h2>ARGUMENTS <a name=\"ARGUMENTS\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><i>pathname<\/i><\/p>\n<p style=\"margin-left:22%;\">the pathname of the directory tree to be searched.<\/p>\n<h2>SEE ALSO <a name=\"SEE ALSO\"><\/a> <\/h2>\n<p style=\"margin-left:11%; margin-top: 1em\"><b>restorecon<\/b>(8), <b>setfiles<\/b>(8)<\/p>\n<hr>\n","protected":false},"excerpt":{"rendered":"<p>  restorecon_xattr \u2212 manage security.sehash extended attribute entries added by setfiles(8) or restorecon(8). <\/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,169],"class_list":["post-2817","post","type-post","status-publish","format-standard","hentry","category-8-administracion-del-sistema","tag-5","tag-administracion","tag-man8","tag-restorecon_xattr"],"gutentor_comment":0,"_links":{"self":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/2817","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=2817"}],"version-history":[{"count":0,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/posts\/2817\/revisions"}],"wp:attachment":[{"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/media?parent=2817"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/categories?post=2817"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/lode.uno\/linux-man\/wp-json\/wp\/v2\/tags?post=2817"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}