skylab
/
skylab-ansible
Archived
2
0
Fork 0

Fix ssh auth config settings labels

This commit is contained in:
Ethan Paul 2021-11-06 22:14:20 -04:00
parent fe0cd3ab67
commit 4069d8a77a
No known key found for this signature in database
GPG Key ID: 6A337337DF6B5B1A
1 changed files with 5 additions and 9 deletions

View File

@ -7,20 +7,16 @@
replace: "{{ item.value }}"
notify: [restart-sshd]
loop:
- name: disable root login
regex: "^.*PermitRootLogin (yes|no).*$"
- regex: "^.*PermitRootLogin (yes|no).*$"
value: PermitRootLogin no
- name: disable password auth
regex: "^.*PasswordAuthentication (yes|no).*$"
- regex: "^.*PasswordAuthentication (yes|no).*$"
value: PasswordAuthentication no
- name: disable challenge response auth
regex: "^.*ChallengeResponseAuthentication (yes|no).*$"
- regex: "^.*ChallengeResponseAuthentication (yes|no).*$"
value: ChallengeResponseAuthentication no
- name: disable GSSAPI auth
regex: "^.*GSSAPIAuthentication (yes|no).*$"
- regex: "^.*GSSAPIAuthentication (yes|no).*$"
value: GSSAPIAuthentication no
loop_control:
label: "{{ item.name }}"
label: "{{ item.value }}"
- name: Disable dynamic MOTD on debian systems
when: ansible_os_family == "Debian"