EddyVerbruggen / SSLCertificateChecker-PhoneGap-Plugin

:passport_control: Prevent Man in the Middle attacks with this Cordova plugin
MIT License
155 stars 89 forks source link

Only the first call work and all other call receive CONNECTION_SECURE #52

Open crreddys opened 5 years ago

crreddys commented 5 years ago

NSURLConnection is caching even i disable the cache.

Created a fork and made changes and waiting for feedback. I am using NSURLSession instead of NSURLConnection.

https://github.com/crreddys/SSLCertificateChecker-PhoneGap-Plugin

@jacobweber @EddyVerbruggen can you guys take a look.

crreddys commented 5 years ago

In our use case we have 3 servers which I am verifying cert pinning. Here is the scenario let’s assume we are having man in the middle attack for server 2. When I am first checking the server 1, I get valid response back and all subsequent calls are cached and it always returns true irrespective of the server.

With this change, the calls won’t be cached anymore.

Created PR for this change.