title: Issue with NSURLConnection, Basic Auth and Cookies
body: <p>I have discovered that the server I make REST calls to passes on cookies to my iPhone. It also employs HTTP Basic Auth. </p>
  
  <p>I have an app where you can change accounts used for the authentication, however I have discovered that changing the credentials doesn't matter since <code>didReceiveAuthenticationChallenge</code> is never called.</p>
  
  <p>I have looked into two potential fixes: </p>
  
  <ul>
  <li>removing the cookies manually whenever credentials are changed</li>
  <li>setting <code>[request setHTTPShouldHandleCookies:NO]</code></li>
  </ul>
  
  <p>I wonder if I'm understanding this correctly. I expected that <code>NSURLRequestReloadIgnoringCacheData</code> would take care of caching, but it doesn't seem to be the case.</p>
  
  <p>How can I resolve this?</p>
  
  <p><strong>EDIT:</strong> I've just tried setting <code>shouldHandleCookies</code> to <code>NO</code>, but it seems that the cookies are still passed on to the server.</p>