Skip to content
This repository has been archived by the owner on Dec 26, 2020. It is now read-only.

Commit

Permalink
Use sha2 HMACs on RHEL 6 / CentOS 6.
Browse files Browse the repository at this point in the history
  • Loading branch information
foonix committed Apr 1, 2020
1 parent 3d351ef commit 50e4ab4
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
4 changes: 4 additions & 0 deletions defaults/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,10 @@ ssh_macs_53_default:
- hmac-ripemd160
- hmac-sha1

ssh_macs_53_el_6_5_default:
- hmac-sha2-512
- hmac-sha2-256

ssh_macs_59_default:
- hmac-sha2-512
- hmac-sha2-256
Expand Down
8 changes: 8 additions & 0 deletions tasks/crypto.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,14 @@
ssh_macs: '{{ ssh_macs_59_default }}'
when: sshd_version is version('5.9', '>=') and not ssh_macs

- name: set macs for Enterprise Linux >= 6.5 (openssh 5.3 with backports)
set_fact:
ssh_macs: '{{ ssh_macs_53_el_6_5_default }}'
when:
- ansible_distribution in ['CentOS', 'RedHat']
- ansible_distribution_version is version('6.5', '>=')
- not ssh_macs

- name: set macs according to openssh-version
set_fact:
ssh_macs: '{{ ssh_macs_53_default }}'
Expand Down

0 comments on commit 50e4ab4

Please sign in to comment.