Security and latency
SSH
An issue with the above solutions using 802.1x, IPsec, and so forth is that they'll generally need root access, and 802.1x can be tricky to manage remotely. SSH is a great way to connect disparate systems (everything supports it by default), especially at the user level. For example, simply using public/private key pairs, you can easily configure a program on one system to connect to another system and run a program, connect to a socket, or use some other form of communication channel. The downside of SSH is key management, and rotation can be tricky unless, of course, you use OpenSSH certificates [3].
OpenSSH Certificates
Traditional SSH relies simply on simple public/private key pairs. When you connect to a server, the public key is sent to you and you are asked whether you want to trust it. If this is the first time you're connecting to that server and you don't have some way to verify the key fingerprint, you really have no idea whether it is legitimate or not. In OpenSSH 5.4, support for a simple homegrown certificate protocol was added (for some reason, they wanted to avoid the complexity of X.509 certificates, and I tend to agree with them). Deployment and configuration are simple: You create a trusted signing key and then use it to sign host keys and user keys:
# ssh-keygen -f ssh_signing_key # ssh-keygen -h -s ssh_signing_key -I someid -V +365d -n hostname,hostname.example.org /etc/ssh/ssh_host_dsa_key.pub
You'll want the key signature to expire at some point (a year is good), and you'll need to specify the hostname and any aliases allowed for that host. The preceding command will drop the signed key into /etc/ssh/ssh_host_dsa_key-cert.pub
. To handle remote systems, you'll need to copy the key to your signing server, sign it, and then upload the signed copy to the original server and configure sshd_config
to use it:
HostCertificate /etc/ssh/ssh_host_rsa_key-cert.pub
Users will also need a copy of the public signing key so they can verify signatures made using the private signing key. The key itself needs to be in a text file with a @cert-authority
statement to let it know that it is the public part of a certificate-signing key pair:
@cert-authority * ssh-rsa [public key here]
You can then distribute that file manually and tell users to use the -oUserKnownHostsFile
command-line option; or, you can deploy it on all your systems in /etc/ssh
and use a GlobalKnownHostsFile
directive to point at the file so that all clients by default on that system trust the signing key. In future, new connections to any system with a signed public key will just work, so there will be no need to distribute the host keys manually and all that entails.
Kerberos and SSL Certificates
If you're not afraid of complexity, Kerberos and traditional SSL certificates can also work. However, you'll need to kerberize your services and clients or set everything up to handle SSL connections. Kerberos is especially well suited for large-scale deployments because it not only authenticates the client to the server but also the server to the client. Additionally, Kerberos uses several levels of tickets so that, ultimately, "service tickets" are used to connect to a service – such a ticket offers an attacker only minimal access at best.
« Previous 1 2 3 Next »
Buy this article as PDF
(incl. VAT)
Buy Linux Magazine
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.
News
-
So Long Neofetch and Thanks for the Info
Today is a day that every Linux user who enjoys bragging about their system(s) will mourn, as Neofetch has come to an end.
-
Ubuntu 24.04 Comes with a “Flaw"
If you're thinking you might want to upgrade from your current Ubuntu release to the latest, there's something you might want to consider before doing so.
-
Canonical Releases Ubuntu 24.04
After a brief pause because of the XZ vulnerability, Ubuntu 24.04 is now available for install.
-
Linux Servers Targeted by Akira Ransomware
A group of bad actors who have already extorted $42 million have their sights set on the Linux platform.
-
TUXEDO Computers Unveils Linux Laptop Featuring AMD Ryzen CPU
This latest release is the first laptop to include the new CPU from Ryzen and Linux preinstalled.
-
XZ Gets the All-Clear
The back door xz vulnerability has been officially reverted for Fedora 40 and versions 38 and 39 were never affected.
-
Canonical Collaborates with Qualcomm on New Venture
This new joint effort is geared toward bringing Ubuntu and Ubuntu Core to Qualcomm-powered devices.
-
Kodi 21.0 Open-Source Entertainment Hub Released
After a year of development, the award-winning Kodi cross-platform, media center software is now available with many new additions and improvements.
-
Linux Usage Increases in Two Key Areas
If market share is your thing, you'll be happy to know that Linux is on the rise in two areas that, if they keep climbing, could have serious meaning for Linux's future.
-
Vulnerability Discovered in xz Libraries
An urgent alert for Fedora 40 has been posted and users should pay attention.