[OSM-dev] HTTP error 417 with cURL

Frederik Ramm frederik at remote.org
Fri May 11 00:50:40 BST 2007


> I've just discovered I don't get a 200 OK, I get a HTTP code 417. This came up 
> on another post (by Lars) earlier this week suggesting it was an 
> incompatiblity between cURL and lighthttpd 

Funny, same issue came up on talk at the same time posted by someone 
else. You have to keep CURL from setting that evil header. Details were at


- but is there a workaround?

I had a quick glance at the CURL PHP binding and it seems that there's 
no equivalent for the command-line -H switch that lets you suppress a 
header. The relevant man page seems to be


If you're lucky, you can use CURLOPT_HTTPHEADER, set the problematic 
header to an empty string, and maybe it works. Otherwise you'll have to 
use CURLOPT_HEADERFUNCTION and write ashort handler method that passes 
through all headers except the one you don't like.


Frederik Ramm  ##  eMail frederik at remote.org  ##  N49°00.09' E008°23.33'

More information about the dev mailing list