AdsBypasser

Bypass Ads

当前为 2016-05-02 提交的版本,查看 最新版本

  1. // ==UserScript==
  2. // @name AdsBypasser
  3. // @namespace AdsBypasser
  4. // @description Bypass Ads
  5. // @copyright 2012+, Wei-Cheng Pan (legnaleurc)
  6. // @version 5.54.0
  7. // @license BSD
  8. // @homepageURL https://adsbypasser.github.io/
  9. // @supportURL https://github.com/adsbypasser/adsbypasser/issues
  10. // @icon https://raw.githubusercontent.com/adsbypasser/adsbypasser/v5.54.0/img/logo.png
  11. // @grant unsafeWindow
  12. // @grant GM_xmlhttpRequest
  13. // @grant GM_addStyle
  14. // @grant GM_getResourceText
  15. // @grant GM_getResourceURL
  16. // @grant GM_getValue
  17. // @grant GM_openInTab
  18. // @grant GM_registerMenuCommand
  19. // @grant GM_setValue
  20. // @run-at document-start
  21. // @resource alignCenter https://raw.githubusercontent.com/adsbypasser/adsbypasser/v5.54.0/css/align_center.css
  22. // @resource scaleImage https://raw.githubusercontent.com/adsbypasser/adsbypasser/v5.54.0/css/scale_image.css
  23. // @resource bgImage https://raw.githubusercontent.com/adsbypasser/adsbypasser/v5.54.0/img/imagedoc-darknoise.png
  24. // @include http://*
  25. // @include https://*
  26. // ==/UserScript==
  27. (function (context, factory) {
  28. if (typeof module === 'object' && typeof module.exports === 'object') {
  29. var bluebird = require('bluebird');
  30. module.exports = factory(context, bluebird.Promise);
  31. } else {
  32. var P = null;
  33. if (context.unsafeWindow.Future) {
  34. P = function (fn) {
  35. return context.unsafeWindow.Future.call(this, function (fr) {
  36. fn(fr.resolve.bind(fr), fr.reject.bind(fr));
  37. });
  38. };
  39. } else if (context.PromiseResolver) {
  40. P = function (fn) {
  41. return new context.Promise(function (pr) {
  42. fn(pr.resolve.bind(pr), pr.reject.bind(pr));
  43. });
  44. };
  45. } else {
  46. P = context.Promise;
  47. }
  48. factory(context, P);
  49. }
  50. }(this, function (context, Promise) {
  51. 'use strict';
  52. var _ = context._ = {};
  53. function setupStack () {
  54. if (Error.captureStackTrace) {
  55. Error.captureStackTrace(this, this.constructor);
  56. } else if (!this.hasOwnProperty('stack')) {
  57. var stack = (new Error()).stack.split('\n').slice(2);
  58. var e = stack[0].match(/^.*@(.*):(\d*)$/);
  59. this.fileName = e[1];
  60. this.lineNumber = parseInt(e[2], 10);
  61. this.stack = stack.join('\n');
  62. }
  63. }
  64. function AdsBypasserError (message) {
  65. setupStack.call(this);
  66. this.message = message;
  67. }
  68. AdsBypasserError.prototype = Object.create(Error.prototype);
  69. AdsBypasserError.prototype.constructor = AdsBypasserError;
  70. AdsBypasserError.prototype.name = 'AdsBypasserError';
  71. AdsBypasserError.extend = function (protoProps, staticProps) {
  72. var parent = this, child = function () {
  73. setupStack.call(this);
  74. protoProps.constructor.apply(this, arguments);
  75. };
  76. extend(child, parent, staticProps);
  77. child.prototype = Object.create(parent.prototype);
  78. extend(child.prototype, protoProps);
  79. child.prototype.constructor = child;
  80. child.super = parent.prototype;
  81. return child;
  82. };
  83. AdsBypasserError.super = null;
  84. _.AdsBypasserError = AdsBypasserError;
  85. function any (c, fn) {
  86. if (c.some) {
  87. return c.some(fn);
  88. }
  89. if (typeof c.length === 'number') {
  90. return Array.prototype.some.call(c, fn);
  91. }
  92. return Object.keys(c).some(function (k) {
  93. return fn(c[k], k, c);
  94. });
  95. }
  96. function all (c, fn) {
  97. if (c.every) {
  98. return c.every(fn);
  99. }
  100. if (typeof c.length === 'number') {
  101. return Array.prototype.every.call(c, fn);
  102. }
  103. return Object.keys(c).every(function (k) {
  104. return fn(c[k], k, c);
  105. });
  106. }
  107. function each (c, fn) {
  108. if (c.forEach) {
  109. c.forEach(fn);
  110. } else if (typeof c.length === 'number') {
  111. Array.prototype.forEach.call(c, fn);
  112. } else {
  113. Object.keys(c).forEach(function (k) {
  114. fn(c[k], k, c);
  115. });
  116. }
  117. }
  118. function map (c, fn) {
  119. if (c.map) {
  120. return c.map(fn);
  121. }
  122. if (typeof c.length === 'number') {
  123. return Array.prototype.map.call(c, fn);
  124. }
  125. return Object.keys(c).map(function (k) {
  126. return fn(c[k], k, c);
  127. });
  128. }
  129. function extend(c) {
  130. Array.prototype.slice.call(arguments, 1).forEach(function (source) {
  131. if (!source) {
  132. return;
  133. }
  134. _.C(source).each(function (v, k) {
  135. c[k] = v;
  136. });
  137. });
  138. return c;
  139. }
  140. function CollectionProxy (collection) {
  141. this._c = collection;
  142. }
  143. CollectionProxy.prototype.size = function () {
  144. if (typeof this._c.length === 'number') {
  145. return this._c.length;
  146. }
  147. return Object.keys(c).length;
  148. };
  149. CollectionProxy.prototype.at = function (k) {
  150. return this._c[k];
  151. };
  152. CollectionProxy.prototype.each = function (fn) {
  153. each(this._c, fn);
  154. return this;
  155. };
  156. CollectionProxy.prototype.find = function (fn) {
  157. var result;
  158. any(this._c, function (value, index, self) {
  159. var tmp = fn(value, index, self);
  160. if (tmp !== _.none) {
  161. result = {
  162. key: index,
  163. value: value,
  164. payload: tmp,
  165. };
  166. return true;
  167. }
  168. return false;
  169. });
  170. return result;
  171. };
  172. CollectionProxy.prototype.all = function (fn) {
  173. return all(this._c, fn);
  174. };
  175. CollectionProxy.prototype.map = function (fn) {
  176. return map(this._c, fn);
  177. };
  178. _.C = function (collection) {
  179. return new CollectionProxy(collection);
  180. };
  181. _.T = function (s) {
  182. if (typeof s === 'string') {
  183. } else if (s instanceof String) {
  184. s = s.toString();
  185. } else {
  186. throw new AdsBypasserError('template must be a string');
  187. }
  188. var T = {
  189. '{{': '{',
  190. '}}': '}',
  191. };
  192. return function () {
  193. var args = Array.prototype.slice.call(arguments);
  194. var kwargs = args[args.length-1];
  195. return s.replace(/\{\{|\}\}|\{([^\}]+)\}/g, function (m, key) {
  196. if (T.hasOwnProperty(m)) {
  197. return T[m];
  198. }
  199. if (args.hasOwnProperty(key)) {
  200. return args[key];
  201. }
  202. if (kwargs.hasOwnProperty(key)) {
  203. return kwargs[key];
  204. }
  205. return m;
  206. });
  207. };
  208. };
  209. _.P = function (fn) {
  210. if (typeof fn !== 'function') {
  211. throw new _.AdsBypasserError('must give a function');
  212. }
  213. var slice = Array.prototype.slice;
  214. var args = slice.call(arguments, 1);
  215. return function () {
  216. return fn.apply(this, args.concat(slice.call(arguments)));
  217. };
  218. };
  219. _.D = function (fn) {
  220. return new Promise(fn);
  221. };
  222. _.parseJSON = function (json) {
  223. try {
  224. return JSON.parse(json);
  225. } catch (e) {
  226. _.warn(e, json);
  227. }
  228. return _.none;
  229. };
  230. _.isString = function (value) {
  231. return (typeof value === 'string') || (value instanceof String);
  232. };
  233. _.nop = function () {
  234. };
  235. _.none = _.nop;
  236. _.wait = function (msDelay) {
  237. return _.D(function (resolve, reject) {
  238. setTimeout(resolve, msDelay);
  239. });
  240. };
  241. _.try = function (msInterval, fn) {
  242. return _.D(function (resolve, reject) {
  243. var handle = setInterval(function () {
  244. var result = fn();
  245. if (result !== _.none) {
  246. clearInterval(handle);
  247. resolve(result);
  248. }
  249. }, msInterval);
  250. });
  251. };
  252. function log (method, args) {
  253. if (_._quiet) {
  254. return;
  255. }
  256. args = Array.prototype.slice.call(args);
  257. if (_.isString(args[0])) {
  258. args[0] = 'AdsBypasser: ' + args[0];
  259. } else {
  260. args.unshift('AdsBypasser:');
  261. }
  262. var f = console[method];
  263. if (typeof f === 'function') {
  264. f.apply(console, args);
  265. }
  266. }
  267. _._quiet = false;
  268. _.info = function () {
  269. log('info', arguments);
  270. };
  271. _.warn = function () {
  272. log('warn', arguments);
  273. };
  274. return _;
  275. }));
  276. (function (context, factory) {
  277. if (typeof module === 'object' && typeof module.exports === 'object') {
  278. module.exports = function (context) {
  279. var core = require('./core.js');
  280. return factory(context, core);
  281. };
  282. } else {
  283. context.$ = factory(context, context._);
  284. }
  285. }(this, function (context, _) {
  286. 'use strict';
  287. var window = context.window;
  288. var document = window.document;
  289. var DomNotFoundError = _.AdsBypasserError.extend({
  290. name: 'DomNotFoundError',
  291. constructor: function (selector) {
  292. DomNotFoundError.super.constructor.call(this, _.T('`{0}` not found')(selector));
  293. },
  294. });
  295. var $ = function (selector, context) {
  296. if (!context || !context.querySelector) {
  297. context = document;
  298. }
  299. var n = context.querySelector(selector);
  300. if (!n) {
  301. throw new DomNotFoundError(selector);
  302. }
  303. return n;
  304. };
  305. $.$ = function (selector, context) {
  306. try {
  307. return $(selector, context);
  308. } catch (e) {
  309. return null;
  310. }
  311. };
  312. $.$$ = function (selector, context) {
  313. if (!context || !context.querySelectorAll) {
  314. context = document;
  315. }
  316. var ns = context.querySelectorAll(selector);
  317. return _.C(ns);
  318. };
  319. $.toDOM = function(rawHTML) {
  320. try {
  321. var parser = new DOMParser();
  322. var DOMHTML = parser.parseFromString(rawHTML, "text/html");
  323. return DOMHTML;
  324. } catch (e) {
  325. throw new _.AdsBypasserError('could not parse HTML to DOM');
  326. }
  327. };
  328. $.removeNodes = function (selector, context) {
  329. $.$$(selector, context).each(function (e) {
  330. e.parentNode.removeChild(e);
  331. });
  332. };
  333. function searchScriptsByRegExp (pattern, context) {
  334. var m = $.$$('script', context).find(function (s) {
  335. var m = s.innerHTML.match(pattern);
  336. if (!m) {
  337. return _.none;
  338. }
  339. return m;
  340. });
  341. if (!m) {
  342. return null;
  343. }
  344. return m.payload;
  345. }
  346. function searchScriptsByString (pattern, context) {
  347. var m = $.$$('script', context).find(function (s) {
  348. var m = s.innerHTML.indexOf(pattern);
  349. if (m < 0) {
  350. return _.none;
  351. }
  352. return m;
  353. });
  354. if (!m) {
  355. return null;
  356. }
  357. return m.value.innerHTML;
  358. }
  359. $.searchScripts = function (pattern, context) {
  360. if (pattern instanceof RegExp) {
  361. return searchScriptsByRegExp(pattern, context);
  362. } else if (_.isString(pattern)) {
  363. return searchScriptsByString(pattern, context);
  364. } else {
  365. return null;
  366. }
  367. };
  368. return $;
  369. }));
  370. (function (context, factory) {
  371. if (typeof module === 'object' && typeof module.exports === 'object') {
  372. module.exports = function (context, GM) {
  373. var core = require('./core.js');
  374. return factory(context, GM, core);
  375. };
  376. } else {
  377. factory(context, {
  378. xmlhttpRequest: GM_xmlhttpRequest,
  379. }, context._);
  380. }
  381. }(this, function (context, GM, _) {
  382. 'use strict';
  383. var window = context.window;
  384. var document = window.document;
  385. var $ = context.$ || {};
  386. function deepJoin (prefix, object) {
  387. return _.C(object).map(function (v, k) {
  388. var key = _.T('{0}[{1}]')(prefix, k);
  389. if (typeof v === 'object') {
  390. return deepJoin(key, v);
  391. }
  392. return _.T('{0}={1}').apply(this, [key, v].map(encodeURIComponent));
  393. }).join('&');
  394. }
  395. function toQuery (data) {
  396. var type = typeof data;
  397. if (data === null || (type !== 'string' && type !== 'object')) {
  398. return '';
  399. }
  400. if (type === 'string') {
  401. return data;
  402. }
  403. if (data instanceof String) {
  404. return data.toString();
  405. }
  406. return _.C(data).map(function (v, k) {
  407. if (typeof v === 'object') {
  408. return deepJoin(k, v);
  409. }
  410. return _.T('{0}={1}').apply(this, [k, v].map(encodeURIComponent));
  411. }).join('&');
  412. }
  413. function ajax (method, url, data, headers) {
  414. var l = document.createElement('a');
  415. l.href = url;
  416. var reqHost = l.hostname;
  417. var overrideHeaders = {
  418. Host: reqHost || window.location.host,
  419. Origin: window.location.origin,
  420. Referer: window.location.href,
  421. 'X-Requested-With': 'XMLHttpRequest',
  422. };
  423. _.C(overrideHeaders).each(function (v, k, c) {
  424. if (headers[k] === _.none) {
  425. delete headers[k];
  426. } else {
  427. headers[k] = v;
  428. }
  429. });
  430. if (data) {
  431. if (headers['Content-Type'].indexOf('json') >= 0) {
  432. data = JSON.stringify(data);
  433. } else {
  434. data = toQuery(data);
  435. }
  436. headers['Content-Length'] = data.length;
  437. }
  438. var xhr = null;
  439. var promise = _.D(function (resolve, reject) {
  440. xhr = GM.xmlhttpRequest({
  441. method: method,
  442. url: url,
  443. data: data,
  444. headers: headers,
  445. onload: function (response) {
  446. response = (typeof response.responseText !== 'undefined') ? response : this;
  447. if (response.status !== 200) {
  448. reject(response.responseText);
  449. } else {
  450. resolve(response.responseText);
  451. }
  452. },
  453. onerror: function (response) {
  454. response = (typeof response.responseText !== 'undefined') ? response : this;
  455. reject(response.responseText);
  456. },
  457. });
  458. });
  459. promise.abort = function () {
  460. xhr.abort();
  461. };
  462. return promise;
  463. }
  464. $.get = function (url, data, headers) {
  465. data = toQuery(data);
  466. data = data ? '?' + data : '';
  467. headers = headers || {};
  468. return ajax('GET', url + data, '', headers);
  469. };
  470. $.post = function (url, data, headers) {
  471. var h = {
  472. 'Content-Type': 'application/x-www-form-urlencoded; charset=UTF-8',
  473. };
  474. if (headers) {
  475. _.C(headers).each(function (v, k) {
  476. h[k] = v;
  477. });
  478. }
  479. return ajax('POST', url, data, h);
  480. };
  481. return $;
  482. }));
  483. (function (context, factory) {
  484. if (typeof module === 'object' && typeof module.exports === 'object') {
  485. module.exports = function (context) {
  486. var core = require('./core.js');
  487. return factory(context, core);
  488. };
  489. } else {
  490. factory(context, context._);
  491. }
  492. }(this, function (context, _) {
  493. 'use strict';
  494. var window = context.window;
  495. var document = window.document;
  496. var $ = context.$ || {};
  497. $.setCookie = function (key, value) {
  498. var now = new Date();
  499. now.setTime(now.getTime() + 3600 * 1000);
  500. var tpl = _.T('{0}={1};path={2};');
  501. document.cookie = tpl(key, value, window.location.pathname, now.toUTCString());
  502. };
  503. $.getCookie = function (key) {
  504. var c = _.C(document.cookie.split(';')).find(function (v) {
  505. var k = v.replace(/^\s*([a-zA-Z0-9-_]+)=.+$/, '$1');
  506. if (k !== key) {
  507. return _.none;
  508. }
  509. });
  510. if (!c) {
  511. return null;
  512. }
  513. c = c.value.replace(/^\s*[a-zA-Z0-9-_]+=([^;]+).?$/, '$1');
  514. if (!c) {
  515. return null;
  516. }
  517. return c;
  518. };
  519. $.resetCookies = function () {
  520. var a = document.domain;
  521. var b = document.domain.replace(/^www\./, '');
  522. var c = document.domain.replace(/^(\w+\.)+?(\w+\.\w+)$/, '$2');
  523. var d = (new Date(1e3)).toUTCString();
  524. _.C(document.cookie.split(';')).each(function (v) {
  525. var k = v.replace(/^\s*(\w+)=.+$/, '$1');
  526. document.cookie = _.T('{0}=;expires={1};')(k, d);
  527. document.cookie = _.T('{0}=;path=/;expires={1};')(k, d);
  528. var e = _.T('{0}=;path=/;domain={1};expires={2};');
  529. document.cookie = e(k, a, d);
  530. document.cookie = e(k, b, d);
  531. document.cookie = e(k, c, d);
  532. });
  533. };
  534. return $;
  535. }));
  536. (function (context, factory) {
  537. if (typeof module === 'object' && typeof module.exports === 'object') {
  538. module.exports = function (context) {
  539. var core = require('./core.js');
  540. return factory(context, core);
  541. };
  542. } else {
  543. factory(context, context._);
  544. }
  545. }(this, function (context, _) {
  546. 'use strict';
  547. var window = context.window;
  548. var document = window.document;
  549. var $ = context.$ || {};
  550. var patterns = [];
  551. $.register = function (pattern) {
  552. patterns.push(pattern);
  553. };
  554. function dispatchByObject (rule, url_6) {
  555. var matched = {};
  556. var passed = _.C(rule).all(function (pattern, part) {
  557. if (pattern instanceof RegExp) {
  558. matched[part] = url_6[part].match(pattern);
  559. } else if (pattern instanceof Array) {
  560. var r = _.C(pattern).find(function (p) {
  561. var m = url_6[part].match(p);
  562. return m || _.none;
  563. });
  564. matched[part] = r ? r.payload : null;
  565. }
  566. return !!matched[part];
  567. });
  568. return passed ? matched : null;
  569. }
  570. function dispatchByRegExp (rule, url_1) {
  571. return url_1.match(rule);
  572. }
  573. function dispatchByArray (byLocation, rules, url_1, url_3, url_6) {
  574. var tmp = _.C(rules).find(function (rule) {
  575. var m = dispatch(byLocation, rule, url_1, url_3, url_6);
  576. if (!m) {
  577. return _.none;
  578. }
  579. return m;
  580. });
  581. return tmp ? tmp.payload : null;
  582. }
  583. function dispatchByString (rule, url_3) {
  584. var scheme = /\*|https?|file|ftp|chrome-extension/;
  585. var host = /\*|(\*\.)?([^\/*]+)/;
  586. var path = /\/.*/;
  587. var up = new RegExp(_.T('^({scheme})://({host})?({path})$')({
  588. scheme: scheme.source,
  589. host: host.source,
  590. path: path.source,
  591. }));
  592. var matched = rule.match(up);
  593. if (!matched) {
  594. return null;
  595. }
  596. scheme = matched[1];
  597. host = matched[2];
  598. var wc = matched[3];
  599. var sd = matched[4];
  600. path = matched[5];
  601. if (scheme === '*' && !/https?/.test(url_3.scheme)) {
  602. return null;
  603. } else if (scheme !== url_3.scheme) {
  604. return null;
  605. }
  606. if (scheme !== 'file' && host !== '*') {
  607. if (wc) {
  608. up = url_3.host.indexOf(sd);
  609. if (up < 0 || up + sd.length !== url_3.host.length) {
  610. return null;
  611. }
  612. } else if (host !== url_3.host) {
  613. return null;
  614. }
  615. }
  616. path = new RegExp(_.T('^{0}$')(path.replace(/[*.\[\]?+#]/g, function (c) {
  617. if (c === '*') {
  618. return '.*';
  619. }
  620. return '\\' + c;
  621. })));
  622. if (!path.test(url_3.path)) {
  623. return null;
  624. }
  625. return url_3;
  626. }
  627. function dispatchByFunction (rule, url_1, url_3, url_6) {
  628. return rule(url_1, url_3, url_6);
  629. }
  630. function dispatch (byLocation, rule, url_1, url_3, url_6) {
  631. if (rule instanceof Array) {
  632. return dispatchByArray(byLocation, rule, url_1, url_3, url_6);
  633. }
  634. if (typeof rule === 'function') {
  635. if (byLocation) {
  636. return null;
  637. }
  638. return dispatchByFunction(rule, url_1, url_3, url_6);
  639. }
  640. if (rule instanceof RegExp) {
  641. return dispatchByRegExp(rule, url_1);
  642. }
  643. if (_.isString(rule)) {
  644. return dispatchByString(rule, url_3);
  645. }
  646. return dispatchByObject(rule, url_6);
  647. }
  648. $._findHandler = function (byLocation) {
  649. var url_1 = window.location.toString();
  650. var url_3 = {
  651. scheme: window.location.protocol.slice(0, -1),
  652. host: window.location.host,
  653. path: window.location.pathname + window.location.search + window.location.hash,
  654. };
  655. var url_6 = {
  656. scheme: window.location.protocol,
  657. host: window.location.hostname,
  658. port: window.location.port,
  659. path: window.location.pathname,
  660. query: window.location.search,
  661. hash: window.location.hash,
  662. };
  663. var pattern = _.C(patterns).find(function (pattern) {
  664. var m = dispatch(byLocation, pattern.rule, url_1, url_3, url_6);
  665. if (!m) {
  666. return _.none;
  667. }
  668. return m;
  669. });
  670. if (!pattern) {
  671. return null;
  672. }
  673. var matched = pattern.payload;
  674. pattern = pattern.value;
  675. if (!pattern.start && !pattern.ready) {
  676. return null;
  677. }
  678. return {
  679. start: pattern.start ? _.P(pattern.start, matched) : _.nop,
  680. ready: pattern.ready ? _.P(pattern.ready, matched) : _.nop,
  681. };
  682. };
  683. return $;
  684. }));
  685. (function (context, factory) {
  686. if (typeof module === 'object' && typeof module.exports === 'object') {
  687. module.exports = function (context) {
  688. var core = require('./core.js');
  689. return factory(context, core);
  690. };
  691. } else {
  692. factory(context, context._);
  693. }
  694. }(this, function (context, _) {
  695. 'use strict';
  696. var window = context.window;
  697. var document = window.document;
  698. var $ = context.$ || {};
  699. function prepare (e) {
  700. if (!document.body) {
  701. document.body = document.createElement('body');
  702. }
  703. document.body.appendChild(e);
  704. }
  705. function get (url) {
  706. var a = document.createElement('a');
  707. a.href = url;
  708. prepare(a);
  709. a.click();
  710. }
  711. function post (path, params) {
  712. params = params || {};
  713. var form = document.createElement('form');
  714. form.method = 'post';
  715. form.action = path;
  716. _.C(params).each(function (value, key) {
  717. var input = document.createElement('input');
  718. input.type = 'hidden';
  719. input.name = key;
  720. input.value = value;
  721. form.appendChild(input);
  722. });
  723. prepare(form);
  724. form.submit();
  725. }
  726. $.openLink = function (to, options) {
  727. if (!_.isString(to) && !to) {
  728. _.warn('false URL');
  729. return;
  730. }
  731. options = options || {};
  732. var withReferer = typeof options.referer === 'undefined' ? true : options.referer;
  733. var postData = options.post;
  734. var from = window.location.toString();
  735. _.info(_.T('{0} -> {1}')(from, to));
  736. if (postData) {
  737. post(to, postData);
  738. return;
  739. }
  740. if (withReferer) {
  741. get(to);
  742. return;
  743. }
  744. window.top.location.replace(to);
  745. };
  746. return $;
  747. }));
  748. (function (context, factory) {
  749. if (typeof module === 'object' && typeof module.exports === 'object') {
  750. module.exports = function (context) {
  751. var core = require('./core.js');
  752. var ajax = require('./ajax.js');
  753. var $ = ajax(context);
  754. return factory(context, core, $);
  755. };
  756. } else {
  757. factory(context, context._, context.$);
  758. }
  759. }(this, function (context, _, $) {
  760. 'use strict';
  761. var window = context.window;
  762. var unsafeWindow = context.unsafeWindow || (0, eval)('this').window;
  763. var document = window.document;
  764. $.removeAllTimer = function () {
  765. var handle = window.setInterval(_.nop, 10);
  766. while (handle > 0) {
  767. window.clearInterval(handle--);
  768. }
  769. handle = window.setTimeout(_.nop, 10);
  770. while (handle > 0) {
  771. window.clearTimeout(handle--);
  772. }
  773. };
  774. $.generateRandomIP = function () {
  775. return [0,0,0,0].map(function () {
  776. return Math.floor(Math.random() * 256);
  777. }).join('.');
  778. };
  779. $.captcha = function (imgSrc, cb) {
  780. if (!$.config.externalServerSupport) {
  781. return;
  782. }
  783. var a = document.createElement('canvas');
  784. var b = a.getContext('2d');
  785. var c = new Image();
  786. c.src = imgSrc;
  787. c.onload = function () {
  788. a.width = c.width;
  789. a.height = c.height;
  790. b.drawImage(c, 0, 0);
  791. var d = a.toDataURL();
  792. var e = d.substr(d.indexOf(',') + 1);
  793. $.post('http://www.wcpan.info/cgi-bin/captcha.cgi', {
  794. i: e,
  795. }, cb);
  796. };
  797. };
  798. function clone (safe) {
  799. if (safe === null || !(safe instanceof Object)) {
  800. return safe;
  801. }
  802. if (safe instanceof String) {
  803. return safe.toString();
  804. }
  805. if (safe instanceof Function) {
  806. return exportFunction(safe, unsafeWindow, {
  807. allowCrossOriginArguments: true,
  808. });
  809. }
  810. if (safe instanceof Array) {
  811. var unsafe = new unsafeWindow.Array();
  812. for (var i = 0; i < safe.length; ++i) {
  813. unsafe.push(clone(safe[i]));
  814. }
  815. return unsafe;
  816. }
  817. var unsafe = new unsafeWindow.Object();
  818. _.C(safe).each(function (v, k) {
  819. unsafe[k] = clone(v);
  820. });
  821. return unsafe;
  822. }
  823. var MAGIC_KEY = '__adsbypasser_reverse_proxy__';
  824. $.window = (function () {
  825. var isFirefox = typeof InstallTrigger !== 'undefined';
  826. if (!isFirefox) {
  827. return unsafeWindow;
  828. }
  829. var decorator = {
  830. set: function (target, key, value) {
  831. if (key === MAGIC_KEY) {
  832. return false;
  833. }
  834. if (target === unsafeWindow && key === 'open') {
  835. var d = Object.getOwnPropertyDescriptor(target, key);
  836. d.value = clone(value);
  837. Object.defineProperty(target, key, d);
  838. } else {
  839. target[key] = clone(value);
  840. }
  841. return true;
  842. },
  843. get: function (target, key) {
  844. if (key === MAGIC_KEY) {
  845. return target;
  846. }
  847. var value = target[key];
  848. var type = typeof value;
  849. if (value === null || (type !== 'function' && type !== 'object')) {
  850. return value;
  851. }
  852. return new Proxy(value, decorator);
  853. },
  854. apply: function (target, self, args) {
  855. args = Array.prototype.slice.call(args);
  856. if (target === unsafeWindow.Object.defineProperty) {
  857. args[0] = args[0][MAGIC_KEY];
  858. }
  859. if (target === unsafeWindow.Function.apply) {
  860. self = self[MAGIC_KEY];
  861. args[1] = Array.prototype.slice.call(args[1]);
  862. }
  863. if (target === unsafeWindow.document.querySelector) {
  864. self = self[MAGIC_KEY];
  865. }
  866. var usargs = clone(args);
  867. return target.apply(self, usargs);
  868. },
  869. construct: function (target, args) {
  870. args = Array.prototype.slice.call(args);
  871. args.unshift(undefined);
  872. var usargs = clone(args);
  873. var bind = unsafeWindow.Function.prototype.bind;
  874. return new (bind.apply(target, usargs));
  875. },
  876. };
  877. return new Proxy(unsafeWindow, decorator);
  878. })();
  879. return $;
  880. }));
  881. (function (context, factory) {
  882. if (typeof module === 'object' && typeof module.exports === 'object') {
  883. module.exports = function (context, GM) {
  884. var _ = require('lodash');
  885. var core = require('./core.js');
  886. var misc = require('./misc.js');
  887. var dispatcher = require('./dispatcher.js');
  888. var modules = [misc, dispatcher].map(function (v) {
  889. return v.call(null, context, GM);
  890. });
  891. var $ = _.assign.apply(null, modules);
  892. return factory(context, GM, core, $);
  893. };
  894. } else {
  895. factory(context, {
  896. getValue: GM_getValue,
  897. setValue: GM_setValue,
  898. }, context._, context.$);
  899. }
  900. }(this, function (context, GM, _, $) {
  901. 'use strict';
  902. var MANIFEST = [
  903. {
  904. name: 'version',
  905. key: 'version',
  906. default_: 0,
  907. verify: function (v) {
  908. return typeof v === 'number' && v >= 0;
  909. },
  910. },
  911. {
  912. name: 'alignCenter',
  913. key: 'align_center',
  914. default_: true,
  915. verify: isBoolean,
  916. },
  917. {
  918. name: 'changeBackground',
  919. key: 'change_background',
  920. default_: true,
  921. verify: isBoolean,
  922. },
  923. {
  924. name: 'externalServerSupport',
  925. key: 'external_server_support',
  926. default_: false,
  927. verify: isBoolean,
  928. },
  929. {
  930. name: 'redirectImage',
  931. key: 'redirect_image',
  932. default_: true,
  933. verify: isBoolean,
  934. },
  935. {
  936. name: 'scaleImage',
  937. key: 'scale_image',
  938. default_: true,
  939. verify: isBoolean,
  940. },
  941. {
  942. name: 'logLevel',
  943. key: 'log_level',
  944. default_: 1,
  945. verify: function (v) {
  946. return typeof v === 'number' && v >= 0 && v <= 2;
  947. },
  948. },
  949. ];
  950. var PATCHES = [
  951. function (c) {
  952. var ac = typeof c.alignCenter === 'boolean';
  953. if (typeof c.changeBackground !== 'boolean') {
  954. c.changeBackground = ac ? c.alignCenter : true;
  955. }
  956. if (typeof c.scaleImage !== 'boolean') {
  957. c.scaleImage = ac ? c.alignCenter : true;
  958. }
  959. if (!ac) {
  960. c.alignCenter = true;
  961. }
  962. if (typeof c.redirectImage !== 'boolean') {
  963. c.redirectImage = true;
  964. }
  965. },
  966. function (c) {
  967. if (typeof c.externalServerSupport !== 'boolean') {
  968. c.externalServerSupport = false;
  969. }
  970. },
  971. function (c) {
  972. if (typeof c.logLevel !== 'number') {
  973. c.logLevel = 1;
  974. }
  975. },
  976. ];
  977. var window = context.window;
  978. function isBoolean(v) {
  979. return typeof v === 'boolean';
  980. }
  981. function createConfig () {
  982. var c = {};
  983. _.C(MANIFEST).each(function (m) {
  984. Object.defineProperty(c, m.name, {
  985. configurable: true,
  986. enumerable: true,
  987. get: function () {
  988. return GM.getValue(m.key, m.default_);
  989. },
  990. set: function (v) {
  991. GM.setValue(m.key, v);
  992. },
  993. });
  994. });
  995. return c;
  996. }
  997. function senityCheck (c) {
  998. var ok = _.C(MANIFEST).all(function (m) {
  999. return m.verify(c[m.name]);
  1000. });
  1001. if (!ok) {
  1002. c.version = 0;
  1003. }
  1004. return c;
  1005. }
  1006. function migrate (c) {
  1007. while (c.version < PATCHES.length) {
  1008. PATCHES[c.version](c);
  1009. ++c.version;
  1010. }
  1011. return c;
  1012. }
  1013. $.config = migrate(senityCheck(createConfig()));
  1014. $.register({
  1015. rule: {
  1016. host: /^adsbypasser\.github\.io$/,
  1017. path: /^\/configure\.html$/,
  1018. },
  1019. ready: function () {
  1020. $.window.commit = function (data) {
  1021. data.version = $.config.version;
  1022. _.C(data).each(function (v, k) {
  1023. $.config[k] = v;
  1024. });
  1025. };
  1026. $.window.render({
  1027. version: $.config.version,
  1028. options: {
  1029. alignCenter: {
  1030. type: 'checkbox',
  1031. value: $.config.alignCenter,
  1032. label: 'Align Center',
  1033. help: 'Align image to the center if possible. (default: enabled)',
  1034. },
  1035. changeBackground: {
  1036. type: 'checkbox',
  1037. value: $.config.changeBackground,
  1038. label: 'Change Background',
  1039. help: 'Use Firefox-like image background if possible. (default: enabled)',
  1040. },
  1041. redirectImage: {
  1042. type: 'checkbox',
  1043. value: $.config.redirectImage,
  1044. label: 'Redirect Image',
  1045. help: [
  1046. 'Directly open image link if possible. (default: enabled)',
  1047. 'If disabled, redirection will only works on link shortener sites.',
  1048. ].join('<br/>\n'),
  1049. },
  1050. scaleImage: {
  1051. type: 'checkbox',
  1052. value: $.config.scaleImage,
  1053. label: 'Scale Image',
  1054. help: 'When image loaded, scale it to fit window if possible. (default: enabled)',
  1055. },
  1056. externalServerSupport: {
  1057. type: 'checkbox',
  1058. value: $.config.externalServerSupport,
  1059. label: 'External Server Support',
  1060. help: [
  1061. 'Send URL information to external server to enhance features (e.g.: captcha resolving). (default: disabled)',
  1062. 'Affected sites:',
  1063. 'setlinks.us (captcha)',
  1064. ].join('<br/>\n'),
  1065. },
  1066. logLevel: {
  1067. type: 'select',
  1068. value: $.config.logLevel,
  1069. menu: [
  1070. [0, '0 (quiet)'],
  1071. [1, '1 (default)'],
  1072. [2, '2 (verbose)'],
  1073. ],
  1074. label: 'Log Level',
  1075. help: [
  1076. 'Log level in developer console. (default: 1)',
  1077. '0 will not print anything in console.',
  1078. '1 will only print logs on affected sites.',
  1079. '2 will print on any sites.',
  1080. ].join('<br/>\n'),
  1081. },
  1082. },
  1083. });
  1084. },
  1085. });
  1086. return $;
  1087. }));
  1088. $.register({
  1089. rule: {
  1090. host: /^01\.nl$/,
  1091. },
  1092. ready: function () {
  1093. 'use strict';
  1094. var f = $('iframe#redirectframe');
  1095. $.openLink(f.src);
  1096. },
  1097. });
  1098. $.register({
  1099. rule: {
  1100. host: /^(www\.)?1be\.biz$/,
  1101. path: /^\/s\.php$/,
  1102. query: /^\?(.+)/,
  1103. },
  1104. start: function (m) {
  1105. 'use strict';
  1106. $.openLink(m.query[1]);
  1107. },
  1108. });
  1109. $.register({
  1110. rule: {
  1111. host: /^(www\.)?1tiny\.net$/,
  1112. path: /\/\w+/
  1113. },
  1114. ready: function () {
  1115. 'use strict';
  1116. var directUrl = $.searchScripts(/window\.location='([^']+)';/);
  1117. if (!directUrl) {
  1118. throw new _.AdsBypasserError('script content changed');
  1119. }
  1120. $.openLink(directUrl[1]);
  1121. },
  1122. });
  1123. $.register({
  1124. rule: {
  1125. host: /^2ty\.cc$/,
  1126. path: /^\/.+/,
  1127. },
  1128. ready: function () {
  1129. 'use strict';
  1130. $.removeNodes('iframe');
  1131. var a = $('#close');
  1132. $.openLink(a.href);
  1133. },
  1134. });
  1135. $.register({
  1136. rule: {
  1137. host: /^(www\.)?3ra\.be$/,
  1138. },
  1139. ready: function () {
  1140. 'use strict';
  1141. $.removeNodes('iframe');
  1142. var f = $.window.fc;
  1143. if (!f) {
  1144. throw new _.AdsBypasserError('window.fc is undefined');
  1145. }
  1146. f = f.toString();
  1147. f = f.match(/href="([^"]*)/);
  1148. if (!f) {
  1149. throw new _.AdsBypasserError('url pattern outdated');
  1150. }
  1151. $.openLink(f[1]);
  1152. },
  1153. });
  1154. $.register({
  1155. rule: {
  1156. host: /^(www\.)?4fun\.tw$/,
  1157. },
  1158. ready: function () {
  1159. 'use strict';
  1160. var i = $('#original_url');
  1161. $.openLink(i.value);
  1162. },
  1163. });
  1164. $.register({
  1165. rule: {
  1166. host: /^ad2links\.com$/,
  1167. path: /^\/\w-.+$/,
  1168. },
  1169. ready: function () {
  1170. 'use strict';
  1171. $.removeNodes('iframe');
  1172. $.openLinkByPost(window.location.toString(), {
  1173. post: {
  1174. image: 'Skip Ad.',
  1175. },
  1176. });
  1177. },
  1178. });
  1179. $.register({
  1180. rule: {
  1181. host: /^ad4\.fr$/,
  1182. },
  1183. ready: function () {
  1184. 'use strict';
  1185. $.removeNodes('iframe');
  1186. var s = $.searchScripts(/"src", "([^"]+)"/);
  1187. if (!s) {
  1188. _.warn('changed');
  1189. return;
  1190. }
  1191. $.openLink(s[1]);
  1192. },
  1193. });
  1194. (function () {
  1195. 'use strict';
  1196. $.register({
  1197. rule: {
  1198. host: /^ad7.biz$/,
  1199. path: /^\/\d+\/(.*)$/,
  1200. },
  1201. start: function (m) {
  1202. $.removeNodes('iframe');
  1203. var redirectLink = m.path[1];
  1204. if (!redirectLink.match(/^https?:\/\//)) {
  1205. redirectLink = "http://" + redirectLink;
  1206. }
  1207. $.openLink(redirectLink);
  1208. },
  1209. });
  1210. $.register({
  1211. rule: {
  1212. host: /^ad7.biz$/,
  1213. path: /^\/\w+$/,
  1214. },
  1215. ready: function () {
  1216. $.removeNodes('iframe');
  1217. var script = $.searchScripts('var r_url');
  1218. var url = script.match(/&url=([^&]+)/);
  1219. url = url[1];
  1220. $.openLink(url);
  1221. },
  1222. });
  1223. })();
  1224. $.register({
  1225. rule: {
  1226. host: [
  1227. /^(www\.)?adb\.ug$/,
  1228. /^(www\.)?lynk\.my$/,
  1229. /^adyou\.me$/,
  1230. ],
  1231. path: /^(?!\/(?:privacy|terms|contact(\/.*)?|#.*)?$).*$/
  1232. },
  1233. ready: function () {
  1234. 'use strict';
  1235. $.removeNodes('iframe');
  1236. var m = $.searchScripts(/top\.location\.href="([^"]+)"/);
  1237. if (m) {
  1238. $.openLink(m[1]);
  1239. return;
  1240. }
  1241. m = $.searchScripts(/\{_args.+\}/);
  1242. if (!m) {
  1243. throw new _.AdsBypasserError('script content changed');
  1244. }
  1245. m = eval('(' + m[0] + ')');
  1246. var url = window.location.pathname + '/skip_timer';
  1247. var i = setInterval(function () {
  1248. $.post(url, m).then(function (text) {
  1249. var jj = _.parseJSON(text);
  1250. if (!jj.errors && jj.messages) {
  1251. clearInterval(i);
  1252. $.openLink(jj.messages.url);
  1253. }
  1254. });
  1255. }, 1000);
  1256. },
  1257. });
  1258. (function () {
  1259. 'use strict';
  1260. function getTokenFromRocketScript () {
  1261. var a = $.searchScripts(/var eu = '(?!false)(.*)'/);
  1262. return a ? a[1] : null;
  1263. }
  1264. $.register({
  1265. rule: {
  1266. path: /\/locked$/,
  1267. query: /url=([^&]+)/,
  1268. },
  1269. start: function (m) {
  1270. $.resetCookies();
  1271. var url = decodeURIComponent(m.query[1]);
  1272. if (url.match(/^http/)) {
  1273. $.openLink(url);
  1274. } else {
  1275. $.openLink('/' + url);
  1276. }
  1277. },
  1278. });
  1279. $.register({
  1280. rule: [
  1281. 'http://u.shareme.in/*',
  1282. 'http://server.sbenny.com/*',
  1283. function () {
  1284. var h = $.$('html[id="main_html"]');
  1285. var b = $.$('body[id="home"]');
  1286. if (h && b) {
  1287. return true;
  1288. } else {
  1289. return null;
  1290. }
  1291. },
  1292. ],
  1293. start: function () {
  1294. $.window.document.write = _.nop;
  1295. },
  1296. ready: function () {
  1297. var h = $.$('#main_html'), b = $.$('#home');
  1298. if (!h || !b || h.nodeName !== 'HTML' || b.nodeName !== 'BODY') {
  1299. return;
  1300. }
  1301. $.removeNodes('iframe');
  1302. $.window.cookieCheck = _.nop;
  1303. h = $.window.eu || getTokenFromRocketScript();
  1304. if (!h) {
  1305. h = $('#adfly_bar');
  1306. $.window.close_bar();
  1307. return;
  1308. }
  1309. var a = h.indexOf('!HiTommy');
  1310. if (a >= 0) {
  1311. h = h.substring(0, a);
  1312. }
  1313. a = '';
  1314. b = '';
  1315. for (var i = 0; i < h.length; ++i) {
  1316. if (i % 2 === 0) {
  1317. a = a + h.charAt(i);
  1318. } else {
  1319. b = h.charAt(i) + b;
  1320. }
  1321. }
  1322. h = atob(a + b);
  1323. h = h.substr(2);
  1324. if (location.hash) {
  1325. h += location.hash;
  1326. }
  1327. $.openLink(h);
  1328. },
  1329. });
  1330. })();
  1331. $.register({
  1332. rule: {
  1333. host: /^(www\.)?adfe\.es$/,
  1334. path: /^\/\w+$/,
  1335. },
  1336. ready: function () {
  1337. 'use strict';
  1338. var f = $('#frmvideo');
  1339. if (!f.STEP4) {
  1340. return;
  1341. }
  1342. f.submit();
  1343. },
  1344. });
  1345. $.register({
  1346. rule: 'http://adfoc.us/*',
  1347. ready: function () {
  1348. 'use strict';
  1349. var root = document.body;
  1350. var observer = new MutationObserver(function (mutations) {
  1351. var o = $.$('#showSkip');
  1352. if (o) {
  1353. observer.disconnect();
  1354. o = o.querySelector('a');
  1355. $.openLink(o.href);
  1356. }
  1357. });
  1358. observer.observe(root, {
  1359. childList: true,
  1360. subtree: true,
  1361. });
  1362. },
  1363. });
  1364. $.register({
  1365. rule: {
  1366. host: /^(www\.)?adjet\.biz$/,
  1367. },
  1368. ready: function () {
  1369. 'use strict';
  1370. var m = $.searchScripts(/href=(\S+)/);
  1371. if (!m) {
  1372. throw new _.AdsBypasserError('site changed');
  1373. }
  1374. $.openLink(m[1]);
  1375. },
  1376. });
  1377. $.register({
  1378. rule: {
  1379. host: /^adlock\.org$/,
  1380. },
  1381. ready: function () {
  1382. 'use strict';
  1383. var a = $.$('#xre a.xxr, #downloadButton1');
  1384. if (a) {
  1385. $.openLink(a.href);
  1386. return;
  1387. }
  1388. a = $.window.fileLocation;
  1389. if (a) {
  1390. $.openLink(a);
  1391. }
  1392. },
  1393. });
  1394. $.register({
  1395. rule: {
  1396. host: /^(www\.)?adlot\.us$/,
  1397. },
  1398. ready: function () {
  1399. 'use strict';
  1400. $.removeNodes('iframe');
  1401. var script = $.searchScripts('form');
  1402. var p = /name='([^']+)' value='([^']+)'/g;
  1403. var opt = {
  1404. image: ' ',
  1405. };
  1406. var tmp = null;
  1407. while (tmp = p.exec(script)) {
  1408. opt[tmp[1]] = tmp[2];
  1409. }
  1410. $.openLink('', {
  1411. path: opt,
  1412. });
  1413. },
  1414. });
  1415. $.register({
  1416. rule: {
  1417. host: /^(www\.)?ah-informatique\.com$/,
  1418. path: /^\/ZipUrl/,
  1419. },
  1420. ready: function () {
  1421. 'use strict';
  1422. var a = $('#zip3 a');
  1423. $.openLink(a.href);
  1424. },
  1425. });
  1426. $.register({
  1427. rule: {
  1428. host: /^ah\.pe$/,
  1429. },
  1430. ready: function () {
  1431. 'use strict';
  1432. $.removeNodes('iframe');
  1433. var url = $.window.url;
  1434. $.get(url).then(function (url) {
  1435. $.openLink(url);
  1436. });
  1437. },
  1438. });
  1439. $.register({
  1440. rule: {
  1441. host: /^aka\.gr$/
  1442. },
  1443. ready: function () {
  1444. 'use strict';
  1445. var l = $('iframe#yourls-frame');
  1446. $.openLink(l.src);
  1447. },
  1448. });
  1449. $.register({
  1450. rule: {
  1451. host: /^al\.ly$/,
  1452. },
  1453. ready: function () {
  1454. 'use strict';
  1455. $.removeNodes('iframe, #CashSlideDiv, #ct_catfish');
  1456. var a = $('#modal-shadow');
  1457. a.style.display = 'block';
  1458. a = $('#modal-alert');
  1459. a.style.left = 0;
  1460. a.style.top = 80;
  1461. a.style.display = 'block';
  1462. },
  1463. });
  1464. $.register({
  1465. rule: {
  1466. host: /^(www\.)?allkeyshop\.com$/,
  1467. },
  1468. ready: function (m) {
  1469. 'use strict';
  1470. var matches = $.searchScripts(/window\.location\.href = "([^"]+)"/);
  1471. $.openLink(matches[1]);
  1472. $.removeAllTimer();
  1473. },
  1474. });
  1475. $.register({
  1476. rule: {
  1477. host: /^anonymbucks\.com$/,
  1478. },
  1479. ready: function () {
  1480. 'use strict';
  1481. var a = $('#boton-continuar');
  1482. a.click();
  1483. },
  1484. });
  1485. $.register({
  1486. rule: {
  1487. host: [
  1488. /^(awet|sortir)\.in$/,
  1489. /^st\.benfile\.com$/,
  1490. /^st\.azhie\.net$/,
  1491. ],
  1492. },
  1493. ready: function () {
  1494. 'use strict';
  1495. var m = $.searchScripts(/window\.location="([^"]*)";/);
  1496. $.openLink(m[1]);
  1497. },
  1498. });
  1499. (function () {
  1500. 'use strict';
  1501. $.register({
  1502. rule: {
  1503. host: [
  1504. /^bc\.vc$/,
  1505. /^linc\.ml$/,
  1506. ],
  1507. path: /^.+(https?:\/\/.+)$/,
  1508. },
  1509. start: function (m) {
  1510. $.openLink(m.path[1] + document.location.search + document.location.hash);
  1511. },
  1512. });
  1513. function decompress (script, unzip) {
  1514. if (!unzip) {
  1515. return script;
  1516. }
  1517. var matches = script.match(/eval(.*)/);
  1518. matches = matches[1];
  1519. script = eval(matches);
  1520. return script;
  1521. }
  1522. function searchScript (unzip) {
  1523. var content = $.searchScripts('make_log');
  1524. if (content) {
  1525. return {
  1526. direct: false,
  1527. script: decompress(content, unzip),
  1528. };
  1529. }
  1530. content = $.searchScripts('click_log');
  1531. if (content) {
  1532. return {
  1533. direct: true,
  1534. script: decompress(content, unzip),
  1535. };
  1536. }
  1537. throw _.AdsBypasserError('script changed');
  1538. }
  1539. function knockServer (script, dirtyFix) {
  1540. var matches = script.match(/\$.post\('([^']*)'[^{]+(\{opt:'make_log'[^}]+\}\}),/i);
  1541. var make_url = matches[1];
  1542. var make_opts = eval('(' + matches[2] + ')');
  1543. var i = setInterval(function () {
  1544. $.post(make_url, make_opts).then(function (text) {
  1545. if (dirtyFix) {
  1546. text = text.match(/\{.+\}/)[0];
  1547. }
  1548. var jj = _.parseJSON(text);
  1549. if (jj.message) {
  1550. clearInterval(i);
  1551. $.openLink(jj.message.url);
  1552. }
  1553. });
  1554. }, 1000);
  1555. }
  1556. function knockServer2 (script) {
  1557. var post = $.window.$.post;
  1558. $.window.$.post = function (a, b, c) {
  1559. if (typeof c !== 'function') {
  1560. return;
  1561. }
  1562. setTimeout(function () {
  1563. var data = {
  1564. error: false,
  1565. message: {
  1566. url: '#',
  1567. },
  1568. };
  1569. c(JSON.stringify(data));
  1570. }, 1000);
  1571. };
  1572. var matches = script.match(/\$.post\('([^']*)'[^{]+(\{opt:'make_log'[^}]+\}\}),/i);
  1573. var make_url = matches[1];
  1574. var tZ, cW, cH, sW, sH;
  1575. var make_opts = eval('(' + matches[2] + ')');
  1576. function makeLog () {
  1577. make_opts.opt = 'make_log';
  1578. post(make_url, make_opts, function (text) {
  1579. var data = _.parseJSON(text);
  1580. _.info('make_log', data);
  1581. if (!data.message) {
  1582. checksLog();
  1583. return;
  1584. }
  1585. $.openLink(data.message.url);
  1586. });
  1587. }
  1588. function checkLog () {
  1589. make_opts.opt = 'check_log';
  1590. post(make_url, make_opts, function (text) {
  1591. var data = _.parseJSON(text);
  1592. _.info('check_log', data);
  1593. if (!data.message) {
  1594. checkLog();
  1595. return;
  1596. }
  1597. makeLog();
  1598. });
  1599. }
  1600. function checksLog () {
  1601. make_opts.opt = 'checks_log';
  1602. post(make_url, make_opts, function () {
  1603. _.info('checks_log');
  1604. checkLog();
  1605. });
  1606. }
  1607. checksLog();
  1608. }
  1609. $.register({
  1610. rule: {
  1611. host: /^bc\.vc$/,
  1612. path: /^\/.+/,
  1613. },
  1614. ready: function () {
  1615. $.removeNodes('iframe');
  1616. var result = searchScript(false);
  1617. if (!result.direct) {
  1618. knockServer2(result.script);
  1619. } else {
  1620. result = result.script.match(/top\.location\.href = '([^']+)'/);
  1621. if (!result) {
  1622. throw new _.AdsBypasserError('script changed');
  1623. }
  1624. result = result[1];
  1625. $.openLink(result);
  1626. }
  1627. },
  1628. });
  1629. function run (dirtyFix) {
  1630. $.removeNodes('iframe');
  1631. var result = searchScript(true);
  1632. if (!result.direct) {
  1633. knockServer(result.script,dirtyFix);
  1634. } else {
  1635. result = result.script.match(/top\.location\.href='([^']+)'/);
  1636. if (!result) {
  1637. throw new _.AdsBypasserError('script changed');
  1638. }
  1639. result = result[1];
  1640. $.openLink(result);
  1641. }
  1642. }
  1643. $.register({
  1644. rule: {
  1645. host: /^adcrun\.ch$/,
  1646. path: /^\/\w+$/,
  1647. },
  1648. ready: function () {
  1649. $.removeNodes('.user_content');
  1650. var rSurveyLink = /http\.open\("GET", "api_ajax\.php\?sid=\d*&ip=[^&]*&longurl=([^"]+)" \+ first_time, (?:true|false)\);/;
  1651. var l = $.searchScripts(rSurveyLink);
  1652. if (l) {
  1653. $.openLink(l[1]);
  1654. return;
  1655. }
  1656. run(true);
  1657. },
  1658. });
  1659. $.register({
  1660. rule: {
  1661. host: [
  1662. /^1tk\.us$/,
  1663. /^gx\.si$/,
  1664. /^adwat\.ch$/,
  1665. /^(fly2url|urlwiz|xafox)\.com$/,
  1666. /^(zpoz|ultry)\.net$/,
  1667. /^(wwy|myam)\.me$/,
  1668. /^ssl\.gs$/,
  1669. /^lin(c\.ml|k\.tl)$/,
  1670. /^hit\.us$/,
  1671. /^shortit\.in$/,
  1672. /^(adbla|tl7)\.us$/,
  1673. /^www\.adjet\.eu$/,
  1674. /^srk\.gs$/,
  1675. /^cun\.bz$/,
  1676. /^miniurl\.tk$/,
  1677. /^vizzy\.es$/,
  1678. /^kazan\.vc$/,
  1679. /^linkcash\.ml$/,
  1680. ],
  1681. path: /^\/.+/,
  1682. },
  1683. ready: run,
  1684. });
  1685. $.register({
  1686. rule: {
  1687. host: /^adtr\.im|ysear\.ch|xip\.ir$/,
  1688. path: /^\/.+/,
  1689. },
  1690. ready: function () {
  1691. var a = $.$('div.fly_head a.close');
  1692. var f = $.$('iframe.fly_frame');
  1693. if (a && f) {
  1694. $.openLink(f.src);
  1695. } else {
  1696. run();
  1697. }
  1698. },
  1699. });
  1700. $.register({
  1701. rule: {
  1702. host: /^ad5\.eu$/,
  1703. path: /^\/[^.]+$/,
  1704. },
  1705. ready: function() {
  1706. $.removeNodes('iframe');
  1707. var s = searchScript(true);
  1708. var m = s.script.match(/(<form name="form1"method="post".*(?!<\\form>)<\/form>)/);
  1709. if (!m) {return;}
  1710. m = m[1];
  1711. var tz = -(new Date().getTimezoneOffset()/60);
  1712. m = m.replace("'+timezone+'",tz);
  1713. var d = document.createElement('div');
  1714. d.setAttribute('id','AdsBypasserFTW');
  1715. d.setAttribute('style', 'display:none;');
  1716. d.innerHTML = m;
  1717. document.body.appendChild(d);
  1718. $('#AdsBypasserFTW > form[name=form1]').submit();
  1719. },
  1720. });
  1721. $.register({
  1722. rule: {
  1723. host: /^tr5\.in$/,
  1724. path: /^\/.+/,
  1725. },
  1726. ready: function () {
  1727. run(true);
  1728. },
  1729. });
  1730. })();
  1731. $.register({
  1732. rule: {
  1733. host: /^(www\.)?biglistofwebsites\.com$/,
  1734. path: /^\/go\/(\w+\.\w+)$/
  1735. },
  1736. start: function (m) {
  1737. 'use strict';
  1738. $.openLink('http://' + m.path[1]);
  1739. },
  1740. });
  1741. $.register({
  1742. rule: 'http://www.bild.me/bild.php?file=*',
  1743. ready: function () {
  1744. 'use strict';
  1745. var i = $('#Bild');
  1746. $.openLink(i.src);
  1747. },
  1748. });
  1749. $.register({
  1750. rule: 'http://bildr.no/view/*',
  1751. ready: function () {
  1752. 'use strict';
  1753. var i = $('img.bilde');
  1754. $.openLink(i.src);
  1755. },
  1756. });
  1757. $.register({
  1758. rule: {
  1759. host: /^(www\.)?([a-zA-Z0-9]+\.)?binbox\.io$/,
  1760. path: /\/o\/([a-zA-Z0-9]+)/,
  1761. },
  1762. start: function (m) {
  1763. 'use strict';
  1764. var direct_link = window.atob(m.path[1]);
  1765. $.openLink(direct_link);
  1766. },
  1767. });
  1768. (function () {
  1769. 'use strict';
  1770. function hostMapper (host) {
  1771. switch (host) {
  1772. case 'bk-ddl.net':
  1773. case 'disingkat.in':
  1774. return function () {
  1775. var a = $('a.btn-block.redirect');
  1776. return a.href;
  1777. };
  1778. case 'link.animagz.org':
  1779. return function () {
  1780. var a = $('a.redirect');
  1781. a = a.onclick.toString();
  1782. a = a.match(/window\.open \('([^']+)'\)/);
  1783. return a[1];
  1784. };
  1785. case 'coeg.in':
  1786. return function () {
  1787. var a = $('.link a');
  1788. return a.href;
  1789. };
  1790. default:
  1791. return null;
  1792. }
  1793. }
  1794. $.register({
  1795. rule: {
  1796. host: [
  1797. /^bk-ddl\.net$/,
  1798. /^link\.animagz\.org$/,
  1799. /^coeg\.in$/,
  1800. /^disingkat\.in$/,
  1801. ],
  1802. path: /^\/\w+$/,
  1803. },
  1804. ready: function (m) {
  1805. var mapper = hostMapper(m.host[0]);
  1806. var b64 = mapper().match(/\?r=(\w+={0,2}?)/);
  1807. $.openLink(atob(b64[1]));
  1808. },
  1809. });
  1810. })();
  1811. $.register({
  1812. rule: {
  1813. host: /^(www\.)?boxcash\.net$/,
  1814. path: /^\/[\w~]+$/,
  1815. },
  1816. ready: function () {
  1817. 'use strict';
  1818. var m = $.searchScripts(/\'\/ajax_link\.php\',\s*\{key:\s*'(\w+)',\s*url:\s*'(\d+)',\s*t:\s*'(\d+)',\s*r:\s*'(\w*)'\}/);
  1819. if (!m) {
  1820. return;
  1821. }
  1822. $.post('/ajax_link.php', {
  1823. key: m[1],
  1824. url: m[2],
  1825. t: m[3],
  1826. r: m[4],
  1827. }).then(function (response) {
  1828. var l = response.match(/window(?:.top.window)\.location="([^"]+)"/);
  1829. $.openLink(l[1]);
  1830. });
  1831. },
  1832. });
  1833. $.register({
  1834. rule: {
  1835. host: /^(www\.)?boxcash\.net$/,
  1836. path: /^\/redirect\.html$/,
  1837. query: /url=(.+)$/,
  1838. },
  1839. start: function (m) {
  1840. 'use strict';
  1841. var l = decodeURIComponent(m.query[1]);
  1842. $.openLink(l);
  1843. },
  1844. });
  1845. $.register({
  1846. rule: {
  1847. host: /^(www\.)?(buz|vzt)url\.com$/,
  1848. },
  1849. ready: function () {
  1850. 'use strict';
  1851. var frame = $('frame[scrolling=yes]');
  1852. $.openLink(frame.src);
  1853. },
  1854. });
  1855. $.register({
  1856. rule: {
  1857. host: /^(cf|ex|xt)\d\.(me|co)$/,
  1858. },
  1859. ready: function (m) {
  1860. 'use strict';
  1861. $.removeNodes('iframe');
  1862. var a = $('#skip_button');
  1863. $.openLink(a.href);
  1864. },
  1865. });
  1866. $.register({
  1867. rule: {
  1868. host: /^cf\.ly$/,
  1869. path: /^\/[^\/]+$/,
  1870. },
  1871. start: function (m) {
  1872. 'use strict';
  1873. $.removeNodes('iframe');
  1874. $.openLink('/skip' + m.path[0]);
  1875. },
  1876. });
  1877. $.register({
  1878. rule: {
  1879. host: /^(www\.)?cli\.gs$/,
  1880. },
  1881. ready: function () {
  1882. 'use strict';
  1883. var a = $('a.RedirectLink');
  1884. $.openLink(a.href);
  1885. },
  1886. });
  1887. $.register({
  1888. rule: {
  1889. host: /^(www\.)?clictune\.com$/,
  1890. path: /^\/id=\d+/,
  1891. },
  1892. ready: function () {
  1893. 'use strict';
  1894. $.removeNodes('iframe');
  1895. var matches = $.searchScripts(/<a href="http:\/\/(?:www.)?clictune\.com\/redirect\.php\?url=([^&]+)&/);
  1896. var url = decodeURIComponent(matches[1]);
  1897. $.openLink(url);
  1898. },
  1899. });
  1900. $.register({
  1901. rule: {
  1902. host: /^clk\.im$/,
  1903. },
  1904. ready: function (m) {
  1905. 'use strict';
  1906. $.removeNodes('iframe');
  1907. var matches = $.searchScripts(/\$\("\.countdown"\)\.attr\("href","([^"]+)"\)/);
  1908. $.openLink(matches[1]);
  1909. },
  1910. });
  1911. $.register({
  1912. rule: {
  1913. host: /^(?:(\w+)\.)?(coinurl\.com|cur\.lv)$/,
  1914. path: /^\/([-\w]+)$/
  1915. },
  1916. ready: function (m) {
  1917. 'use strict';
  1918. $.removeNodes('iframe');
  1919. var host = 'http://cur.lv/redirect_curlv.php';
  1920. var param = m.host[1] === undefined ? {
  1921. code: m.path[1],
  1922. } : {
  1923. zone: m.host[1],
  1924. name: m.path[1],
  1925. };
  1926. $.get(host, param).then(function(mainFrameContent) {
  1927. try {
  1928. var docMainFrame = $.toDOM(mainFrameContent);
  1929. } catch (e) {
  1930. throw new _.AdsBypasserError('main frame changed');
  1931. }
  1932. var rExtractLink = /onclick="open_url\('([^']+)',\s*'go'\)/;
  1933. var innerFrames = $.$$('iframe', docMainFrame).each(function (currFrame) {
  1934. var currFrameAddr = currFrame.getAttribute('src');
  1935. $.get(currFrameAddr).then(function(currFrameContent) {
  1936. var aRealLink = rExtractLink.exec(currFrameContent);
  1937. if (aRealLink === undefined || aRealLink[1] === undefined) {
  1938. return;
  1939. }
  1940. var realLink = aRealLink[1];
  1941. $.openLink(realLink);
  1942. });
  1943. });
  1944. });
  1945. },
  1946. });
  1947. $.register({
  1948. rule: {
  1949. host: /^comyonet\.com$/,
  1950. },
  1951. ready: function () {
  1952. 'use strict';
  1953. var input = $('input[name="enter"]');
  1954. input.click();
  1955. },
  1956. });
  1957. $.register({
  1958. rule: {
  1959. host: /^www\.cuzle\.com$/,
  1960. path: /^\/$/,
  1961. query: /^\?(.+)=$/,
  1962. },
  1963. start: function (m) {
  1964. 'use strict';
  1965. var url = atob(m.query[1]);
  1966. $.openLink(url);
  1967. },
  1968. });
  1969. $.register({
  1970. rule: {
  1971. host: /^(www\.)?cvc\.la$/,
  1972. path: /^\/\w+$/,
  1973. },
  1974. start: function () {
  1975. 'use strict';
  1976. $.post(document.location.href, {
  1977. hidden: 24,
  1978. image: ' ',
  1979. }).then(function (text) {
  1980. var matches = text.match(/window\.location\.replace\('([^']+)'\);/);
  1981. $.openLink(matches[1]);
  1982. });
  1983. },
  1984. });
  1985. $.register({
  1986. rule: {
  1987. host: /^(www\.)?dapat\.in$/,
  1988. },
  1989. ready: function () {
  1990. 'use strict';
  1991. var f = $('iframe[name=pagetext]');
  1992. $.openLink(f.src);
  1993. },
  1994. });
  1995. $.register({
  1996. rule: {
  1997. host: /^(www\.)?dd\.ma$/,
  1998. },
  1999. ready: function (m) {
  2000. 'use strict';
  2001. var i = $.$('#mainframe');
  2002. if (i) {
  2003. $.openLink(i.src);
  2004. return;
  2005. }
  2006. var a = $('#btn_open a');
  2007. $.openLink(a.href);
  2008. },
  2009. });
  2010. $.register({
  2011. rule: {
  2012. host: /^(www\.)?dereferer\.website$/,
  2013. query: /^\?(.+)/,
  2014. },
  2015. start: function (m) {
  2016. 'use strict';
  2017. $.openLink(m.query[1]);
  2018. },
  2019. });
  2020. $.register({
  2021. rule: {
  2022. host: /^www\.dewaurl\.com$/,
  2023. },
  2024. ready: function () {
  2025. 'use strict';
  2026. var f = $('.framedRedirectTopFrame');
  2027. $.get(f.src).then(function (html) {
  2028. html = $.toDOM(html);
  2029. var a = $('#continueButton > a', html);
  2030. $.openLink(a.href);
  2031. }).catch(function (e) {
  2032. _.warn(e);
  2033. });
  2034. },
  2035. });
  2036. $.register({
  2037. rule: {
  2038. host: /^dikit\.in$/,
  2039. },
  2040. ready: function () {
  2041. 'use strict';
  2042. $.removeNodes('iframe');
  2043. var a = $('.disclaimer a');
  2044. $.openLink(a.href);
  2045. },
  2046. });
  2047. $.register({
  2048. rule: 'http://www.dumppix.com/viewer.php?*',
  2049. ready: function () {
  2050. 'use strict';
  2051. var i = $.$('#boring');
  2052. if (i) {
  2053. $.openLink(i.src);
  2054. return;
  2055. }
  2056. i = $('table td:nth-child(1) a');
  2057. $.openLink(i.href);
  2058. },
  2059. });
  2060. $.register({
  2061. rule: {
  2062. host: /^durl\.me$/,
  2063. },
  2064. ready: function () {
  2065. 'use strict';
  2066. var a = $('a[class="proceedBtn"]');
  2067. $.openLink(a.href);
  2068. },
  2069. });
  2070. $.register({
  2071. rule: {
  2072. host: /easyurl\.net|(atu|clickthru|redirects|readthis)\.ca|goshrink\.com$/,
  2073. },
  2074. ready: function () {
  2075. 'use strict';
  2076. var f = $('frame[name=main]');
  2077. $.openLink(f.src);
  2078. },
  2079. });
  2080. $.register({
  2081. rule: {
  2082. host: /empireload\.com$/,
  2083. path: /^\/plugin\.php$/,
  2084. query: /^\?id=linkout&url=([^&]+)$/,
  2085. },
  2086. start: function (m) {
  2087. $.openLink(m.query[1]);
  2088. },
  2089. });
  2090. $.register({
  2091. rule: {
  2092. host: [
  2093. /^ethi\.in$/,
  2094. /^st\.wardhanime\.net$/,
  2095. ],
  2096. path: /^\/i\/\d+$/,
  2097. },
  2098. ready: function () {
  2099. 'use strict';
  2100. var a = $('#wrapper > [class^="tombo"] > a[target="_blank"]');
  2101. $.openLink(a.href);
  2102. },
  2103. });
  2104. $.register({
  2105. rule: {
  2106. host: /^(www\.)?filoops.info$/
  2107. },
  2108. ready: function () {
  2109. 'use strict';
  2110. var a = $('#text > center a, #text > div[align=center] a');
  2111. $.openLink(a.href);
  2112. },
  2113. });
  2114. $.register({
  2115. rule: {
  2116. host: /^fit\.sh$/,
  2117. },
  2118. ready: function () {
  2119. 'use strict';
  2120. $.removeNodes('.container-body');
  2121. var m = $.searchScripts(/token="([^"]+)"/);
  2122. if (!m) {
  2123. throw new _.AdsBypasserError('site changed');
  2124. }
  2125. m = m[1];
  2126. var interLink = '/go/' + m + '?fa=15466&a=' + window.location.hash.substr(1);
  2127. setTimeout(function () {
  2128. $.openLink(interLink);
  2129. }, 6000);
  2130. },
  2131. });
  2132. $.register({
  2133. rule:{
  2134. host:/^(www\.)?fiuxy\.net$/,
  2135. path:/^\/link\/\?.*$/
  2136. },
  2137. ready:function(){
  2138. $.openLink($('a.btn.a').href);
  2139. }
  2140. });
  2141. $.register({
  2142. rule: {
  2143. host: /^www\.forbes\.com$/,
  2144. },
  2145. ready: function () {
  2146. 'use strict';
  2147. var o = $.window.ox_zones;
  2148. if (o) {
  2149. $.openLink(o.page_url);
  2150. }
  2151. },
  2152. });
  2153. $.register({
  2154. rule: {
  2155. host: /^www\.free-tv-video-online\.info$/,
  2156. path: /^\/interstitial2\.html$/,
  2157. query: /lnk=([^&]+)/,
  2158. },
  2159. start: function (m) {
  2160. 'use strict';
  2161. var url = decodeURIComponent(m.query[1]);
  2162. $.openLink(url);
  2163. },
  2164. });
  2165. (function () {
  2166. 'use strict';
  2167. $.register({
  2168. rule: {
  2169. host: /^(www\.)?fundurl\.com$/,
  2170. query: /i=([^&]+)/,
  2171. },
  2172. start: function (m) {
  2173. $.openLink(m.query[1]);
  2174. },
  2175. });
  2176. $.register({
  2177. rule: {
  2178. host: /^(www\.)?fundurl\.com$/,
  2179. path: /^\/(go-\w+|load\.php)$/,
  2180. },
  2181. ready: function () {
  2182. var f = $('iframe[name=fpage3]');
  2183. $.openLink(f.src);
  2184. },
  2185. });
  2186. })();
  2187. (function () {
  2188. var hosts = /^gca\.sh|repla\.cr$/;
  2189. $.register({
  2190. rule: {
  2191. host: hosts,
  2192. path: /^\/adv\/\w+\/(.*)$/,
  2193. query: /^(.*)$/,
  2194. hash: /^(.*)$/,
  2195. },
  2196. start: function (m) {
  2197. 'use strict';
  2198. var l = m.path[1] + m.query[1] + m.hash[1];
  2199. $.openLink(l);
  2200. },
  2201. });
  2202. $.register({
  2203. rule: {
  2204. host: hosts,
  2205. },
  2206. ready: function () {
  2207. 'use strict';
  2208. $.removeNodes('iframe');
  2209. var jQuery = $.window.$;
  2210. setTimeout(function () {
  2211. jQuery("#captcha-dialog").dialog("open");
  2212. }, 1000);
  2213. },
  2214. });
  2215. })();
  2216. $.register({
  2217. rule: {
  2218. host: /^gkurl\.us$/,
  2219. },
  2220. ready: function () {
  2221. 'use strict';
  2222. var iframe = $('#gkurl-frame');
  2223. $.openLink(iframe.src);
  2224. },
  2225. });
  2226. $.register({
  2227. rule: {
  2228. host: /^u\.go2\.me$/,
  2229. },
  2230. ready: function () {
  2231. 'use strict';
  2232. var iframe = $('iframe');
  2233. $.openLink(iframe.src);
  2234. },
  2235. });
  2236. $.register({
  2237. rule: {
  2238. host: /^hotshorturl\.com$/,
  2239. },
  2240. ready: function () {
  2241. 'use strict';
  2242. var frame = $('frame[scrolling=yes]');
  2243. $.openLink(frame.src);
  2244. },
  2245. });
  2246. $.register({
  2247. rule: {
  2248. host: /^(www\.)?(ilix\.in|priva\.us)$/,
  2249. path: /\/(\w+)/,
  2250. },
  2251. ready: function (m) {
  2252. 'use strict';
  2253. var realHost = 'ilix.in';
  2254. if (m.host[2] !== realHost) {
  2255. var realURL = location.href.replace(m.host[2], realHost);
  2256. $.openLink(realURL);
  2257. return;
  2258. }
  2259. var f = $.$('iframe[name=ifram]');
  2260. if (f) {
  2261. $.openLink(f.src);
  2262. return;
  2263. }
  2264. if (!$.$('img#captcha')) {
  2265. $('form[name=frm]').submit();
  2266. }
  2267. },
  2268. });
  2269. $.register({
  2270. rule: {
  2271. host: /^itw\.me$/,
  2272. path: /^\/r\//,
  2273. },
  2274. ready: function () {
  2275. 'use strict';
  2276. var f = $('.go-form');
  2277. f.submit();
  2278. },
  2279. });
  2280. $.register({
  2281. rule: {
  2282. host: /^ity\.im$/,
  2283. },
  2284. ready: function () {
  2285. 'use strict';
  2286. var f = $.$('#main');
  2287. if (f) {
  2288. $.openLink(f.src);
  2289. return;
  2290. }
  2291. f = $.$$('frame').find(function (frame) {
  2292. if (frame.src.indexOf('interheader.php') < 0) {
  2293. return _.none;
  2294. }
  2295. return frame.src;
  2296. });
  2297. if (f) {
  2298. $.openLink(f.payload);
  2299. return;
  2300. }
  2301. f = $.searchScripts(/krypted=([^&]+)/);
  2302. if (!f) {
  2303. throw new _.AdsBypasserError('site changed');
  2304. }
  2305. f = f[1];
  2306. var data = $.window.des('ksnslmtmk0v4Pdviusajqu', $.window.hexToString(f), 0, 0);
  2307. if (data) {
  2308. $.openLink('http://ity.im/1104_21_50846_' + data);
  2309. }
  2310. },
  2311. });
  2312. $.register({
  2313. rule: {
  2314. host: /^(www\.)?kingofshrink\.com$/,
  2315. },
  2316. ready: function () {
  2317. 'use strict';
  2318. var l = $('#textresult > a');
  2319. $.openLink(l.href);
  2320. },
  2321. });
  2322. $.register({
  2323. rule: {
  2324. host: /^(www\.)?leechbd\.tk$/,
  2325. path: /^\/Shortener\/(\w+)$/,
  2326. },
  2327. start: function (m) {
  2328. 'use strict';
  2329. $.get('/Shortener/API/read/get', {id: m.path[1], type: 'json'}).then(function (text) {
  2330. var r = _.parseJSON(text);
  2331. if (r.success == true && r.data.full) {
  2332. $.openLink(r.data.full);
  2333. } else {
  2334. _.warn('API Error ' + r.error.code + ' : ' + r.error.msg);
  2335. }
  2336. });
  2337. },
  2338. });
  2339. $.register({
  2340. rule: {
  2341. host: /^leechpremium\.space$/,
  2342. path: /^\/\w+$/,
  2343. },
  2344. ready: function () {
  2345. 'use strict';
  2346. var a = $('#btn-main');
  2347. var i = a.href.lastIndexOf('http');
  2348. a = a.href.substr(i);
  2349. $.openLink(a);
  2350. },
  2351. });
  2352. $.register({
  2353. rule: 'http://www.lienscash.com/l/*',
  2354. ready: function () {
  2355. 'use strict';
  2356. var a = $('#redir_btn');
  2357. $.openLink(a.href);
  2358. },
  2359. });
  2360. $.register({
  2361. rule: {
  2362. host: /^(www\.)?\w+\.link-protector\.com$/,
  2363. },
  2364. ready: function (m) {
  2365. 'use strict';
  2366. var f = $('form[style="font-weight:normal;font-size:12;font-family:Verdana;"]');
  2367. $.openLink(f.action);
  2368. },
  2369. });
  2370. $.register({
  2371. rule: {
  2372. host: /^(www\.)?link\.im$/,
  2373. path: /^\/\w+$/,
  2374. },
  2375. start: function () {
  2376. 'use strict';
  2377. $.post(document.location.href, {
  2378. image: 'Continue',
  2379. }).then(function (text) {
  2380. var m = text.match(/window\.location\.replace\('([^']+)'\)/);
  2381. $.openLink(m[1]);
  2382. });
  2383. },
  2384. });
  2385. $.register({
  2386. rule: {
  2387. host: /\.link2dollar\.com$/,
  2388. path: /^\/\d+$/,
  2389. },
  2390. ready: function () {
  2391. 'use strict';
  2392. var m = $.searchScripts(/var rlink = '([^']+)';/);
  2393. if (!m) {
  2394. throw new _.AdsBypasserError('site changed');
  2395. }
  2396. m = m[1];
  2397. $.openLink(m);
  2398. },
  2399. });
  2400. $.register({
  2401. rule: {
  2402. host: /^link2you\.ru$/,
  2403. path: /^\/\d+\/(.+)$/,
  2404. },
  2405. start: function (m) {
  2406. 'use strict';
  2407. var url = m.path[1];
  2408. if (!url.match(/^https?:\/\//)) {
  2409. url = '//' + url;
  2410. }
  2411. $.openLink(url);
  2412. },
  2413. });
  2414. $.register({
  2415. rule: {
  2416. host: /^link(4ad|ajc)\.com$/,
  2417. path: /^\/(.+)$/,
  2418. },
  2419. ready: function (m) {
  2420. 'use strict';
  2421. var d = $('div[id^=module_]');
  2422. d = d.id.match(/module_(\d+)/);
  2423. d = d[1];
  2424. $.post('form.php?block_id=' + d, {
  2425. cmd: 'get_source',
  2426. act: 'waiting',
  2427. id: m.path[1],
  2428. }).then(function (url) {
  2429. $.openLink(url);
  2430. }).catch(function (e) {
  2431. _.warn(e);
  2432. });
  2433. },
  2434. });
  2435. (function () {
  2436. 'use strict';
  2437. function sendRequest (opts) {
  2438. return $.post('/ajax/r.php', opts).then(function (data) {
  2439. if (data.length <= 1) {
  2440. return sendRequest(opts);
  2441. }
  2442. var a = $.toDOM(data);
  2443. a = $('a', a);
  2444. return a.href;
  2445. });
  2446. }
  2447. $.register({
  2448. rule: {
  2449. host: /^link5s\.com$/,
  2450. path: /^\/([^\/]+)$/,
  2451. },
  2452. ready: function (m) {
  2453. $.window.$ = null;
  2454. var i = $('#iframeID');
  2455. var opts = {
  2456. page: m.path[1],
  2457. advID: i.dataset.cmp,
  2458. u: i.dataset.u,
  2459. };
  2460. $.removeNodes('iframe');
  2461. sendRequest(opts).then(function (url) {
  2462. $.openLink(url);
  2463. });
  2464. },
  2465. });
  2466. })();
  2467. $.register({
  2468. rule: {
  2469. host: /^www\.linkarus\.com$/,
  2470. path: /^\/skip\//,
  2471. },
  2472. ready: function () {
  2473. 'use strict';
  2474. $.removeNodes('iframe');
  2475. var m = $.searchScripts(/action="([^"]+)"/);
  2476. m = m[1];
  2477. $.openLink(m);
  2478. },
  2479. });
  2480. $.register({
  2481. rule: {
  2482. host: /^www\.linkarus\.com$/,
  2483. },
  2484. ready: function () {
  2485. 'use strict';
  2486. $.removeNodes('iframe');
  2487. var m = $.searchScripts(/var counter = (\d+);/);
  2488. m = parseInt(m[1], 10);
  2489. m = m * 1000 + 500;
  2490. _.wait(m).then(function () {
  2491. var a = $('#skip-ad');
  2492. $.openLink(a.href);
  2493. });
  2494. },
  2495. });
  2496. (function() {
  2497. function ConvertFromHex (str) {
  2498. var result = [];
  2499. while (str.length >= 2) {
  2500. result.push(String.fromCharCode(parseInt(str.substring(0, 2), 16)));
  2501. str = str.substring(2, str.length);
  2502. }
  2503. return result.join("");
  2504. }
  2505. var Encode = function (str) {
  2506. var s = [], j = 0, x, res = '', k = arguments.callee.toString().replace(/\s+/g, "");
  2507. for (var i = 0; i < 256; i++) {
  2508. s[i] = i;
  2509. }
  2510. for (i = 0; i < 256; i++) {
  2511. j = (j + s[i] + k.charCodeAt(i % k.length)) % 256;
  2512. x = s[i];
  2513. s[i] = s[j];
  2514. s[j] = x;
  2515. }
  2516. i = 0;
  2517. j = 0;
  2518. for (var y = 0; y < str.length; y++) {
  2519. i = (i + 1) % 256;
  2520. j = (j + s[i]) % 256;
  2521. x = s[i];
  2522. s[i] = s[j];
  2523. s[j] = x;
  2524. res += String.fromCharCode(str.charCodeAt(y) ^ s[(s[i] + s[j]) % 256]);
  2525. }
  2526. return res;
  2527. };
  2528. var hostRules = [
  2529. /^(([\w]{8}|www)\.)?(allanalpass|cash4files|drstickyfingers|fapoff|freegaysitepass|(gone|tube)viral|(pic|tna)bucks|whackyvidz|fuestfka)\.com$/,
  2530. /^(([\w]{8}|www)\.)?(a[mn]y|deb|dyo|sexpalace)\.gs$/,
  2531. /^(([\w]{8}|www)\.)?(filesonthe|poontown|seriousdeals|ultrafiles|urlbeat|eafyfsuh|sasontnwc|zatnawqy)\.net$/,
  2532. /^(([\w]{8}|www)\.)?freean\.us$/,
  2533. /^(([\w]{8}|www)\.)?galleries\.bz$/,
  2534. /^(([\w]{8}|www)\.)?hornywood\.tv$/,
  2535. /^(([\w]{8}|www)\.)?link(babes|bucks)\.com$/,
  2536. /^(([\w]{8}|www)\.)?(megaline|miniurls|qqc|rqq|tinylinks|yyv|zff)\.co$/,
  2537. /^(([\w]{8}|www)\.)?(these(blog|forum)s)\.com$/,
  2538. /^(([\w]{8}|www)\.)?youfap\.me$/,
  2539. /^warning-this-linkcode-will-cease-working-soon\.www\.linkbucksdns\.com$/,
  2540. ];
  2541. (function () {
  2542. 'use strict';
  2543. function findToken (context) {
  2544. var script = $.searchScripts(' var f = window[\'init\' + \'Lb\' + \'js\' + \'\']', context);
  2545. if (!script) {
  2546. _.warn('pattern changed');
  2547. return null;
  2548. }
  2549. var adurl = script.match(/AdUrl\s*:\s*'([^']+)'/);
  2550. if (!adurl) {
  2551. return null;
  2552. }
  2553. adurl = adurl[1];
  2554. var m1 = script.match(/AdPopUrl\s*:\s*'.+\?[^=]+=([\w\d]+)'/);
  2555. var m2 = script.match(/Token\s*:\s*'([\w\d]+)'/);
  2556. var token = m1[1] || m2[1];
  2557. var m = script.match(/=\s*(\d+);/);
  2558. var ak = parseInt(m[1], 10);
  2559. var re = /\+\s*(\d+);/g;
  2560. var tmp = null;
  2561. while((m = re.exec(script)) !== null) {
  2562. tmp = m[1];
  2563. }
  2564. ak += parseInt(tmp, 10);
  2565. return {
  2566. t: token,
  2567. aK: ak,
  2568. adurl: adurl,
  2569. };
  2570. }
  2571. function sendRequest (token) {
  2572. $.get(token.adurl);
  2573. delete token.adurl;
  2574. token.a_b = false;
  2575. _.info('waiting the interval');
  2576. return _.wait(5000).then(function () {
  2577. _.info('sending token: %o', token);
  2578. return $.get('/intermission/loadTargetUrl', token, {
  2579. 'X-Requested-With': _.none,
  2580. Origin: _.none,
  2581. });
  2582. }).then(function (text) {
  2583. var data = _.parseJSON(text);
  2584. _.info('response: %o', data);
  2585. if (!data.Success && data.Errors[0] === 'Invalid token') {
  2586. _.warn('got invalid token');
  2587. return retry();
  2588. }
  2589. if (data.AdBlockSpotted) {
  2590. _.warn('adblock spotted');
  2591. return;
  2592. }
  2593. if (data.Success && !data.AdBlockSpotted && data.Url) {
  2594. return data.Url;
  2595. }
  2596. });
  2597. }
  2598. function retry () {
  2599. return $.get(window.location.toString(), {}, {
  2600. 'X-Forwarded-For': $.generateRandomIP(),
  2601. }).then(function (text) {
  2602. var d = $.toDOM(text);
  2603. var t = findToken(d);
  2604. if (!t) {
  2605. return _.wait(1000).then(retry);
  2606. }
  2607. return sendRequest(t);
  2608. });
  2609. }
  2610. $.register({
  2611. rule: {
  2612. host: hostRules,
  2613. path: /^\/\w+\/url\/(.+)$/,
  2614. },
  2615. ready: function(m) {
  2616. $.removeAllTimer();
  2617. $.resetCookies();
  2618. $.removeNodes('iframe');
  2619. var url = m.path[1] + window.location.search;
  2620. var match = $.searchScripts(/UrlEncoded: ([^,]+)/);
  2621. if (match && match[1] === 'true') {
  2622. url = Encode(ConvertFromHex(url));
  2623. }
  2624. $.openLink(url);
  2625. }
  2626. });
  2627. $.register({
  2628. rule: {
  2629. host: hostRules,
  2630. },
  2631. start: function () {
  2632. $.window.XMLHttpRequest = _.nop;
  2633. },
  2634. ready: function () {
  2635. $.removeAllTimer();
  2636. $.resetCookies();
  2637. $.removeNodes('iframe');
  2638. if (window.location.pathname.indexOf('verify') >= 0) {
  2639. var path = window.location.pathname.replace('/verify', '');
  2640. $.openLink(path);
  2641. return;
  2642. }
  2643. var token = findToken(document);
  2644. sendRequest(token).then(function (url) {
  2645. $.openLink(url);
  2646. });
  2647. },
  2648. });
  2649. $.register({
  2650. rule: {
  2651. query: /^(.*)[?&]_lbGate=\d+$/,
  2652. },
  2653. start: function (m) {
  2654. $.setCookie('_lbGatePassed', 'true');
  2655. $.openLink(window.location.pathname + m.query[1]);
  2656. },
  2657. });
  2658. })();
  2659. })();
  2660. $.register({
  2661. rule: {
  2662. host: [
  2663. /^www\.linkdecode\.com$/,
  2664. /^www\.fastdecode\.com$/,
  2665. ],
  2666. path: /^\/$/,
  2667. query: /^\?(.+)$/,
  2668. },
  2669. ready: function (m) {
  2670. 'use strict';
  2671. $.removeNodes('iframe');
  2672. var lnk = m.query[1];
  2673. if (m.query[1].match(/^https?:\/\//)) {
  2674. $.openLink(lnk);
  2675. return;
  2676. }
  2677. var b = $.$('#popup');
  2678. if (b && b.href) {
  2679. $.openLink(b.href);
  2680. return;
  2681. }
  2682. b = $('#m > .Visit_Link');
  2683. b = b.onclick.toString().match(/window\.open\(\'([^']+)\'/);
  2684. if (!b) {
  2685. throw new _.AdsBypasser('pattern changed');
  2686. }
  2687. lnk = b[1].match(/\?(https?:\/\/.*)$/);
  2688. if (lnk) {
  2689. $.openLink(lnk[1]);
  2690. return;
  2691. }
  2692. $.openLink(b[1]);
  2693. },
  2694. });
  2695. $.register({
  2696. rule: {
  2697. host: /^(www\.)?linkdrop\.net$/,
  2698. },
  2699. ready: function () {
  2700. 'use strict';
  2701. $.removeNodes('iframe');
  2702. var matches = $.searchScripts(/\$\("a\.redirect"\)\.attr\("href","([^"]+)"\)\.text/);
  2703. if (!matches) {
  2704. return;
  2705. }
  2706. var l = matches[1];
  2707. $.openLink(l);
  2708. },
  2709. });
  2710. $.register({
  2711. rule: {
  2712. host: /^(www\.)?linkplugapp\.com$/,
  2713. },
  2714. ready: function () {
  2715. 'use strict'
  2716. var a = $('#mc_embed_signup_scroll a')
  2717. $.openLink(a.href)
  2718. },
  2719. })
  2720. $.register({
  2721. rule: {
  2722. host: /^linksas\.us$/,
  2723. path: /^(\/\w+)$/,
  2724. },
  2725. ready: function (m) {
  2726. 'use strict';
  2727. _.try(1000, function () {
  2728. var recaptcha = $('#g-recaptcha-response');
  2729. if (!recaptcha) {
  2730. return null;
  2731. }
  2732. if (!recaptcha.value) {
  2733. return _.none;
  2734. }
  2735. return recaptcha.value;
  2736. }).then(function (recaptcha) {
  2737. var url = _.T('http://ipinfo.io/{0}/json')($.generateRandomIP());
  2738. return $.get(url).then(function (ipinfo) {
  2739. ipinfo = _.parseJSON(ipinfo);
  2740. return {
  2741. codeAds: 1,
  2742. country: ipinfo.country,
  2743. ipAddress: ipinfo.ip,
  2744. recaptcha: recaptcha,
  2745. };
  2746. });
  2747. }).then(function (payload) {
  2748. var token = $.getCookie('XSRF-TOKEN');
  2749. return $.post('/go' + m.path[1], payload, {
  2750. 'Content-Type': 'application/json',
  2751. 'X-XSRF-TOKEN': token,
  2752. });
  2753. }).then(function (data) {
  2754. data = _.parseJSON(data);
  2755. $.openLink(data.message);
  2756. }).catch(function (e) {
  2757. _.warn(e);
  2758. });
  2759. },
  2760. });
  2761. $.register({
  2762. rule: {
  2763. host: /^linksas\.us$/,
  2764. path: /^\/go\//,
  2765. },
  2766. ready: function () {
  2767. 'use strict';
  2768. var a = $.$('#btnSubmit');
  2769. if (!a) {
  2770. return;
  2771. }
  2772. var url = a.href;
  2773. var pattern = /https?:\/\//g;
  2774. var lastURL = '';
  2775. while (true) {
  2776. var matched = pattern.exec(url);
  2777. if (!matched) {
  2778. break;
  2779. }
  2780. lastURL = matched + url.substring(pattern.lastIndex);
  2781. }
  2782. $.openLink(lastURL);
  2783. },
  2784. });
  2785. $.register({
  2786. rule: {
  2787. host: /^linkshrink\.net$/,
  2788. path: /^\/[a-zA-Z0-9]+$/,
  2789. },
  2790. start: function () {
  2791. 'use strict';
  2792. $.window._impspcabe = 0;
  2793. },
  2794. ready: function () {
  2795. 'use strict';
  2796. var l = $('#skip .bt');
  2797. $.openLink(l.href);
  2798. },
  2799. });
  2800. $.register({
  2801. rule: {
  2802. host: /^linkshrink\.net$/,
  2803. path: /=(.+)$/,
  2804. },
  2805. start: function (m) {
  2806. 'use strict';
  2807. $.openLink(m.path[1]);
  2808. },
  2809. });
  2810. $.register({
  2811. rule: 'http://lix.in/-*',
  2812. ready: function () {
  2813. 'use strict';
  2814. var i = $.$('#ibdc');
  2815. if (i) {
  2816. return;
  2817. }
  2818. i = $.$('form');
  2819. if (i) {
  2820. i.submit();
  2821. return;
  2822. }
  2823. i = $('iframe');
  2824. $.openLink(i.src);
  2825. },
  2826. });
  2827. $.register({
  2828. rule: {
  2829. host: /^lnk\.in$/,
  2830. },
  2831. ready: function () {
  2832. 'use strict';
  2833. var a = $('#divRedirectText a');
  2834. $.openLink(a.innerHTML);
  2835. },
  2836. });
  2837. $.register({
  2838. rule: {
  2839. host: /^(rd?)lnk\.co|reducelnk\.com$/,
  2840. path: /^\/[^.]+$/,
  2841. },
  2842. ready: function () {
  2843. 'use strict';
  2844. var f = $.$('iframe#dest');
  2845. if (f) {
  2846. $.openLink(f.src);
  2847. return;
  2848. }
  2849. $.removeNodes('iframe');
  2850. var o = $.$('#urlholder');
  2851. if (o) {
  2852. $.openLink(o.value);
  2853. return;
  2854. }
  2855. o = $.$('#skipBtn');
  2856. if (o) {
  2857. o = o.querySelector('a');
  2858. $.openLink(o.href);
  2859. return;
  2860. }
  2861. o = document.title.replace(/(LNK.co|Linkbee)\s*:\s*/, '');
  2862. $.openLink(o);
  2863. },
  2864. });
  2865. $.register({
  2866. rule: {
  2867. host: /^lnx\.lu|url\.fm|z\.gs$/,
  2868. },
  2869. ready: function () {
  2870. 'use strict';
  2871. var a = $('#clickbtn a');
  2872. $.openLink(a.href);
  2873. },
  2874. });
  2875. $.register({
  2876. rule: {
  2877. host: /^(www\.)?loook\.ga$/,
  2878. path: /^\/\d+$/
  2879. },
  2880. ready: function (m) {
  2881. 'use strict';
  2882. var a = $('#download_link > a.btn');
  2883. $.openLink(a.href);
  2884. },
  2885. });
  2886. $.register({
  2887. rule: [
  2888. 'http://madlink.sk/',
  2889. 'http://madlink.sk/*.html',
  2890. ],
  2891. });
  2892. $.register({
  2893. rule: 'http://madlink.sk/*',
  2894. start: function (m) {
  2895. 'use strict';
  2896. $.removeNodes('iframe');
  2897. $.post('/ajax/check_redirect.php', {
  2898. link: m[1],
  2899. }).then(function (text) {
  2900. $.openLink(text);
  2901. });
  2902. },
  2903. });
  2904. $.register({
  2905. rule: {
  2906. host: [
  2907. /^mant[ae][pb]\.in$/,
  2908. /^st\.oploverz\.net$/,
  2909. /^minidroid\.net$/,
  2910. /^susutin\.com$/,
  2911. /^ww3\.awaremmxv\.com$/,
  2912. ],
  2913. },
  2914. ready: function () {
  2915. 'use strict';
  2916. var a = $('a.redirect, a[target=_blank][rel=nofollow]');
  2917. $.openLink(a.href);
  2918. },
  2919. });
  2920. $.register({
  2921. rule: {
  2922. host: /^www\.mije\.net$/,
  2923. path: /^\/\w+\/(.+)$/,
  2924. },
  2925. start: function (m) {
  2926. 'use strict';
  2927. var url = atob(m.path[1]);
  2928. $.openLink(url);
  2929. },
  2930. });
  2931. $.register({
  2932. rule: {
  2933. host: [
  2934. /^moe\.god\.jp$/,
  2935. /^moesubs\.akurapopo\.pro$/,
  2936. /^dl\.nsfk\.in$/,
  2937. ]
  2938. },
  2939. ready: function () {
  2940. 'use strict';
  2941. var a = $('div div center a');
  2942. $.openLink(a.href);
  2943. },
  2944. });
  2945. $.register({
  2946. rule: {
  2947. host: /^mt0\.org$/,
  2948. path: /^\/[^\/]+\/$/,
  2949. },
  2950. ready: function () {
  2951. 'use strict';
  2952. $.removeNodes('frame[name=bottom]');
  2953. var f = $('frame[name=top]');
  2954. var i = setInterval(function () {
  2955. var a = $.$('div a', f.contentDocument);
  2956. if (!a) {
  2957. return;
  2958. }
  2959. clearInterval(i);
  2960. $.openLink(a.href)
  2961. }, 1000);
  2962. },
  2963. });
  2964. $.register({
  2965. rule: 'http://my-link.pro/*',
  2966. ready: function () {
  2967. 'use strict';
  2968. var i = $('iframe[scrolling=auto]');
  2969. if (i) {
  2970. $.openLink(i.src);
  2971. }
  2972. },
  2973. });
  2974. $.register({
  2975. rule: {
  2976. host: /^nsfw\.in$/,
  2977. },
  2978. ready: function () {
  2979. 'use strict';
  2980. var a = $('#long_url a');
  2981. $.openLink(a.href);
  2982. },
  2983. });
  2984. $.register({
  2985. rule: {
  2986. host: /^nutshellurl\.com$/,
  2987. },
  2988. ready: function () {
  2989. 'use strict';
  2990. var iframe = $('iframe');
  2991. $.openLink(iframe.src);
  2992. },
  2993. });
  2994. $.register({
  2995. rule: {
  2996. host: /^(www\.)?ohleech\.com$/,
  2997. path: /^\/dl\/$/,
  2998. },
  2999. ready: function () {
  3000. 'use strict';
  3001. $.window.startdl();
  3002. },
  3003. });
  3004. $.register({
  3005. rule: {
  3006. host: /^www\.oni\.vn$/,
  3007. },
  3008. ready: function () {
  3009. 'use strict';
  3010. $.removeNodes('iframe');
  3011. var data = $.searchScripts(/data:"([^"]+)"/);
  3012. if (!data) {
  3013. throw new _.AdsBypasserError('pattern changed');
  3014. }
  3015. data = data[1];
  3016. $.get('/click.html', data).then(function (url) {
  3017. $.openLink(url);
  3018. });
  3019. },
  3020. });
  3021. $.register({
  3022. rule: {
  3023. host: /^(www\.)?ouo\.io$/,
  3024. path: /^\/go\/\w+$/,
  3025. },
  3026. ready: function (m) {
  3027. 'use strict';
  3028. var a = $('#btn-main');
  3029. $.openLink(a.href);
  3030. },
  3031. });
  3032. $.register({
  3033. rule: {
  3034. host: /^oxyl\.me$/,
  3035. },
  3036. ready: function () {
  3037. 'use strict';
  3038. var l = $.$$('.links-container.result-form > a.result-a');
  3039. if (l.size() > 1) {
  3040. return;
  3041. }
  3042. $.openLink(l.at(0).href);
  3043. },
  3044. });
  3045. $.register({
  3046. rule: {
  3047. host: /^p\.pw$/,
  3048. },
  3049. ready: function () {
  3050. 'use strict';
  3051. $.removeNodes('iframe');
  3052. var m = $.searchScripts(/window\.location = "(.*)";/);
  3053. m = m[1];
  3054. $.openLink(m);
  3055. },
  3056. });
  3057. $.register({
  3058. rule: {
  3059. host: /^(www\.)?\w+\.rapeit\.net$/,
  3060. path: /^\/(go|prepair|request|collect|analyze)\/[a-f0-9]+$/,
  3061. },
  3062. ready: function (m) {
  3063. 'use strict';
  3064. var a = $('a#download_link');
  3065. $.openLink(a.href);
  3066. },
  3067. });
  3068. $.register({
  3069. rule: 'http://reffbux.com/refflinx/view/*',
  3070. ready: function () {
  3071. 'use strict';
  3072. $.removeNodes('iframe');
  3073. var m = $.searchScripts(/skip_this_ad_(\d+)_(\d+)/);
  3074. var id = m[1];
  3075. var share = m[2];
  3076. var location = window.location.toString();
  3077. $.post('http://reffbux.com/refflinx/register', {
  3078. id: id,
  3079. share: share,
  3080. fp: 0,
  3081. location: location,
  3082. referer: '',
  3083. }).then(function (text) {
  3084. var m = text.match(/'([^']+)'/);
  3085. if (!m) {
  3086. throw new _.AdsBypasserError('pattern changed');
  3087. }
  3088. $.openLink(m[1]);
  3089. });
  3090. },
  3091. });
  3092. $.register({
  3093. rule: 'http://richlink.com/app/webscr?cmd=_click&key=*',
  3094. ready: function () {
  3095. 'use strict';
  3096. var f = $('frameset');
  3097. f = f.onload.toString();
  3098. f = f.match(/url=([^&]+)/);
  3099. if (f) {
  3100. f = decodeURIComponent(f[1]);
  3101. } else {
  3102. f = $('frame[name=site]');
  3103. f = f.src;
  3104. }
  3105. $.openLink(f);
  3106. },
  3107. });
  3108. $.register({
  3109. rule: 'http://rijaliti.info/*.php',
  3110. ready: function () {
  3111. 'use strict';
  3112. var a = $('#main td[align="center"] a');
  3113. $.openLink(a.href);
  3114. },
  3115. });
  3116. $.register({
  3117. rule: {
  3118. host: /^riurl\.com$/,
  3119. path: /^\/.+/,
  3120. },
  3121. ready: function () {
  3122. 'use strict';
  3123. var s = $.$('body script');
  3124. if (s) {
  3125. s = s.innerHTML.indexOf('window.location.replace');
  3126. if (s >= 0) {
  3127. return;
  3128. }
  3129. }
  3130. $.openLink('', {
  3131. path: {
  3132. hidden: '1',
  3133. image: ' ',
  3134. },
  3135. });
  3136. },
  3137. });
  3138. $.register({
  3139. rule: {
  3140. host: /^preview\.rlu\.ru$/,
  3141. },
  3142. ready: function () {
  3143. 'use strict';
  3144. var a = $('#content > .long_url > a');
  3145. $.openLink(a.href);
  3146. },
  3147. });
  3148. $.register({
  3149. rule: {
  3150. host: /^robo\.us$/,
  3151. },
  3152. ready: function () {
  3153. 'use strict';
  3154. $.removeNodes('iframe');
  3155. var url = atob($.window.fl);
  3156. $.openLink(url);
  3157. },
  3158. });
  3159. $.register({
  3160. rule: {
  3161. host: /^www\.ron\.vn$/,
  3162. },
  3163. ready: function () {
  3164. 'use strict';
  3165. var script = $.searchScripts('linknexttop');
  3166. var data = script.match(/data:"([^"]+)"/);
  3167. var url = $.window.domain + 'click.html?' + data[1];
  3168. $.get(url, {}, {
  3169. 'Content-Type': 'application/json; charset=utf-8',
  3170. }).then(function (url) {
  3171. $.openLink(url);
  3172. });
  3173. },
  3174. });
  3175. $.register({
  3176. rule: {
  3177. host: /^(www\.)?sa\.ae$/,
  3178. path: /^\/\w+\/$/,
  3179. },
  3180. ready: function () {
  3181. 'use strict';
  3182. var m = $.searchScripts(/var real_link = '([^']+)';/);
  3183. $.openLink(m[1]);
  3184. },
  3185. });
  3186. $.register({
  3187. rule: {
  3188. host: /^(www\.)?safeurl\.eu$/,
  3189. path: /\/\w+/,
  3190. },
  3191. ready: function () {
  3192. 'use strict';
  3193. var directUrl = $.searchScripts(/window\.open\("([^"]+)"\);/);
  3194. if (!directUrl) {
  3195. throw new _.AdsBypasserError('script content changed');
  3196. }
  3197. directUrl = directUrl[1];
  3198. $.openLink(directUrl);
  3199. },
  3200. });
  3201. $.register({
  3202. rule: {
  3203. host: [
  3204. /^segmentnext\.com$/,
  3205. /^(www\.)?videogamesblogger.com$/,
  3206. ],
  3207. path: /^\/interstitial\.html$/,
  3208. query: /return_url=([^&]+)/,
  3209. },
  3210. start: function (m) {
  3211. 'use strict';
  3212. $.openLink(decodeURIComponent(m.query[1]));
  3213. },
  3214. });
  3215. $.register({
  3216. rule: {
  3217. host: /^(www\.)?(apploadz\.ru|seomafia\.net)$/
  3218. },
  3219. ready: function () {
  3220. 'use strict';
  3221. $.removeNodes('iframe');
  3222. var a = $('table a');
  3223. $.openLink(a.href);
  3224. },
  3225. });
  3226. $.register({
  3227. rule: /http:\/\/setlinks\.us\/(p|t|d).*/,
  3228. ready: function () {
  3229. 'use strict';
  3230. var k = $.searchScripts(/window\.location='([^']+)'/);
  3231. if (k) {
  3232. $.openLink(k[1]);
  3233. return;
  3234. }
  3235. var aLinks = $.$$('div.links-container.result-form:not(.p-links-container) > span.dlinks > a');
  3236. if (aLinks.size() === 1) {
  3237. $.openLink(aLinks.at(0).href);
  3238. return;
  3239. }
  3240. k = $('img[alt=captcha]');
  3241. $.captcha(k.src, function (a) {
  3242. var b = $('#captcha');
  3243. var c = $('input[name=Submit]');
  3244. b.value = a;
  3245. c.click();
  3246. });
  3247. },
  3248. });
  3249. (function () {
  3250. 'use strict';
  3251. function afterGotSessionId (sessionId) {
  3252. var X_NewRelic_ID = $.searchScripts(/xpid:"([^"]+)"/);
  3253. var data = {
  3254. adSessionId: sessionId,
  3255. };
  3256. var header = {
  3257. Accept: 'application/json, text/javascript',
  3258. };
  3259. if (X_NewRelic_ID) {
  3260. header['X-NewRelic-ID'] = X_NewRelic_ID;
  3261. }
  3262. var i = setInterval(function () {
  3263. $.get('/shortest-url/end-adsession', data, header).then(function (text) {
  3264. var r = _.parseJSON(text);
  3265. if (r.status == "ok" && r.destinationUrl) {
  3266. clearInterval(i);
  3267. $.removeAllTimer();
  3268. var url = decodeURIComponent(r.destinationUrl);
  3269. $.openLink(url);
  3270. }
  3271. });
  3272. }, 1000);
  3273. }
  3274. var hostRules = /^sh\.st|(dh10thbvu|u2ks|jnw0)\.com|digg\.to$/;
  3275. $.register({
  3276. rule: {
  3277. host: hostRules,
  3278. path: /^\/freeze\/.+/,
  3279. },
  3280. ready: function () {
  3281. var o = new MutationObserver(function (mutations) {
  3282. mutations.forEach(function (mutation) {
  3283. if (mutation.target.getAttribute('class').match(/active/)) {
  3284. o.disconnect();
  3285. $.openLink(mutation.target.href);
  3286. }
  3287. });
  3288. });
  3289. o.observe($('#skip_button'), {
  3290. attributes: true,
  3291. attributeFilter: ['class'],
  3292. });
  3293. },
  3294. });
  3295. $.register({
  3296. rule: {
  3297. host: hostRules,
  3298. path: /https?:\/\//,
  3299. },
  3300. start: function () {
  3301. var url = window.location.pathname + window.location.search + window.location.hash;
  3302. url = url.match(/(https?:\/\/.*)$/);
  3303. url = url[1];
  3304. $.openLink(url);
  3305. },
  3306. });
  3307. $.register({
  3308. rule: {
  3309. host: hostRules,
  3310. path: /^\/[\d\w]+/,
  3311. },
  3312. start: function () {
  3313. $.window._impspcabe = 0;
  3314. },
  3315. ready: function () {
  3316. $.removeNodes('iframe');
  3317. $.removeAllTimer();
  3318. var m = $.searchScripts(/sessionId: "([\d\w]+)",/);
  3319. if (m) {
  3320. afterGotSessionId(m[1]);
  3321. return;
  3322. }
  3323. var o = new MutationObserver(function (mutations) {
  3324. mutations.forEach(function (mutation) {
  3325. var m = $.searchScripts(/sessionId: "([\d\w]+)",/);
  3326. if (m) {
  3327. o.disconnect();
  3328. afterGotSessionId(m[1]);
  3329. }
  3330. });
  3331. });
  3332. o.observe(document.body, {
  3333. childList: true,
  3334. });
  3335. },
  3336. });
  3337. })();
  3338. $.register({
  3339. rule: {
  3340. host: /^(www\.)?shink\.in$/,
  3341. path: /^\/\w+$/,
  3342. },
  3343. ready: function () {
  3344. 'use strict';
  3345. var f = $('#skip');
  3346. if (!$.$('#captcha')) {
  3347. f.submit();
  3348. return;
  3349. }
  3350. var envio = $('#envio');
  3351. envio.disabled = false;
  3352. envio.style.visibility = 'hidden';
  3353. envio.style.display = 'none';
  3354. var envio2 = $('#envio2');
  3355. envio2.style.visibility = 'visible';
  3356. envio2.style.display = 'block';
  3357. $.window.$('#myModal').reveal();
  3358. },
  3359. });
  3360. $.register({
  3361. rule: {
  3362. host: /^(www\.)?shink\.in$/,
  3363. path: /^\/go\/\w+$/,
  3364. },
  3365. ready: function () {
  3366. 'use strict';
  3367. var a = $('#btn-main');
  3368. $.openLink(a.href);
  3369. },
  3370. });
  3371. $.register({
  3372. rule: {
  3373. host: [
  3374. /^(www\.)?shortenurl\.tk$/,
  3375. /^(www\.)?pengaman\.link$/,
  3376. ],
  3377. path: /^\/\w+$/,
  3378. },
  3379. ready: function (m) {
  3380. 'use strict';
  3381. var l = $('a.btn-block.redirect');
  3382. $.openLink(l.href);
  3383. },
  3384. });
  3385. $.register({
  3386. rule: {
  3387. host: /^(www\.)?shorti\.ga$/,
  3388. path: [
  3389. /^\/\w+$/,
  3390. /^\/url_redirector\.html$/,
  3391. ],
  3392. },
  3393. ready: function () {
  3394. 'use strict';
  3395. var f = $.$$('frame');
  3396. var fl = f.find(function(value, key, self) {
  3397. if (value.getAttribute('class')) {
  3398. return _.none;
  3399. }
  3400. return 'Target frame found';
  3401. });
  3402. $.openLink(fl.value.src);
  3403. },
  3404. });
  3405. $.register({
  3406. rule: {
  3407. host: /^www\.shortskip\.com$/,
  3408. path: /^\/short\.php$/,
  3409. query: /i=([^&]+)/,
  3410. },
  3411. start: function (m) {
  3412. 'use strict';
  3413. var url = decodeURIComponent(m.query[1]);
  3414. $.openLink(url);
  3415. },
  3416. });
  3417. $.register({
  3418. rule: {
  3419. host: /^sht\.io$/,
  3420. path: /^\/\d+\/(.+)$/,
  3421. },
  3422. start: function (m) {
  3423. 'use strict';
  3424. var url = atob(m.path[1]);
  3425. url = url.match(/\{sht-io\}(.+)$/);
  3426. $.openLink(url[1]);
  3427. },
  3428. });
  3429. $.register({
  3430. rule: {
  3431. host: /^(www\.)?similarsites\.com$/,
  3432. path: /^\/goto\/([^?]+)/
  3433. },
  3434. start: function (m) {
  3435. 'use strict';
  3436. var l = m.path[1];
  3437. if (!/^https?:\/\//.test(l)) {
  3438. l = 'http://' + l;
  3439. }
  3440. $.openLink(l);
  3441. },
  3442. });
  3443. $.register({
  3444. rule: {
  3445. host: /^www\.spaste\.com$/,
  3446. path: /^\/go\/(\w+)$/,
  3447. },
  3448. start: function (m) {
  3449. 'use strict';
  3450. $.post('/site/getRedirectLink', {
  3451. code: m.path[1],
  3452. }).then(function (url) {
  3453. $.openLink(url);
  3454. });
  3455. },
  3456. });
  3457. $.register({
  3458. rule: {
  3459. host: /^srnk\.co$/,
  3460. path: /^\/i\//,
  3461. },
  3462. ready: function () {
  3463. 'use strict';
  3464. var a = $.$('#btn-with-link');
  3465. if (!a) {
  3466. return;
  3467. }
  3468. var href = a.href;
  3469. var method = a.dataset.method;
  3470. if (method) {
  3471. var csrfParam = $('meta[name="csrf-param"]').content;
  3472. var csrfToken = $('meta[name="csrf-token"]').content;
  3473. var form = document.createElement('form');
  3474. form.method = 'post';
  3475. form.action = href;
  3476. var input = document.createElement('input');
  3477. input.name = '_method';
  3478. input.value = method;
  3479. form.appendChild(input);
  3480. input = document.createElement('input');
  3481. input.name = csrfParam;
  3482. input.value = csrfToken;
  3483. form.appendChild(input);
  3484. document.body.appendChild(form);
  3485. form.submit();
  3486. return;
  3487. }
  3488. $.post(location.pathname + '.js').then(function (script) {
  3489. var m = script.match(/var link = "([^"]+)";/);
  3490. if (!m) {
  3491. _.warn('script changed');
  3492. return;
  3493. }
  3494. $.openLink(m[1]);
  3495. });
  3496. },
  3497. });
  3498. $.register({
  3499. rule: {
  3500. host: /^stash-coins\.com$/,
  3501. },
  3502. start: function () {
  3503. 'use strict';
  3504. var url = window.location.toString();
  3505. var i = url.lastIndexOf('http');
  3506. url = url.substr(i);
  3507. $.openLink(url);
  3508. },
  3509. });
  3510. $.register({
  3511. rule: {
  3512. host: /^streamingfrench\.net$/,
  3513. path: /^\/$/,
  3514. query: /^\?xb=(.+)$/,
  3515. },
  3516. start: function (m) {
  3517. 'use strict';
  3518. var url = decodeURIComponent(m.query[1]);
  3519. $.openLink(url);
  3520. },
  3521. });
  3522. $.register({
  3523. rule: {
  3524. host: /^(www\.)?supercheats\.com$/,
  3525. path: /^\/interstitial\.html$/,
  3526. query: /(?:\?|&)oldurl=([^&]+)(?:$|&)/,
  3527. },
  3528. start: function (m) {
  3529. 'use strict';
  3530. $.openLink(m.query[1]);
  3531. },
  3532. });
  3533. $.register({
  3534. rule: [
  3535. {
  3536. host: [
  3537. /^(www\.)?sylnk\.net$/,
  3538. /^dlneko\.(com|net|org)$/,
  3539. /^rumahsimpel\.com$/,
  3540. ],
  3541. query: /link=([^&]+)/,
  3542. },
  3543. {
  3544. host: /^(www\.)?compul\.in$/,
  3545. path: /^\/n\.php$/,
  3546. query: /v=([^&]+)/,
  3547. },
  3548. {
  3549. host: /^(www\.)?safelinkair\.com$/,
  3550. path: /^\/code$/,
  3551. query: /(?:\?|&)link=([a-zA-Z0-9=]+)(?:$|&)/,
  3552. },
  3553. {
  3554. host: /^link\.filmku\.net$/,
  3555. path: /^\/p\/go\.html$/,
  3556. query: /^\?url=([a-zA-Z0-9=]+)$/,
  3557. },
  3558. {
  3559. host: [
  3560. /^(gadget|auto)14\.pw$/,
  3561. /^nar-04\.tk$/,
  3562. ],
  3563. query: /^\?d=([a-zA-Z0-9=]+)$/,
  3564. },
  3565. ],
  3566. start: function (m) {
  3567. 'use strict';
  3568. var rawLink = atob(m.query[1]);
  3569. $.openLink(rawLink);
  3570. },
  3571. });
  3572. $.register({
  3573. rule: [
  3574. {
  3575. host: [
  3576. /^(www\.)?(link\.)?safelink(converter2?|s?review)\.com$/,
  3577. /^susutin\.com$/,
  3578. ],
  3579. query: /id=(\w+=*)/,
  3580. },
  3581. {
  3582. host: [
  3583. /^(www\.)?dlneko\.com$/,
  3584. /^(satuasia|tawaku)\.com$/,
  3585. /^ww3\.manteb\.in$/,
  3586. /^link\.filmku\.net$/,
  3587. /^www\.muucih\.com$/,
  3588. /^naisho\.lompat\.in$/,
  3589. ],
  3590. query: /go=(\w+=*)/,
  3591. },
  3592. ],
  3593. start: function (m) {
  3594. 'use strict';
  3595. var l = atob(m.query[1]);
  3596. var table = {
  3597. '!': 'a',
  3598. ')': 'e',
  3599. '_': 'i',
  3600. '(': 'o',
  3601. '*': 'u',
  3602. };
  3603. l = l.replace(/[!)_(*]/g, function (m) {
  3604. return table[m];
  3605. });
  3606. $.openLink(l);
  3607. },
  3608. });
  3609. $.register({
  3610. rule: {
  3611. host: /^(www\.)?safelinkreview\.com$/,
  3612. path: /^\/\w+\/cost\/([\w\.]+)\/?$/,
  3613. },
  3614. start: function (m) {
  3615. 'use strict';
  3616. var l = 'http://' + m.path[1];
  3617. $.openLink(l);
  3618. },
  3619. });
  3620. $.register({
  3621. rule: {
  3622. host: /^thinfi\.com$/,
  3623. },
  3624. ready: function () {
  3625. 'use strict';
  3626. var a = $('div p a');
  3627. $.openLink(a.href);
  3628. },
  3629. });
  3630. $.register({
  3631. rule: {
  3632. host: /^tinyarrows\.com$/,
  3633. path: /^\/preview\.php$/,
  3634. query: /^\?page=([^&]+)/,
  3635. },
  3636. start: function (m) {
  3637. 'use strict';
  3638. $.openLink(decodeURIComponent(m.query[1]));
  3639. },
  3640. });
  3641. $.register({
  3642. rule: {
  3643. host: /^(www\.)?totaldebrid\.org$/,
  3644. path:/\/l\/(l\.php)?$/,
  3645. query: /\?ads=([a-zA-Z0-9=]+)$/,
  3646. },
  3647. start: function (m) {
  3648. 'use strict';
  3649. var l = atob(m.query[1]);
  3650. $.openLink(l);
  3651. },
  3652. });
  3653. $.register({
  3654. rule: {
  3655. host: /^(www\.)?typ\.me$/,
  3656. },
  3657. ready: function (m) {
  3658. 'use strict';
  3659. var a = $('#skipAdBtn');
  3660. $.openLink(a.href);
  3661. },
  3662. });
  3663. $.register({
  3664. rule: {
  3665. host: /^(www\.)?ultshare\.com$/,
  3666. path: /^\/(?:(?:\d-)?(\d+)|index\.php)$/,
  3667. query: /^(?:\?a=\d&c=(\d+))?$/
  3668. },
  3669. start: function (m) {
  3670. 'use strict';
  3671. var linkId = m.path[1]?m.path[1]:m.query[1];
  3672. var directLink = '/3-' + linkId;
  3673. $.openLink(directLink);
  3674. },
  3675. });
  3676. $.register({
  3677. rule: {
  3678. host: /^unfake\.it$/,
  3679. },
  3680. ready: function () {
  3681. 'use strict';
  3682. var frame = $('frame');
  3683. var i = frame.src.lastIndexOf('http://');
  3684. $.openLink(frame.src.substr(i));
  3685. },
  3686. });
  3687. $.register({
  3688. rule: {
  3689. host: /^(www\.)?(upan|gxp)\.so$/,
  3690. path: /^\/\w+$/,
  3691. },
  3692. ready: function () {
  3693. 'use strict';
  3694. var a = $('table.td_line a[onclick="down_process_s();"]');
  3695. $.openLink(a.href);
  3696. },
  3697. });
  3698. $.register({
  3699. rule: {
  3700. host: /^url\.ie$/,
  3701. },
  3702. ready: function () {
  3703. 'use strict';
  3704. var a = $('a[title="Link to original URL"]');
  3705. $.openLink(a.href);
  3706. },
  3707. });
  3708. $.register({
  3709. rule: {
  3710. host: /urlcash\.(com|net|org)|(bat5|detonating|celebclk|eightteen|smilinglinks|peekatmygirlfriend|pornyhost|clb1|urlgalleries)\.com|looble\.net|xxxs\.org$/,
  3711. },
  3712. ready: function () {
  3713. 'use strict';
  3714. if ($.window && $.window.linkDestUrl) {
  3715. $.openLink($.window.linkDestUrl);
  3716. return;
  3717. }
  3718. var matches = document.body.innerHTML.match(/linkDestUrl = '(.+)'/);
  3719. if (matches) {
  3720. $.openLink(matches[1]);
  3721. return;
  3722. }
  3723. },
  3724. });
  3725. $.register({
  3726. rule: {
  3727. host: /^urlinn\.com$/,
  3728. },
  3729. ready: function () {
  3730. 'use strict';
  3731. var m = $('META[HTTP-EQUIV=refresh]').getAttribute('CONTENT').match(/url='([^']+)'/);
  3732. if (m) {
  3733. $.openLink(m[1]);
  3734. }
  3735. },
  3736. });
  3737. $.register({
  3738. rule: {
  3739. host: /^urlms\.com$/,
  3740. },
  3741. ready: function () {
  3742. 'use strict';
  3743. var iframe = $('#content');
  3744. $.openLink(iframe.src);
  3745. },
  3746. });
  3747. $.register({
  3748. rule: {
  3749. host: /^(www\.)?urlv2\.com$/,
  3750. },
  3751. ready: function (m) {
  3752. 'use strict';
  3753. if (window.location.pathname.indexOf('locked') >= 0) {
  3754. var path = window.location.pathname.replace('/locked', '');
  3755. $.openLink(path);
  3756. return;
  3757. }
  3758. var m = $.searchScripts(/jeton=([\w]+)/);
  3759. var l = 'http://urlv2.com/algo.php?action=passer&px=0&so=1&jeton=' + m[1];
  3760. window.setTimeout(function() {$.openLink(l)}, 5000);
  3761. },
  3762. });
  3763. $.register({
  3764. rule: {
  3765. host: /^(www\.)?victly\.com$/,
  3766. path: /^\/\w+$/,
  3767. },
  3768. start: function () {
  3769. 'use strict';
  3770. $.post(document.location.href, {
  3771. hidden: '',
  3772. image: 'Skip+Ads',
  3773. }).then(function (text) {
  3774. var m = text.match(/window\.location\.replace\('([^']+)'\)/);
  3775. $.openLink(m[1]);
  3776. });
  3777. },
  3778. });
  3779. $.register({
  3780. rule: {
  3781. host: /^www\.viidii\.info$/,
  3782. },
  3783. ready: function () {
  3784. 'use strict';
  3785. var o = $('#directlink');
  3786. $.openLink(o.href);
  3787. },
  3788. });
  3789. $.register({
  3790. rule: {
  3791. host: /^(www\.)?vir\.al$/,
  3792. },
  3793. ready: function () {
  3794. 'use strict';
  3795. var m = $.searchScripts(/var target_url = '([^']+)';/);
  3796. if (!m) {
  3797. throw new _.AdsBypasserError('site changed');
  3798. }
  3799. $.openLink(m[1]);
  3800. },
  3801. });
  3802. $.register({
  3803. rule: {
  3804. host: /^(www\.)?wzzq\.me$/,
  3805. },
  3806. ready: function () {
  3807. 'use strict';
  3808. try {
  3809. var l = $('#img_loading_table2 div.wz_img_hit a[target=_blank]').href;
  3810. $.openLink(l);
  3811. } catch (e) {
  3812. }
  3813. },
  3814. });
  3815. $.register({
  3816. rule: {
  3817. host: /^xlink.me$/
  3818. },
  3819. ready: function () {
  3820. 'use strict';
  3821. var a = $('#main_form > center > a');
  3822. if (!a) {return;}
  3823. $.openLink(a.href);
  3824. },
  3825. });
  3826. $.register({
  3827. rule: 'http://yep.it/preview.php?p=*',
  3828. ready: function () {
  3829. 'use strict';
  3830. var link = $('font[color="grey"]').innerHTML;
  3831. $.openLink(link);
  3832. },
  3833. });
  3834. $.register({
  3835. rule: 'http://www.yooclick.com/l/*',
  3836. ready: function () {
  3837. 'use strict';
  3838. $.removeNodes('iframe');
  3839. var uniq = $.window.uniq || $.window.uniqi;
  3840. if (!uniq) {return;}
  3841. var path = window.location.pathname;
  3842. var url = _.T('{0}?ajax=true&adblock=false&old=false&framed=false&uniq={1}')(path, uniq);
  3843. var getURL = function() {
  3844. $.get(url).then(function (text) {
  3845. var goodURL = /^(https?|ftp):\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i.test(text);
  3846. if (goodURL) {
  3847. $.openLink(text);
  3848. } else {
  3849. setTimeout(getURL, 500);
  3850. }
  3851. });
  3852. }
  3853. getURL();
  3854. },
  3855. });
  3856. $.register({
  3857. rule: {
  3858. host: /^ysf\.pl$/,
  3859. path: /^\/3\/(.+)$/,
  3860. },
  3861. start: function (m) {
  3862. 'use strict';
  3863. var url = atob(m.path[1]);
  3864. $.openLink(url);
  3865. },
  3866. });
  3867. $.register({
  3868. rule: {
  3869. host: /^ysf\.pl$/,
  3870. path: /^\/2\/(.+)$/,
  3871. },
  3872. start: function (m) {
  3873. 'use strict';
  3874. var url = m.path[1].match(/.{2}/g).map(function (h) {
  3875. return String.fromCharCode(parseInt(h, 16));
  3876. }).join('');
  3877. $.openLink(url);
  3878. },
  3879. });
  3880. $.register({
  3881. rule: 'http://zo.mu/redirector/process?link=*',
  3882. ready: function () {
  3883. 'use strict';
  3884. $.removeNodes('iframe');
  3885. window.location.reload();
  3886. },
  3887. });
  3888. $.register({
  3889. rule: {
  3890. host: /^zzz\.gl$/,
  3891. },
  3892. ready: function () {
  3893. 'use strict';
  3894. var m = $.searchScripts(/var domainurl = '([^']+)';/);
  3895. if (!m) {
  3896. throw new _.AdsBypasserError('site changed');
  3897. }
  3898. $.openLink(m[1]);
  3899. },
  3900. });
  3901. (function (context, factory) {
  3902. if (typeof module === 'object' && typeof module.exports === 'object') {
  3903. module.exports = function (context, GM) {
  3904. var _ = require('lodash');
  3905. var core = require('./core.js');
  3906. var dom = require('./dom.js');
  3907. var config = require('./config.js');
  3908. var link = require('./link.js');
  3909. var misc = require('./misc.js');
  3910. var modules = [dom, config, link, misc].map(function (v) {
  3911. return v.call(null, context, GM);
  3912. });
  3913. var $ = _.assign.apply(_, modules);
  3914. return factory(context, GM, core, $);
  3915. };
  3916. } else {
  3917. factory(context, {
  3918. getResourceText: GM_getResourceText,
  3919. addStyle: GM_addStyle,
  3920. getResourceURL: GM_getResourceURL,
  3921. }, context._, context.$);
  3922. }
  3923. }(this, function (context, GM, _, $) {
  3924. 'use strict';
  3925. var window = context.window;
  3926. var document = window.document;
  3927. $.openImage = function (imgSrc, options) {
  3928. options = options || {};
  3929. var replace = !!options.replace;
  3930. var referer = !!options.referer;
  3931. if (replace) {
  3932. replaceBody(imgSrc);
  3933. return;
  3934. }
  3935. if ($.config.redirectImage) {
  3936. $.openLink(imgSrc, {
  3937. referer: referer,
  3938. });
  3939. }
  3940. };
  3941. function enableScrolling () {
  3942. var o = document.compatMode === 'CSS1Compat' ? document.documentElement : document.body;
  3943. o.style.overflow = '';
  3944. };
  3945. function toggleShrinking () {
  3946. this.classList.toggle('adsbypasser-shrinked');
  3947. }
  3948. function checkScaling () {
  3949. var nw = this.naturalWidth;
  3950. var nh = this.naturalHeight;
  3951. var cw = document.documentElement.clientWidth;
  3952. var ch = document.documentElement.clientHeight;
  3953. if ((nw > cw || nh > ch) && !this.classList.contains('adsbypasser-resizable')) {
  3954. this.classList.add('adsbypasser-resizable');
  3955. this.classList.add('adsbypasser-shrinked');
  3956. this.addEventListener('click', toggleShrinking);
  3957. } else {
  3958. this.removeEventListener('click', toggleShrinking);
  3959. this.classList.remove('adsbypasser-shrinked');
  3960. this.classList.remove('adsbypasser-resizable');
  3961. }
  3962. }
  3963. function scaleImage (i) {
  3964. var style = GM.getResourceText('scaleImage');
  3965. GM.addStyle(style);
  3966. if (i.naturalWidth && i.naturalHeight) {
  3967. checkScaling.call(i);
  3968. } else {
  3969. i.addEventListener('load', checkScaling);
  3970. }
  3971. var h;
  3972. window.addEventListener('resize', function () {
  3973. window.clearTimeout(h);
  3974. h = window.setTimeout(checkScaling.bind(i), 100);
  3975. });
  3976. }
  3977. function changeBackground () {
  3978. var bgImage = GM.getResourceURL('bgImage');
  3979. document.body.style.backgroundColor = '#222222';
  3980. document.body.style.backgroundImage = _.T('url(\'{0}\')')(bgImage);
  3981. }
  3982. function alignCenter () {
  3983. var style = GM.getResourceText('alignCenter');
  3984. GM.addStyle(style);
  3985. }
  3986. function injectStyle (d, i) {
  3987. $.removeNodes('style, link[rel=stylesheet]');
  3988. d.id = 'adsbypasser-wrapper';
  3989. i.id = 'adsbypasser-image';
  3990. }
  3991. function replaceBody (imgSrc) {
  3992. if (!$.config.redirectImage) {
  3993. return;
  3994. }
  3995. if (!imgSrc) {
  3996. _.warn('false url');
  3997. return;
  3998. }
  3999. _.info(_.T('replacing body with `{0}` ...')(imgSrc));
  4000. $.removeAllTimer();
  4001. enableScrolling();
  4002. document.body = document.createElement('body');
  4003. var d = document.createElement('div');
  4004. document.body.appendChild(d);
  4005. var i = document.createElement('img');
  4006. i.src = imgSrc;
  4007. d.appendChild(i);
  4008. if ($.config.alignCenter || $.config.scaleImage) {
  4009. injectStyle(d, i);
  4010. }
  4011. if ($.config.alignCenter) {
  4012. alignCenter();
  4013. }
  4014. if ($.config.changeBackground) {
  4015. changeBackground();
  4016. }
  4017. if ($.config.scaleImage) {
  4018. scaleImage(i);
  4019. }
  4020. };
  4021. return $;
  4022. }));
  4023. $.register({
  4024. rule: [
  4025. {
  4026. host: /^1dl\.biz$/,
  4027. path: /^\/(\w)\.php$/,
  4028. query: /^\?([\d\/]+)$/,
  4029. },
  4030. {
  4031. host: /^img\.1dl\.biz$/,
  4032. path: /^\/(\w)\.php$/,
  4033. query: /^\?\w\/([\d\/]+)$/,
  4034. },
  4035. ],
  4036. ready: function () {
  4037. 'use strict';
  4038. var a = $('.main a, .main-l a');
  4039. $.openImage(a.href, {
  4040. referer: true,
  4041. });
  4042. },
  4043. });
  4044. $.register({
  4045. rule: {
  4046. host: /^1pics\.ru$/,
  4047. },
  4048. ready: function () {
  4049. 'use strict';
  4050. var img = $('img[alt$="1Pics.Ru"]');
  4051. $.openImage(img.src);
  4052. },
  4053. });
  4054. $.register({
  4055. rule: {
  4056. host: /^www\.(2i\.(sk|cz)|2imgs\.com)$/,
  4057. },
  4058. ready: function () {
  4059. 'use strict';
  4060. var img = $('#wrap3 img');
  4061. $.openImage(img.src);
  4062. },
  4063. });
  4064. $.register({
  4065. rule: [
  4066. {
  4067. host: /^a\.pomf\.se$/,
  4068. path: /^\/.+\.htm$/,
  4069. query: /^$/,
  4070. },
  4071. {
  4072. host: /^empireload\.com$/,
  4073. path: /^\/sexy\/.+\.htm$/,
  4074. query: /^$/,
  4075. },
  4076. ],
  4077. ready: function () {
  4078. 'use strict';
  4079. var a = $.$('body > a');
  4080. if (a) {
  4081. $.openImage(a.href);
  4082. return;
  4083. }
  4084. $.removeNodes('#boxes, iframe');
  4085. },
  4086. });
  4087. (function () {
  4088. 'use strict';
  4089. function run () {
  4090. var i = $('#image');
  4091. $.openImage(i.src);
  4092. }
  4093. $.register({
  4094. rule: {
  4095. host: /^(www\.)?imagepearl\.com$/,
  4096. path: /^\/(verify|view)\/(.+)$/,
  4097. },
  4098. start: function (m) {
  4099. $.openLink('/image/' + m.path[2], {
  4100. referer: false,
  4101. });
  4102. },
  4103. });
  4104. $.register({
  4105. rule: {
  4106. host: /^www\.imageberyl\.com$/,
  4107. path: /^\/verify\/(.+)$/,
  4108. },
  4109. start: function (m) {
  4110. $.openLink('/view/' + m.path[1]);
  4111. },
  4112. });
  4113. $.register({
  4114. rule: [
  4115. 'http://*.abload.de/image.php?img=*',
  4116. 'http://www.imageup.ru/*/*/*.html',
  4117. 'http://itmages.ru/image/view/*/*',
  4118. {
  4119. host: /^(www\.)?imagepearl\.com$/,
  4120. path: /^\/image\//,
  4121. },
  4122. {
  4123. host: /^www\.imageberyl\.com$/,
  4124. path: /^\/view\//,
  4125. },
  4126. ],
  4127. ready: run,
  4128. });
  4129. })();
  4130. $.register({
  4131. rule: {
  4132. host: /^avenuexxx\.com$/,
  4133. path: /^\/archives\//,
  4134. },
  4135. ready: function () {
  4136. 'use strict';
  4137. var i = $('#content img');
  4138. $.openImage(i.src);
  4139. },
  4140. });
  4141. $.register({
  4142. rule: {
  4143. host: /^freeimgup\.com$/,
  4144. path: /^\/xxx/,
  4145. query: /^\?v=([^&]+)/,
  4146. },
  4147. start: function (m) {
  4148. 'use strict';
  4149. $.openImage('/xxx/images/' + m.query[1]);
  4150. },
  4151. });
  4152. $.register({
  4153. rule: {
  4154. host: /^(b4he|freeimgup|fullimg)\.com|fastpics\.net|ifap\.co$/,
  4155. query: /^\?v=([^&]+)/,
  4156. },
  4157. start: function (m) {
  4158. 'use strict';
  4159. $.openImage('/images/' + m.query[1]);
  4160. },
  4161. });
  4162. $.register({
  4163. rule: {
  4164. host: /^bayimg\.com$/,
  4165. },
  4166. ready: function () {
  4167. 'use strict';
  4168. var i = $('#mainImage');
  4169. $.openImage(i.src);
  4170. },
  4171. });
  4172. $.register({
  4173. rule: {
  4174. host: /^beeimg\.com$/,
  4175. path: /\/view\/.*/,
  4176. },
  4177. ready: function () {
  4178. 'use strict';
  4179. var img = $('img.img-responsive');
  4180. $.openImage(img.src);
  4181. },
  4182. });
  4183. $.register({
  4184. rule: 'http://www.bilder-space.de/*.htm',
  4185. ready: function () {
  4186. 'use strict';
  4187. $.removeNodes('iframe');
  4188. var img = $('img.picture');
  4189. $.openImage(img.src);
  4190. },
  4191. });
  4192. $.register({
  4193. rule: 'http://www.bilder-upload.eu/show.php?file=*',
  4194. ready: function () {
  4195. 'use strict';
  4196. var i = $('input[type=image]');
  4197. $.openImage(i.src);
  4198. },
  4199. });
  4200. $.register({
  4201. rule: 'http://blackcatpix.com/v.php?*',
  4202. ready: function () {
  4203. 'use strict';
  4204. var img = $('td center img');
  4205. $.openImage(img.src);
  4206. },
  4207. });
  4208. $.register({
  4209. rule: 'http://www.casimages.com/img.php?*',
  4210. ready: function () {
  4211. 'use strict';
  4212. var img = $('td a img');
  4213. $.openImage(img.src);
  4214. },
  4215. });
  4216. $.register({
  4217. rule: {
  4218. host: /^www\.x45x\.info|(imadul|mypixxx\.lonestarnaughtygirls)\.com|ghanaimages\.co|imgurban\.info|d69\.in$/,
  4219. query: /\?p[mt]=(.+)/,
  4220. },
  4221. start: function (m) {
  4222. 'use strict';
  4223. $.openImage('/?di=' + m.query[1]);
  4224. },
  4225. });
  4226. $.register({
  4227. rule: 'http://javelite.tk/viewer.php?id=*',
  4228. ready: function () {
  4229. 'use strict';
  4230. var i = $('table img');
  4231. $.openImage(i.src);
  4232. },
  4233. });
  4234. $.register({
  4235. rule: {
  4236. host: /^imgchili\.(com|net)|www\.pixhost\.org$/,
  4237. path: /^\/show\//,
  4238. },
  4239. ready: function () {
  4240. 'use strict';
  4241. $.removeNodes('iframe, #ad');
  4242. try {
  4243. $('#all').style.display = '';
  4244. } catch (e) {
  4245. }
  4246. var o = $('#show_image');
  4247. $.openImage(o.src);
  4248. },
  4249. });
  4250. $.register({
  4251. rule: {
  4252. host: /^crd\.ht$/,
  4253. },
  4254. ready: function () {
  4255. 'use strict';
  4256. var i = $('.continue > form > input[name=link]');
  4257. $.openImage(i.value);
  4258. },
  4259. });
  4260. $.register({
  4261. rule: 'http://cubeupload.com/im/*',
  4262. ready: function () {
  4263. 'use strict';
  4264. var img = $('img.galleryBigImg');
  4265. $.openImage(img.src);
  4266. },
  4267. });
  4268. $.register({
  4269. rule: {
  4270. host: [
  4271. /^dailyss\.net$/,
  4272. /daily-img\.com$/,
  4273. /img-365\.com$/,
  4274. /^365-img\.com$/,
  4275. /^i\.hentai-ddl\.org$/,
  4276. ],
  4277. path: /^\/image\/.+$/,
  4278. },
  4279. ready: function () {
  4280. 'use strict';
  4281. var i = $('#image-viewer-container img');
  4282. $.openImage(i.src);
  4283. },
  4284. });
  4285. $.register({
  4286. rule: {
  4287. host: /^(depic\.me|(www\.)?picamatic\.com)$/,
  4288. },
  4289. ready: function () {
  4290. 'use strict';
  4291. var i = $('#pic');
  4292. $.openImage(i.src);
  4293. },
  4294. });
  4295. $.register({
  4296. rule: {
  4297. host: /^img(dino|tiger|zap)\.com$/,
  4298. path: /^\/viewer\.php$/,
  4299. query: /^\?file=/,
  4300. },
  4301. ready: function () {
  4302. 'use strict';
  4303. var o = $('#cursor_lupa');
  4304. $.openImage(o.src);
  4305. },
  4306. });
  4307. $.register({
  4308. rule: 'http://*.directupload.net/file/*.htm',
  4309. ready: function () {
  4310. 'use strict';
  4311. var i = $('#ImgFrame');
  4312. $.openImage(i.src);
  4313. },
  4314. });
  4315. $.register({
  4316. rule: {
  4317. host: /^(www\.)?empireload\.com$/,
  4318. path: /^(\/images(\/files\/\w)?)\/.\.php$/,
  4319. query: /^\?link=(.+)$/,
  4320. },
  4321. start: function (m) {
  4322. 'use strict';
  4323. $.openImage(m.path[1] + '/link/' + m.query[1]);
  4324. },
  4325. });
  4326. $.register({
  4327. rule: [
  4328. {
  4329. host: [
  4330. /^emptypix\.com|overdream\.cz$/,
  4331. /^www\.sexseeimage\.com$/,
  4332. ],
  4333. path: /^\/image\//,
  4334. },
  4335. {
  4336. host: /^10\.imageleon\.com$/,
  4337. path: /^\/img-(.+)\.html$/,
  4338. },
  4339. {
  4340. host: /^sexyxpixels\.com$/,
  4341. query: /^\?v=/,
  4342. },
  4343. ],
  4344. ready: function () {
  4345. 'use strict';
  4346. var img = $('#full_image');
  4347. $.openImage(img.src);
  4348. },
  4349. });
  4350. $.register({
  4351. rule: {
  4352. host: /^fastpic\.ru$/,
  4353. path: /^\/view\//,
  4354. },
  4355. ready: function () {
  4356. 'use strict';
  4357. var img = $('#picContainer #image');
  4358. $.openImage(img.src, {
  4359. referer: true,
  4360. });
  4361. },
  4362. });
  4363. $.register({
  4364. rule: 'http://www.fotolink.su/v.php?id=*',
  4365. ready: function () {
  4366. 'use strict';
  4367. var i = $('#content img');
  4368. $.openImage(i.src);
  4369. },
  4370. });
  4371. $.register({
  4372. rule: 'http://www.fotosik.pl/pokaz_obrazek/pelny/*.html',
  4373. ready: function () {
  4374. 'use strict';
  4375. var i = $('a.noborder img');
  4376. $.openImage(i.src);
  4377. },
  4378. });
  4379. $.register({
  4380. rule: {
  4381. host: /^freakimage\.com|www\.hostpic\.org$/,
  4382. path: /^\/view\.php$/,
  4383. query: /^\?filename=([^&]+)/,
  4384. },
  4385. start: function (m) {
  4386. 'use strict';
  4387. $.openImage('/images/' + m.query[1]);
  4388. },
  4389. });
  4390. $.register({
  4391. rule: {
  4392. host: /^freeimgup\.com$/,
  4393. path: /^\/xxx\//,
  4394. },
  4395. ready: function () {
  4396. 'use strict';
  4397. var img = $('#mainimage');
  4398. $.openImage(img.src);
  4399. },
  4400. });
  4401. $.register({
  4402. rule: [
  4403. 'http://funkyimg.com/viewer.php?img=*',
  4404. 'http://funkyimg.com/view/*',
  4405. ],
  4406. ready: function () {
  4407. 'use strict';
  4408. var i = $('#viewer img');
  4409. $.openImage(i.src);
  4410. },
  4411. });
  4412. $.register({
  4413. rule: {
  4414. host: /^(www\.)?gallery(nova|sense)\.se$/,
  4415. path: /^\/site\/v\//,
  4416. },
  4417. ready: function () {
  4418. 'use strict';
  4419. var i = $('#myUniqueImg').parentNode;
  4420. $.openImage(i.href);
  4421. },
  4422. });
  4423. $.register({
  4424. rule: {
  4425. host: /^(www\.)?gallerynova\.se$/,
  4426. path: /^\/site\/viewImage\/(\w+)/,
  4427. },
  4428. ready: function (m) {
  4429. 'use strict';
  4430. var confirm = $.searchScripts(/\$\("#confirmImage"\).val\("([^"]+)"\)/)[1];
  4431. $.post('/site/viewConfirmCode/' + m.path[1], {
  4432. confirm: confirm
  4433. }).then(function (rawJson) {
  4434. var json = _.parseJSON(rawJson);
  4435. var decodedHTML = document.createTextNode(json.content).data;
  4436. var imgURL = decodedHTML.match(/<a href="([^"]+)" target="_blank">/)[1];
  4437. $.openImage(imgURL);
  4438. });
  4439. },
  4440. });
  4441. (function () {
  4442. 'use strict';
  4443. var hostRule = /^goimagehost\.com$/;
  4444. $.register({
  4445. rule: {
  4446. host: hostRule,
  4447. path: /^\/xxx\/images\//,
  4448. },
  4449. });
  4450. $.register({
  4451. rule: {
  4452. host: hostRule,
  4453. path: /^\/xxx\/(.+)/,
  4454. },
  4455. start: function (m) {
  4456. $.openImage('/xxx/images/' + m.path[1]);
  4457. },
  4458. });
  4459. $.register({
  4460. rule: {
  4461. host: hostRule,
  4462. query: /^\?v=(.+)/,
  4463. },
  4464. start: function (m) {
  4465. $.openImage('/xxx/images/' + m.query[1]);
  4466. },
  4467. });
  4468. })();
  4469. $.register({
  4470. rule: {
  4471. host: /www\.(h-animes|adultmove)\.info/,
  4472. path: /^\/.+\/.+\/.+\.html$/,
  4473. },
  4474. ready: function () {
  4475. 'use strict';
  4476. var a = $('.dlbutton2 > a');
  4477. $.openImage(a.href);
  4478. },
  4479. });
  4480. $.register({
  4481. rule: 'http://hentaimg.com/mg/lndex-1.php?img=*',
  4482. ready: function () {
  4483. 'use strict';
  4484. $.openLink('index-1.php' + window.location.search);
  4485. },
  4486. });
  4487. $.register({
  4488. rule: 'http://hentaimg.com/mg/index-1.php?img=*',
  4489. ready: function () {
  4490. 'use strict';
  4491. var i = $('#content img');
  4492. $.openImage(i.src);
  4493. },
  4494. });
  4495. $.register({
  4496. rule: 'http://www.hostingpics.net/viewer.php?id=*',
  4497. ready: function () {
  4498. 'use strict';
  4499. var i = $('#img_viewer');
  4500. $.openImage(i.src);
  4501. },
  4502. });
  4503. $.register({
  4504. rule: {
  4505. host: /^ichan\.org$/,
  4506. path: /^\/image\.php$/,
  4507. query: /path=(.+)$/,
  4508. },
  4509. start: function (m) {
  4510. 'use strict';
  4511. $.openImage('/' + m.query[1]);
  4512. },
  4513. });
  4514. $.register({
  4515. rule: {
  4516. host: /ichan\.org$/,
  4517. },
  4518. ready: function () {
  4519. 'use strict';
  4520. $.$$('a').each(function (a) {
  4521. if (a.href.indexOf('/url/http://') > -1) {
  4522. a.href = a.href.replace(/http:\/\/.+\/url\/(?=http:\/\/)/, '');
  4523. }
  4524. });
  4525. },
  4526. });
  4527. $.register({
  4528. rule: 'http://ifotos.pl/zobacz/*',
  4529. ready: function () {
  4530. 'use strict';
  4531. var m = $('meta[property="og:image"]');
  4532. $.openImage(m.content);
  4533. },
  4534. });
  4535. $.register({
  4536. rule: {
  4537. host: /^ima\.so$/,
  4538. },
  4539. ready: function () {
  4540. 'use strict';
  4541. var a = $('#image_block a');
  4542. $.openImage(a.href);
  4543. },
  4544. });
  4545. $.register({
  4546. rule: [
  4547. 'http://image18.org/show/*',
  4548. 'http://screenlist.ru/details.php?image_id=*',
  4549. 'http://www.imagenetz.de/*/*.html',
  4550. ],
  4551. ready: function () {
  4552. 'use strict';
  4553. var img = $('#picture');
  4554. $.openImage(img.src);
  4555. },
  4556. });
  4557. $.register({
  4558. rule: {
  4559. host: /^image2you\.ru$/,
  4560. path: /^\/\d+\/\d+/,
  4561. },
  4562. ready: function () {
  4563. 'use strict';
  4564. var i = $.$('div.t_tips2 div > img');
  4565. if (!i) {
  4566. $.openLink('', {
  4567. post: {
  4568. _confirm: '',
  4569. },
  4570. });
  4571. return;
  4572. }
  4573. $.openImage(i.src);
  4574. },
  4575. });
  4576. $.register({
  4577. rule: 'http://imagearn.com/image.php?id=*',
  4578. ready: function () {
  4579. 'use strict';
  4580. var i = $('#img');
  4581. $.openImage(i.src);
  4582. },
  4583. });
  4584. $.register({
  4585. rule: 'http://www.imagebam.com/image/*',
  4586. ready: function () {
  4587. 'use strict';
  4588. var o = $('.image-container img[id]');
  4589. $.openImage(o.src, {
  4590. replace: true,
  4591. });
  4592. },
  4593. });
  4594. $.register({
  4595. rule: {
  4596. host: /^imageheli\.com|imgtube\.net|pixliv\.com$/,
  4597. path: /^\/img-([a-zA-Z0-9\-]+)\..+$/,
  4598. },
  4599. ready: function () {
  4600. 'use strict';
  4601. var a = $.$('a[rel="lightbox"]');
  4602. if (!a) {
  4603. $.openLink('', {
  4604. post: {
  4605. browser_fingerprint: '',
  4606. ads: '0',
  4607. },
  4608. });
  4609. return;
  4610. }
  4611. $.openImage(a.href);
  4612. },
  4613. });
  4614. $.register({
  4615. rule: 'http://www.imagehousing.com/image/*',
  4616. ready: function () {
  4617. 'use strict';
  4618. var i = $('td.text_item img');
  4619. $.openImage(i.src);
  4620. },
  4621. });
  4622. $.register({
  4623. rule: 'http://imageno.com/*.html',
  4624. ready: function () {
  4625. 'use strict';
  4626. var i = $('#image_div img');
  4627. $.openImage(i.src);
  4628. },
  4629. });
  4630. $.register({
  4631. rule: 'http://imagepix.org/image/*.html',
  4632. ready: function () {
  4633. 'use strict';
  4634. var i = $('img[border="0"]');
  4635. $.openImage(i.src);
  4636. },
  4637. });
  4638. (function () {
  4639. 'use strict';
  4640. function run () {
  4641. var o = $('#download_box img[id]');
  4642. $.openImage(o.src);
  4643. }
  4644. $.register({
  4645. rule: {
  4646. host: /^www\.imageporter\.com$/,
  4647. path: /^\/\w{12}\/.*\.html$/,
  4648. },
  4649. ready: run,
  4650. });
  4651. $.register({
  4652. rule: {
  4653. host: /^(www\.)?(image(carry|dunk|porter|switch)|pic(leet|turedip|tureturn)|imgspice)\.com|(piclambo|yankoimages)\.net$/,
  4654. },
  4655. ready: run,
  4656. });
  4657. })();
  4658. $.register({
  4659. rule: [
  4660. {
  4661. host: /^imagescream\.com$/,
  4662. path: /^\/img\/(soft\/)?/,
  4663. },
  4664. {
  4665. host: /^(www\.)?(picturescream|picturevip)\.com$/,
  4666. path: /^\/x\//,
  4667. },
  4668. {
  4669. host: [
  4670. /^picturescream\.asia$/,
  4671. /^uploadimage\.eu$/,
  4672. ],
  4673. },
  4674. ],
  4675. ready: function () {
  4676. 'use strict';
  4677. var i = $('#shortURL-content img');
  4678. $.openImage(i.src);
  4679. },
  4680. });
  4681. $.register({
  4682. rule: {
  4683. host: /^(imagescream|anonpic)\.com|all-poster\.ru$/,
  4684. query: /^\?v=/,
  4685. },
  4686. ready: function () {
  4687. 'use strict';
  4688. var i = $('#imagen img');
  4689. $.openImage(i.src);
  4690. },
  4691. });
  4692. $.register({
  4693. rule: {
  4694. host: /^bunnyforum\.org$/,
  4695. query: /^\?v=/,
  4696. },
  4697. ready: function () {
  4698. 'use strict';
  4699. var i = $('img[title^=Click]');
  4700. $.openImage(i.src);
  4701. },
  4702. });
  4703. (function () {
  4704. 'use strict';
  4705. var host = /^imageshack\.us$/;
  4706. $.register({
  4707. rule: {
  4708. host: host,
  4709. path: /^\/photo\/.+\/(.+)\/([^\/]+)/,
  4710. },
  4711. start: function (m) {
  4712. $.openImage(_.T('/f/{0}/{1}/')(m.path[1], m.path[2]));
  4713. },
  4714. });
  4715. $.register({
  4716. rule: {
  4717. host: host,
  4718. path: /^\/f\/.+\/[^\/]+/,
  4719. },
  4720. ready: function () {
  4721. var i = $('#fullimg');
  4722. $.openImage(i.src);
  4723. },
  4724. });
  4725. })();
  4726. $.register({
  4727. rule: 'http://imageshost.ru/photo/*/id*.html',
  4728. ready: function () {
  4729. 'use strict';
  4730. var a = $('#bphoto a');
  4731. $.openImage(a.href);
  4732. },
  4733. });
  4734. (function () {
  4735. 'use strict';
  4736. function run () {
  4737. var i = $('#img_obj');
  4738. $.openImage(i.src);
  4739. }
  4740. function run2 () {
  4741. var i = $('#img_obj');
  4742. $.openImage(i.src, {
  4743. replace: true,
  4744. });
  4745. }
  4746. $.register({
  4747. rule: [
  4748. {
  4749. host: /^www\.(freebunker|imagesnake|imgcarry|imgshots)\.com$/,
  4750. path: /^\/show\.php$/,
  4751. query: /^\?/,
  4752. },
  4753. {
  4754. host: /^www\.freebunker\.com$/,
  4755. path: /^\/show\//,
  4756. },
  4757. {
  4758. host: /^www\.(imagesnake|imagefruit)\.com$/,
  4759. path: /^\/(img|show)\/.+/,
  4760. },
  4761. {
  4762. host: /^imageban\.(ru|net)$/,
  4763. path: /^\/show\/\d{4}\/\d{2}\/\d{2}\/.+/,
  4764. },
  4765. 'http://fotoo.pl/show.php?img=*.html',
  4766. {
  4767. host: /^www\.(fotoszok\.pl|imagestime)\.com$/,
  4768. path: /^\/show\.php\/.*\.html$/,
  4769. },
  4770. ],
  4771. ready: run,
  4772. });
  4773. $.register({
  4774. rule: {
  4775. host: /^www\.imgcarry\.com$/,
  4776. path: /^\/show\//,
  4777. },
  4778. ready: run2,
  4779. });
  4780. })();
  4781. (function () {
  4782. 'use strict';
  4783. function run (rp) {
  4784. $.window.jQuery.prototype.append = undefined;
  4785. var i = $('img.pic');
  4786. $.openImage(i.src, {
  4787. replace: rp,
  4788. });
  4789. }
  4790. $.register({
  4791. rule: {
  4792. host: /^imagenpic\.com$/,
  4793. path: /^\/.*\/.+\.html$/,
  4794. },
  4795. ready: _.P(run, true),
  4796. });
  4797. $.register({
  4798. rule: {
  4799. host: /^imagecherry\.com$/,
  4800. },
  4801. ready: _.P(run, true),
  4802. });
  4803. $.register({
  4804. rule: {
  4805. host: /^imagetwist\.com$/,
  4806. },
  4807. ready: _.P(run, false),
  4808. });
  4809. })();
  4810. $.register({
  4811. rule: 'http://imageupper.com/i/?*',
  4812. ready: function () {
  4813. 'use strict';
  4814. var i = $('#img');
  4815. $.openImage(i.src);
  4816. },
  4817. });
  4818. $.register({
  4819. rule: [
  4820. 'http://*.imagevenue.com/img.php?*',
  4821. 'http://hotchyx.com/d/adult-image-hosting-view-08.php?id=*',
  4822. 'http://www.hostingfailov.com/photo/*',
  4823. ],
  4824. ready: function () {
  4825. 'use strict';
  4826. var i = $('#thepic');
  4827. $.openImage(i.src);
  4828. },
  4829. });
  4830. $.register({
  4831. rule: {
  4832. host: /^imagezilla\.net$/,
  4833. },
  4834. ready: function () {
  4835. 'use strict';
  4836. var i = $('#photo');
  4837. $.openImage(i.src, {
  4838. referer: true,
  4839. });
  4840. },
  4841. });
  4842. $.register({
  4843. rule: {
  4844. host: /^imagik\.fr$/,
  4845. path: /^\/view(-rl)?\/(.+)/,
  4846. },
  4847. start: function (m) {
  4848. 'use strict';
  4849. $.openImage('/uploads/' + m.path[2]);
  4850. },
  4851. });
  4852. $.register({
  4853. rule: 'http://img.3ezy.net/*.htm',
  4854. ready: function () {
  4855. 'use strict';
  4856. var l = $('link[rel="image_src"]');
  4857. $.openImage(l.href);
  4858. },
  4859. });
  4860. $.register({
  4861. rule: 'http://img1.imagilive.com/*/*',
  4862. ready: function () {
  4863. 'use strict';
  4864. var a = $.$('#page a.button');
  4865. if (a) {
  4866. $.redirect(a.href);
  4867. return;
  4868. }
  4869. var i = $('#page > img:not([id])');
  4870. $.openImage(i.src);
  4871. },
  4872. });
  4873. $.register({
  4874. rule: {
  4875. host: /^img24\.org$/,
  4876. },
  4877. ready: function () {
  4878. 'use strict';
  4879. var f = $.$('img.img-polaroid + form');
  4880. if (f) {
  4881. f.submit();
  4882. return;
  4883. }
  4884. f = $('img.img-polaroid');
  4885. $.openImage(f.src, {
  4886. referer: true,
  4887. });
  4888. },
  4889. });
  4890. $.register({
  4891. rule: {
  4892. host: /^img3x\.net$/,
  4893. },
  4894. ready: function () {
  4895. 'use strict';
  4896. var f = $.$('form');
  4897. if (f) {
  4898. f.submit();
  4899. return;
  4900. }
  4901. f = $('#show_image');
  4902. $.openImage(f.src);
  4903. },
  4904. });
  4905. $.register({
  4906. rule: {
  4907. host: /^www\.img(babes|flare)\.com$/,
  4908. },
  4909. ready: function () {
  4910. 'use strict';
  4911. var i = $.$('input[onclick]');
  4912. if (i) {
  4913. $.window.Decode();
  4914. return;
  4915. }
  4916. var i = $('#this_image');
  4917. $.openImage(i.src);
  4918. },
  4919. });
  4920. $.register({
  4921. rule: {
  4922. host: /^imgbar\.net$/,
  4923. path: /^\/img_show\.php$/,
  4924. query: /^\?view_id=/,
  4925. },
  4926. ready: function () {
  4927. 'use strict';
  4928. var i = $('center img');
  4929. $.openImage(i.src);
  4930. },
  4931. });
  4932. $.register({
  4933. rule: {
  4934. host: /^imgbar\.net$/,
  4935. },
  4936. ready: function () {
  4937. 'use strict';
  4938. var i = $('div.panel.top form input[name=sid]');
  4939. $.openLink('/img_show.php?view_id=' + i.value);
  4940. },
  4941. });
  4942. $.register({
  4943. rule: {
  4944. host: /^imgbin\.me$/,
  4945. path: /^\/view\/([A-Z]+)$/,
  4946. },
  4947. start: function (m) {
  4948. 'use strict';
  4949. var tpl = _.T('/image/{0}.jpg');
  4950. $.openImage(tpl(m.path[1]));
  4951. },
  4952. });
  4953. $.register({
  4954. rule: {
  4955. host: /^imgbox\.com$/,
  4956. path: /^\/[\d\w]+$/,
  4957. },
  4958. ready: function () {
  4959. 'use strict';
  4960. $.removeNodes('iframe');
  4961. var i = $('#img');
  4962. $.openImage(i.src);
  4963. },
  4964. });
  4965. $.register({
  4966. rule: {
  4967. host: [
  4968. /^img(fantasy|leech|\.pornleech|smile|say|nemo|sense)\.com$/,
  4969. /^(imagedomino|lovechix)\.com$/,
  4970. /^imageporn\.eu$/,
  4971. /^0img\.net$/,
  4972. /^daily-img\.com$/,
  4973. /^picangel\.in$/,
  4974. ],
  4975. query: /^\?[pv]=/,
  4976. },
  4977. ready: function () {
  4978. 'use strict';
  4979. if ($.window.confirmAge) {
  4980. $.window.confirmAge(1);
  4981. return;
  4982. }
  4983. var i = $('#container-home img[onclick]');
  4984. $.openImage(i.src);
  4985. },
  4986. });
  4987. $.register({
  4988. rule: {
  4989. host: /^imglocker\.com$/,
  4990. path: [
  4991. /^(\/\w+)\/(.+)\.html$/,
  4992. /^(\/\w+)\/(.+)$/,
  4993. ],
  4994. },
  4995. start: function (m) {
  4996. 'use strict';
  4997. var url = _.T('//img.imglocker.com{0}_{1}');
  4998. $.openImage(url(m.path[1], m.path[2]));
  4999. },
  5000. });
  5001. $.register({
  5002. rule: {
  5003. host: [
  5004. /^imgnova\.xyz$/,
  5005. /^www\.hentai-hot\.xyz$/,
  5006. /^www\.hentai-king\.online$/,
  5007. ],
  5008. path: /^\/i\/.+\.php$/,
  5009. query: /f=(.+)$/,
  5010. },
  5011. start: function (m) {
  5012. 'use strict';
  5013. $.openImage('f/' + m.query[1]);
  5014. },
  5015. });
  5016. (function () {
  5017. 'use strict';
  5018. function waitDOM (element, fn) {
  5019. return _.D(function (resolve, reject) {
  5020. var observer = new MutationObserver(function (mutations) {
  5021. mutations.forEach(function (mutation) {
  5022. if (mutation.type !== 'childList') {
  5023. return;
  5024. }
  5025. var result = _.C(mutation.addedNodes).find(function (child) {
  5026. return fn(child) ? child : _.none;
  5027. });
  5028. if (!result) {
  5029. return;
  5030. }
  5031. observer.disconnect();
  5032. resolve(result.payload);
  5033. });
  5034. });
  5035. observer.observe(element, {
  5036. childList: true,
  5037. });
  5038. });
  5039. }
  5040. var pathRule = /^\/([0-9a-z]+)(\.|\/|$)/;
  5041. function go (id, pre, next) {
  5042. $.openLink('', {
  5043. post: {
  5044. op: 'view',
  5045. id: id,
  5046. pre: pre,
  5047. next: next,
  5048. },
  5049. });
  5050. }
  5051. function getNext1 (i) {
  5052. return i.value;
  5053. }
  5054. function getNext2 (i) {
  5055. var next = i.onclick && i.onclick.toString().match(/value='([^']+)'/);
  5056. if (next) {
  5057. next = next[1];
  5058. return next;
  5059. } else {
  5060. return i.value;
  5061. }
  5062. }
  5063. function helper (id, getNext) {
  5064. var recaptcha = $.$('#recaptcha_widget');
  5065. if (recaptcha) {
  5066. _.info('stop because recaptcha');
  5067. return;
  5068. }
  5069. var i = $.$('input[name="next"]');
  5070. if (i) {
  5071. var next = getNext(i);
  5072. go(id, $('input[name="pre"]').value, next);
  5073. return;
  5074. }
  5075. i = $.$('img.pic');
  5076. if (i) {
  5077. $.openImage(i.src);
  5078. return;
  5079. }
  5080. _.info('do nothing');
  5081. }
  5082. $.register({
  5083. rule: {
  5084. host: [
  5085. /^img(universal|paying|mega|zeus|monkey|trex|ve|dew|diamond)\.com$/,
  5086. /^(www\.)?imgsee\.me$/,
  5087. /^img(click|maid)\.net$/,
  5088. /^(uploadrr|imageeer|imzdrop|www\.uimgshare|pic-maniac)\.com$/,
  5089. /^imgdrive\.co$/,
  5090. /^cuteimg\.cc$/,
  5091. /^img(tiger|gold)\.org$/,
  5092. /^myimg\.club$/,
  5093. /^foxyimg\.link$/,
  5094. /^hulkimge\.com$/,
  5095. /^coreimg\.net$/,
  5096. ],
  5097. path: pathRule,
  5098. },
  5099. ready: function (m) {
  5100. helper(m.path[1], getNext1);
  5101. },
  5102. });
  5103. $.register({
  5104. rule: {
  5105. host: [
  5106. /^img(rock|town)\.net$/,
  5107. /^img(maze|outlet)\.com$/,
  5108. ],
  5109. path: pathRule,
  5110. },
  5111. ready: function () {
  5112. var i = $.$('img.pic');
  5113. if (i) {
  5114. $.openImage(i.src);
  5115. return;
  5116. }
  5117. var d = $('div[id^="imageviewi"]');
  5118. waitDOM(d, function (node) {
  5119. return node.nodeName === 'FORM' && $.$('input[name="id"]', node);
  5120. }).then(function (node) {
  5121. node.submit();
  5122. }).catch(function (e) {
  5123. _.warn(e);
  5124. });
  5125. },
  5126. });
  5127. $.register({
  5128. rule: {
  5129. host: /^chronos\.to$/,
  5130. path: pathRule,
  5131. },
  5132. ready: function (m) {
  5133. helper(m.path[1], getNext2);
  5134. },
  5135. });
  5136. $.register({
  5137. rule: 'http://imgview.net/tpind.php',
  5138. ready: function () {
  5139. var i = $.$('img.pic');
  5140. if (i) {
  5141. $.openImage(i.src, {replace: true});
  5142. return;
  5143. }
  5144. var d = $('div[id^="imageviewi"] input[type="submit"][style=""]');
  5145. d = d.parentNode;
  5146. d.submit();
  5147. },
  5148. });
  5149. })();
  5150. $.register({
  5151. rule: {
  5152. host: /^(imgsure|picexposed)\.com$/,
  5153. },
  5154. ready: function () {
  5155. 'use strict';
  5156. var i = $('img.pic');
  5157. $.openImage(i.src);
  5158. },
  5159. });
  5160. $.register({
  5161. rule: 'http://imgtheif.com/image/*.html',
  5162. ready: function () {
  5163. 'use strict';
  5164. var a = $('div.content-container a');
  5165. $.openImage(a.href);
  5166. },
  5167. });
  5168. $.register({
  5169. rule: {
  5170. host: /^imgvault\.pw$/,
  5171. path: /^\/view-image\//,
  5172. },
  5173. ready: function () {
  5174. 'use strict';
  5175. var a = $('article div.span7 a[target="_blank"]');
  5176. $.openImage(a.href);
  5177. },
  5178. });
  5179. $.register({
  5180. rule: 'http://ipic.su/?page=img&pic=*',
  5181. ready: function () {
  5182. 'use strict';
  5183. var i = $('#fz');
  5184. $.openImage(i.src);
  5185. },
  5186. });
  5187. $.register({
  5188. rule: {
  5189. host: /^javcity\.com$/,
  5190. },
  5191. ready: function () {
  5192. 'use strict';
  5193. var a = $('.entry-content > h1:nth-child(1) > a:nth-child(1)');
  5194. var url = a.onclick.toString();
  5195. url = url.match(/window\.open\('([^']+)'\)/);
  5196. if (!url) {
  5197. _.info('pattern changed')
  5198. return;
  5199. }
  5200. $.openImage(url[1]);
  5201. },
  5202. });
  5203. $.register({
  5204. rule: {
  5205. host: /keptarolo\.hu$/,
  5206. path: /^(\/[^\/]+\/[^\/]+\.jpg)$/,
  5207. },
  5208. start: function (m) {
  5209. 'use strict';
  5210. $.openImage('http://www.keptarolo.hu/kep' + m.path[1]);
  5211. },
  5212. });
  5213. $.register({
  5214. rule: {
  5215. host: /^lostpic\.net$/,
  5216. query: /^\?photo=\d+$/,
  5217. },
  5218. ready: function () {
  5219. 'use strict';
  5220. var i = $('img.notinline.circle');
  5221. $.openImage(i.src);
  5222. },
  5223. });
  5224. (function () {
  5225. 'use strict';
  5226. function helper (m) {
  5227. $.openImage('/images/' + m.query[1]);
  5228. }
  5229. $.register({
  5230. rule: {
  5231. host: [
  5232. /^(hentai-hosting|miragepics|funextra\.hostzi|imgrex)\.com$/,
  5233. /^bilder\.nixhelp\.de$/,
  5234. /^imagecurl\.(com|org)$/,
  5235. /^imagevau\.eu$/,
  5236. /^img\.deli\.sh$/,
  5237. /^img(dream|soo|nm)\.net$/,
  5238. /^imgsicily\.it$/,
  5239. /^www\.imghere\.net$/,
  5240. ],
  5241. path: /^\/viewer\.php$/,
  5242. query: /file=([^&]+)/,
  5243. },
  5244. start: helper,
  5245. });
  5246. $.register({
  5247. rule: {
  5248. host: /^(dwimg|imgsin|www\.pictureshoster)\.com$/,
  5249. path: /^\/viewer\.php$/,
  5250. query: /file=([^&]+)/,
  5251. },
  5252. start: function (m) {
  5253. $.openImage('/files/' + m.query[1]);
  5254. },
  5255. });
  5256. $.register({
  5257. rule: {
  5258. host: [
  5259. /img(nip|central|cream)\.com$/,
  5260. /imageview\.me|244pix\.com|postimg\.net$/,
  5261. ],
  5262. path: /^\/viewerr.*\.php$/,
  5263. query: /file=([^&]+)/,
  5264. },
  5265. start: helper,
  5266. });
  5267. $.register({
  5268. rule: [
  5269. 'http://www.overpic.net/viewer.php?file=*',
  5270. ],
  5271. ready: function () {
  5272. var i = $('#main_img');
  5273. $.openImage(i.src);
  5274. },
  5275. });
  5276. $.register({
  5277. rule: {
  5278. host: /(empireload|loadsanook)\.com$/,
  5279. query: /file=([^&]+)/,
  5280. },
  5281. start: function (m) {
  5282. $.openImage('files/' + m.query[1]);
  5283. },
  5284. });
  5285. })();
  5286. $.register({
  5287. rule: {
  5288. host: /^www\.mrjh\.org$/,
  5289. path: /^\/gallery\.php$/,
  5290. query: /^\?entry=(.+)$/,
  5291. },
  5292. ready: function (m) {
  5293. 'use strict';
  5294. var url = m.query[1];
  5295. $.openImage('/' + url);
  5296. },
  5297. });
  5298. $.register({
  5299. rule: {
  5300. host: /^www\.noelshack\.com$/
  5301. },
  5302. ready: function () {
  5303. var i = $('#elt_to_aff');
  5304. $.openImage(i.src);
  5305. },
  5306. });
  5307. $.register({
  5308. rule: 'http://pic-money.ru/*.html',
  5309. ready: function () {
  5310. 'use strict';
  5311. var f = document.forms[0];
  5312. var sig = $('input[name="sig"]', f).value;
  5313. var pic_id = $('input[name="pic_id"]', f).value;
  5314. var referer = $('input[name="referer"]', f).value;
  5315. var url = _.T('/pic.jpeg?pic_id={pic_id}&sig={sig}&referer={referer}');
  5316. $.openImage(url({
  5317. sig: sig,
  5318. pic_id: pic_id,
  5319. referer: referer,
  5320. }));
  5321. },
  5322. });
  5323. $.register({
  5324. rule: 'http://www.pic-upload.de/view-*.html',
  5325. ready: function () {
  5326. 'use strict';
  5327. $.removeNodes('.advert');
  5328. var i = $('img.preview_picture_2b, img.original_picture_2b');
  5329. $.openImage(i.src);
  5330. },
  5331. });
  5332. $.register({
  5333. rule: {
  5334. host: /^pic(2profit|p2)\.com$/,
  5335. },
  5336. ready: function () {
  5337. 'use strict';
  5338. var i = $('form > #d1 ~ input[name=bigimg]');
  5339. $.openImage(i.value);
  5340. },
  5341. });
  5342. $.register({
  5343. rule: {
  5344. host: /^pic(4|5)you.ru$/
  5345. },
  5346. ready: function () {
  5347. if ($.$('#d1 > img') != null) {
  5348. var URLparams = location.href.split("/", 5);
  5349. var next = URLparams[0] + '/' + URLparams[1] + '/' + URLparams[2] + '/' + URLparams[3] + '/' + URLparams[4] + '/1/';
  5350. $.setCookie('p4yclick','1');
  5351. $.openLink(next);
  5352. } else {
  5353. var i = $('#d1 img').src;
  5354. $.openImage(i);
  5355. }
  5356. },
  5357. });
  5358. $.register({
  5359. rule: {
  5360. host: /^(www\.)?piccash\.net$/
  5361. },
  5362. ready: function () {
  5363. var i = $('.container > img');
  5364. var m =i.onclick.toString().match(/mshow\('([^']+)'\);/);
  5365. $.openImage(m[1]);
  5366. },
  5367. });
  5368. $.register({
  5369. rule: [
  5370. 'http://amateurfreak.org/share-*.html',
  5371. 'http://amateurfreak.org/share.php?id=*',
  5372. 'http://images.maxigame.by/share-*.html',
  5373. 'http://picfox.org/*',
  5374. 'http://www.euro-pic.eu/share.php?id=*',
  5375. 'http://www.gratisimage.dk/share-*.html',
  5376. 'http://xxx.freeimage.us/share.php?id=*',
  5377. 'http://npicture.net/share-*.html',
  5378. 'http://www.onlinepic.net/share.php?id=*',
  5379. 'http://www.pixsor.com/share.php?id=*',
  5380. 'http://www.pixsor.com/share-*.html',
  5381. 'http://pixsor.com/XXX/share-*.html',
  5382. 'http://holdthemoan.net/x/share-*.html',
  5383. 'http://imgurx.net/x/share-*.html',
  5384. ],
  5385. ready: function () {
  5386. 'use strict';
  5387. var o = $('#iimg');
  5388. $.openImage(o.src);
  5389. },
  5390. });
  5391. $.register({
  5392. rule: 'http://picmoe.net/d.php?id=*',
  5393. ready: function () {
  5394. 'use strict';
  5395. var i = $('img');
  5396. $.openImage(i.src);
  5397. },
  5398. });
  5399. $.register({
  5400. rule: [
  5401. 'http://pics-money.ru/allpicfree/*',
  5402. 'http://www.pics-money.ru/allimage/*',
  5403. ],
  5404. });
  5405. $.register({
  5406. rule: {
  5407. host: /^pics-money\.ru$/,
  5408. path: /^\/v\.php$/,
  5409. },
  5410. ready: function () {
  5411. 'use strict';
  5412. $.removeNodes('iframe');
  5413. var i = $('center img:not([id])');
  5414. $.openImage(i.src);
  5415. },
  5416. });
  5417. $.register({
  5418. rule: {
  5419. host: /^www\.pics-money\.ru$/,
  5420. },
  5421. ready: function () {
  5422. 'use strict';
  5423. $.removeNodes('iframe');
  5424. var i = $('#d1 img');
  5425. i = i.onclick.toString();
  5426. i = i.match(/mshow\('(.+)'\)/);
  5427. i = i[1];
  5428. $.openImage(i);
  5429. },
  5430. });
  5431. $.register({
  5432. rule: 'http://picshare.geenza.com/pics/*',
  5433. ready: function () {
  5434. 'use strict';
  5435. var i = $('#picShare_image_container');
  5436. $.openImage(i.src);
  5437. },
  5438. });
  5439. $.register({
  5440. rule: {
  5441. host: /^picstream\.tv$/,
  5442. path: /^\/.*\/.*\.html$/,
  5443. },
  5444. ready: function () {
  5445. 'use strict';
  5446. var img = $('#view1 > div:nth-child(1) > a:nth-child(1) > img:nth-child(1)');
  5447. $.openImage(img.src);
  5448. },
  5449. });
  5450. $.register({
  5451. rule: {
  5452. host: /^(www\.)?pimpandhost\.com$/,
  5453. path: /^\/image\//,
  5454. },
  5455. ready: function () {
  5456. 'use strict';
  5457. var a = $('#image_original');
  5458. var el = document.createElement('div');
  5459. el.innerHTML = a.value;
  5460. var img = $('img', el);
  5461. $.openImage(img.src);
  5462. },
  5463. });
  5464. $.register({
  5465. rule: {
  5466. host: /^pixhub\.eu$/,
  5467. },
  5468. ready: function () {
  5469. 'use strict';
  5470. $.removeNodes('iframe, .adultpage, #FFN_Banner_Holder');
  5471. var i = $('.image-show img');
  5472. $.openImage(i.src);
  5473. },
  5474. });
  5475. $.register({
  5476. rule: {
  5477. host: /^(www\.)?pixroute\.com$/
  5478. },
  5479. ready: function () {
  5480. 'use strict';
  5481. var o = $('.fr4me > div:nth-child(20) > a:nth-child(1) > img:nth-child(1)');
  5482. $.openImage(o.src);
  5483. },
  5484. });
  5485. $.register({
  5486. rule: {
  5487. host: /^www\.pornimagex\.com$/,
  5488. path: /^\/image\/.*$/,
  5489. },
  5490. ready: function () {
  5491. 'use strict';
  5492. var img = $('#fixed img.border2px');
  5493. $.openImage(img.src);
  5494. },
  5495. });
  5496. $.register({
  5497. rule: {
  5498. host: /^postimg\.org$/,
  5499. },
  5500. ready: function () {
  5501. 'use strict';
  5502. var a = $.$('body > center > a > img');
  5503. if(a){
  5504. $.openLink(a.parentNode.href);
  5505. }
  5506. var i = $('body > center > img');
  5507. $.openImage(i.src);
  5508. },
  5509. });
  5510. $.register({
  5511. rule: {
  5512. host: /^prntscr\.com$/
  5513. },
  5514. ready: function () {
  5515. 'use strict';
  5516. var i = $('#screenshot-image');
  5517. $.openImage(i.src);
  5518. },
  5519. });
  5520. $.register({
  5521. rule: {
  5522. host: /^pronpic\.org$/,
  5523. },
  5524. ready: function () {
  5525. 'use strict';
  5526. var img = $('table.new_table2:nth-child(2) img.link');
  5527. var url = img.src.replace('th_', '');
  5528. $.openImage(url);
  5529. },
  5530. });
  5531. $.register({
  5532. rule: {
  5533. host: /^(qrrro|greenpiccs)\.com$/,
  5534. path: /^(\/images\/.+)\.html$/,
  5535. },
  5536. start: function (m) {
  5537. 'use strict';
  5538. $.openImage(m.path[1]);
  5539. },
  5540. });
  5541. (function () {
  5542. 'use strict';
  5543. function ready () {
  5544. $.removeNodes('iframe, #adblock_detect, .popupOverlay');
  5545. var node = $.$('#continuetoimage > form input');
  5546. if (node) {
  5547. _.wait(500).then(function () {
  5548. node.removeAttribute('disabled');
  5549. return _.wait(500);
  5550. }).then(function () {
  5551. node.focus();
  5552. node.click();
  5553. node.click();
  5554. });
  5555. return;
  5556. }
  5557. var i = $('img[class^=centred]');
  5558. $.openImage(i.src);
  5559. }
  5560. $.register({
  5561. rule: [
  5562. {
  5563. host: [
  5564. /^image(ontime|corn|picsa|horse)\.com$/,
  5565. /^(zonezeed|zelje|croft|myhot|bok|hostur|greasy)image\.com$/,
  5566. /^img(icy|next|savvy|\.spicyzilla|twyti|xyz|devil|tzar|ban|pu|beer|wet|tornado|kicks|-pay|nimz|binbou|2share|22|cover|hit|main|trial)\.com$/,
  5567. /^img-(zone|planet)\.com$/,
  5568. /^www\.(imagefolks|img(blow|lemon))\.com$/,
  5569. /^xxx(\.pornprimehd|imagenow|screens)\.com$/,
  5570. /^(picstwist|ericsony|wpc8|uplimg|lexiit|thumbnailus|newimagepost|fapingpics|dimtus|tinizo)\.com$/,
  5571. /^((i|hentai)\.)?imgslip\.com$/,
  5572. /^(i|xxx)\.hentaiyoutube\.com$/,
  5573. /^(go|er)imge\.com$/,
  5574. /^(like\.)?08lkk\.com$/,
  5575. /^(www\.)?\.imgult\.com$/,
  5576. /^nim(plus|zshare)\.com$/,
  5577. /^nudeximg\.com$/,
  5578. /imgseeds?\.com$/,
  5579. /xxxsparrow?\.com$/,
  5580. /damimage\.com$/,
  5581. /imagedecode\.com$/,
  5582. /^img(serve|coin|fap|candy|master|-view|run|boom|project|python|pics)\.net$/,
  5583. /^(naughtygate|gallerycloud|imagelaser|picture-bang|project-photo|pix-link|funimg|golfpit|xximg)\.net$/,
  5584. /^(shot|adult)img\.org$/,
  5585. /^img(studio|spot)\.org$/,
  5586. /^image(\.adlock|on|team)\.org$/,
  5587. /^(drag|teen|mega)image\.org$/,
  5588. /^teenshot\.org$/,
  5589. /^(hotimages|55888)\.eu$/,
  5590. /^img(cloud|mag)\.co$/,
  5591. /^pixup\.us$/,
  5592. /^(bulkimg|photo-up|myimg|pop-img|img-pop|ads-img)\.info$/,
  5593. /^img\.yt$/,
  5594. /^vava\.in$/,
  5595. /^(pixxx|picspornfree|imgload|fapat)\.me$/,
  5596. /^(porno-pirat|24avarii|loftlm|18pron|imgplus)\.ru$/,
  5597. /^www\.hotimage\.uk$/,
  5598. /^imgease\.re$/,
  5599. /^goimg\.xyz$/,
  5600. /^pic2pic\.site$/,
  5601. /^darpix\.ga$/,
  5602. /^sxpics\.nl$/,
  5603. /^darpix\.desi$/,
  5604. /^pic4you\.top$/,
  5605. /^imgsen\.se$/,
  5606. ],
  5607. path: /^\/img-.*\.html/,
  5608. },
  5609. {
  5610. host: [
  5611. /^img(run|twyti)\.net$/,
  5612. /^imgtwyti\.com$/,
  5613. ],
  5614. path: /^\/t\/img-.*\.html/,
  5615. },
  5616. {
  5617. host: /^imgking\.co$/,
  5618. path: /^\/img-.*\.html/,
  5619. },
  5620. {
  5621. host: /^imgbb\.net$/,
  5622. path: /^\/.-.+$/,
  5623. },
  5624. ],
  5625. ready: ready,
  5626. });
  5627. $.register({
  5628. rule: {
  5629. host: [
  5630. /^www\.img(taxi|adult|wallet)\.com$/,
  5631. /^www\.imgdrive\.net$/,
  5632. ],
  5633. path: /^\/img-.*\.html$/,
  5634. },
  5635. start: function () {
  5636. var c = $.getCookie('img_c_d') || $.getCookie('img_p_d');
  5637. if (c) {
  5638. return;
  5639. }
  5640. $.post(window.location.href.toString(), {
  5641. cti: 1,
  5642. ref: '',
  5643. rc: 1,
  5644. }).then(function (data) {
  5645. window.location.reload();
  5646. });
  5647. },
  5648. ready: function () {
  5649. $.removeNodes('iframe');
  5650. var node = $.$('#continuetoimage > form input');
  5651. if (node) {
  5652. node.click();
  5653. node.click();
  5654. return;
  5655. }
  5656. $.resetCookies();
  5657. var i = $('img[class^=centred]');
  5658. $.openImage(i.src);
  5659. },
  5660. });
  5661. function helper () {
  5662. $.window.setTimeout = _.nop;
  5663. return $.get(window.location.toString()).then(function (data) {
  5664. return $.toDOM(data);
  5665. });
  5666. }
  5667. $.register({
  5668. rule: {
  5669. host: /^08lkk\.com$/,
  5670. path: /^\/Photo\/img-.+\.html$/,
  5671. },
  5672. start: function () {
  5673. helper().then(function (page) {
  5674. var i = $('img[class^=centred]', page);
  5675. $.openImage(i.src);
  5676. });
  5677. },
  5678. });
  5679. $.register({
  5680. rule: {
  5681. host: /^08lkk\.com$/,
  5682. path: /^\/\d+\/img-.*\.html$/,
  5683. },
  5684. start: function () {
  5685. helper().then(function (page) {
  5686. var bbcode = $.$('#imagecodes input', page);
  5687. bbcode = bbcode.value.match(/.+\[IMG\]([^\[]+)\[\/IMG\].+/);
  5688. bbcode = bbcode[1];
  5689. bbcode = bbcode.replace('small', 'big');
  5690. $.openImage(bbcode);
  5691. });
  5692. },
  5693. });
  5694. $.register({
  5695. rule: [
  5696. {
  5697. host: /^imgking\.co$/,
  5698. path: /^\/img3-.*\.html/,
  5699. },
  5700. {
  5701. host: /^imgkings\.com$/,
  5702. path: /^\/img-.*\.html/,
  5703. },
  5704. ],
  5705. ready: function () {
  5706. var url = $.window.linkid;
  5707. $.openImage(url);
  5708. },
  5709. });
  5710. $.register({
  5711. rule: [
  5712. {
  5713. host: /^imgking\.co$/,
  5714. path: /^\/img4-.*\.html/,
  5715. },
  5716. {
  5717. host: /^imgkings\.com$/,
  5718. path: /^\/img2-.*\.html/,
  5719. },
  5720. ],
  5721. ready: ready,
  5722. });
  5723. })();
  5724. $.register({
  5725. rule: 'http://www.subirimagenes.com/*.html',
  5726. ready: function () {
  5727. 'use strict';
  5728. var i = $('#ImagenVisualizada');
  5729. $.openImage(i.src);
  5730. },
  5731. });
  5732. $.register({
  5733. rule: 'http://tinypic.com/view.php?pic=*',
  5734. ready: function () {
  5735. 'use strict';
  5736. var i = $('#imgElement');
  5737. $.openImage(i.src);
  5738. },
  5739. });
  5740. $.register({
  5741. rule: {
  5742. host: /^www\.turboimagehost\.com$/,
  5743. path: /^\/p\//,
  5744. },
  5745. ready: function () {
  5746. 'use strict';
  5747. var i = $('#imageid');
  5748. $.openImage(i.src);
  5749. },
  5750. });
  5751. $.register({
  5752. rule: 'http://vvcap.net/db/*.htp',
  5753. ready: function () {
  5754. 'use strict';
  5755. var i = $('img');
  5756. $.openImage(i.src, {
  5757. replace: true,
  5758. });
  5759. },
  5760. });
  5761. $.register({
  5762. rule: {
  5763. host: /^x\.pixfarm\.net$/,
  5764. path: /^\/sexy\/\d+\/\d+\/.+\.html$/,
  5765. },
  5766. ready: function () {
  5767. 'use strict';
  5768. var i = $('img');
  5769. $.openImage(i.src);
  5770. },
  5771. });
  5772. $.register({
  5773. rule: {
  5774. host: /\.yfrog\.com$/,
  5775. },
  5776. ready: function () {
  5777. 'use strict';
  5778. if (/^\/z/.test(window.location.pathname)) {
  5779. var i = $('#the-image img');
  5780. $.openImage(i.src);
  5781. return;
  5782. }
  5783. var a = $.$('#continue-link a, #main_image');
  5784. if (a) {
  5785. $.openLink('/z' + window.location.pathname);
  5786. return;
  5787. }
  5788. },
  5789. });
  5790. $.register({
  5791. rule: {
  5792. host: /^akoam\.com$/,
  5793. path: /^\/download\//,
  5794. },
  5795. start: function () {
  5796. 'use strict';
  5797. var location_link = location.hash;
  5798. $.post(location_link).then(function (data) {
  5799. data = JSON.parse(data);
  5800. if (!data.hash_data) {
  5801. _.warn('rule changed');
  5802. return;
  5803. }
  5804. $.openLink(data.direct_link);
  5805. });
  5806. },
  5807. });
  5808. $.register({
  5809. rule: {
  5810. host: /^www\.anafile\.com$/,
  5811. },
  5812. ready: function () {
  5813. 'use strict';
  5814. var b = $.$('#btn_download');
  5815. if (b) {
  5816. b.disabled = false;
  5817. $.removeNodes('div[align=center]');
  5818. return;
  5819. }
  5820. b = $('#plans_free form [type=submit]');
  5821. b.click();
  5822. },
  5823. });
  5824. $.register({
  5825. rule: {
  5826. host: /^(www\.)?arab\.sh$/,
  5827. path: /^\/\w+$/,
  5828. },
  5829. ready: function () {
  5830. 'use strict';
  5831. var f = $('form[name=F1]');
  5832. setTimeout(function() {
  5833. f.submit();
  5834. }, 20000);
  5835. },
  5836. });
  5837. $.register({
  5838. rule: {
  5839. host: /^(www\.)?coolrom\.com$/,
  5840. path: /^\/dlpop\.php$/,
  5841. },
  5842. ready: function () {
  5843. 'use strict';
  5844. var matches = $.searchScripts(/<form method="POST" action="([^"]+)">/);
  5845. $.openLink(matches[1]);
  5846. },
  5847. });
  5848. (function() {
  5849. 'use strict';
  5850. $.register({
  5851. rule: {
  5852. host: /^(www\.)?dl-protect\.com$/,
  5853. path: /\/[A-Z0-9]+/,
  5854. },
  5855. ready: function () {
  5856. if ($.$('#captcha')) {
  5857. return;
  5858. }
  5859. var f = $.$('form[name=ccerure]');
  5860. if (f) {
  5861. var observer = new MutationObserver(function (mutations) {
  5862. var iIn = $('input[id=in]');
  5863. for (var i = 0; i < mutations.length; i++) {
  5864. if (mutations[i].target.value && mutations[i].attributeName === 'value') {
  5865. observer.disconnect();
  5866. iIn.value = "Tracking too much hurts users' privacy";
  5867. if (!canFastRedirect()) {
  5868. return;
  5869. }
  5870. setTimeout(function() {
  5871. f.submit();
  5872. }, 600);
  5873. break;
  5874. }
  5875. }
  5876. });
  5877. var iIn = $('input[id=in]');
  5878. if (iIn.value) {
  5879. setTimeout(function() {
  5880. f.submit();
  5881. }, 600);
  5882. } else {
  5883. observer.observe(iIn, {
  5884. attributes: true,
  5885. });
  5886. }
  5887. return;
  5888. }
  5889. var l = $.$$('#slinks > a');
  5890. if (l.size() === 1) {
  5891. $.openLink(l.at(0).href);
  5892. }
  5893. },
  5894. });
  5895. function canFastRedirect () {
  5896. return !$.$('form[name=ccerure]').onsubmit && !$.$('form[name=ccerure] input[name=pwd]');
  5897. }
  5898. })();
  5899. $.register({
  5900. rule: {
  5901. host: /^(www\.)?embedupload\.com$/,
  5902. path: /^\/$/,
  5903. query: /^\?\w{2}=\w+$/
  5904. },
  5905. ready: function () {
  5906. 'use strict';
  5907. var downloadPage = $('.categories a[target=_blank]');
  5908. $.openLink(downloadPage);
  5909. },
  5910. });
  5911. $.register({
  5912. rule: {
  5913. host: /^www\.fileproject\.com\.br$/,
  5914. path: /^\/files\/+/,
  5915. },
  5916. ready: function () {
  5917. 'use strict';
  5918. var m = $.searchScripts(/<a id="down" href="([^"]+)">/);
  5919. $.openLink(m[1]);
  5920. },
  5921. });
  5922. $.register({
  5923. rule: {
  5924. host: /^(www\.)?(firedrive|putlocker)\.com$/,
  5925. path: /^\/file\/[0-9A-F]+$/,
  5926. },
  5927. ready: function () {
  5928. 'use strict';
  5929. var c = $('#confirm_form');
  5930. c.submit();
  5931. },
  5932. });
  5933. $.register({
  5934. rule: {
  5935. host: /^iori\.us$/,
  5936. },
  5937. ready: function () {
  5938. 'use strict';
  5939. var a = $('#wrapper .tombol a');
  5940. $.openLink(a.href);
  5941. },
  5942. });
  5943. $.register({
  5944. rule: {
  5945. host: /^(www\.)?jheberg\.net$/,
  5946. path: /^\/captcha\//,
  5947. },
  5948. ready: function () {
  5949. 'use strict';
  5950. $('.dl-button').click();
  5951. },
  5952. });
  5953. $.register({
  5954. rule: {
  5955. host: /^(www\.)?jheberg\.net$/,
  5956. path: /^\/redirect\//,
  5957. },
  5958. ready: function () {
  5959. 'use strict';
  5960. $.removeAllTimer();
  5961. var matches = $.searchScripts(/'slug':\s*'([^']+)',\s*'hoster':\s*'([^']+)'/);
  5962. var slug = matches[1];
  5963. var hoster = matches[2];
  5964. $.post('/get/link/', {
  5965. 'slug': slug,
  5966. 'hoster': hoster
  5967. }).then(function(response) {
  5968. var respJSON = _.parseJSON(response);
  5969. $.openLink(respJSON.url);
  5970. });
  5971. },
  5972. });
  5973. $.register({
  5974. rule: {
  5975. host: /^(www\.)?larashare\.com$/,
  5976. path: /^\/do\.php$/,
  5977. query: /id=\d+/,
  5978. },
  5979. start: function () {
  5980. 'use strict';
  5981. $.openLink(document.location.href.replace('id=','down='));
  5982. },
  5983. });
  5984. $.register({
  5985. rule: {
  5986. host: /^(www\.)?maxmirror\.com$/,
  5987. path: /^\/redirect\//,
  5988. },
  5989. ready: function () {
  5990. 'use strict';
  5991. var l = $('#download_url > a');
  5992. $.openLink(l.href);
  5993. },
  5994. });
  5995. $.register({
  5996. rule: {
  5997. host: /^(www\.)?mirrorcreator\.com$/,
  5998. path: /^\/showlink\.php$/,
  5999. },
  6000. ready: function () {
  6001. 'use strict';
  6002. var a = $.$('#redirectlink a');
  6003. if (a) {
  6004. $.openLink(a.href);
  6005. return;
  6006. }
  6007. a = $('#redirectlink > div.redirecturl');
  6008. a = a.innerHTML;
  6009. if (!a.match(/^http/)) {
  6010. throw new _.AdsBypasserError('not a valid URL');
  6011. }
  6012. $.openLink(a);
  6013. },
  6014. });
  6015. $.register({
  6016. rule: {
  6017. host: /^www.mirrorupload.net$/,
  6018. },
  6019. ready: function () {
  6020. 'use strict';
  6021. var accessForm = $('form[name=form_upload]');
  6022. var accessInput = document.createElement('input');
  6023. accessInput.type = 'hidden';
  6024. accessInput.name = 'access';
  6025. accessInput.value = Math.random();
  6026. accessForm.appendChild(accessInput);
  6027. accessForm.submit();
  6028. },
  6029. });
  6030. $.register({
  6031. rule: {
  6032. host: /^www\.multiupfile\.com$/,
  6033. path: /^\/f\//,
  6034. },
  6035. ready: function () {
  6036. 'use strict';
  6037. var f = $('#yw0');
  6038. f.submit();
  6039. },
  6040. });
  6041. $.register({
  6042. rule: {
  6043. host: /^mylinkgen\.com$/,
  6044. path: /^\/p\/(.+)$/,
  6045. },
  6046. start: function (m) {
  6047. 'use strict';
  6048. $.openLink('/g/' + m.path[1]);
  6049. },
  6050. });
  6051. $.register({
  6052. rule: {
  6053. host: /^mylinkgen\.com$/,
  6054. path: /^\/g\//,
  6055. },
  6056. ready: function () {
  6057. 'use strict';
  6058. var a = $('#main-content a.btn.btn-default');
  6059. $.openLink(a.href);
  6060. },
  6061. });
  6062. $.register({
  6063. rule: {
  6064. host: /^openload\.co$/,
  6065. path: /^\/f\/.*/,
  6066. },
  6067. start: function (m) {
  6068. $.window.adblock = false;
  6069. $.window.adblock2 = false;
  6070. },
  6071. ready: function () {
  6072. var a = $('#realdl>a');
  6073. if (a.href) {
  6074. $.openLink(a.href);
  6075. }
  6076. }
  6077. });
  6078. $.register({
  6079. rule: {
  6080. host: /^(www\.)?upmirror\.info$/,
  6081. },
  6082. ready: function () {
  6083. 'use strict';
  6084. $.setCookie('user', 'ppp');
  6085. if ($.$('#countDownText')) {
  6086. $.openLink(document.location.toString());
  6087. }
  6088. },
  6089. });
  6090. $.register({
  6091. rule: {
  6092. host: /^(www\.)?vidto\.me$/,
  6093. },
  6094. ready: function () {
  6095. 'use strict';
  6096. var f = $('#btn_download').form;
  6097. setTimeout(function() {
  6098. f.submit();
  6099. }, 6000);
  6100. },
  6101. });
  6102. (function () {
  6103. 'use strict';
  6104. var sUrl = '(\\b(https?|ftp|file):\/\/[-A-Z0-9+&@#\/%?=~_|!:,.;]*[-A-Z0-9+&@#\/%=~_|])';
  6105. function isLink (text) {
  6106. var rUrl = new RegExp(_.T('^{0}$')(sUrl), 'i');
  6107. return rUrl.test(text);
  6108. }
  6109. function linkify (text) {
  6110. var rUrl = new RegExp(sUrl, 'ig');
  6111. return text.replace(rUrl, function(match) {
  6112. return _.T("<a href='{0}'>{0}</a>")(match);
  6113. });
  6114. }
  6115. $.register({
  6116. rule: {
  6117. host: /^(www\.)?([a-zA-Z0-9]+\.)?binbox\.io$/,
  6118. path: /\/([a-zA-Z0-9]+)/,
  6119. hash: /(?:#([a-zA-Z0-9]+))?/,
  6120. },
  6121. ready: function (m) {
  6122. var sjcl = $.window.sjcl;
  6123. var paste_id = m.path[1];
  6124. var paste_salt = m.hash[1];
  6125. var API_URL = _.T('https://binbox.io/{0}.json')(paste_id);
  6126. $.get(API_URL, false, {
  6127. Origin: _.none,
  6128. Referer: _.none,
  6129. Cookie: 'referrer=1',
  6130. 'X-Requested-With': _.none,
  6131. }).then(function (pasteInfo) {
  6132. pasteInfo = _.parseJSON(pasteInfo);
  6133. if (!pasteInfo.ok) {
  6134. throw new _.AdsBypasserError("error when getting paste information");
  6135. }
  6136. if (pasteInfo.paste.url) {
  6137. $.openLink(pasteInfo.paste.url);
  6138. return;
  6139. }
  6140. var raw_paste = sjcl.decrypt(paste_salt, pasteInfo.paste.text);
  6141. if (isLink(raw_paste)) {
  6142. $.openLink(raw_paste);
  6143. return;
  6144. }
  6145. var elm = document.createElement('pre');
  6146. elm.id = 'paste-text';
  6147. elm.innerHTML = linkify(raw_paste);
  6148. var frame = $('#paste-frame, #captcha-page');
  6149. frame.parentNode.replaceChild(elm, frame);
  6150. });
  6151. },
  6152. });
  6153. })();
  6154. $.register({
  6155. rule: {
  6156. host: /^(www\.)?pasted\.co$/,
  6157. path: /^\/\w+$/,
  6158. },
  6159. ready: function () {
  6160. 'use strict';
  6161. $.removeNodes('#captcha_overlay');
  6162. },
  6163. });
  6164. (function (context, factory) {
  6165. if (typeof module === 'object' && typeof module.exports === 'object') {
  6166. module.exports = function (context, GM) {
  6167. var _ = require('lodash');
  6168. var core = require('./core.js');
  6169. var misc = require('./misc.js');
  6170. var dispatcher = require('./dispatcher.js');
  6171. var modules = [misc, dispatcher].map(function (v) {
  6172. return v.call(null, context, GM);
  6173. });
  6174. var $ = _.assign.apply(_, modules);
  6175. return factory(context, GM, core, $);
  6176. };
  6177. } else {
  6178. factory(context, {
  6179. openInTab: GM_openInTab,
  6180. registerMenuCommand: GM_registerMenuCommand,
  6181. }, context._, context.$);
  6182. }
  6183. }(this, function (context, GM, _, $) {
  6184. 'use strict';
  6185. var window = context.window;
  6186. var document = window.document;
  6187. var isSafari = Object.prototype.toString.call(window.HTMLElement).indexOf('Constructor') > 0;
  6188. function disableWindowOpen () {
  6189. $.window.open = _.nop;
  6190. $.window.alert = _.nop;
  6191. $.window.confirm = _.nop;
  6192. }
  6193. function disableLeavePrompt (element) {
  6194. if (!element) {
  6195. return;
  6196. }
  6197. var seal = {
  6198. set: function () {
  6199. _.info('blocked onbeforeunload');
  6200. },
  6201. };
  6202. element.onbeforeunload = undefined;
  6203. if (isSafari) {
  6204. element.__defineSetter__('onbeforeunload', seal.set);
  6205. } else {
  6206. $.window.Object.defineProperty(element, 'onbeforeunload', {
  6207. configurable: true,
  6208. enumerable: false,
  6209. get: undefined,
  6210. set: seal.set,
  6211. });
  6212. }
  6213. var oael = element.addEventListener;
  6214. var nael = function (type) {
  6215. if (type === 'beforeunload') {
  6216. _.info('blocked addEventListener onbeforeunload');
  6217. return;
  6218. }
  6219. return oael.apply(this, arguments);
  6220. };
  6221. element.addEventListener = nael;
  6222. }
  6223. function changeTitle () {
  6224. document.title += ' - AdsBypasser';
  6225. }
  6226. function beforeDOMReady (handler) {
  6227. _.info('working on\n%s \nwith\n%s', window.location.toString(), JSON.stringify($.config));
  6228. disableLeavePrompt($.window);
  6229. disableWindowOpen();
  6230. handler.start();
  6231. }
  6232. function afterDOMReady (handler) {
  6233. disableLeavePrompt($.window.document.body);
  6234. changeTitle();
  6235. handler.ready();
  6236. }
  6237. function waitDOM () {
  6238. return _.D(function (resolve, reject) {
  6239. if (document.readyState !== 'loading') {
  6240. resolve();
  6241. return;
  6242. }
  6243. document.addEventListener('DOMContentLoaded', function () {
  6244. resolve();
  6245. });
  6246. });
  6247. }
  6248. $._main = function () {
  6249. var findHandler = $._findHandler;
  6250. delete $._main;
  6251. delete $._findHandler;
  6252. if (window.top !== window.self) {
  6253. return;
  6254. }
  6255. GM.registerMenuCommand('AdsBypasser - Configure', function () {
  6256. GM.openInTab('https://adsbypasser.github.io/configure.html');
  6257. });
  6258. var handler = findHandler(true);
  6259. if (handler) {
  6260. if ($.config.logLevel <= 0) {
  6261. _._quiet = true;
  6262. }
  6263. beforeDOMReady(handler);
  6264. waitDOM().then(function () {
  6265. afterDOMReady(handler);
  6266. });
  6267. return;
  6268. }
  6269. if ($.config.logLevel < 2) {
  6270. _._quiet = true;
  6271. }
  6272. _.info('does not match location on `%s`, will try HTML content', window.location.toString());
  6273. waitDOM().then(function () {
  6274. handler = findHandler(false);
  6275. if (!handler) {
  6276. _.info('does not match HTML content on `%s`', window.location.toString());
  6277. return;
  6278. }
  6279. beforeDOMReady(handler);
  6280. afterDOMReady(handler);
  6281. });
  6282. };
  6283. return $;
  6284. }));
  6285. $._main();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址