mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-10-08 00:07:30 +09:00
Reject opening intents with file data schemes.
This commit is contained in:
parent
27bb9f94c3
commit
ab541cba98
1 changed files with 6 additions and 0 deletions
|
|
@ -287,6 +287,12 @@ public final class IntentHelper implements GeckoEventListener,
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
final Uri data = intent.getData();
|
||||||
|
if (data != null && "file".equals(data.normalizeScheme().getScheme())) {
|
||||||
|
Log.w(LOGTAG, "Blocked intent with \"file://\" data scheme.");
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
// Only open applications which can accept arbitrary data from a browser.
|
// Only open applications which can accept arbitrary data from a browser.
|
||||||
intent.addCategory(Intent.CATEGORY_BROWSABLE);
|
intent.addCategory(Intent.CATEGORY_BROWSABLE);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue