• 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
Re: Make Web Services Core ignore SSL Server's certificate
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Make Web Services Core ignore SSL Server's certificate


  • Subject: Re: Make Web Services Core ignore SSL Server's certificate
  • From: Dominik Pich <email@hidden>
  • Date: Mon, 13 Nov 2006 16:51:54 +0100

Well, through the WSCore I cannot get the Stream.. I have the CFHTTPMessage though...

Am Nov 13, 2006 um 4:40 PM schrieb Frederick Cheung:


On 13 Nov 2006, at 15:29, Dominik Pich wrote:

And... any solution for that available?! *hopeful*

I know nothing of webservices, but have used CFHTTPMessage quite a lot

On 10.4, then the CFStream produced by CFHTTPMessage has a kCFStreamPropertySSLSettings property which is a dictionary you can fill with options, including stuff like kCFStreamSSLAllowsExpiredCertificates

Prior to 10.4, there is not a supported way of changing the way ssl happens (as far as i know).
There is a (not in the headers) constant extern CFStringRef kCFStreamPropertySocketSSLContext, once the stream has opened (ie in its kCFStreamEventOpenCompleted event) you can then query the stream for that property, the result is a CFDataRef that contains an SSLContextRef. You can then call the functions in the SecureTransport API on it (achieving basically the same thing as you can in 10.4.
This isnt supported, althought the odds of 10.3 changing are probably quite low. It also works in 10.4 (at least in the initial versions of 10.4, i've since removed that code from my codebase so I don'y know if it still works).


Fred



Am Nov 13, 2006 um 3:50 PM schrieb Alexander v. Below:


Am 13.11.2006 um 15:39 schrieb Dominik Pich:

Ok either what I did was wrong or WsInvocation doesnt use the NSURLRequest...

Sorry, of course.

As you can see in WSGeneratedObj.m, WSInvocation uses CFHTTPMessage, not NSURLRequest

Alex

Am Nov 13, 2006 um 3:19 PM schrieb Alexander von Below:

Hi Dominik,

there is a somewhat ugly way of doing this by overriding allowsAnyHTTPSCertificateForHost: in the NSURLRequest class:

@implementation NSURLRequest(NSHTTPURLRequest)
+ (BOOL)allowsAnyHTTPSCertificateForHost:(NSString *)host
{
	return YES; // Or whatever logic
}
@end

Alex

Am 13.11.2006 um 15:11 schrieb Dominik Pich:

Hi,

Im using Web Services Core to access a SOAP-Webservice and it works quite well over HTTP and even HTTPS (as long as the Server has a valid certificate) If it doesnt, can I somehow make WSCore ignore that?

Regards,
Dominik
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40mac.com


This email sent to email@hidden




_______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
email@hidden


This email sent to email@hidden


_______________________________________________ Do not post admin requests to the list. They will be ignored. Macnetworkprog mailing list (email@hidden) Help/Unsubscribe/Update your Subscription: This email sent to email@hidden
References: 
 >Make Web Services Core ignore SSL Server's certificate (From: Dominik Pich <email@hidden>)
 >Re: Make Web Services Core ignore SSL Server's certificate (From: Alexander von Below <email@hidden>)
 >Re: Make Web Services Core ignore SSL Server's certificate (From: Dominik Pich <email@hidden>)
 >Re: Make Web Services Core ignore SSL Server's certificate (From: "Alexander v. Below" <email@hidden>)
 >Re: Make Web Services Core ignore SSL Server's certificate (From: Dominik Pich <email@hidden>)
 >Re: Make Web Services Core ignore SSL Server's certificate (From: Frederick Cheung <email@hidden>)

  • Prev by Date: Re: Make Web Services Core ignore SSL Server's certificate
  • Next by Date: SSID Encoding
  • Previous by thread: Re: Make Web Services Core ignore SSL Server's certificate
  • Next by thread: SSID Encoding
  • Index(es):
    • Date
    • Thread