allow seperate password login for sftp

Signed-off-by: Michael <[email protected]>
This commit is contained in:
mib1185 authored and Michael committed 2025-02-25 15:28:54 +00:00
1 parent e318aab870
commit 0a52f9195a
3 files changed
+9 -1

No files matched your search

+5
View File
@@ -89,6 +89,11 @@ For more information, see [this issue](https://github.com/dev-sec/ansible-collec
- Description: Specifies the umask for sftp. - Description: Specifies the umask for sftp.
- Type: str - Type: str
- Required: no - Required: no
- `sftp_password_login`
- Default: inherite from `ssh_server_password_login`
- Description: Set to `true` to allow password-based authentication to the sftp server. You probably also need to change `sshd_authenticationmethods` to include `password` if you set `sftp_password_login`: `true`.
- Type: bool
- Required: no
- `ssh_allow_agent_forwarding` - `ssh_allow_agent_forwarding`
- Default: `False` - Default: `False`
- Description: Set to `false` to disable Agent Forwarding. Set to `true` to allow Agent Forwarding. - Description: Set to `false` to disable Agent Forwarding. Set to `true` to allow Agent Forwarding.
+3
View File
@@ -180,6 +180,9 @@ sftp_umask: "0027"
# change default sftp chroot location # change default sftp chroot location
sftp_chroot_dir: /home/%u sftp_chroot_dir: /home/%u
# If true, password login for sftp is allowed
sftp_password_login: "{{ ssh_server_password_login }}"
# enable experimental client roaming # enable experimental client roaming
ssh_client_roaming: false ssh_client_roaming: false
@@ -283,7 +283,7 @@ Match Group sftponly
{% endif %} {% endif %}
AllowTcpForwarding no AllowTcpForwarding no
AllowAgentForwarding no AllowAgentForwarding no
PasswordAuthentication {{ 'yes' if (ssh_server_password_login|bool) else 'no' }} PasswordAuthentication {{ 'yes' if (sftp_password_login|bool) else 'no' }}
PermitRootLogin no PermitRootLogin no
X11Forwarding no X11Forwarding no
{% endif %} {% endif %}