4 ms·
Running untrusted code in a sandbox made client-side web apps possible, so I think there’s more to it than that.
by skybrian 5y ago
Running untrusted code in a sandbox made client-side web apps possible, so I think there’s more to it than that.
- croes 5y agoBut you wouldn't say it's safe just less unsafe.
- skybrian 5y agoMaybe safety isn’t binary? We are usually more sophisticated about evaluating risks than that. If all you think about is whether things are safe versus unsafe, everything is “fake security” and you’ll never come up with defense in depth.
- croes 5y agoOf course. My problem with parent's comment is, that the solution for running unsafe C code with high risk of buffer overflows is to put it in a sandbox. That's not safety it just changes the attack vector.
- skybrian 5y agoA good reason to use a sandbox for untrusted code is so that you don’t have to vet the code. If it has security holes, the damage is limited to the capabilities granted to the plug-in. The sandbox should make buffer overflows someone else’s problem, or at least an acceptable risk. You seem to be denying one of the most important reasons we have them? A consequence, though, if the code is genuinely untrusted, is that you have to revalidate any requests after they’re sent to the system outside the sandbox. (Just as we can’t trust client-side validation on the server.) It seems like that would be duplicate work. (An exception might be when an authenticated user is modifying their own files and you don’t care what they do.)