mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-07 08:18:41 +09:00
Make the url bar strip javascript even when preceded by control characters
This commit is contained in:
parent
3df0152d88
commit
b1ed995cb1
1 changed files with 1 additions and 1 deletions
|
|
@ -5688,7 +5688,7 @@ function middleMousePaste(event) {
|
|||
function stripUnsafeProtocolOnPaste(pasteData) {
|
||||
// Don't allow pasting javascript URIs since we don't support
|
||||
// LOAD_FLAGS_DISALLOW_INHERIT_PRINCIPAL for those.
|
||||
return pasteData.replace(/\r?\n/g, "").replace(/^(?:\s*javascript:)+/i, "");
|
||||
return pasteData.replace(/\r?\n/g, "").replace(/^(?:\W*javascript:)+/i, "");
|
||||
}
|
||||
|
||||
// handleDroppedLink has the following 2 overloads:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue