userscripts icon indicating copy to clipboard operation
userscripts copied to clipboard

GM.addElement support

Open UtterDonkey opened this issue 2 years ago • 5 comments

Could the GM.addElement API be added which would allow elements such as script elements to be added into the page bypassing CSP?

UtterDonkey avatar Feb 14 '24 10:02 UtterDonkey

Referring to #106, there currently seems to be no feasible way to bypass the severely restricted CSP in Safari.

ACTCD avatar Feb 14 '24 16:02 ACTCD

Isn't it done in the iOS version of tampermonkey?

UtterDonkey avatar Feb 14 '24 17:02 UtterDonkey

Have you actually tested this on your own?

We don't have access to the extension, and it's not open source, so we don't know in what way it bypasses CSP if it's implemented.

If you know, new knowledge is always welcome.

ACTCD avatar Feb 14 '24 23:02 ACTCD

Would the way it bypasses CSP in safari be different from how it does it in other browsers?

UtterDonkey avatar Feb 14 '24 23:02 UtterDonkey

Yes, it's not the same, the relevant APIs are lacking in Safari and have tighter restrictions.

ACTCD avatar Feb 14 '24 23:02 ACTCD