1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-04-29 23:24:55 +02:00
tldr/pages/linux/matchpathcon.md
cyqsimon 2f3a08f8c0
matchpathcon, secon: add page (#12841)
* matchpathcon: add page

* secon: add page

* Explicitly state "absolute path"

Co-authored-by: Juri Dispan <juri.dispan@posteo.net>

---------

Co-authored-by: Juri Dispan <juri.dispan@posteo.net>
2024-05-27 20:00:22 +08:00

17 lines
578 B
Markdown

# matchpathcon
> Lookup the persistent SELinux security context setting of a path.
> See also: `semanage-fcontext`, `secon`, `chcon`, `restorecon`.
> More information: <https://manned.org/man/matchpathcon.8>.
- Lookup the persistent security context setting of an absolute path:
`matchpathcon {{/path/to/file}}`
- Restrict lookup to settings on a specific file type:
`matchpathcon -m {{file|dir|pipe|chr_file|blk_file|lnk_file|sock_file}} {{/path/to/file}}`
- [V]erify that the persistent and current security context of a path agree:
`matchpathcon -V {{/path/to/file}}`