• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
NSURLConnection and https
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

NSURLConnection and https


  • Subject: NSURLConnection and https
  • From: "Lesin, Vladislav" <email@hidden>
  • Date: Mon, 22 Jan 2007 13:56:07 +0300
  • Thread-topic: NSURLConnection and https

Hi all



  I am loading links with NSURLConnection. I do this by setting up an

instance of NSURLRequest.



The problem I have occurs under the following situation:

   1)     The NSURL in question is "https://"; (secure)

   2)     The cert can't be validated



What is occurring is that the NSURLConnection promptly calls its

delegate function:

connection:didFailWithError:





The NSError is filled with

    Error = "bad server certificate"

    Domain = NSURLErrorDomain

    Code = -1203

    UserInfo =

        NSErrorFailingURLKey = <url>

        NSErrorFailingURLStringKey = <url>

        NSLocalizedDescription = "bad server certificate"



Now, what I want is a chance to present the user with "Certificate

can't be validated, do you wish to proceed?" But I have no idea how to

recover from this or intercept the cert or anything.



How to use NSURLConnection to get data from HTTPS server with a self-signed/unknown certificate?



Thanks!



Best regards

Vlad

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: NSURLConnection and https
      • From: Julio Cesar Silva dos Santos <email@hidden>
  • Prev by Date: Re: credits.rtf problem
  • Next by Date: Re: NSURLConnection and https
  • Previous by thread: Listening for multiple keypresses
  • Next by thread: Re: NSURLConnection and https
  • Index(es):
    • Date
    • Thread