3 ms·
> setting aside the arguments of whether JIT code is a security concern (it is not unless your security model is one where codesigning exists to prevent the add
by inetknght 5y ago
> setting aside the arguments of whether JIT code is a security concern (it is not unless your security model is one where codesigning exists to prevent the addition of new native code)
But, it is.
1) provide a JIT compiler
2) download code from the internet
3) provide code to JIT compiler
4) ???
5) Profit!
JIT code obfuscates the inspection of the app. It therefore is a security concern.
- SheinhardtWigCo 5y agoHow is this significantly different from: 1) link JavaScriptCore 2) download JavaScript code from the internet 3) provide code to JSC 4) ??? 5) Profit!
- lacker 5y agoApple makes sure that JavaScriptCore can safely run untrusted code, but they don't apply that same level of security to their native API.
- eat_veggies 5y agoI suppose the difference is that JSC can only execute javascript (an interface which is relatively self-contained and which Apple can control) and not arbitrary machine instructions?
- egeozcan 5y agoBut you can't provide a JS JIT as well.
- candiodari 5y agoJIT's can be made 100% secure. Inspection by humans cannot be made secure, for a lot of different reasons. So it's just the opposite. I've run bots that executed code from the internet and while yes, I've had to learn some lessons the hard way, you can have perfectly safe JITs.
- saagarjha 5y agoIf I was a malicious developer I’d just spray my app with ROP gadgets and run arbitrary native code, just somewhat slower.