0
0
mirror of https://github.com/saltstack-formulas/openssh-formula.git synced 2024-11-28 01:18:12 +01:00

Made host key algos configurable; dropped DSA

This commit is contained in:
Alexander Weidinger 2019-02-12 14:53:10 +01:00
parent 54dde36e53
commit 4b84dead8e
2 changed files with 5 additions and 1 deletions

View File

@ -36,7 +36,7 @@ ssh_config:
{%- endif %} {%- endif %}
{% endif %} {% endif %}
{%- for keyType in ['ecdsa', 'dsa', 'rsa', 'ed25519'] %} {%- for keyType in openssh['host_key_algos'].split(',') %}
{%- set keyFile = "/etc/ssh/ssh_host_" ~ keyType ~ "_key" %} {%- set keyFile = "/etc/ssh/ssh_host_" ~ keyType ~ "_key" %}
{%- set keySize = salt['pillar.get']('openssh:generate_' ~ keyType ~ '_size', False) %} {%- set keySize = salt['pillar.get']('openssh:generate_' ~ keyType ~ '_size', False) %}
{%- if salt['pillar.get']('openssh:provide_' ~ keyType ~ '_keys', False) %} {%- if salt['pillar.get']('openssh:provide_' ~ keyType ~ '_keys', False) %}

View File

@ -19,6 +19,10 @@ openssh:
dig_pkg: dnsutils dig_pkg: dnsutils
ssh_moduli: /etc/ssh/moduli ssh_moduli: /etc/ssh/moduli
root_group: root root_group: root
# Prevent merge of array; always override values
host_key_algos: ecdsa,ed25519,rsa
# To manage/remove DSA:
#host_key_algos: dsa,ecdsa,ed25519,rsa
sshd_config: {} sshd_config: {}
ssh_config: {} ssh_config: {}