Skip to content

Commit 074cf0b

Browse files
committed
DLPX-86530 CIS: delphix user lockout after failed login attempts
PR URL: https://www.github.com/delphix/delphix-platform/pull/504
1 parent 8aa7466 commit 074cf0b

File tree

1 file changed

+35
-0
lines changed
  • files/common/var/lib/delphix-platform/ansible/10-delphix-platform/roles/delphix-platform/tasks

1 file changed

+35
-0
lines changed

files/common/var/lib/delphix-platform/ansible/10-delphix-platform/roles/delphix-platform/tasks/main.yml

+35
Original file line numberDiff line numberDiff line change
@@ -483,6 +483,41 @@
483483
- login
484484
- sshd
485485

486+
#
487+
#
488+
# Lock out the user after an unsuccessful consecutive login attempts.
489+
#
490+
- lineinfile:
491+
path: /etc/pam.d/common-auth
492+
line: "{{ item }}"
493+
insertbefore: '^auth\s+\[success=1\s+default=ignore\]\s+pam_unix\.so\s+nullok\s+try_first_pass'
494+
with_items:
495+
- 'auth required pam_tally2.so audit silent deny=5 unlock_time=900'
496+
497+
#
498+
#
499+
# Configuration to enforce account lockout policies.
500+
#
501+
- lineinfile:
502+
path: /etc/pam.d/common-account
503+
line: "{{ item }}"
504+
insertafter: EOF
505+
with_items:
506+
- 'account required pam_tally2.so'
507+
508+
509+
#
510+
#
511+
# Configuration to remember user password history.
512+
#
513+
- lineinfile:
514+
path: /etc/pam.d/common-password
515+
line: "{{ item }}"
516+
insertbefore: '^password\s+\[success=1 default=ignore\]\s+pam_unix\.so\s+obscure\s+sha512'
517+
with_items:
518+
- 'password required pam_pwhistory.so remember=5'
519+
520+
486521
#
487522
# On Xen, block devices, including cdroms, are named with the scheme /dev/xvdX.
488523
# Thus, the udev rules for cdroms are written to match devices with that naming

0 commit comments

Comments
 (0)