Skip to content

Commit e05c0ca

Browse files
committed
Fix hardening overrides for SSH and LXD
1 parent 31807f9 commit e05c0ca

2 files changed

Lines changed: 16 additions & 2 deletions

File tree

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
11
sysctl_overwrite:
22
net.ipv4.ip_forward: "1"
33
net.ipv6.conf.all.forwarding: "1"
4+
kernel.unprivileged_userns_clone: "1"
45

56
os_firewall: false
67
manage_ufw: false
7-
ssh_server_permitrootlogin: prohibit-password
8+
ssh_permit_root_login: "without-password"
9+
ssh_server_password_login: false
810
ssh_use_pam: true
911
ssh_client_alive_interval: 300
10-
ssh_client_alive_count_max: 2
12+
ssh_client_alive_count: 2
13+
ssh_max_auth_retries: 6
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,18 @@
11
- name: Apply dev-sec OS hardening
22
ansible.builtin.include_role:
33
name: devsec.hardening.os_hardening
4+
vars:
5+
sysctl_overwrite: "{{ sysctl_overwrite }}"
6+
os_firewall: "{{ os_firewall }}"
7+
manage_ufw: "{{ manage_ufw }}"
48

59
- name: Apply dev-sec SSH hardening
610
ansible.builtin.include_role:
711
name: devsec.hardening.ssh_hardening
12+
vars:
13+
ssh_permit_root_login: "{{ ssh_permit_root_login }}"
14+
ssh_server_password_login: "{{ ssh_server_password_login }}"
15+
ssh_use_pam: "{{ ssh_use_pam }}"
16+
ssh_client_alive_interval: "{{ ssh_client_alive_interval }}"
17+
ssh_client_alive_count: "{{ ssh_client_alive_count }}"
18+
ssh_max_auth_retries: "{{ ssh_max_auth_retries }}"

0 commit comments

Comments
 (0)