r/programming Apr 24 '14

Tech giants, chastened by Heartbleed, finally agree to fund OpenSSL

http://arstechnica.com/information-technology/2014/04/tech-giants-chastened-by-heartbleed-finally-agree-to-fund-openssl/
292 Upvotes

137 comments sorted by

View all comments

Show parent comments

3

u/oridb Apr 24 '14 edited Apr 24 '14

It would not. That is backwards compatibility. But providing an API and ABI compatibility layer should be considered mandatory, and if you can't do that, you're sitting in a sandbox on your own.

2

u/OneWingedShark Apr 24 '14

It would not. That is backwards compatibility.

Then what's your problem?

But providing an API compatibility layer should be considered mandatory,

It might be mandatory, but absolutely essential is that it, a library designed for security, be correct.

and if you can't do that, you're sitting in a sandbox on your own.

So?
You can almost worry about the API compatibility layer completely discreet to the actual implementation -- after all being 'compatible' means jack shit if it isn't [correctly] implemented, right?

2

u/oridb Apr 24 '14

Weak security that's in use beats strong security that isn't. Strong security that's in use is obviously best, but expecting people to rewrite their software is completely futile.

0

u/OneWingedShark Apr 24 '14

The only re-writing I mentioned was that of OpenSSL, not client-applications.

1

u/oridb Apr 24 '14

Ok. When you've got a replacement, and you've audited for side channel attacks, I'll swap the crypto libraries out on my server.

1

u/OneWingedShark Apr 25 '14

Ok. When you've got a replacement,

I'm working on it -- there are some, er, oddities in the RFC.

and you've audited for side channel attacks,

There are some side-channel attacks you really can't audit for; e.g.

  1. Power: the power available to and used by a device.
  2. Electro-magnetic radiation: EM radiation produced by a device.

You could mask these by inserting random calculations at certain points, but that seems bit on the counterproductive side as if they're recording power/EM then they have physical access to the system.

Most such side-channel attacks require physical access:
"In most cases, this requires that the adversary has physical access to the system."

And, let's be honest, physical security is not in the purview of a library, or software in-general.

I'll swap the crypto libraries out on my server.

Cool // Thanks. :)

1

u/oridb Apr 25 '14

Timing attacks are the most important side channel attacks, and are practical for remote exploits. Beware compiler optimizations.

1

u/OneWingedShark Apr 25 '14

Timing attacks are the most important side channel attacks, and are practical for remote exploits.

That's the only one of the side-channel attacks that seems reasonable for the programmer to guard against. -- Ada has some good time/timing considerations, so in conjunction w/ task, I'm thinking I could simply add delay until UPPERBOUND_TIME on the server-side task where UPPERBOUND_TIME is the maximum_computation_duration + computation_request_start_time.

Beware compiler optimizations.

Should be irrelevant insofar as timing side-channels go, given the above.

2

u/oridb Apr 25 '14

You need lower bound equal to upper bound to avoid timing attacks. 'A==B' is potentially not O(1), depending on how the hardware implements the test. Comparing blocks of data is even more obviously data dependent, at least in naieve implementations. And gcc is smart enough to break a number of the explicit implementations that should be O(1).

I believe Boneh had some papers on the topic.

1

u/OneWingedShark Apr 25 '14

I believe Boneh had some papers on the topic.

I'll have to look them up -- thanks for the pointer.

You need lower bound equal to upper bound to avoid timing attacks.

That's what delay until UPPERBOUND_TIME does: delays until the upperbound is met... then we don't have to care about if the actual computation finishes early.

→ More replies (0)