mount /proc with hidepid=2 option

This commit is contained in:
Alexander Miroshnichenko 2019-07-15 16:28:07 +03:00
parent 217b4cfc06
commit 43bd01a374
No known key found for this signature in database
GPG Key ID: E93720C6C73A77F4
2 changed files with 28 additions and 0 deletions

27
sls/gentoo/hardening.sls Normal file
View File

@ -0,0 +1,27 @@
proc_view:
group.present:
- gid: 391
- system: True
{%- if salt['cmd.retcode']('id polkitd') == 0 %}
- addusers:
- polkitd
{%- endif %}
/proc:
mount.mounted:
- device: proc
- fstype: proc
- dump: 0
- pass_num: 0
- persist: True
- mkmnt: True
- opts:
- defaults
- nosuid
- nodev
- noexec
- relatime
- hidepid=2
- gid=391
- require:
- group: proc_view

View File

@ -4,4 +4,5 @@ include:
- gentoo.repos.gentoo
- gentoo.profile
- gentoo.makeconf
- gentoo.hardening