From ea51068f221e8afbb6ea1c6886f367ee486e2ab7 Mon Sep 17 00:00:00 2001 From: Alan Moore Date: Wed, 18 Dec 2024 17:03:50 +0000 Subject: [PATCH] Make sure to enable pwquality module on Ubuntu when do ansible remediation --- shared/templates/accounts_password/ansible.template | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/shared/templates/accounts_password/ansible.template b/shared/templates/accounts_password/ansible.template index f25e7cc5428..858f462f33a 100644 --- a/shared/templates/accounts_password/ansible.template +++ b/shared/templates/accounts_password/ansible.template @@ -29,6 +29,10 @@ }}} {{% endif %}} +{{% if "ubuntu" in product %}} +{{{ ansible_pam_pwquality_enable('/usr/share/pam-configs/cac_pwquality') }}} +{{% endif %}} + - name: {{{ rule_title }}} - Ensure PAM variable {{{ VARIABLE }}} is set accordingly ansible.builtin.lineinfile: create: yes