LWN: Comments on "OpenSSH 7.0" https://lwn.net/Articles/654129/ This is a special feed containing comments posted to the individual LWN article titled "OpenSSH 7.0". en-us Thu, 23 Oct 2025 01:08:39 +0000 Thu, 23 Oct 2025 01:08:39 +0000 https://www.rssboard.org/rss-specification lwn@lwn.net OpenSSH 7.0 https://lwn.net/Articles/655377/ https://lwn.net/Articles/655377/ gerv <div class="FormattedComment"> Actually, there's only _one_ now, and we are trying to removing that one too: <a href="https://bugzilla.mozilla.org/show_bug.cgi?id=1156844">https://bugzilla.mozilla.org/show_bug.cgi?id=1156844</a> . But there's not much you can do, except wait, if lots of websites keep using certs chaining to it.<br> <p> Gerv <br> </div> Mon, 24 Aug 2015 12:14:18 +0000 OpenSSH 7.0 https://lwn.net/Articles/654365/ https://lwn.net/Articles/654365/ jwilk <div class="FormattedComment"> <font class="QuotedText">&gt; Except commercial CAs never used 1024-bit RSA keys</font><br> <p> They did. In fact, there are still 1024-bit RSA keys in the Mozilla CA store.<br> </div> Thu, 13 Aug 2015 09:39:50 +0000 generating keys https://lwn.net/Articles/654342/ https://lwn.net/Articles/654342/ malor <div class="FormattedComment"> There are no guarantees. But, as far as we know, 4096-bit RSA should last that long. You can generate one this way: <br> <p> ssh-keygen -t rsa -b 4096 -o<br> <p> (the -o tells it to encrypt the file with a newer, stronger algorithm, making it harder to bruteforce the passphrase.)<br> <p> The Curve25519 keys are about equivalent to 3072-bit RSA keys, and can be generated like this:<br> <p> ssh-keygen -t ed25519<br> <p> The resulting keys are quite short, only 32 bytes, and they generate almost instantly. There are no other options: all ed25519 keys are 256-bit, and all are stored with the better encryption.<br> <p> If you want to force your ssh servers to use Curve25519 encryption only, you can do so with these lines:<br> <p> Ciphers chacha20-poly1305@openssh.com<br> MACs hmac-sha2-512-etm@openssh.com<br> KexAlgorithms curve25519-sha256@libssh.org<br> <p> This explicitly turns off all other encryption. I'm not sure the MAC line actually does anything: someone commented that there's a MAC built into Curve25519 encryption already. So that line may be superfluous. <br> <p> You can put the same lines in ssh_config, as well, if you want to force those options on all outgoing connections. <br> <p> This is a very fast algorithm, and will run very well even on weak CPUs. On a modern Intel processor with the AES New Instructions, hardware-accelerated AES is faster than Curve25519, which might be an issue if you're driving extreme bandwidth. Most processors with AESNI should still be able to saturate a gigabit with Curve25519, but an unusually weak CPU or unusually large bandwidth demands might make hardware-accelerated AES more attractive.<br> <p> Perhaps foolishly, the biggest reason I trust Curve25519 was because the NIST had nothing whatsoever to do with it: after the DUAL_EC random number generator debacle (it was deliberately compromised by the NSA, who then bribed the RSA company to make it their default RNG), I'd rather use encryption standards that the American government has nothing whatsoever to do with.<br> <p> </div> Thu, 13 Aug 2015 00:32:34 +0000 OpenSSH 7.0 https://lwn.net/Articles/654341/ https://lwn.net/Articles/654341/ malor <div class="FormattedComment"> Use ChaCha20/Poly1305. It runs fine on the Pi.... the bottleneck there will be either the USB storage or the 100MBit Ethernet, so if a cipher can go twice that fast (25Mbit/sec), that should be adequate to keep the wire saturated. <br> <p> The person at ImperialViolet benched an ARM7 CPU at about 90Mbyte/sec. Even a Pi 1 would probably be able to do half that. A Pi 2 would probably be loping at the 12.5Mbyte maximum data rate the platform can handle. <br> <p> <p> <p> </div> Thu, 13 Aug 2015 00:18:57 +0000 generating keys https://lwn.net/Articles/654282/ https://lwn.net/Articles/654282/ nix <div class="FormattedComment"> That requires knowing what cryptographic breaks will happen in the next ten years. If you have a crystal ball that clear, there are a lot of other interesting things you can do with it too :)<br> <p> </div> Wed, 12 Aug 2015 15:40:53 +0000 OpenSSH 7.0 https://lwn.net/Articles/654281/ https://lwn.net/Articles/654281/ nix <div class="FormattedComment"> ssh -oHostKeyAlgorithms=+ssh-dss -i .ssh/my_dsa_key host<br> <p> is what you want.<br> <p> If it was just a -i away, the algorithm wouldn't be disabled in any sense that I can see.<br> </div> Wed, 12 Aug 2015 15:40:10 +0000 generating keys https://lwn.net/Articles/654226/ https://lwn.net/Articles/654226/ glen <div class="FormattedComment"> so what would be ssh-keygen arguments to generate new key that would be working now and considered safe/secure in ten years?<br> </div> Wed, 12 Aug 2015 11:45:40 +0000 OpenSSH 7.0 https://lwn.net/Articles/654217/ https://lwn.net/Articles/654217/ Otus <div class="FormattedComment"> <font class="QuotedText">&gt; 1024-bit Diffie-Hellman keys are really only a practical concern when using a well-known prime group (i.e. prime plus generator).</font><br> <p> I still think it's easier to just use a well known 2048-bit group (group 14), and that protects you from both targeted and untargeted attacks.<br> <p> <font class="QuotedText">&gt; So notwithstanding the greater strength of ECC, it also makes users easier targets in this respect.</font><br> <p> But the solution is easy: just use a larger curve. A factor of 2^x in curve size is ~equivalent to having 2^(x/2) unique user defined curves instead. If 160-bit ECC is roughly equivalent to 1024-bit DH, you can step up to 256-bit ECC and be more secure than with a realistic amount of different curves. That's faster, with a good implementation, and has way smaller keys and messages.<br> <p> Yes, you need to trust the curve, but there are a bunch of curves from independent parties now.<br> </div> Wed, 12 Aug 2015 07:23:56 +0000 OpenSSH 7.0 https://lwn.net/Articles/654215/ https://lwn.net/Articles/654215/ arekm <div class="FormattedComment"> Looks now client side keys are ignored unless are matching PubkeyAcceptedKeyTypes.<br> <p> Too bad that even explictly telling ssh client to use specific key doesn't work (without PubkeyAcceptedKeyTypes matching) like:<br> ssh -i .ssh/my_dsa_key host<br> <p> :-/<br> </div> Wed, 12 Aug 2015 06:35:53 +0000 OpenSSH 7.0 https://lwn.net/Articles/654206/ https://lwn.net/Articles/654206/ wahern <div class="FormattedComment"> 1024-bit Diffie-Hellman keys are really only a practical concern when using a well-known prime group (i.e. prime plus generator). Once upon a time protocols and implementations only used well-known prime groups because of suspicions about accidentally generating weak primes. These prime groups were (and largely still are) identical across all users of the software, and so by attacking a single prime group you could snoop on all users of that software, or at least a substantial fraction of them a substantial amount of the time. It's analogous to certificate authorities, where cracking the CA's key effects the security of everybody downstream. Except commercial CAs never used 1024-bit RSA keys, and cracking their signing key only permits man-in-the-middle attacks, whereas breaking a DH prime group let's you record and decrypt the conversation, regardless of the presence of ephemeral DH private keys.<br> <p> But today it's no longer considered poor practice to generate prime groups dynamically. Still, generation of safe primes can take an appreciable amount of time even on modern hardware. Compare the running time of<br> <p> $ openssl dhparam 1024<br> <p> to <br> <p> $ openssl genrsa 1024<br> <p> (You may have to run the former multiple times if you, per chance, found one more quickly than usual.)<br> <p> Generating the parameters dynamically causes headaches because of the possibly very long initial startup time and general logistical issues of doing it in-process. Most software on both the server and client side just doesn't know how to dynamically generate DH groups, even for ephemeral DH. This is especially true for embedded and appliance systems. This is why over the years there have been security issues with compromised DH parameters, such as when software projects or vendors generated parameters on systems with broken a PRNG, effecting everybody downstream.<br> <p> But they all usually allow you to specify your own at startup. If you can't switch to ECDH, there's nothing wrong with generating your own random 1024-bit DH parameters. I seriously doubt the NSA will expend the same effort to crack a key used by one person the same as one shared by millions of people. Of course, 2048-bit would be even better. 1024-bit has stuck around for so long because in the 2000s there was still plenty of software which only worked with key sizes &lt;= 1024 bits. But I can't imagine a randomly generated 1024-bit DH prime group being the weakest link in a targeted attack. Most people don't even have a hardware RNG. (It's a real shame Soekris doesn't provide their crypto accelerator in mini PCI express form; it's been useless for accelerating anything for years, but it sported the cheapest and most widely supported hardware RNG.)<br> <p> With ECDH protocols you _must_ use shared curves (equivalent to shared prime groups for DH). You can't generate random ones, for various technical and functional reasons. So notwithstanding the greater strength of ECC, it also makes users easier targets in this respect. Which is perhaps why some people are very suspicious about the NIST-standardized curves.<br> <p> </div> Wed, 12 Aug 2015 03:34:02 +0000 OpenSSH 7.0 https://lwn.net/Articles/654173/ https://lwn.net/Articles/654173/ stqn <div class="FormattedComment"> I’m not sure that the use case is so "niche", given the popularity of the Raspberry Pi and NAS boxes nowadays. Also installing NFS is not "minor extra effort". And of course any Linux user knows that using an old version is neither convenient nor recommended, if at all possible.<br> </div> Tue, 11 Aug 2015 19:56:59 +0000 OpenSSH 7.0 https://lwn.net/Articles/654171/ https://lwn.net/Articles/654171/ jhoblitt <div class="FormattedComment"> Actually, my statement about about EL is incorrect -- my memory must be really going. RHEL appears to have never included hpn-ssh. Scientific Linux (SL) 4 definitely included hpn-ssh patches. I thought SL 5/6 had as well but it looks like not.<br> </div> Tue, 11 Aug 2015 19:18:18 +0000 OpenSSH 7.0 https://lwn.net/Articles/654170/ https://lwn.net/Articles/654170/ jhoblitt <div class="FormattedComment"> I believe that patches for "null" or "none" ciphers ssh were popular about a decade ago. "hpn-ssh" may have been the most popular patch set. EL5 &amp; EL6 both included hpn patches.<br> <p> <a href="http://www.psc.edu/index.php/hpn-ssh">http://www.psc.edu/index.php/hpn-ssh</a><br> <p> My recollection, which may be faulty, is that is that the "none" cipher didn't make much of a difference below a few 100 mbit/s.<br> </div> Tue, 11 Aug 2015 19:01:33 +0000 OpenSSH 7.0 https://lwn.net/Articles/654158/ https://lwn.net/Articles/654158/ jtaylor <div class="FormattedComment"> As you are happy with weak crypto I assume the fileserver is not on the public net.<br> So the solution is simple: just use an older version of ssh or don't update whatever you have now.<br> <p> Requiring some minor extra effort for niche use cases is in my opinion preferable than risking everyone else due to the possibility of misconfiguration or higher attack surface.<br> </div> Tue, 11 Aug 2015 16:43:48 +0000 OpenSSH 7.0 https://lwn.net/Articles/654156/ https://lwn.net/Articles/654156/ ibukanov <div class="FormattedComment"> <font class="QuotedText">&gt; a very weak Atom CPU</font><br> <p> Intel started to put AES instructions into Atoms since Q3 2013. If you have one of those, then aes128-gcm@openssh.com should be the fastest cipher. <br> </div> Tue, 11 Aug 2015 16:31:08 +0000 OpenSSH 7.0 https://lwn.net/Articles/654155/ https://lwn.net/Articles/654155/ bgmarete <div class="FormattedComment"> Chacha20-Poly1305 is what you are looking for. If it can do 95MB/s on a phone-class ARM cpu, I am sure your Atom can run it fast enough. See: <a rel="nofollow" href="https://www.imperialviolet.org/2013/10/07/chacha20.html">https://www.imperialviolet.org/2013/10/07/chacha20.html</a><br> </div> Tue, 11 Aug 2015 16:25:15 +0000 OpenSSH 7.0 https://lwn.net/Articles/654146/ https://lwn.net/Articles/654146/ mordocai <div class="FormattedComment"> If you are worried about resource usage you really shouldn't be using sshfs, with or without encryption. NFS/Samba may be harder to setup, but in my experience are much more efficient than any setup you can achieve with sshfs. I'd strongly recommend just learning NFS(or samba if you need to play nice with windows). The hardest part isn't the setup, but tweaking the configuration params to be optimal.<br> </div> Tue, 11 Aug 2015 15:32:07 +0000 OpenSSH 7.0 https://lwn.net/Articles/654135/ https://lwn.net/Articles/654135/ stqn <div class="FormattedComment"> I am using sshfs with arcfour and/or blowfish-cbc on my local network in order to have the smallest possible load on my file server, which is running a very weak Atom CPU. If it was possible to use ssh with no encryption I would do it instead, but unfortunately it is not.<br> <p> Sshfs is very easy to setup and use, unlike nfs or samba... So I hope they reconsider the deletion of weaker algorithms.<br> <p> It is my understanding that the new Raspberry Pi 2 is also relatively slow for encryption, so it is not only "old" computers that would be affected.<br> </div> Tue, 11 Aug 2015 15:20:40 +0000 OpenSSH 7.0 https://lwn.net/Articles/654132/ https://lwn.net/Articles/654132/ Otus <div class="FormattedComment"> <font class="QuotedText">&gt; Refusing all RSA keys smaller than 1024 bits (the current minimum is 768 bits)</font><br> <p> Wow, long past time to refuse 768 bit keys, those could demonstrably be factored six years ago.<br> <p> I don't think even 1024 should really be considered secure any more either: <a rel="nofollow" href="http://crypto.stackexchange.com/a/1982/13625">http://crypto.stackexchange.com/a/1982/13625</a><br> </div> Tue, 11 Aug 2015 14:30:02 +0000 OpenSSH 7.0 https://lwn.net/Articles/654130/ https://lwn.net/Articles/654130/ mattdm <div class="FormattedComment"> Finally, the PermitRootLogin option does what one might naively expect. Nice. <br> </div> Tue, 11 Aug 2015 14:11:02 +0000