by admin

Openssl Alternatives For Mac

Has anyone experience using Indy with SSL on OS X? I would require connecting it to OpenSSL, but not sure if this is feasible on OS X or if perhaps a better solution exists.

On Windows I am now using WinIne with Indy as fallback since users there have to download OpenSSL themselves. I have read OS X comes with old versions of OpenSSL - if so, I guess I could try hook those together with Indy?

I would prefer a soluion where users do not have o download something to get SSL working (although such a solution is preferable to not having a solution). The Apple-supplied OpenSSL libraries have been deprecated for years and should not be used. That means you should not use Indy, Synapse, or FPC's HTTP client unless you include a newer version of the OpenSSL libraries in your app bundle (may require changes to HTTP client code).

Here's my suggestion: Follow Apple's advice and use their URL Loading System instead when accessing https sites. See the nsurlrequest.pas unit in nsunits-src.zip here. It uses Apple's Foundation framework classes.

Note that the error you cite is likely not due to the age of the OpenSLL libraries, so it's possible that using Apple's frameworks will not work either. Handshake failures usually mean a problem between the client and server agreeing on what protocol version to use. Best free pc optimizer software. The Apple-supplied OpenSSL libraries have been deprecated for years and should not be used. That means you should not use Indy, Synapse, or FPC's HTTP client unless you include a newer version of the OpenSSL libraries in your app bundle (may require changes to HTTP client code). Here's my suggestion: Follow Apple's advice and use their URL Loading System instead when accessing https sites. See the nsurlrequest.pas unit in nsunits-src.zip here.

It uses Apple's Foundation framework classes. Note that the error you cite is likely not due to the age of the OpenSLL libraries, so it's possible that using Apple's frameworks will not work either. Handshake failures usually mean a problem between the client and server agreeing on what protocol version to use. Nsurlrequest.pas will work on iOS. Indy, Synapse and FPC's HTTP clients will NOT work on iOS with https sites since iOS does not include OpenSSL. Note that if you need to work with a SOAP server, for example, via the Web Service Toolkit, you can use nsurlrequest.pas with WST too.

Openssl For Mac Os

Mac

Openssl Mac Install

WST includes nshttpprotocol.pas (analogous to its indyhttpprotocol.pas, etc.). See the ndfd library used in the example apps here to see how easy it is to conditionally switch between HTTP clients with WST (see file NdfdForecast.pas): You can also use nsurlrequest.pas to post form data to a server.

Yes, per Apple's recommendation in the link above, you can do that on both iOS and OS X. Apple does suggest using a known version. I can't tell what version these are - the archive files in OpenSSLStaticLibs.7z are dated April 21, 2014. Maybe they don't get much love. Static linking will add considerably to the size of the app's executable, depending on how many of the 5 architectures from the archive are linked in. Currently, 4 of the 5 architectures would probably be needed, 2 for the Simulator app (32 and 64 bit) and 2 for the iOS native device app (32 and 64 bit). Plus some bloat from Indy code.

Mac

If the app only needs to send an HTTP request or work with a SOAP server via WST, then that might be overkill. In contrast, using a Foundation-framework based client won't link in any additional code since everything the client code uses is already on the iOS device or Mac.