Remix.run Logo
▲ Banou an hour ago

In the case of password managers, amy decent one will put their DOM elements in a closed shadowDOM root, which prevents the page scripts from interacting with it entirely.

▲forgotmypw17 an hour ago | parent [-]

Shadow DOM is not a security boundary, and can be bypassed.

▲moi2388 35 minutes ago | parent [-]

From a page, which loads after the extension? How?

▲forgotmypw17 28 minutes ago | parent [-]

>The {mode: "open"} argument gives the page a way to break the encapsulation of your shadow DOM. If you don't want to give the page this ability, pass {mode: "closed"} instead, and then shadowRoot returns null.

>However, you should not consider this a strong security mechanism, because there are ways it can be evaded, for example by browser extensions running in the page. It's more of an indication that the page should not access the internals of your shadow DOM tree.

https://developer.mozilla.org/en-US/docs/Web/API/Web_compone...

This presentation talks about using window.find() and other methods:

https://speakerdeck.com/masatokinugawa/shadow-dom-and-securi...