Incorporates a workaround provided by Apple in TN 2287:
Is basically the same change as this pull request:
The main difference from the other pull request is rather than downgrading the SSL security across all iOS versions, I wrapped the SSL Level setting in an iOS version check.
make it use correct ssl settings for ios 5.0 and 5.0.1
revised ssl settings -- last commit didn't work unless validation was…
… turned off or client certificates were used