I want to check what the header values are for outgoing HTTP messages, in particular I would like to see what cookies are being set in the header.
I’m using NSURLConnection, if at the point of initializing the NSURLConnection with an NSURLRequest I examine [NSURLRequest allHTTPHeaderFields] then it is empty (unless I set a header field myself, such as the user agent, in which case that is the only field returned by allHTTPHeaderFields.
However the OS must be adding other default values for the header at some point after this, where/how can I see what header values are being sent out with HTTP POST/GETs?
In particular I want to check if/what cookies are being automatically set in the headers.
Cookies are added by the system and pulled from the shared cookie storage on the phone. So to see what cookies are stored for your domain you would use: