News for hackers. Stuff that matters.
Re:Was the iOS SSL Flaw Deliberate? by tptacek on Thursday February 27, 2014 @09:08AM (#7312192)
Another sad indicator of the level Schneier is playing at today, in the same vein as "avoid elliptic curves, we don't trust the math".

Once again: the only reason this bug got so much attention and press is that it's easy for laypeople to get their heads around. All you have to understand is how "goto" works. The bug is vivid, and so (paradoxically) seems scarier.

Significantly worse bugs are found every week. Within a few days of the announcement of this TLS bug, a Flash bug was announced, after being detected in exploits in the wild, that enabled reliable drive-by hijackings of browsers --- multiple browsers. It was off the HN front page within an hour.

TLS bugs aren't even unusual. We get a new one every few years ago. Firefox managed a PKCS1v15 parsing bug that allowed anyone with a Python script and 30 milliseconds to generate a certificate for any domain. Other browsers have screwed up certificate chaining, so that any domain could sign any other domain. But nobody understands PKCS1v15 padding, nobody understands certificate chaining, and so nobody writes stories about these bugs. But their impact is identical to this one.

Re:Was the iOS SSL Flaw Deliberate? by makomk on Thursday February 27, 2014 @09:23AM (#7312281)
Whatever may or may not be wrong with Schneier's article, it's certainly a hell of a lot better than (say) conflating a vulnerability that was in released, stable versions of iOS and OS X for over a year with one that never made it into an actual release of Firefox in order to make it look like the media were making a big deal about nothing[1], as you did previously on this topic. I'd suggest you take a good, hard look at your own tactics before accusing others of misinformation, and that anyone else doesn't take your word on these matters. (Sadly that comment got upvoted all the way to the top of the discussion, just like this one no doubt will.)

[1] https://news.ycombinator.com/item?id=7284290

(Edit: also, while it was 4 years ago and my memory's a bit fuzzy, I seem to recall the earlier, actually exploitable in the wild, PKCSv15 vulnerability was discussed a lot in the tech media and community. It just didn't get the mainstream media attention, most likely because it wasn't as badly mishandled and "obscure security issue fixed already" is much less of a story than "you're at risk now and there's nothing you can do, because someone fucked up".)

Re:Was the iOS SSL Flaw Deliberate? by tptacek on Thursday February 27, 2014 @09:32AM (#7312339)
You are confused. The NSS bug you're referring to was in False Start. Mozilla found and fixed the False Start bug before any release of Firefox (which is not the only user of NSS) could be impacted. I am not talking about the False Start bug. The PKCS1v15 parsing bug had nothing to do with False Start. Which makes your comment a little silly.
Re:Was the iOS SSL Flaw Deliberate? by makomk on Thursday February 27, 2014 @09:36AM (#7312369)
You're not talking about it anymore, most likely because someone from Mozilla called you out on it last time. Instead you're talking about a vulnerability that's 4 years old and have quietly stopped mentioning exactly how old it was, because it'd make it obvious just how weak your argument actually is.
Re:Was the iOS SSL Flaw Deliberate? by tptacek on Thursday February 27, 2014 @09:38AM (#7312379)
So your problem with an argument you don't like is that I didn't make it? You didn't understand the point I was making on that thread and now, embarrassingly, are attempting to port your misconception into a thread that has nothing to do with either my point or your fictitious version of it. I don't think you know what you're talking about.
Re:Was the iOS SSL Flaw Deliberate? by makomk on Thursday February 27, 2014 @09:56AM (#7312472)
Okay, what exactly is your point then? You seem to be arguing that the only reason this got coverage was because it was easy for laypeople to understand, but none of the other examples you're comparing to involved the spectacular vendor incompetence in rolling out the patch that made Apple a laughing-stock online and gave the media such a sensational story to cover, and the only one [edit: well, only TLS one] that even made it into a release was so long ago most people on here have probably forgotten the details. (I wasn't on Hacker News at the time, but it definitely made it to Slashdot and as I recall resulted in a lot of people complaining about SSL/TLS being a disaster by design.)
Re:Was the iOS SSL Flaw Deliberate? by cperciva on Thursday February 27, 2014 @09:25AM (#7312290)
I agree that TLS bugs aren't unusual. This is one of the reasons I don't trust TLS for anything serious. ;-)

But as I said a few days ago (https://news.ycombinator.com/item?id=7284957) I think this far more likely to be an NSA-exploited bug than an arbitrary-code-execution bug in Flash, because it's something which can be exploited widely and quietly without worrying about accidentally causing new versions of the program to core dump and reveal the presence of the bug.

I hate to say it, but I think you're being insufficiently paranoid.

Re:Was the iOS SSL Flaw Deliberate? by tptacek on Thursday February 27, 2014 @09:31AM (#7312331)
We already know that NSA exploits Flash bugs, and bugs like it, in the large, with impunity. They have an elaborate MITM apparatus to direct people to clientside exploiters. These things we all disclosed in the leaks. Why make new stuff up? I know security people at Apple. I do not believe for a heartbeat that they would cooperate with NSA on a backdoor.

I'm coming around to your take on TLS, for what it's worth, although the only thing I can think of that's worse than TLS are the crypto transports generalist developers come up with.

Re:Was the iOS SSL Flaw Deliberate? by nly on Thursday February 27, 2014 @09:57AM (#7312478)
> I know security people at Apple. I do not believe for a heartbeat that they would cooperate with NSA on a backdoor.

In other words, you're not being objective. You already attribute good character to the people you know at Apple, and are therefore are looking for ways to defend them against an accusation that hasn't even been made. The fact that you unnecessarily called Schneiers current occupation as 'sad', imo, tends to support this rationalisation.

None of the issues with Flash or certificate verification bugs you bring up are relevant to the discussion Schneier is having about this being the perfect kind of backdoor, and that, if it were a backdoor, it would have been hugely successful over the last year or more.

Re:Was the iOS SSL Flaw Deliberate? by tptacek on Thursday February 27, 2014 @10:43AM (#7312733)
Are we perhaps operating from different definitions of the word "backdoor"? If so, I think mine's correct: a backdoor is a security vulnerability deliberately introduced into a codebase.

I have no doubt at all that if NSA knew about this bug, they were exploiting it. That's what they do. It is not my argument that this bug is irrelevant to NSA.

Re:Was the iOS SSL Flaw Deliberate? by pessimizer on Thursday February 27, 2014 @12:38PM (#7313543)
If you assume that the only way that the NSA could get a bug into apple products is by making a call to Apple execs and asking them to do it. What do you think of the possibility of them approaching someone who already codes at Apple, possibly someone who they've had previous contact with, or have leverage against that would guarantee that they won't go public about an (unsuccessful) approach from the NSA, and employing them to find places to insert deniable vulnerabilities into Apple products?

It's unlikely that Apple would agree to sabotage their own products in a way that will eventually be detected and affect their own credibility. That's restricting the argument that people are making to a straw man, though. Have spies ever worked that way? What people are mostly speculating about is whether this was an intentionally introduced vulnerability, not the mechanism by which that would come about.

Re:Was the iOS SSL Flaw Deliberate? by larrys on Thursday February 27, 2014 @11:10AM (#7312920)
"The fact that you unnecessarily called Schneiers current occupation as 'sad', imo, tends to support this rationalisation."

Let me give you the perspective of someone who is outside the security business but knows a good deal about PR and the media and how it operates. And selling books (one that I was doing was mentioned on the front page of the WSJ - all from PR that I organized on my own).

Schneier has certainly transformed himself and it's all about his image and selling books with his new found fame. I know it when I see it. Because as he just said in a way "it's what I would do if I wanted to..."

So in other words he has an axe to grind in getting mentioned in the media. Period. That doesn't mean what he is saying isn't correct in some fashion of course. But it does give credence to the statement "Another sad indicator of the level Schneier is playing at today". That level is publicity for Schneier. So to repeat myself, exactly what I'd be doing if I was him.

Re:Was the iOS SSL Flaw Deliberate? by cperciva on Thursday February 27, 2014 @11:28AM (#7313046)
I know security people at Apple. I do not believe for a heartbeat that they would cooperate with NSA on a backdoor.

I agree with you based on the security people I know at Apple. However, I would be surprised if Apple's security people have enough time to carefully audit every line of security-relevant code which other people at Apple touch.

Re:Was the iOS SSL Flaw Deliberate? by eik3_de on Thursday February 27, 2014 @10:11AM (#7312550)
> I know security people at Apple. I do not believe for a heartbeat that they would cooperate with NSA on a backdoor

So you're absolutely sure that there is no developer (in the position) at Apple that would take a discrete paper bag of $$$ to make just a tiny error by hitting ctrl-v twice?

Re:Was the iOS SSL Flaw Deliberate? by twoodfin on Thursday February 27, 2014 @11:09AM (#7312907)
For one thing, it's hard to imagine an amount of money that would be simultaneously large enough to entice an Apple engineer to risk his job and reputation, but small enough to not trigger questions about where it came from. You'd have to concoct elaborate schemes that convince the IRS to look the other way, or target someone who could be blackmailed without fear that they'll run immediately to the authorities or their boss. Not anywhere near as easy or safe as handing over a bag of cash.

If I were the NSA, a strategy with much lower variance would be to hire a lot of smart folks to do the intense security reviews and testing that Apple (and many other companies, presumably) fail to do, and try to find bugs before they're patched. As tptacek has pointed out, there are plenty of these, and an organization with the resources of the NSA can probably find them frequently enough for most purposes without sticking its neck out.

Re:Was the iOS SSL Flaw Deliberate? by pessimizer on Thursday February 27, 2014 @12:52PM (#7313660)
>it's hard to imagine an amount of money that would be simultaneously large enough to entice an Apple engineer to risk his job and reputation

The odds are that this engineer will never be revealed publicly, and it will not effect his/her reputation in any way.

>but small enough to not trigger questions about where it came from.

You don't think that the NSA has the ability to hide money?

Re:Was the iOS SSL Flaw Deliberate? by twoodfin on Thursday February 27, 2014 @05:05PM (#7315507)
Surely this hypothetical bribed engineer will be identified during Apple's post-mortem. Hopefully he's a good liar, otherwise the NSA risks exposure that way. Even if he's a terrific liar, of course his reputation will be hurt: His 'mistake' caused Apple a major PR hit and engineering scramble that likely cost millions of dollars.

And for what? The NSA can hide money, but you or I would quickly find ourselves talking with the IRS if our spending or bank accounts rose dramatically without a commensurate rise in reported income. We could probably hide a few thousand dollars a month under the table, but that doesn't sound like it would turn the head of even a particularly amoral Apple engineer already making six figures.

I'm not saying this scenario is impossible. But to be plausible, it requires both the perpetrator and the NSA to take on a degree of risk that doesn't seem to match the reward for either.

If this is standard procedure for the NSA and happens often, given the risk involved, why hasn't anyone been caught at it and publicly exposed?

If the NSA made an exception and executed some unusually elaborate cloak and dagger to seduce or blackmail an Apple employee for this change, why do we think it was for this vulnerability and not the dozens of others that are discovered annually?

Re:Was the iOS SSL Flaw Deliberate? by tptacek on Thursday February 27, 2014 @05:10PM (#7315552)
Since we're at a nosebleed altitude of hypothetical here, I think now might be the time to point out that this thread is demanding that people prove a negative.
Re:Was the iOS SSL Flaw Deliberate? by PhantomGremlin on Thursday February 27, 2014 @09:30PM (#7316912)
> If I were the NSA, a strategy with much lower variance would be to hire a lot of smart folks to do the intense security reviews and testing that Apple (and many other companies, presumably) fail to do, and try to find bugs before they're patched.

Very very good point.

Until you made it, I might have thought "well of course NSA looks for bugs to exploit", but I didn't think through the implications.

Here we have Apple open sourcing their security code. They made the NSA's job 10x easier than w/o the source. So of course the NSA will lint and review and test and exploit Apple's source code. Intensively. It's low-hanging fruit, of the Apple variety. :)

Re:Was the iOS SSL Flaw Deliberate? by sarreph on Thursday February 27, 2014 @10:14AM (#7312566)
It's cmd-v on a Mac, I'm afraid ;)
Re:Was the iOS SSL Flaw Deliberate? by diminish on Thursday February 27, 2014 @09:44AM (#7312417)
> I know security people at Apple.

Do you have any information, whether they're using any kind of of code -security- auditing tools?

Could it be that the programmer simply got a backdoor request, which s/he in protest implemented this way to ensure to be caught.

Re:Was the iOS SSL Flaw Deliberate? by josu on Thursday February 27, 2014 @09:27AM (#7312302)
>Once again: the only reason this bug got so much attention and press is that it's easy for laypeople to get their heads around. All you have to understand is how "goto" works.

I don't agree. Most people don't even have a basic understanding of coding. I think that it has more to do with the fact that there are about 500 million vulnerable devices out there, and that we are talking about Apple. Remember Antennagate, it wasn't even that big of a deal and look at what the press made of it.

Re:Was the iOS SSL Flaw Deliberate? by rimantas on Thursday February 27, 2014 @09:49AM (#7312439)
Maybe "laypeople" in this context means "programmers with very basic/naive understanding of crypto and implications".
Re:Was the iOS SSL Flaw Deliberate? by aidenn0 on Thursday February 27, 2014 @11:56AM (#7313249)
Most people on HN know what a "goto" is. We're talking about attention on the HN front-page after all.

[edit]

Also I bet most readers of Schneier's bug know what goto is as well.

Re:Was the iOS SSL Flaw Deliberate? by josu on Thursday February 27, 2014 @10:59PM (#7317170)
He said laypeople though, not HN readers.
Re:Was the iOS SSL Flaw Deliberate? by pessimizer on Thursday February 27, 2014 @12:28PM (#7313467)
>Once again: the only reason this bug got so much attention and press is that it's easy for laypeople to get their heads around.

I think that's the reason why this bug should get a lot of attention and press. Most programmers can see this bug instantly, without even knowing the purpose of the code. How long does something like that in a (maybe the most) security-critical piece of code in a product go unseen and uncorrected without it being a result of maliciousness or incompetence?

How many dopey errors like this would have to be inserted into how many products to guarantee that the vast majority of communications could be monitored for (lets say) 5-10 years? 50 errors in 15 products? This single error compromised all iPhones, all iPads, and all Macs.

This sort of strategy would be the most efficient way for the NSA to spend money that I've ever heard of it doing. If money isn't exchanged (the companies aren't being paid to compromise themselves) we don't even have the evidence trail that outed RSA, who sabotaged their products in an equally deniable way.

I'm with the people asking who did the commit that introduced the bug. I'd like to know if they had any intelligence connections.

Re:Was the iOS SSL Flaw Deliberate? by tptacek on Thursday February 27, 2014 @12:32PM (#7313501)
You think that because you learned about the bug from blog posts that just showed the diff. If that was what the developers of the stack saw, I'd agree. But of course, that isn't all they saw: you're looking at a needle in a haystack that someone has taken the time to find for you, and then wondering why it was so hard for anyone to distinguish between a needle and a blade of grass.
Re:Was the iOS SSL Flaw Deliberate? by pessimizer on Thursday February 27, 2014 @12:43PM (#7313592)
I'm not thinking that from the diff, I'm thinking that from the two gotos in a row.

Can you think of a reason why that would be in any computer program, and if you saw it in while reading any code, wouldn't it either indicate some weird trick that you maybe don't understand (and should look up) or an obvious error?

It doesn't look like anything that any static analysis tool wouldn't instantly scream about, either. I can't think of a less subtle error to accomplish the same thing.

Re:Was the iOS SSL Flaw Deliberate? by tptacek on Thursday February 27, 2014 @12:45PM (#7313613)
Have you been reading the same technical coverage of this story that I have? Because what I'm reading is people saying that their static analysis regimes wouldn't have caught this, starting with Adam Langley. Veracode, which exists to sell a tool designed specifically to catch stuff like this, wrote the same thing.
Re:Was the iOS SSL Flaw Deliberate? by pessimizer on Thursday February 27, 2014 @12:54PM (#7313678)
I haven't. I'd like links, though. If I can see with my eyes that code will never be executed, I'd like to know what's wrong with the state of current static analysis.

edit: http://blog.veracode.com/2014/02/do-not-pass-qa-do-not-goto-...

Veracode does static analysis of the binary, and says that it would be thwarted because it wouldn't know that some functions were meant to be called. Static code analysis would tell you that it was impossible for some of the code to be run.

edit 2:(the second comment on the vericode blog)

caf | February 24, 2014 11:05 pm

In the Evil Unit Tests part you can use code coverage tools to at least verify that your unit tests exercise all code paths. It won’t catch every bug, but it would have caught this one.

Re:Was the iOS SSL Flaw Deliberate? by tptacek on Thursday February 27, 2014 @01:31PM (#7313951)
Unit test coverage isn't static analysis. It's practically the opposite of static analysis.
Re:Was the iOS SSL Flaw Deliberate? by pessimizer on Thursday February 27, 2014 @01:58PM (#7314143)
I'm not talking about unit test coverage:) I read the comment too quickly.

I'm talking about tools like http://oclint.org/ and http://clang-analyzer.llvm.org/

If they work anything like similar tools in other languages, they would have found this bug trivially.

Re:Was the iOS SSL Flaw Deliberate? by tptacek on Thursday February 27, 2014 @02:15PM (#7314256)
Yes, along with hundreds of other issues that would have had no security impact.
Re:Was the iOS SSL Flaw Deliberate? by rdl on Thursday February 27, 2014 @11:21AM (#7312990)
I cared a lot more than usual about the bug because iOS is generally my go-to advice for "secure web browsing platform", and because I personally use iOS and OSX, and the slow response on OSX patching. I expect people care about Apple products in the media for this reason -- Microsoft bugs would have similar reach (as did the Android RNG bug), but Apple bugs are relatively rare and thus more a dog bites man story.

Flash I know to be insane. I don't use Firefox. So, less reason to care.

But yes, Schneier has become the USA Today of security advice. A lot of people read USA Today, so it's important, but it's probably not where you go for deep or substantial analysis. (and, generally a week after everyone else has discussed an issue to death)

Re:Was the iOS SSL Flaw Deliberate? by MatthiasP on Thursday February 27, 2014 @12:56PM (#7313686)
Bruce Schneier does have vast expertise when it comes to security/encryption and the fact that he is formulating his conclusions in a way that they can be consumed by the general public, is something that is commendable and makes him way more dangerous for the NSA. Which is one of the reaseons why he gets attacked for it, i guess.
Re:Was the iOS SSL Flaw Deliberate? by tptacek on Thursday February 27, 2014 @01:08PM (#7313787)
Does he? What makes you think that? Can you be specific? I understand this to be an article of faith, but cryptography has changed significantly since the 1990s --- and software security has (a) changed even more and (b) been a pretty consistent weak spot in Schneier's analyses even in the '90s.
Re:Was the iOS SSL Flaw Deliberate? by rdl on Thursday February 27, 2014 @01:25PM (#7313916)
Bruce Schneier is an exceptionally good writer and a very good public speaker. That alone is sufficient to make him incredibly important in the security community.
Re:Was the iOS SSL Flaw Deliberate? by r0h1n on Thursday February 27, 2014 @11:19AM (#7312972)
I think you're using a different definition of "worse" when it comes to backdoors, compared to Schneier (in this post). His yardsticks seems to be "low chance of discovery, high deniability if discovered, and minimal conspiracy to implement."

When you say "significantly worse bugs are found every week", are you considering them worse using Schneier's yardsticks above, or your own (which to me as a lay person appear to be their potential for damage)?

Re:Was the iOS SSL Flaw Deliberate? by chiph on Thursday February 27, 2014 @10:41AM (#7312725)
> TLS bugs aren't even unusual.

Is there a public test-suite that implementers can check against?

Re:Was the iOS SSL Flaw Deliberate? by tptacek on Thursday February 27, 2014 @10:44AM (#7312742)
No, not that I know of.
Re:Was the iOS SSL Flaw Deliberate? by astrodust on Thursday February 27, 2014 @11:29AM (#7313051)
There's the problem.

Plus, if there were tests, they just become another target.

Re:Was the iOS SSL Flaw Deliberate? by tptacek on Thursday February 27, 2014 @11:53AM (#7313233)
It's hard to design a good TLS test suite, for at least a couple reasons:

* The TLS stacks all have different APIs, and you'll need some fine-grained configuration over client options to exercise the code.

* There are only a few important TLS stacks, and the effort required to build a test suite is probably greater than the effort required to build a TLS stack.

It would still be a cool project. If it exists, I'd love to hear about it.

Re:Was the iOS SSL Flaw Deliberate? by rqebmm on Thursday February 27, 2014 @01:52PM (#7314111)
I bet the NSA has one to look for vulnerabilities like this though!
Re:Was the iOS SSL Flaw Deliberate? by mzs on Thursday February 27, 2014 @11:55AM (#7313240)
You mean this one right?

http://www.theregister.co.uk/2014/02/20/flash_adobe_posts_em...

That was the day before the iOS update. You scared me for a moment that there was a flash update I had missed cause of all the hoopla around gotofail.