Live data from Hacker News

The DROWN Attack

drownattack.com

131–140 of 206 posts

Re: The DROWN Attack

#131

Earlier quoted context omitted.

> RSA is obsolete. Stop using it. The problem is, the ONLY curves that are supported in practice are NIST P-256 (prime256v1) and P-384 (secp384r1), which aren't considered safe. So, I guess, many are reluctant to switch (because we're non-experts and don't know real implications, but we heard that there's something not right there - and shouldn't one be wary?). Neither Curve25519 nor Curve448 - which are said to be s…

Use Curve25519.

drdaeman says that Curve25519 isn't usable with X.509 and TLS. Your reply is "Use Curve25519". What are you saying? That drdaeman is wrong, and Curve25519 can be used with TLS? Or are you saying, "don't use TLS"? Or... what?

Re: The DROWN Attack

#132
post #67

The vulnerability here is tricky to exploit but actually simple to describe. There's a padding oracle in the form of RSA used by both TLS and SSLv2; by repeatedly sending permuted versions of a ciphertext to an SSLv2 server, you can gradually discover the plaintext†. Both SSLv2 and TLS have countermeasures for this attack. But SSLv2's countermeasures are sabotaged by the crappy ciphers it also supports. In both TLS a…

> The vulnerability here is tricky to exploit but actually simple to describe. Yessss finally > There's a padding oracle hysterical sobbing sounds

I ran across a related issue working on a project that I think helped me understand the broader issue better. I'll relate it here and see if it helps.

We had user search functionality for an internal business application. We allowed searching by several fields, such as name, and phone number, and allowed partial matches, where the first part of a field matched.

Phone numbers were restricted information for some users, and we didn't display them in the search results. But you could search by those fields, if you already knew the value.

It turned out we left 'partial matching' available in the phone number field.

If you knew the name of a particular person, you could do the following:

Enter their name to confirm a single match shows up.

Then enter the same search, but put a single digit in the phone field, say "0". If no result came back, you knew that their phone number didn't start with that digit. So you try the next, 1, 2, 3... when you hit, say 5, you get a result. Now you know their phone number starts with a 5.

So you start on the next digit. 50-, 51-, 52-... and you get the next digit. Eventually you can reveal their entire phone number, and it was fast enough to do manually.

It wasn't super critical for the internal system, so we changed the phone numbers to exact match only and that was fine. but let's continue.

Let's say we had a REALLY slow system, and it checked each digit one at a time, taking one second per digit, and sent back a failure when it hit a non matching digit. We aren't leaking information DIRECTLY, you get no records back for partial matches. But we ARE leaking information indirectly. The attack now works roughly like this:

Do the same verification search to get a record.

Now do the same digit by digit search, start with 0. Carefully time the delay when you submit the question, and when the error shows up. If it's almost instant, you know the first digit failed. If it takes about a second to give you an error, you know the first digit worked.

You then continue to the second digit. One second fails, two seconds verifies.

Using only the timing you can determine each digit, and reveal the entire number. This is not the main information channel, the timings are what they call a side channel. The service that gives you this information by responding with an error and varying the time is an 'oracle' because it answers your questions.

This seems clear at a one-second time scale and obvious when it's explained, but it turns out that even over public networks with enough tries you can determine very small time differences, on the millisecond or less scale.

It turns out there are a lot of variations on this, some of them are very complex, and secure systems need to work very hard to run in the same amount of time ("constant time") for any query to avoid leaking information this way. The timing exploit described above is a very simplified form of the root of the described vulnerability.

This situation helped me understand 'timing attacks' and 'oracles' in a more mundane coding context, and hopefully it will help others.

Re: The DROWN Attack

#134
post #73

Earlier quoted context omitted.

Well how long before the novelty names run out of meaning ? For starters there are probably more issues out there then there are catchy American English anachronisms. I vote for using the names of Mezzo-American gods . Like Hachäk'yum or Xbalanque!

I think GitHub should starting doing something this for issues and pull requests. Instead of the nondescript - Issue #2654: misplaced comma on page 3 of documentation - Issue #2653: open() should accept relative file path it should be - Quetzalcoatl's Rage: misplaced comma on page 3 of documentation - The Dying Curse of Buluc Chabtan: open() should accept relative file path

That would make issue trackers / change logs more interesting to read. ;-) A lot!

Re: The DROWN Attack

#135
post #133

does cloudflare block this?

I didn't find any affected CloudFlare sites on their test site, so I assume they don't allow SSLv2 connections.

You should probably patch your origin servers anyway.

Re: The DROWN Attack

#137
> the attack exploits a fundamental weakness in the SSLv2 protocol that relates to export-grade cryptography that was introduced to comply with 1990s-era U.S. government restrictions.

Thanks again US government.

Re: The DROWN Attack

#138

Earlier quoted context omitted.

> The vulnerability here is tricky to exploit but actually simple to describe. Yessss finally > There's a padding oracle hysterical sobbing sounds

I ran across a related issue working on a project that I think helped me understand the broader issue better. I'll relate it here and see if it helps. We had user search functionality for an internal business application. We allowed searching by several fields, such as name, and phone number, and allowed partial matches, where the first part of a field matched. Phone numbers were restricted information for some users…

This really helped me understand a few security concepts including the fundamentals of this attack. Thanks for the post.

Re: The DROWN Attack

#139
post #67

The vulnerability here is tricky to exploit but actually simple to describe. There's a padding oracle in the form of RSA used by both TLS and SSLv2; by repeatedly sending permuted versions of a ciphertext to an SSLv2 server, you can gradually discover the plaintext†. Both SSLv2 and TLS have countermeasures for this attack. But SSLv2's countermeasures are sabotaged by the crappy ciphers it also supports. In both TLS a…

Thanks for the excellent summary.

"The big problem here is that people run old SSLv2 servers with the same RSA keypairs as their TLS servers. So you can take messages you captured from the TLS servers, and, with some very clever message manipulation owing to an older Bardou paper, make them intelligible to SSLv2, and use the SSLv2 padding oracle to decrypt them."

That is a lesson worth remembering: something acquired in one context might become valuable in an attack in another context. I've seen this concept show up repeatedly hacking and security analysis. Clever how this attack applied it.

I've occasionally wondered if that could be turned into some mental framework or heuristics for generically applying it to various security analyses. Some systematic way, maybe semi-automated, of saying we've collected all these pieces of information for protocols, configs, etc. Now what does that automatically infer in terms of attacks or even connections that might lead to them?

Not sure that it's feasible in general case. I used it in prototype security scanners before the commercial ones showed up. Might be something to be had researching the concept further. (shrugs)

Re: The DROWN Attack

#140

Earlier quoted context omitted.

I think developers of elliptic curve crypto overestimate their ability too. Avoiding side channels in RSA is easier than avoiding them in ECC - fewer moving parts.

Developers that are likely to expose exploitable side channels in curve software are just as likely to expose them in RSA software. But developers that use curve software are going to avoid a bunch of vulnerabilities that are specific to RSA. They should use curves, and avoid RSA. But I don't know why I'm letting you off the hook on this. Can you be as specific as you can about the additional moving parts you're refe…

The amount I tend to learn after you get invested in a thread and start busting out things I've never heard of is honestly my counterpoint to arguing on the Internet being unproductive. That it is Percival you are fencing makes me look forward to the rest of this thread, because EC vs RSA is an interesting dialogue and you both have a lot to say on it. It might look like arguing to both of you, but scraps of useful information do fling off and I appreciate your arguing.

This thread and others like it make me think we need a security (and general) debate series.

Post reply on HN