#security

wazoox@diasp.eu

Systemd haters have a point

#linux #systemd #security

from https://serverfault.com/questions/1159599/how-to-change-the-ssh-server-port-on-ubuntu

Ubuntu has been using systemd-sockets for some time now, which makes the port configuration in the SSH server configuration obsolete.

To change the port of the SSH server, the systemd configuration for ssh.socket must be changed or supplemented. The configuration adjustment is made by creating a *.conf file in the directory /etc/systemd/system/ssh.socket.d/.

Create conf file to extend the default config:
systemctl edit ssh.socket
or
vim /etc/systemd/system/ssh.socket.d/override.conf

    [Socket]
    ListenStream=
    ListenStream=2222

The line ListenStream= is required that port 22 is no longer used. Without this line, the SSH server would then be accessible via port 22 (default) and 2222.

WHAT THE ACTUAL FUCK? systemd silently overrides SSH configuration with obscure parameters, and silently keeps default parameters active? WHO THE FUCK IS THE DANGEROUS MORON who imagined this ? What other services are similarly hobbled silently ?