Re: Stronger ssh settings

Christian Weisgerber <[email protected]> Sun, 5 Apr 2026 16:09:43 +0200
Newsgroups gmane.os.freebsd.architechture
Message-ID <[email protected]>
Alexander Leidinger:

> I propose to extend our ssh config (and maybe other configs) regarding
>  - settings for government standards
>  - improved FreeBSD defaults

Upstream OpenSSH has a history of walking a good compromise line
between phasing out aging algorithms and maintaining compatibility
with most of the installed base.  I don't think FreeBSD can improve
on those defaults.

Government standards may require disabling some of the algorithms
OpenSSH prefers.  That is more likely a disimprovement.  Anyway,
if people would like example configurations compliant with FIPS or
such, I don't object.

> (I simply included what I use on my systems, and they
> should work for connections from and to all supported FreeBSD releases as I
> have them like that since a long time; an alternative would be to use the
> exclude syntax instead).

Algorithm lists have the habit of going stale.  They would have to
be carefully reviewed each time OpenSSH is updated.  Unless a
definitive list is required, using the +/- syntax to prefer/disable
algorithms is frequently a better choice.

> +### FreeBSD ###
> +HostKeyAlgorithms rsa-sha2-512,rsa-sha2-256,ssh-ed25519

Why do you drop ECDSA and all CA algorithms?

> +KexAlgorithms [email protected],curve25519-sha256,[email protected],diffie-hellman-group-exchange-sha256,diffie-hellman-group16-sha512,diffie-hellman-group18-sha512,diffie-hellman-group14-sha256

Why do you drop the standard name "sntrup761x25519-sha512"?
More importantly, who do you drop mlkem768x25519-sha256, which is the
upstream default?
Let me guess, this list is a few years old and has gone stale.

I think "improved FreeBSD defaults" are a bad idea.

-- 
Christian "naddy" Weisgerber                          [email protected]