Summary: | Greasemonkey doesn't check content type | ||
---|---|---|---|
Product: | [Applications] Falkon | Reporter: | Schimon Jehudah <sjehuda> |
Component: | extensions | Assignee: | David Rosca <nowrep> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | jurajoravec, rory.ashton |
Priority: | NOR | ||
Version: | unspecified | ||
Target Milestone: | --- | ||
Platform: | Other | ||
OS: | Linux | ||
Latest Commit: | https://invent.kde.org/network/falkon/-/commit/4772efb483473f2a1f0f4268589bfe9a6002838d | Version Fixed In: | |
Sentry Crash Report: |
Description
Schimon Jehudah
2023-03-16 20:18:35 UTC
Greasemonkey only checks the URL. If it ends with "user.js" it is regarded as userscript and should b e installed and hidden from user. My proposed solutions are to: - always allow loading the userscript code (user will always see it). - Adapt the GreaseMonkey code to detect if the file is a proper userscript or not. OR - When the "user.js" is detected in URL try to download it and based on results allow to display the file in browser. (In reply to Schimon Jehudah from comment #0) > It appears that Greasemonkey doesn't check content type. > When Greasemonkey is enabled, navigating to the following link (HTML > filetype) won't be possible. > https://github.com/glitsj16/firejail-handler-extra/blob/master/fjyt.user.js If you install GM on FF it also opens that page normally. To trigger the install click 'raw' button on the upper right of the code box. A possibly relevant merge request was started @ https://invent.kde.org/network/falkon/-/merge_requests/90 Git commit 4772efb483473f2a1f0f4268589bfe9a6002838d by Juraj Oravec. Committed on 06/11/2024 at 19:10. Pushed by jurajo into branch 'master'. GreaseMonkey - Check content type of url *.user.js - Do not stop loading the page with url matching user script - Only match clicked links Signed-off-by: Juraj Oravec <jurajoravec@mailo.com> M +7 -0 src/plugins/GreaseMonkey/gm_downloader.cpp M +2 -3 src/plugins/GreaseMonkey/gm_plugin.cpp https://invent.kde.org/network/falkon/-/commit/4772efb483473f2a1f0f4268589bfe9a6002838d |