Comment by JoshTriplett
1 year ago
You're trying to present an "instead of" that assumes I should want native apps and should jump through hoops to find a way to get what I want from apps that aren't designed for it. I want web apps, because they already do what I want, and keep getting better.
The right answer to "download our app!" is "no, stay in your browser tab".
> try looking at existing sandbox solutions.
I have, quite extensively; virtualization and sandboxing are things I have a great deal of expertise in. The best available application sandboxing solution that provides useful comprehensive APIs is the web. The next best solutions are mobile platforms, but that doesn't help laptops/desktops (no, iOS apps on macOS don't count), and aren't designed to let the user do things like block ads.
If an application is open, then sure, there are plenty of other options. If an application isn't open, I want it contained in a sandbox not of its own making, that it can't escape, that provides sufficiently comprehensive APIs such that interesting applications get built for it, and that keeps the user in control.
> You're trying to present an "instead of" that assumes I should want native apps
Yes.
> and should jump through hoops to find a way to get what I want from apps that aren't designed for it
What do you want which isn't designed for a native app?
> I want web apps, because they already do what I want, and keep getting better.
Perhaps. But where a web app might do what you want and get better, a native app can do what you want and get even more better.
> The best available application sandboxing solution that provides useful comprehensive APIs is the web.
You missed the next part: Or, hey, use an open source operating system and extend the existing sandbox solutions for whatever you think is missing.
> If an application is open, then sure, there are plenty of other options. If an application isn't open, I want it contained in a sandbox not of its own making, that it can't escape, that provides sufficiently comprehensive APIs such that interesting applications get built for it, and that keeps the user in control.
So you're either wanting to use and develop for Linux, or you're wanting to build apps that fit in walled gardens.
Guess which one lets you build and/or run native apps in a sandbox not of its own making, and provides comprehensive APIs, and keeps the user in control? It's not macOS or Windows, it's not iOS or Android, and it's definitely not web apps (which are the least common denominator of the list).
> What do you want which isn't designed for a native app?
Running in a user-agent which is explicitly adversarial to the app's interests and capable of e.g. filtering out and rejecting its HTTPS requests and changing its displayed content based on user preferences, such as preventing the loading or display of advertisements/tracking/etc.
Please by all means suggest an established sandboxing technology that applications use that already does that. If your answer is "you could extend existing native-application sandboxes to be capable of that", my response is "why should I bother when I already have one that does what I want and that applications actually use?".
I would love to instead have a world in which everything is Open Source, in which case it'd be less necessary. Given that we're not in that world, the web is the platform I want proprietary applications to live in.
> So you're either wanting to use and develop for Linux, or you're wanting to build apps that fit in walled gardens.
I already use and develop for Linux, for a variety of Open Source applications. When I run other people's applications, I want them to either be Open Source or I want them to stay confined to a browser tab. Browsers aren't a "walled garden", they're a containment mechanism that works for the user.
> Guess which one lets you build and/or run native apps in a sandbox not of its own making, and provides comprehensive APIs, and keeps the user in control?
Delete the word "native" and the answer is "the web". And you've made zero compelling cases for adding the constraint "native".
To be clear, I could easily describe cases where native applications are better. For instance, I don't particularly want to run a code editor on the web, though many people do. 100% of those are cases where I seek out Open Source applications, so that I can trust them to not be doing things counter to my interests. And such applications don't need the same kind of sandboxing; they need to guard against security issues, but they don't generally need to guard against the application itself intentionally doing things against the user's interests. (That said, things like the xz backdoor do happen, which is an argument for being able to sandbox individual libraries and not just whole applications. But again, that's addressed by coarse-grained sandboxes like "this code shouldn't be doing this whole class of things at all".)
> Running in a user-agent which is explicitly adversarial to the app's interests and capable of e.g. filtering out and rejecting its HTTPS requests and changing its displayed content based on user preferences, such as preventing the loading or display of advertisements/tracking/etc.
I would love to have that in my OS. But, let me know what browser you think that is. It's not Firefox, nor Chrome, and certainly not Edge.
> Please by all means suggest an established sandboxing technology that applications use that already does that.
Linux cgroups is an established sandboxing technology. It has the potential to do what you want but currently needs more work to make it simple.
Applications don't use it to the extent that they should.
> why should I bother when I already have one that does what I want and that applications actually use?
Because browsers don't do what you want. Browsers have been subverted to no longer be user agents. Browsers don't reject HTTPS requests that aren't in the best interests of users. You have to install extensions to get that. If you have to customize your "user agent" then I suggest that customization belongs at the OS level. Otherwise, for example, in the case of Windows or macOS, you're just running someone else's game and the browser is merely a veneer.
> When I run other people's applications, I want them to either be Open Source or I want them to stay confined to a browser tab.
I want more restriction than a browser tab. I want more restriction than browsers are going. I want this in the OS and the reason it doesn't yet exist is because there are so many web developers who build terrible web apps instead of learning computer science to build a (terrible) native application and ask for the same restrictions in the OS instead of a browser.
Access to store and retrieve user credentials? No. I want to run multiple instances of the same app without every app seeing all of the credentials. I want a separate password manager that lets me choose when or where to provide credentials.
Access to store things on my computer [0]? No thanks at all. If you're running in a browser, you should be lightweight. You should eat the storage expenses for your app and you should minimize your app's size to minimize your network transfer costs. I have very limited storage space, limited write endurance, and web apps waste both.
Run stuff in the background [1]? No. Run your compute on your own hardware. Power is expensive and that web app running whatever it's running is making my whole system slow down. Ten different tabs, for six different apps, all thinking they can run whatever the hell they want, and leaves very little available for me to actually get work done.
Access to my GPU [2]? Dude, no. I have a slow GPU and that crappy web app is slowing everything down while eating both main memory and also GPU memory. And who knows what kind of security isolation GPUs have these days (protip: none)!
Access to my USB devices [3]? No friggen thanks. That slow hard disk? It's USB. And that USB bus? Yeah it's slow too. And what a security nightmare: that's where my USB-to-ethernet adapter is, on the same slow bus!
Microphone? Camera? System notifications? No, no, no [4].
I want what you want, but I want it at the OS level. Without OS-level control, that web app isolation makes everything worse.
[0]: https://en.wikipedia.org/wiki/Web_storage
[1]: https://en.wikipedia.org/wiki/Web_worker
[2]: https://en.wikipedia.org/wiki/WebGPU
[3]: https://en.wikipedia.org/wiki/WebUSB
[4]: I got lazy and stopped looking for more web APIs for you
1 reply →