An unofficial, read-only Hacker News reader.

Show HN: Three Linux VMs in a browser tab, each running a different browser (opens external site)

153 points by michidk 2 days ago | michidk.github.io | 34 comments on HN

View full thread · View on Hacker News

Comment thread (3)

  1. Can you please stop posting those comments that conflate memory corruption bugs with isolation escapes?
    Replies (1)
    1. There is zero conflation. WASM does not isolate what you think it isolates as long as the application is running in a memory corruptible engine. Compiling something from C to WASM does not get rid of those C-style vulnerabilities in the guest (which is what attackers use to escape isolation in the first place). That is the main point.

      In fact, you are believing that WASM solves all our isolation problems if something like Linux as the guest application (written in C) is running in the browser, when that is a further from the truth.

      Put it another way: May people thought "microVMs" were "safe" until AI agents found both types of bugs in Linux (key point here) to escape KVM's "hardware isolation" that microVMs use.

      It is even worse. WASM runs the entire application all in a single piece of linear memory and it doesn't even have basic protections (ASLR) to make it difficult for attackers to escape. Just because it runs in WASM, does not mean that the protections are guaranteed for all code, especially converted C/C++ code.

      We are now in an era where AI agents are tearing apart C/C++ based code every day and there are no limits. Therefore that risk is not removed and it still exists regardless.

      Replies (1)
      1. > There is zero conflation.

        A memory corruption bug in the _client memory_ doesn't automatically translate to a memory corruption bug in the _host memory_, which is required for a pathway for a sandbox escape to happen. Additionally a memory corruption of the host memory doesn't automatically translate to a sandbox escape. Even then, with that sandbox escape in the scenario of a browser you usually end up with access to a V8 isolate, but that still only compromises the single website (the website that already has made the decision to load the WASM), so at this point this isn't any worse than loading an arbitrary .js snippet into your website. To make this even worse you would additionally need to find a sandbox escape for the V8 isolate to possible get something like a browser RCE.

        > Compiling something from C to WASM does not get rid of those C-style vulnerabilities in the guest (which is what attackers use to escape isolation in the first place).

        > ... does not mean that the protections are guaranteed for all code, especially converted C/C++ code.

        No, that's not what they use to escape the isolation at all. In an untrusted WASM scenario, you already assume that an attacker can generate arbitrary malicious WASM. There is no need to add the additional layer of indirection where an attacker has to first create malicious C that is then translated to malicious WASM. If the runtime can't possibly contain malicious WASM, then it's already broken anyways.

        > WASM runs the entire application all in a single piece of linear memory and it doesn't even have basic protections (ASLR) to make it difficult for attackers to escape

        As stated above that's not related to sandbox escapes at all. The papers you cited in your comment on the other thread that documented this had the correct conclusions: C programs translated to WASM will likely be exposed to more memory related bugs due to lack of measures like ASLR. However that will typically only have bearing on inner-application memory issues, like e.g. a bug in the GUI of a password manager allowing to read passwords from elsewhere in its memory. Yes, C programs may counterintuitively turn less secure rather than more secure inside WASM, but it does in no way provide you with additional venues of crafting a sandbox escape that weren't already there.

        ---

        Please draw out the attack scenario you vaguely outline in concrete steps and anyone can see how ridiculous this is. In something like this demo or trynix, you would need to start with a supply chain attack and have it contain a chain of ~5 CVSS ~9 exploits.