View Single Post
Old 2021-08-19, 10:04   #15
paulunderwood
 
paulunderwood's Avatar
 
Sep 2002
Database er0rr

2×7×281 Posts
Default

Quote:
Originally Posted by xilman View Post
Another approach I use is to put a SSH public key in /root/.ssh/authorized_keys and, as long as the network is up, root login is available from any machine which can provide the matching private key. I recognize that the network may be down, but it is a way of running programs as root.

This mechanism is used by a backuppc server to gain unfettered access to its clients' files which it needs to save and restore.
You may also add AllowUsers root@<IP addr> in your /etc/ssh/sshd_config files (and run systemctl restart ssh to read the new config files). Further, being even more paranoid, you may also use RSA keys.

Last fiddled with by paulunderwood on 2021-08-19 at 10:05
paulunderwood is offline   Reply With Quote