4 ms·
This sounds like a serious issue, and I wouldn't be surprised if news will come out soon about an app that allows for a massive security breach because it didn'
by jeroenhd 6y ago
This sounds like a serious issue, and I wouldn't be surprised if news will come out soon about an app that allows for a massive security breach because it didn't use the root store correctly.
S/MIME and HTTPS are quite different types of services, the former still usually relying on long-lived certificates whilst the latter is moving to shorter and shorter certificate validity, lessening the impact of a breach. Using S/MIME certificates to validate TLS might even allow a website to use the certificate of some random email address in your company to do a man-in-the-middle attack on your certificate, if the app's implementation was written badly enough.
--
Offtopic: speaking of root stores and Mozilla, I'm still miffed about Firefox's decisions about the subject on Android. They removed the old root certificate management/installation pages, put a switch to enable the system's user certificate store in about:config and then removed the ability to use about:config from the stable release of Firefox for Android.
I've seen a commit message saying that they moved the setting to allow the certificates the user explicitly installed on their system to work inside Firefox into a secret developer menu. I found that thread because I was looking into why my phone would randomly reset the about:config setting every day (because of a bug? because of the change? who even knows).
My intranet websites work on pretty much every browser other than Firefox on my phone. It's really annoying.
- dheera 6y agoAlso, I'm miffed about how hard it is to mitmproxy apps on iOS to see what they are sending to servers. I find this a massive privacy violation on Apple's part, and one of the main reasons I don't use an iPhone as my main device. I want to be able to see what apps are sending about me to their backend APIs. As usual, Apple fanboys, downvote away.
- Operyl 6y agoThis isn’t Apple or Google’s fault that application developers are choosing to pin their certificates in their apps?
- aftbit 6y agoWell they could prohibit it if they wanted. They could even require that apps provide a method to inspect traffic. They never will though, because cert pinning is good for security, and any user-accessible method to access secrets becomes a target for phishing or other social engineering.
- Operyl 6y agoThat would certainly be the day I go "what the heck, Apple/Google." They could certainly try and prohibit it, but I don't think the backlash would bode well for them, and we'd only see people obfuscating their traffic even more.
- ROARosen 6y ago> Also, I'm miffed about how hard it is to mitmproxy apps on iOS to see what they are sending to servers. Did you ever try with Fiddler? You can allow local connections through your PC and proxy through, download a Fiddler root cert, and it should work.
- jrockway 6y agoI think the underlying problem is that the apps stop talking because the certificate validity check fails when traffic is proxied through your MITM. No MITM proxy can make that succeed, but if you can control the CA store that apps read, then you can create a certificate, add it to the trusted roots, use that cert to sign a certificate for someone else's website, and then when the app uses the system library to verify the validity of the certificate, it will appear valid, even though it's not. Without being able to hack the certificate verification, you can't MITM traffic between two devices you own. I think that's the complaint the grandparent has. Apps can still pin certificates, of course. At that point, you have to exploit the app's other faulty assumptions like "I'm running the same code that the compiler produced" or "writing 0 to memory address 0x12344321 and then reading memory address 0x12344321 will result in reading 0", which are straightforward to make false. Though probably not on a stock iPhone.
- ROARosen 6y agoAre you saying that most apps don't rely on the system Trust Store? I believe manually trusting Fiddler's cert adds it to the Trust Store. The only iOS apps I couldn't successfully MITM with this were stock Apple apps.
- morpheuskafka 6y agoThis situation is the same on Android, presuming you do not have a rooted device. On Android >7 third-party apps do not trust user certificates by default, and a non-root user cannot install new system certificates. And afaik there is nothing stopping them from using custom crypto libraries that do not use the system roots at all. And of course, even if you could decrypt the HTTPS traffic the actual API payloads and endpoints need not be in any kind of human readable format.
- dheera 6y agoIt's much, much easier to root Android than it is to jailbreak iOS. For one I run a rooted image to start with so I don't need to actually root it.
- tinus_hn 6y agoFor what it’s worth, there’s just a normal way to install custom root certificates on iOS, no jailbreak required.
- fomine3 6y agohttps://github.com/mitmproxy/mitmproxy/issues/2054 https://github.com/mitmproxy/mitmproxy/issues/2054
- TechBro8615 6y agoIt does suck and it's a tradeoff of security/privacy. But it's not impossible, you just need to try a bit harder. If you have a jailbroken phone (the latest jailbroken version can almost always run every modern app), it's easy to install iOS SSL Kill Switch. If you don't have a jailbroken phone, you can wrap the app in your own certificate and side load it with hooks that disable the SSL routines.
- dang 6y ago> As usual, Apple fanboys, downvote away. Please stop breaking the site guidelines like that. I'm sure you wouldn't think of littering in a city park or starting fires in trash barrels, so please don't do the equivalent here. https://news.ycombinator.com/newsguidelines.html https://news.ycombinator.com/newsguidelines.html
- sleevi 6y agoExample app: NuGet for .NET on Linux and MacOS, from Microsoft: https://github.com/NuGet/Announcements/issues/56 https://github.com/NuGet/Announcements/issues/56 It used SSL/TLS and S/MIME roots to verify code signing and timestamping responses. When Symantec, which was removed for TLS trust, was also removed for S/MIME, NuGet broke, because it was no longer able to verify the TSA signature. As covered in https://github.com/NuGet/Home/issues/10504 https://github.com/NuGet/Home/issues/10504 , this then led some Linux distros, notably Debian/Ubuntu, to re-add Symantec. Any application using the ca-certificates package thus end up trusting CAs that Mozilla does not trust, despite being derived from the Mozilla Root Store. So the news is already out there, this was just a reminder to folks to not do silly things like Microsoft did.