This repository has been archived by the owner on Oct 11, 2020. It is now read-only.
forked from gorhill/uBlock
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Not working: - Downloads (Edge doesn't allow downloads from background pages) - Definition updates (invalid handle error)
- Loading branch information
1 parent
41b20ca
commit 4de6874
Showing
15 changed files
with
2,056 additions
and
0 deletions.
There are no files selected for viewing
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<title></title> | ||
<script async src="js/is-webrtc-supported.js"></script> | ||
</head> | ||
<body></body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
/******************************************************************************* | ||
uBlock Origin - a browser extension to block requests. | ||
Copyright (C) 2015 Raymond Hill | ||
This program is free software: you can redistribute it and/or modify | ||
it under the terms of the GNU General Public License as published by | ||
the Free Software Foundation, either version 3 of the License, or | ||
(at your option) any later version. | ||
This program is distributed in the hope that it will be useful, | ||
but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
GNU General Public License for more details. | ||
You should have received a copy of the GNU General Public License | ||
along with this program. If not, see {http://www.gnu.org/licenses/}. | ||
Home: https://github.com/gorhill/uBlock | ||
*/ | ||
|
||
// https://github.com/gorhill/uBlock/issues/533#issuecomment-164292868 | ||
// If WebRTC is supported, there won't be an exception if we | ||
// try to instanciate a peer connection object. | ||
|
||
// https://github.com/gorhill/uBlock/issues/533#issuecomment-168097594 | ||
// Because Chromium leaks WebRTC connections after they have been closed | ||
// and forgotten, we need to test for WebRTC support inside an iframe, this | ||
// way the closed and forgottetn WebRTC connections are properly garbage | ||
// collected. | ||
|
||
(function() { | ||
'use strict'; | ||
|
||
var pc = null; | ||
try { | ||
var PC = self.RTCPeerConnection || self.webkitRTCPeerConnection; | ||
if ( PC ) { | ||
pc = new PC(null); | ||
} | ||
} catch (ex) { | ||
console.error(ex); | ||
} | ||
if ( pc !== null ) { | ||
pc.close(); | ||
} | ||
|
||
window.top.postMessage( | ||
pc !== null ? 'webRTCSupported' : 'webRTCNotSupported', | ||
window.location.origin | ||
); | ||
})(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
{ | ||
"$schema": "http://json-schema.org/draft-03/schema#", | ||
"type": "object", | ||
"properties": { | ||
"adminSettings": { | ||
"title": "A valid JSON string compliant with uBO's backup format.", | ||
"description": "All entries present will overwrite local settings.", | ||
"type": "string" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,64 @@ | ||
{ | ||
"manifest_version": 2, | ||
|
||
"name": "uBlock Origin", | ||
"version": "1.7.7", | ||
|
||
"default_locale": "en", | ||
"description": "__MSG_extShortDesc__", | ||
"icons": { | ||
"16": "img/icon_16.png", | ||
"128": "img/icon_128.png" | ||
}, | ||
|
||
"browser_action": { | ||
"default_icon": { | ||
"19": "img/browsericons/icon19.png", | ||
"38": "img/browsericons/icon38.png" | ||
}, | ||
"default_title": "uBlock Origin", | ||
"default_popup": "popup.html" | ||
}, | ||
|
||
"author": "All uBlock Origin contributors", | ||
"background": { | ||
"page": "background.html", | ||
"persistent": true | ||
}, | ||
"content_scripts": [ | ||
{ | ||
"matches": ["http://*/*", "https://*/*"], | ||
"js": ["js/vapi-client.js", "js/contentscript.js"], | ||
"run_at": "document_start", | ||
"all_frames": true | ||
}, | ||
{ | ||
"matches": ["http://*/*", "https://*/*"], | ||
"js": ["js/scriptlets/subscriber.js"], | ||
"run_at": "document_idle", | ||
"all_frames": false | ||
} | ||
], | ||
"incognito": "split", | ||
"minimum_edge_version": "38.14393", | ||
"options_page": "dashboard.html", | ||
"options_ui": { | ||
"page": "options_ui.html" | ||
}, | ||
"permissions": [ | ||
"contextMenus", | ||
"privacy", | ||
"storage", | ||
"tabs", | ||
"unlimitedStorage", | ||
"webNavigation", | ||
"webRequest", | ||
"webRequestBlocking", | ||
"http://*/*", | ||
"https://*/*" | ||
], | ||
"short_name": "uBlock₀", | ||
"storage": { | ||
"managed_schema": "managed_storage.json" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<script src="js/vapi-client.js"></script> | ||
<script src="js/options_ui.js"></script> | ||
<title></title> | ||
</head> | ||
<body> | ||
<a href="dashboard.html" target="uBO">Dashboard</a> | ||
</body> | ||
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
/******************************************************************************* | ||
µBlock - a browser extension to block requests. | ||
Copyright (C) 2015 The µBlock authors | ||
This program is free software: you can redistribute it and/or modify | ||
it under the terms of the GNU General Public License as published by | ||
the Free Software Foundation, either version 3 of the License, or | ||
(at your option) any later version. | ||
This program is distributed in the hope that it will be useful, | ||
but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
GNU General Public License for more details. | ||
You should have received a copy of the GNU General Public License | ||
along with this program. If not, see {http://www.gnu.org/licenses/}. | ||
Home: https://github.com/gorhill/uBlock | ||
*/ | ||
|
||
/******************************************************************************/ | ||
|
||
(function() { | ||
|
||
/******************************************************************************/ | ||
|
||
'use strict'; | ||
|
||
vAPI.messaging.send( | ||
'default', | ||
{ | ||
what: 'gotoURL', | ||
details: { | ||
url: 'dashboard.html', | ||
select: true, | ||
index: -1 | ||
} | ||
} | ||
); | ||
window.close(); | ||
|
||
/******************************************************************************/ | ||
|
||
})(); | ||
|
||
/******************************************************************************/ |
Oops, something went wrong.