mount /proc with hidepid=2 option

This commit is contained in:
Alexander Miroshnichenko 2019-07-15 16:28:07 +03:00
parent 97c2b4f598
commit bb6cf384f7
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