News for hackers. Stuff that matters.
Re:The most dangerous code in the world by tptacek on Wednesday October 24, 2012 @09:16PM (#4695889)
I think we are all clear that if library users carefully read the documentation, this is an avoidable flaw. I'm not sure what that has to do with my point. If even the Curl author thinks VERIFYHOST=true isn't useful, why does it work that way? The answer is: it shouldn't.

"Here's an option that you could reasonably expect to be boolean. And lo! the code appears to work if you treat it as a boolean. But, just to mess with you, I introduced an apparently useless option to handle the 'true' case in that boolean, and introduced an 'even truer' value that does what you expected".

This is simply a terrible, dangerous design. It is, like I said on Twitter today, a vulnerability in Curl, and one that should be fixed. The option expressed today by VERIFYHOST=1 should instead be the case when VERIFYHOST=-1 or VERIFYHOST=666. Meanwhile, VERIFYHOST=1 should, tomorrow if possible, do exactly what VERIFYHOST=2 does today.

Re:The most dangerous code in the world by jpdoctor on Thursday October 25, 2012 @12:20AM (#4696357)
> I'm not sure what that has to do with my point.

The point of yours that I addressed was: "that VERIFYHOST=1 exists primarily to give people the feeling of having configured SSL/TLS well without making them actually do that."

Put simply: It does not exist primarily for that purpose.

I can't make it any clearer than that.

Re:The most dangerous code in the world by tptacek on Thursday October 25, 2012 @12:36AM (#4696395)
Oh yeah? Interesting. Tell me, what is the point of checking to see if a certificate has a common name field in it but then not checking to see if that common name is related to the connection bearing the certificate? Make it clear for me, will you?
Re:The most dangerous code in the world by Natsu on Thursday October 25, 2012 @05:26AM (#4696903)
That option exists to punish those evil people who don't read the documentation.

I'm kidding... I think.

Re:The most dangerous code in the world by tptacek on Thursday October 25, 2012 @04:32PM (#4699421)
Of course, who it really punishes is the user.
Re:The most dangerous code in the world by Natsu on Friday October 26, 2012 @01:21AM (#4700960)
Some developers seem to believe that more options are always better, even if removing the bad options makes the software better and easier to use.
Re:The most dangerous code in the world by brazzy on Thursday October 25, 2012 @06:49AM (#4697100)
> Put simply: It does not exist primarily for that purpose.

You fail to provide any proof for that statement. The API doc merely states what the setting does, it says absolutely nothing about about its purpose, and neither do you.

Re:The most dangerous code in the world by zorbo on Thursday October 25, 2012 @02:32AM (#4696627)
You do realize that the curl API says this:

> The default value for this option is 2.

In other words, there is absolutely no issue here. It does the right thing out of the box.

Re:The most dangerous code in the world by kyberias on Thursday October 25, 2012 @12:22AM (#4696361)
This is definitely NOT a vulnerability in curl. I hate it when security people treat everything black and white. There ARE other things to consider.
Re:The most dangerous code in the world by tptacek on Thursday October 25, 2012 @12:36AM (#4696396)
Such as what? When VERIFYHOST=1, curl has basically turned the security part of SSL/TLS off. That seems like kind of a big deal for an HTTPS/SSL API.
Re:The most dangerous code in the world by wisty on Thursday October 25, 2012 @01:50AM (#4696539)
> I hate it when security people treat everything black and white.

That's because experience shows if things are "grey" then someone can almost certainly break in.

Re:The most dangerous code in the world by drivebyacct2 on Wednesday October 24, 2012 @11:12PM (#4696193)
I don't think this shouldn't be changed, but surely it's not one that can be made without thought or concern either. Changing the behavior overnight will undoubtedly break servers and scripts.
Re:The most dangerous code in the world by moe on Wednesday October 24, 2012 @11:52PM (#4696289)
Changing the behavior overnight will undoubtedly break servers and scripts.

It will only break servers and scripts that currently operate under a false sense of security. The maintainer should file a CVE, push the fixed version and let the distros sort out the rest. And he should do it ASAP.