aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMikle KOlyada <zlogene@gentoo.org>2021-01-30 22:50:12 +0300
committerSam James <sam@gentoo.org>2021-01-31 21:37:17 +0000
commitfbbc2d49c860857b2fe4b2a6cdb967b0867261c9 (patch)
tree711190ce8801b3530414eb826de9d313fb709258 /templates
parentRevert "systemd-auth: add systemd-homed support" (diff)
downloadpambase-fbbc2d49c860857b2fe4b2a6cdb967b0867261c9.tar.gz
pambase-fbbc2d49c860857b2fe4b2a6cdb967b0867261c9.tar.bz2
pambase-fbbc2d49c860857b2fe4b2a6cdb967b0867261c9.zip
systemd-auth: add systemd-homed supportpambase-20210201
Signed-off-by: Mikle KOlyada <zlogene@gentoo.org> Closes: https://github.com/gentoo/pambase/pull/5 Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'templates')
-rw-r--r--templates/system-auth.tpl18
-rw-r--r--templates/system-session.tpl4
2 files changed, 20 insertions, 2 deletions
diff --git a/templates/system-auth.tpl b/templates/system-auth.tpl
index 01a29db..1adee05 100644
--- a/templates/system-auth.tpl
+++ b/templates/system-auth.tpl
@@ -8,16 +8,26 @@ auth [success=3 default=ignore] pam_krb5.so {{ krb5_params }}
{% endif %}
auth requisite pam_faillock.so preauth
-auth [success=1 default=ignore] pam_unix.so {{ nullok|default('', true) }} {{ debug|default('', true) }} try_first_pass
+{% if homed %}
+auth [success=2 default=ignore] pam_unix.so {{ nullok|default('', true) }} {{ debug|default('', true) }} try_first_pass
+auth [success=1 default=ignore] pam_systemd_home.so
+{% else %}
+auth [success=1 default=ignore] pam_unix.so {{ nullok|default('', true) }} {{ debug|default('', true) }} try_first_pas
+{% endif %}
auth [default=die] pam_faillock.so authfail
{% if caps %}
--auth optional pam_cap.so
+auth optional pam_cap.so
{% endif %}
{% if krb5 %}
account [success=2 default=ignore] pam_krb5.so {{ krb5_params }}
{% endif %}
+
+{% if homed %}
+account [success=1 default=ignore] pam_systemd_home.so
+{% endif %}
+
account required pam_unix.so {{ debug|default('', true) }}
account required pam_faillock.so
@@ -37,6 +47,10 @@ password required pam_pwhistory.so use_authtok remember=5 retry=3
password [success=1 default=ignore] pam_krb5.so {{ krb5_params }}
{% endif %}
+{% if homed %}
+password [success=1 default=ignore] pam_systemd_home.so
+{% endif %}
+
{% if passwdqc or pwquality %}
password required pam_unix.so try_first_pass {{ unix_authtok|default('', true) }} {{ nullok|default('', true) }} {{ unix_extended_encryption|default('', true) }} {{ debug|default('', true) }}
{% else %}
diff --git a/templates/system-session.tpl b/templates/system-session.tpl
index 2a7024b..536db49 100644
--- a/templates/system-session.tpl
+++ b/templates/system-session.tpl
@@ -8,4 +8,8 @@ session optional pam_mktemp.so
session [success=1 default=ignore] pam_krb5.so {{ krb5_params }}
{% endif %}
+{% if homed %}
+session [success=1 default=ignore] pam_systemd_home.so
+{% endif %}
+
session required pam_unix.so {{ debug|default('', true) }}