Describe the bug
OpenSSH server configuration is handled by 'update-crypto-policy' which provides
/etc/crypto-policies/back-ends/openssh.config
and
/etc/crypto-policies/back-ends/opensshserver.config.bak
These files must be removed or altered in to function correctly.
Expected behavior
OpenSSH policies for Key Exchanges, MACs and Ciphers as defined by the Ansible module work.
Actual behavior
OpenSSH policies for Key Exchanges, MACs and Ciphers as defined by the Ansible module are ignored.
Example Playbook
- hosts: localhost
  roles:
    - ansible-ssh-hardening
  vars:
    ssh_moduli_minimum: 3071
    ssh_host_key_files: [ '/etc/ssh/ssh_host_ed25519_key' ]
    ssh_cipers: [ 'chacha20-poly1305@openssh.com',
                  'aes256-gcm@openssh.com',
                  'aes256-ctr',
                  'aes128-gcm@openssh.com',
                  'aes128-ctr' ]
    ssh_kex: [ 'curve25519-sha256',
               'curve25519-sha256@libssh.org',
               'diffie-hellman-group16-sha512',
               'diffie-hellman-group18-sha512' ]
    ssh_macs: [ 'hmac-sha2-512-etm@openssh.com',
               'hmac-sha2-256-etm@openssh.com',
               'umac-128-etm@openssh.com' ]
 
OS / Environment
CentOS Linux release 8.1.1911 (Core)
Ansible Version
ansible 2.9.7
  config file = None
  configured module search path = ['/root/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/local/lib/python3.6/site-packages/ansible
  executable location = /usr/local/bin/ansible
  python version = 3.6.8 (default, Nov 21 2019, 19:31:34) [GCC 8.3.1 20190507 (Red Hat 8.3.1-4)]
 
Role Version
- src: https://github.com/dev-sec/ansible-ssh-hardening.git
 
Additional context
None