MohGovIL / hamagen-react-native

Israel's Ministry of Health's COVID-19 Exposure Prevention App
https://health.gov.il/
MIT License
508 stars 154 forks source link

Why do you disable App Transport Security on iOS? #63

Open yonilevy opened 4 years ago

yonilevy commented 4 years ago

https://github.com/MohGovIL/hamagen-react-native/blob/056350668fdd3b1411ae481f733a3720aa127ad7/ios/codeAgainstCorona/Info.plist#L31-L43

This basically says, lets disable ATS for everything except localhost 🤔

natanrolnik commented 4 years ago

NSAllowsArbitraryLoads already disables ATS, and adding localhost is redundant.

The correct way to disable ATS for localhost is described here. NSAllowsLocalNetworking is supported on iOS 10.0+.

Now, if the app requires all http connections to be insecure, that's another story.

yonilevy commented 4 years ago

@natanrolnik in case it wasn't clear, that's exactly what i'm saying, thanks for making it clearer.