diff options
| author | Nippy <nippy@Nippy-Mac-mini.local> | 2026-09-19 15:40:27 +0200 |
|---|---|---|
| committer | Nippy <nippy@Nippy-Mac-mini.local> | 2026-09-19 15:40:27 +0200 |
| commit | 88d4beb68b304ea04bdafdb999c39be10d3f954a (patch) | |
| tree | 4e0b03504ddf8782119d2ddaad128a0bf0e2c8c5 /raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources | |
| parent | 42d8e639fffbd3907d8590f1d54e4e78a0b852bb (diff) | |
| download | RaveOS-PKGBUILD-88d4beb68b304ea04bdafdb999c39be10d3f954a.tar.gz RaveOS-PKGBUILD-88d4beb68b304ea04bdafdb999c39be10d3f954a.zip | |
fix profiles
Diffstat (limited to 'raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources')
46 files changed, 9423 insertions, 0 deletions
diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects.yml b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects.yml new file mode 100644 index 0000000..2ad0a33 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects.yml @@ -0,0 +1,4656 @@ +# +# AdGuard Scriptlets (Redirects Source) +# Version 2.5.1 +# +- title: 1x1-transparent.gif + added: v1.0.4 + description: |- + ### Examples + + ```adblock + ||example.org^$image,redirect=1x1-transparent.gif + ``` + aliases: + - 1x1.gif + - 1x1-transparent-gif + comment: 'http://probablyprogramming.com/2009/03/15/the-tiniest-gif-ever' + file: 1x1-transparent.gif + contentType: image/gif;base64 + content: R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw== + +- title: 2x2-transparent.png + added: v1.0.4 + description: |- + ### Examples + + ```adblock + ||example.org^$image,redirect=2x2-transparent.png + ``` + aliases: + - 2x2.png + - 2x2-transparent-png + file: 2x2-transparent.png + contentType: image/png;base64 + content: > + iVBORw0KGgoAAAANSUhEUgAAAAIAAAACCAYAAABytg0kAAAAC0lEQVQI12NgQAcAABIAAe+JVKQAAAAA + SUVORK5CYII= + +- title: 3x2-transparent.png + added: v1.0.4 + description: |- + ### Examples + + ```adblock + ||example.org^$image,redirect=3x2-transparent.png + ``` + aliases: + - 3x2.png + - 3x2-transparent-png + file: 3x2-transparent.png + contentType: image/png;base64 + content: > + iVBORw0KGgoAAAANSUhEUgAAAAMAAAACCAYAAACddGYaAAAAC0lEQVQI12NgwAUAABoAASRETuUAAAAA + SUVORK5CYII= + +- title: 32x32-transparent.png + added: v1.0.4 + description: |- + ### Examples + + ```adblock + ||example.org^$image,redirect=32x32-transparent.png + ``` + aliases: + - 32x32.png + - 32x32-transparent-png + file: 32x32-transparent.png + contentType: image/png;base64 + content: > + iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAGklEQVRYw+3BAQEAAACCIP+vbkhAAQAA + AO8GECAAAZf3V9cAAAAASUVORK5CYII= + +- title: noopframe + added: v1.0.4 + description: |- + ### Examples + + ```adblock + ||example.com^$subdocument,redirect=noopframe,domain=example.org + ``` + aliases: + - noop.html + - blank-html + file: noopframe.html + contentType: text/html + content: |- + <!DOCTYPE html> + <html> + <head><title></title></head> + <body></body> + </html> + +- title: noopcss + added: v1.0.4 + description: |- + ### Examples + + ```adblock + ||example.org/style.css$stylesheet,redirect=noopcss + ``` + aliases: + - noop.css + - blank-css + file: noopcss.css + contentType: text/css + content: '' + +- title: noopjs + added: v1.0.4 + description: |- + ### Examples + + ```adblock + ||example.org/advert.js$script,redirect=noopjs + ``` + aliases: + - noop.js + - blank-js + file: noopjs.js + contentType: application/javascript + content: '(function() {})()' + +- title: noopjson + added: v1.6.2 + description: |- + ### Examples + + ```adblock + ||example.org/geo/location$xmlhttprequest,redirect=noopjson + ``` + aliases: + - noop.json + file: noopjson.json + contentType: application/json + content: '{}' + +- title: nooptext + added: v1.0.4 + description: |- + ### Examples + + ```adblock + ||example.org/advert.js$xmlhttprequest,redirect=nooptext + ``` + aliases: + - noop.txt + - blank-text + file: nooptext.js + contentType: text/plain + content: '' + +- title: empty + added: v1.3.9 + description: |- + Pretty much the same as `nooptext`. Used for conversion of modifier `empty` + so better avoid its using in prod versions of filter lists. + + ### Examples + + ```adblock + ||example.org/log$redirect=empty + ``` + aliases: + - empty + file: nooptext.js + contentType: text/plain + content: '' + +- title: noopvmap-1.0 + added: v1.1.5 + description: |- + Redirects request to an empty VMAP response. + + ### Examples + + ```adblock + ||example.org/vmap01.xml$xmlhttprequest,redirect=noopvmap-1.0 + ``` + aliases: + - noop-vmap1.xml + - noop-vmap1.0.xml + file: noopvmap01.xml + contentType: text/xml + content: >- + <vmap:VMAP xmlns:vmap="http://www.iab.net/videosuite/vmap" + version="1.0"></vmap:VMAP> + +- title: noopvast-2.0 + added: v1.0.10 + description: |- + Redirects request to an empty VAST 2.0 response. + + ### Examples + + ```adblock + ||example.org/vast02.xml^$xmlhttprequest,redirect=noopvast-2.0 + ``` + aliases: + - noop-vast2.xml + file: noopvast02.xml + contentType: text/xml + content: <VAST version="2.0"></VAST> + +- title: noopvast-3.0 + added: v1.0.10 + description: |- + Redirects request to an empty VAST 3.0 response. + + ### Examples + + ```adblock + ||example.org/vast03.xml^$xmlhttprequest,redirect=noopvast-3.0 + ``` + aliases: + - noop-vast3.xml + file: noopvast03.xml + contentType: text/xml + content: <VAST version="3.0"></VAST> + +- title: noopvast-4.0 + added: v1.4.3 + description: |- + Redirects request to an empty VAST 4.0 response. + + ### Examples + + ```adblock + ||example.org/vast04.xml^$xmlhttprequest,redirect=noopvast-4.0 + ``` + aliases: + - noop-vast4.xml + file: noopvast04.xml + contentType: text/xml + content: <VAST version="4.0"></VAST> + +- title: noopmp3-0.1s + added: v1.0.4 + description: |- + ### Examples + + ```adblock + ||example.org/advert.mp3$media,redirect=noopmp3-0.1s + ``` + aliases: + - noopmp3-0.1s + - blank-mp3 + comment: > + From: + https://ubuntuforums.org/showthread.php?t=1911430&p=11624471#post11624471 + ffmpeg -ar 48000 -t 0.1 -f s16le -acodec pcm_s16le -ac 2 -i /dev/zero + -acodec libmp3lame -aq 4 output.mp3 But with 0.1 (second) instead of 60. + file: noopmp3.mp3 + contentType: audio/mp3;base64 + content: > + SUQzBAAAAAAAI1RTU0UAAAAPAAADTGF2ZjU2LjQwLjEwMQAAAAAAAAAAAAAA//tUAAAAAAAAAAAAAAAA + AAAAAAAAAAAAAAAAAAAAAAAAAAAASW5mbwAAAA8AAAAGAAADAABgYGBgYGBgYGBgYGBgYGBggICAgICA + gICAgICAgICAgICgoKCgoKCgoKCgoKCgoKCgwMDAwMDAwMDAwMDAwMDAwMDg4ODg4ODg4ODg4ODg4ODg + 4P////////////////////8AAAAATGF2YzU2LjYwAAAAAAAAAAAAAAAAJAAAAAAAAAAAAwDNZKlY//sU + ZAAP8AAAaQAAAAgAAA0gAAABAAABpAAAACAAADSAAAAETEFNRTMuOTkuNVVVVVVVVVVVVVVVVVVVVVVV + VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV//sUZB4P8AAAaQAAAAgAAA0gAAABAAABpAAA + ACAAADSAAAAEVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV + VVVVVVVVVVVV//sUZDwP8AAAaQAAAAgAAA0gAAABAAABpAAAACAAADSAAAAEVVVVVVVVVVVVVVVVVVVV + VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV//sUZFoP8AAAaQAAAAgA + AA0gAAABAAABpAAAACAAADSAAAAEVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV + VVVVVVVVVVVVVVVVVVVVVVVVVVVV//sUZHgP8AAAaQAAAAgAAA0gAAABAAABpAAAACAAADSAAAAEVVVV + VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV//sU + ZJYP8AAAaQAAAAgAAA0gAAABAAABpAAAACAAADSAAAAEVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV + VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV + +- title: noopmp4-1s + added: v1.0.4 + description: |- + ### Examples + + ```adblock + ||example.org/advert.mp4$media,redirect=noopmp4-1s + ``` + aliases: + - noop-1s.mp4 + - blank-mp4 + comment: | + From https://github.com/kud/blank-video + file: noopmp4.mp4 + contentType: video/mp4;base64 + content: > + AAAAHGZ0eXBNNFYgAAACAGlzb21pc28yYXZjMQAAAAhmcmVlAAAGF21kYXTeBAAAbGliZmFhYyAxLjI4 + AABCAJMgBDIARwAAArEGBf//rdxF6b3m2Ui3lizYINkj7u94MjY0IC0gY29yZSAxNDIgcjIgOTU2Yzhk + OCAtIEguMjY0L01QRUctNCBBVkMgY29kZWMgLSBDb3B5bGVmdCAyMDAzLTIwMTQgLSBodHRwOi8vd3d3 + LnZpZGVvbGFuLm9yZy94MjY0Lmh0bWwgLSBvcHRpb25zOiBjYWJhYz0wIHJlZj0zIGRlYmxvY2s9MTow + OjAgYW5hbHlzZT0weDE6MHgxMTEgbWU9aGV4IHN1Ym1lPTcgcHN5PTEgcHN5X3JkPTEuMDA6MC4wMCBt + aXhlZF9yZWY9MSBtZV9yYW5nZT0xNiBjaHJvbWFfbWU9MSB0cmVsbGlzPTEgOHg4ZGN0PTAgY3FtPTAg + ZGVhZHpvbmU9MjEsMTEgZmFzdF9wc2tpcD0xIGNocm9tYV9xcF9vZmZzZXQ9LTIgdGhyZWFkcz02IGxv + b2thaGVhZF90aHJlYWRzPTEgc2xpY2VkX3RocmVhZHM9MCBucj0wIGRlY2ltYXRlPTEgaW50ZXJsYWNl + ZD0wIGJsdXJheV9jb21wYXQ9MCBjb25zdHJhaW5lZF9pbnRyYT0wIGJmcmFtZXM9MCB3ZWlnaHRwPTAg + a2V5aW50PTI1MCBrZXlpbnRfbWluPTI1IHNjZW5lY3V0PTQwIGludHJhX3JlZnJlc2g9MCByY19sb29r + YWhlYWQ9NDAgcmM9Y3JmIG1idHJlZT0xIGNyZj0yMy4wIHFjb21wPTAuNjAgcXBtaW49MCBxcG1heD02 + OSBxcHN0ZXA9NCB2YnZfbWF4cmF0ZT03NjggdmJ2X2J1ZnNpemU9MzAwMCBjcmZfbWF4PTAuMCBuYWxf + aHJkPW5vbmUgZmlsbGVyPTAgaXBfcmF0aW89MS40MCBhcT0xOjEuMDAAgAAAAFZliIQL8mKAAKvMnJyc + nJycnJycnXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX + XXXXXXXXXXXXXXXXXiEASZACGQAjgCEASZACGQAjgAAAAAdBmjgX4GSAIQBJkAIZACOAAAAAB0GaVAX4 + GSAhAEmQAhkAI4AhAEmQAhkAI4AAAAAGQZpgL8DJIQBJkAIZACOAIQBJkAIZACOAAAAABkGagC/AySEA + SZACGQAjgAAAAAZBmqAvwMkhAEmQAhkAI4AhAEmQAhkAI4AAAAAGQZrAL8DJIQBJkAIZACOAAAAABkGa + 4C/AySEASZACGQAjgCEASZACGQAjgAAAAAZBmwAvwMkhAEmQAhkAI4AAAAAGQZsgL8DJIQBJkAIZACOA + IQBJkAIZACOAAAAABkGbQC/AySEASZACGQAjgCEASZACGQAjgAAAAAZBm2AvwMkhAEmQAhkAI4AAAAAG + QZuAL8DJIQBJkAIZACOAIQBJkAIZACOAAAAABkGboC/AySEASZACGQAjgAAAAAZBm8AvwMkhAEmQAhkA + I4AhAEmQAhkAI4AAAAAGQZvgL8DJIQBJkAIZACOAAAAABkGaAC/AySEASZACGQAjgCEASZACGQAjgAAA + AAZBmiAvwMkhAEmQAhkAI4AhAEmQAhkAI4AAAAAGQZpAL8DJIQBJkAIZACOAAAAABkGaYC/AySEASZAC + GQAjgCEASZACGQAjgAAAAAZBmoAvwMkhAEmQAhkAI4AAAAAGQZqgL8DJIQBJkAIZACOAIQBJkAIZACOA + AAAABkGawC/AySEASZACGQAjgAAAAAZBmuAvwMkhAEmQAhkAI4AhAEmQAhkAI4AAAAAGQZsAL8DJIQBJ + kAIZACOAAAAABkGbIC/AySEASZACGQAjgCEASZACGQAjgAAAAAZBm0AvwMkhAEmQAhkAI4AhAEmQAhkA + I4AAAAAGQZtgL8DJIQBJkAIZACOAAAAABkGbgCvAySEASZACGQAjgCEASZACGQAjgAAAAAZBm6AnwMkh + AEmQAhkAI4AhAEmQAhkAI4AhAEmQAhkAI4AhAEmQAhkAI4AAAAhubW9vdgAAAGxtdmhkAAAAAAAAAAAA + AAAAAAAD6AAABDcAAQAAAQAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAABA + AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAwAAAzB0cmFrAAAAXHRraGQAAAADAAAAAAAAAAAA + AAABAAAAAAAAA+kAAAAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAABA + AAAAALAAAACQAAAAAAAkZWR0cwAAABxlbHN0AAAAAAAAAAEAAAPpAAAAAAABAAAAAAKobWRpYQAAACBt + ZGhkAAAAAAAAAAAAAAAAAAB1MAAAdU5VxAAAAAAALWhkbHIAAAAAAAAAAHZpZGUAAAAAAAAAAAAAAABW + aWRlb0hhbmRsZXIAAAACU21pbmYAAAAUdm1oZAAAAAEAAAAAAAAAAAAAACRkaW5mAAAAHGRyZWYAAAAA + AAAAAQAAAAx1cmwgAAAAAQAAAhNzdGJsAAAAr3N0c2QAAAAAAAAAAQAAAJ9hdmMxAAAAAAAAAAEAAAAA + AAAAAAAAAAAAAAAAALAAkABIAAAASAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA + AAAAGP//AAAALWF2Y0MBQsAN/+EAFWdCwA3ZAsTsBEAAAPpAADqYA8UKkgEABWjLg8sgAAAAHHV1aWRr + aEDyXyRPxbo5pRvPAyPzAAAAAAAAABhzdHRzAAAAAAAAAAEAAAAeAAAD6QAAABRzdHNzAAAAAAAAAAEA + AAABAAAAHHN0c2MAAAAAAAAAAQAAAAEAAAABAAAAAQAAAIxzdHN6AAAAAAAAAAAAAAAeAAADDwAAAAsA + AAALAAAACgAAAAoAAAAKAAAACgAAAAoAAAAKAAAACgAAAAoAAAAKAAAACgAAAAoAAAAKAAAACgAAAAoA + AAAKAAAACgAAAAoAAAAKAAAACgAAAAoAAAAKAAAACgAAAAoAAAAKAAAACgAAAAoAAAAKAAAAiHN0Y28A + AAAAAAAAHgAAAEYAAANnAAADewAAA5gAAAO0AAADxwAAA+MAAAP2AAAEEgAABCUAAARBAAAEXQAABHAA + AASMAAAEnwAABLsAAATOAAAE6gAABQYAAAUZAAAFNQAABUgAAAVkAAAFdwAABZMAAAWmAAAFwgAABd4A + AAXxAAAGDQAABGh0cmFrAAAAXHRraGQAAAADAAAAAAAAAAAAAAACAAAAAAAABDcAAAAAAAAAAAAAAAEB + AAAAAAEAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAABAAAAAAAAAAAAAAAAAAAAkZWR0cwAAABxl + bHN0AAAAAAAAAAEAAAQkAAADcAABAAAAAAPgbWRpYQAAACBtZGhkAAAAAAAAAAAAAAAAAAC7gAAAykBV + xAAAAAAALWhkbHIAAAAAAAAAAHNvdW4AAAAAAAAAAAAAAABTb3VuZEhhbmRsZXIAAAADi21pbmYAAAAQ + c21oZAAAAAAAAAAAAAAAJGRpbmYAAAAcZHJlZgAAAAAAAAABAAAADHVybCAAAAABAAADT3N0YmwAAABn + c3RzZAAAAAAAAAABAAAAV21wNGEAAAAAAAAAAQAAAAAAAAAAAAIAEAAAAAC7gAAAAAAAM2VzZHMAAAAA + A4CAgCIAAgAEgICAFEAVBbjYAAu4AAAADcoFgICAAhGQBoCAgAECAAAAIHN0dHMAAAAAAAAAAgAAADIA + AAQAAAAAAQAAAkAAAAFUc3RzYwAAAAAAAAAbAAAAAQAAAAEAAAABAAAAAgAAAAIAAAABAAAAAwAAAAEA + AAABAAAABAAAAAIAAAABAAAABgAAAAEAAAABAAAABwAAAAIAAAABAAAACAAAAAEAAAABAAAACQAAAAIA + AAABAAAACgAAAAEAAAABAAAACwAAAAIAAAABAAAADQAAAAEAAAABAAAADgAAAAIAAAABAAAADwAAAAEA + AAABAAAAEAAAAAIAAAABAAAAEQAAAAEAAAABAAAAEgAAAAIAAAABAAAAFAAAAAEAAAABAAAAFQAAAAIA + AAABAAAAFgAAAAEAAAABAAAAFwAAAAIAAAABAAAAGAAAAAEAAAABAAAAGQAAAAIAAAABAAAAGgAAAAEA + AAABAAAAGwAAAAIAAAABAAAAHQAAAAEAAAABAAAAHgAAAAIAAAABAAAAHwAAAAQAAAABAAAA4HN0c3oA + AAAAAAAAAAAAADMAAAAaAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkA + AAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkA + AAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkA + AAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAAAJAAAACQAAAAkAAACMc3RjbwAAAAAAAAAfAAAALAAAA1UA + AANyAAADhgAAA6IAAAO+AAAD0QAAA+0AAAQAAAAEHAAABC8AAARLAAAEZwAABHoAAASWAAAEqQAABMUA + AATYAAAE9AAABRAAAAUjAAAFPwAABVIAAAVuAAAFgQAABZ0AAAWwAAAFzAAABegAAAX7AAAGFwAAAGJ1 + ZHRhAAAAWm1ldGEAAAAAAAAAIWhkbHIAAAAAAAAAAG1kaXJhcHBsAAAAAAAAAAAAAAAALWlsc3QAAAAl + qXRvbwAAAB1kYXRhAAAAAQAAAABMYXZmNTUuMzMuMTAw + +- title: click2load.html + added: v1.5.0 + description: >- + Redirects resource and replaces supposed content by decoy frame with button + for original content recovering + + + Related UBO redirect resource: + + https://github.com/gorhill/uBlock/blob/1.31.0/src/web_accessible_resources/click2load.html + + + ### Example + + + ```adblock + + ||youtube.com/embed/$frame,third-party,redirect=click2load.html + + ``` + aliases: + - click2load.html + - ubo-click2load.html + file: click2load.html + contentType: text/html + scriptPath: ./click2load.js + isBlocking: true + content: | + <!DOCTYPE html> + <html> + + <head> + <meta charset="utf-8"> + <title>AdGuard Click2Load</title> + <style> + html, + body, + .wrapper { + height: 100%; + } + + body { + margin: 0; + font-family: Roboto, "Open Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Ubuntu, Arial, sans-serif + } + + .wrapper { + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + } + + .content { + min-height: 160px; + padding: 50px 24px; + text-align: center; + } + + .logo { + background-image: url("data:image/svg+xml,%3Csvg fill='none' height='41' viewBox='0 0 41 41' width='41' xmlns='http://www.w3.org/2000/svg'%3E%3Cg clip-rule='evenodd' fill-rule='evenodd'%3E%3Cpath d='m20.4996.5c-6.2513 0-13.79186 1.43422-19.999594 4.59105 0 6.81785-.085687 23.80335 19.999594 35.40895 20.0856-11.6056 20.0004-28.5911 20.0004-35.40895-6.2082-3.15683-13.7488-4.59105-20.0004-4.59105z' fill='%2368bc71'/%3E%3Cpath d='m20.5.5c-.0001 0-.0003 0-.0004 0-6.2513 0-13.79186 1.43422-19.999594 4.59105 0 .02866-.000003.05751-.000003.08653-.000361 6.87412-.001248 23.76562 19.999597 35.32242.0001-.0001.0003-.0002.0004-.0003z' fill='%2367b279'/%3E%3Cpath d='m20.3236 26.2143 11.605-15.3766c-.8504-.6701-1.5963-.1972-2.0069.169l-.015.0012-9.6763 9.8957-3.6457-4.3132c-1.7393-1.9755-4.1038-.4686-4.6561-.0704z' fill='%23fff'/%3E%3C/g%3E%3C/svg%3E"); + background-size: contain; + width: 40px; + height: 40px; + margin: 0 auto 16px; + } + + .title { + font-weight: 700; + font-size: 20px; + line-height: 25px; + margin-bottom: 8px; + } + + .subtitle { + font-weight: 400; + font-size: 14px; + line-height: 16px; + max-height: 50px; + overflow: hidden; + word-break: break-all; + } + + .footer { + padding-top: 24px; + } + + .button { + display: inline-block; + min-width: 90px; + padding: 6px 15px; + border-radius: 3px; + border: none; + background: #4d4d4d; + color: #fff; + text-align: center; + font-weight: 400; + font-size: 16px; + line-height: 21px; + text-decoration: none; + } + </style> + </head> + + <body> + <div class="wrapper"> + <div class="content"> + <div class="logo"></div> + <div id="clickToLoadTitle" class="title"></div> + <div id="clickToLoadSubtitle" class="subtitle"></div> + <div class="footer"> + <a id="clickToLoadLink" class="button" href="" rel="noreferrer noopener"></a> + </div> + </div> + </div> + <!-- script injection --> + <script>(function () { + 'use strict'; + + function clickToLoad() { + var QUESTION_MARK = '?'; + var AMPERSAND = '&'; + var SEARCH_PARAMS_DIVIDER = '='; + var ORIGIN_URL_PARAM = '__origin'; + var EXT_UNBLOCK_PARAM = '__unblock'; + var CL_UNBLOCK_PARAM = '__adg_unblock_token'; + var CL_SPECIFIC_UNBLOCK_PARAM = '__adg_unblock'; + var BLOCKING_RULE_PARAM = '__adg_blocking_rule'; + var CLICK_EVENT = 'click'; + var CL_FORCE_EVENT = 'force'; + var neededParams = [ORIGIN_URL_PARAM, EXT_UNBLOCK_PARAM, CL_UNBLOCK_PARAM, BLOCKING_RULE_PARAM]; + var parseSearchParam = function parseSearchParam(rawQueryStr) { + var res = {}; + var pattern = /([^&=]+)=([^&]*)/g; + var matchedData; + var queryStr = rawQueryStr.substring(1); + while (matchedData = pattern.exec(queryStr)) { + if (neededParams.includes(matchedData[1])) { + res[matchedData[1]] = matchedData[2]; + } + queryStr = queryStr.substring(matchedData[0]); + } + return res; + }; + var paramsData = parseSearchParam(window.location.search); + var getParamByKey = function getParamByKey(key) { + return paramsData[key] || ''; + }; + var extUnblockToken = getParamByKey(EXT_UNBLOCK_PARAM); + var clUnblockToken = getParamByKey(CL_UNBLOCK_PARAM); + var blockingRule = getParamByKey(BLOCKING_RULE_PARAM); + var originUrl = clUnblockToken + ? window.location.href : decodeURIComponent(getParamByKey(ORIGIN_URL_PARAM)); + var clickTitleElem = document.getElementById('clickToLoadTitle'); + var clickSubtitleElem = document.getElementById('clickToLoadSubtitle'); + var clickButtonElem = document.getElementById('clickToLoadLink'); + var originUrlToDisplay = clUnblockToken ? originUrl.replace(/[&?]__adg_unblock_token=.*/, '') : originUrl; + clickSubtitleElem.textContent = originUrlToDisplay; + clickButtonElem.href = originUrlToDisplay; + clickButtonElem.title = originUrlToDisplay; + var translationsData = { + en: { + title: 'Content blocked by AdGuard', + button: 'Click to load' + }, + ru: { + title: 'AdGuard заблокировал загрузку контента', + button: 'Всё равно загрузить' + }, + es: { + title: 'Contenido bloqueado por AdGuard', + button: 'Pulsa para cargar' + }, + fr: { + title: 'Contenu bloqué par AdGuard', + button: 'Cliquez pour télécharger' + }, + it: { + title: 'Contenuti bloccati da AdGuard', + button: 'Clicca per scaricare' + }, + de: { + title: 'Inhalt blockiert durch AdGuard', + button: 'Trotzdem laden' + }, + 'zh-cn': { + title: 'AdGuard 已将该内容屏蔽', + button: '点击加载' + }, + 'zh-tw': { + title: 'AdGuard 已將該內容封鎖', + button: '點按載入' + }, + ko: { + title: 'AdGuard에 의해 차단된 콘텐츠', + button: '로드하려면 클릭하세요' + }, + ja: { + title: 'AdGuardがコンテンツをブロックしました。', + button: '読み込むにはこちらをクリック' + }, + uk: { + title: 'AdGuard заблокував завантаження вмісту', + button: 'Однаково завантажити' + } + }; + var getTranslations = function getTranslations() { + var baseLocaleData = translationsData.en; + try { + var currentLocale = navigator.language.toLowerCase(); + var localeData = translationsData[currentLocale]; + if (!localeData) { + var lang = currentLocale.split('-')[0]; + localeData = translationsData[lang]; + } + if (!localeData) { + localeData = baseLocaleData; + } + return localeData; + } catch (e) { + return baseLocaleData; + } + }; + var translations = getTranslations(); + clickTitleElem.textContent = translations.title; + clickButtonElem.textContent = translations.button; + var getReplaceUrl = function getReplaceUrl(originUrl, unblockTokenName, unblockTokenValue) { + var questionMarkIndex = originUrl.indexOf(QUESTION_MARK); + var divider = questionMarkIndex > -1 ? AMPERSAND : QUESTION_MARK; + if (originUrl.substring(questionMarkIndex).length === 1) { + divider = ''; + } + return `${originUrl}${divider}${unblockTokenName}${SEARCH_PARAMS_DIVIDER}${unblockTokenValue}`; + }; + var extRun = function extRun() { + var replaceUrl = getReplaceUrl(originUrl, EXT_UNBLOCK_PARAM, extUnblockToken); + window.location.replace(replaceUrl); + }; + var clRun = function clRun() { + var CL_SPECIFIC_UNBLOCK_VALUE = 1; + var replaceUrl = getReplaceUrl(originUrl, CL_SPECIFIC_UNBLOCK_PARAM, CL_SPECIFIC_UNBLOCK_VALUE); + window.location.replace(replaceUrl); + }; + clickButtonElem.addEventListener(CLICK_EVENT, function (e) { + if (e.isTrusted === false) { + return; + } + if (extUnblockToken) { + extRun(); + } else if (clUnblockToken) { + clRun(); + } + e.preventDefault(); + e.stopPropagation(); + }); + clickButtonElem.addEventListener(CL_FORCE_EVENT, function () { + clRun(); + }); + var hasFrameModifier = function hasFrameModifier(rule) { + var substringAfter = function substringAfter(str, separator) { + var index = str.indexOf(separator); + return index < 0 ? '' : str.substring(index + separator.length); + }; + var FRAME_MARKER = 'frame'; + var SUBDOCUMENT_MARKER = 'subdocument'; + var ruleModifiers = substringAfter(rule, '$').split(','); + return ruleModifiers.includes(FRAME_MARKER) || ruleModifiers.includes(SUBDOCUMENT_MARKER); + }; + var isInsideFrame = function isInsideFrame() { + return window.self !== window.top; + }; + if (clUnblockToken && blockingRule && hasFrameModifier(blockingRule) && !isInsideFrame()) { + clickButtonElem.dispatchEvent(CL_FORCE_EVENT); + } + } + clickToLoad(); + + })(); + </script> + </body> + </html> + # To enable the redirect functionality to work within the extension + # the sha256 value of the file is calculated and included in the yaml file + # as the redirect is being used as a single file. + # This will allow the extension to retrieve the value and add it to its CSP. + sha: sha256-GH4MISem+XXlowF3M/QKqtfEOkhzt1IQoYAZCyE46YU= + +- title: amazon-apstag + comment: Mocks Amazon's apstag.js + aliases: + - ubo-amazon_apstag.js + - amazon_apstag.js + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function AmazonApstag(source) { + var apstagWrapper = { + fetchBids(a, b) { + if (typeof b === "function") { + b([]); + } + }, + init: noopFunc, + setDisplayBids: noopFunc, + targetingKeys: noopFunc + }; + window.apstag = apstagWrapper; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + AmazonApstag.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "amazon-apstag", + args: [] + }, []); + file: amazon-apstag.js + +- title: ati-smarttag + comment: Mocks AT Internat SmartTag. + aliases: [] + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function ATInternetSmartTag(source) { + var setNoopFuncWrapper = { + set: noopFunc + }; + var sendNoopFuncWrapper = { + send: noopFunc + }; + var ecommerceWrapper = { + displayCart: { + products: setNoopFuncWrapper, + cart: setNoopFuncWrapper + }, + updateCart: { + cart: setNoopFuncWrapper + }, + displayProduct: { + products: setNoopFuncWrapper + }, + displayPageProduct: { + products: setNoopFuncWrapper + }, + addProduct: { + products: setNoopFuncWrapper + }, + removeProduct: { + products: setNoopFuncWrapper + } + }; + var tag = function tag() {}; + tag.prototype = { + setConfig: noopFunc, + setParam: noopFunc, + dispatch: noopFunc, + customVars: setNoopFuncWrapper, + publisher: setNoopFuncWrapper, + order: setNoopFuncWrapper, + click: sendNoopFuncWrapper, + clickListener: sendNoopFuncWrapper, + internalSearch: { + set: noopFunc, + send: noopFunc + }, + ecommerce: ecommerceWrapper, + identifiedVisitor: { + unset: noopFunc + }, + page: { + set: noopFunc, + send: noopFunc + }, + selfPromotion: { + add: noopFunc, + send: noopFunc + }, + privacy: { + setVisitorMode: noopFunc, + getVisitorMode: noopFunc, + hit: noopFunc + }, + richMedia: { + add: noopFunc, + send: noopFunc, + remove: noopFunc, + removeAll: noopFunc + } + }; + var smartTagWrapper = { + Tracker: { + Tag: tag + } + }; + window.ATInternet = smartTagWrapper; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + ATInternetSmartTag.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "ati-smarttag", + args: [] + }, []); + file: ati-smarttag.js + +- title: didomi-loader + comment: Mocks Didomi's CMP loader script. + aliases: [] + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function DidomiLoader(source) { + function UserConsentStatusForVendorSubscribe() {} + UserConsentStatusForVendorSubscribe.prototype.filter = function() { + return new UserConsentStatusForVendorSubscribe; + }; + UserConsentStatusForVendorSubscribe.prototype.subscribe = noopFunc; + function UserConsentStatusForVendor() {} + UserConsentStatusForVendor.prototype.first = function() { + return new UserConsentStatusForVendorSubscribe; + }; + UserConsentStatusForVendor.prototype.filter = function() { + return new UserConsentStatusForVendorSubscribe; + }; + UserConsentStatusForVendor.prototype.subscribe = noopFunc; + var DidomiWrapper = { + isConsentRequired: falseFunc, + getUserConsentStatusForPurpose: trueFunc, + getUserConsentStatus: trueFunc, + getUserStatus: noopFunc, + getRequiredPurposes: noopArray, + getUserConsentStatusForVendor: trueFunc, + Purposes: { + Cookies: "cookies" + }, + notice: { + configure: noopFunc, + hide: noopFunc, + isVisible: falseFunc, + show: noopFunc, + showDataProcessing: trueFunc + }, + isUserConsentStatusPartial: falseFunc, + on() { + return { + actions: {}, + emitter: {}, + services: {}, + store: {} + }; + }, + shouldConsentBeCollected: falseFunc, + getUserConsentStatusForAll: noopFunc, + getObservableOnUserConsentStatusForVendor() { + return new UserConsentStatusForVendor; + } + }; + window.Didomi = DidomiWrapper; + var didomiStateWrapper = { + didomiExperimentId: "", + didomiExperimentUserGroup: "", + didomiGDPRApplies: 1, + didomiIABConsent: "", + didomiPurposesConsent: "", + didomiPurposesConsentDenied: "", + didomiPurposesConsentUnknown: "", + didomiVendorsConsent: "", + didomiVendorsConsentDenied: "", + didomiVendorsConsentUnknown: "", + didomiVendorsRawConsent: "", + didomiVendorsRawConsentDenied: "", + didomiVendorsRawConsentUnknown: "" + }; + window.didomiState = didomiStateWrapper; + var tcData = { + eventStatus: "tcloaded", + gdprApplies: false, + listenerId: noopFunc, + vendor: { + consents: [] + }, + purpose: { + consents: [] + } + }; + var __tcfapiWrapper = function __tcfapiWrapper(command, version, callback) { + if (typeof callback !== "function" || command === "removeEventListener") { + return; + } + callback(tcData, true); + }; + window.__tcfapi = __tcfapiWrapper; + var didomiEventListenersWrapper = { + stub: true, + push: noopFunc + }; + window.didomiEventListeners = didomiEventListenersWrapper; + var didomiOnReadyWrapper = { + stub: true, + push(arg) { + if (typeof arg !== "function") { + return; + } + if (document.readyState !== "complete") { + window.addEventListener("load", (function() { + setTimeout(arg(window.Didomi)); + })); + } else { + setTimeout(arg(window.Didomi)); + } + } + }; + window.didomiOnReady = window.didomiOnReady || didomiOnReadyWrapper; + if (Array.isArray(window.didomiOnReady)) { + window.didomiOnReady.forEach((function(arg) { + if (typeof arg === "function") { + try { + setTimeout(arg(window.Didomi)); + } catch (e) {} + } + })); + } + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopArray() { + return []; + } + function trueFunc() { + return !0; + } + function falseFunc() { + return !1; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + DidomiLoader.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "didomi-loader", + args: [] + }, []); + file: didomi-loader.js + +- title: fingerprintjs2 + comment: Mocks FingerprintJS v2 + aliases: + - ubo-fingerprint2.js + - fingerprint2.js + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function Fingerprintjs2(source) { + var browserId = ""; + for (var i = 0; i < 8; i += 1) { + browserId += (Math.random() * 65536 + 4096).toString(16).slice(-4); + } + var Fingerprint2 = function Fingerprint2() {}; + Fingerprint2.get = function(options, callback) { + if (!callback) { + callback = options; + } + setTimeout((function() { + if (callback) { + callback(browserId, []); + } + }), 1); + }; + Fingerprint2.prototype = { + get: Fingerprint2.get + }; + window.Fingerprint2 = Fingerprint2; + window.Fingerprint = Fingerprint2; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + Fingerprintjs2.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "fingerprintjs2", + args: [] + }, []); + file: fingerprintjs2.js + +- title: fingerprintjs3 + comment: Mocks FingerprintJS v3 + aliases: + - ubo-fingerprint3.js + - fingerprint3.js + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function Fingerprintjs3(source) { + var visitorId = function() { + var id = ""; + for (var i = 0; i < 8; i += 1) { + id += (Math.random() * 65536 + 4096).toString(16).slice(-4); + } + return id; + }(); + var FingerprintJS = function FingerprintJS() {}; + FingerprintJS.prototype = { + load() { + return Promise.resolve(new FingerprintJS); + }, + get() { + return Promise.resolve({ + visitorId: visitorId + }); + }, + hashComponents: noopStr + }; + window.FingerprintJS = new FingerprintJS; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopStr() { + return ""; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + Fingerprintjs3.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "fingerprintjs3", + args: [] + }, []); + file: fingerprintjs3.js + +- title: freewheel-admanager + comment: Mocks the FreeWheel Ad Manager. + aliases: [] + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function FreewheelAdManager(source) { + var eventsMap = new Map; + var adManagerFunc = noopFunc; + adManagerFunc.prototype.addEventListener = function(type, callback) { + if (type) { + eventsMap.set(type, callback); + } + }; + adManagerFunc.prototype.addKeyValue = noopFunc; + adManagerFunc.prototype.addTemporalSlot = noopFunc; + adManagerFunc.prototype.dispose = noopFunc; + adManagerFunc.prototype.newContext = noopThis; + adManagerFunc.prototype.registerCustomPlayer = noopFunc; + adManagerFunc.prototype.registerVideoDisplayBase = noopFunc; + adManagerFunc.prototype.removeEventListener = noopFunc; + adManagerFunc.prototype.resize = noopFunc; + adManagerFunc.prototype.setCapability = noopFunc; + adManagerFunc.prototype.setContentVideoElement = noopFunc; + adManagerFunc.prototype.setLogLevel = noopFunc; + adManagerFunc.prototype.setNetwork = noopFunc; + adManagerFunc.prototype.setParameter = noopFunc; + adManagerFunc.prototype.setProfile = noopFunc; + adManagerFunc.prototype.setServer = noopFunc; + adManagerFunc.prototype.setSiteSection = noopFunc; + adManagerFunc.prototype.setVideoAsset = noopFunc; + adManagerFunc.prototype.setVideoDisplaySize = noopFunc; + adManagerFunc.prototype.submitRequest = function() { + var event = { + type: window.tv.freewheel.SDK.EVENT_SLOT_ENDED + }; + var callbackFunc = eventsMap.get("EVENT_SLOT_ENDED"); + if (callbackFunc && typeof callbackFunc === "function") { + setTimeout((function() { + try { + callbackFunc(event); + } catch (ex) {} + }), 1); + } + }; + window.tv = { + freewheel: { + SDK: { + _instanceQueue: {}, + Ad: noopFunc, + AdListener: noopFunc, + AdManager: adManagerFunc, + EVENT_SLOT_ENDED: "EVENT_SLOT_ENDED", + setLogLevel: noopFunc + } + } + }; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopThis() { + return this; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + FreewheelAdManager.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "freewheel-admanager", + args: [] + }, []); + file: freewheel-admanager.js + +- title: gemius + comment: Mocks Gemius Analytics. + aliases: [] + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function Gemius(source) { + var GemiusPlayer = function GemiusPlayer() {}; + GemiusPlayer.prototype = { + setVideoObject: noopFunc, + newProgram: noopFunc, + programEvent: noopFunc, + newAd: noopFunc, + adEvent: noopFunc + }; + window.GemiusPlayer = GemiusPlayer; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + Gemius.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "gemius", + args: [] + }, []); + file: gemius.js + +- title: google-analytics-ga + comment: Mocks old Google Analytics API. + aliases: + - ubo-google-analytics_ga.js + - google-analytics_ga.js + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function GoogleAnalyticsGa(source) { + function Gaq() {} + Gaq.prototype.Na = noopFunc; + Gaq.prototype.O = noopFunc; + Gaq.prototype.Sa = noopFunc; + Gaq.prototype.Ta = noopFunc; + Gaq.prototype.Va = noopFunc; + Gaq.prototype._createAsyncTracker = noopFunc; + Gaq.prototype._getAsyncTracker = noopFunc; + Gaq.prototype._getPlugin = noopFunc; + Gaq.prototype.push = function(data) { + if (typeof data === "function") { + data(); + return; + } + if (Array.isArray(data) === false) { + return; + } + if (typeof data[0] === "string" && /(^|\.)_link$/.test(data[0]) && typeof data[1] === "string") { + window.location.assign(data[1]); + } + if (data[0] === "_set" && data[1] === "hitCallback" && typeof data[2] === "function") { + data[2](); + } + }; + var gaq = new Gaq; + var asyncTrackers = window._gaq || []; + if (Array.isArray(asyncTrackers)) { + while (asyncTrackers[0]) { + gaq.push(asyncTrackers.shift()); + } + } + window._gaq = gaq.qf = gaq; + function Gat() {} + var api = [ "_addIgnoredOrganic", "_addIgnoredRef", "_addItem", "_addOrganic", "_addTrans", "_clearIgnoredOrganic", "_clearIgnoredRef", "_clearOrganic", "_cookiePathCopy", "_deleteCustomVar", "_getName", "_setAccount", "_getAccount", "_getClientInfo", "_getDetectFlash", "_getDetectTitle", "_getLinkerUrl", "_getLocalGifPath", "_getServiceMode", "_getVersion", "_getVisitorCustomVar", "_initData", "_link", "_linkByPost", "_setAllowAnchor", "_setAllowHash", "_setAllowLinker", "_setCampContentKey", "_setCampMediumKey", "_setCampNameKey", "_setCampNOKey", "_setCampSourceKey", "_setCampTermKey", "_setCampaignCookieTimeout", "_setCampaignTrack", "_setClientInfo", "_setCookiePath", "_setCookiePersistence", "_setCookieTimeout", "_setCustomVar", "_setDetectFlash", "_setDetectTitle", "_setDomainName", "_setLocalGifPath", "_setLocalRemoteServerMode", "_setLocalServerMode", "_setReferrerOverride", "_setRemoteServerMode", "_setSampleRate", "_setSessionTimeout", "_setSiteSpeedSampleRate", "_setSessionCookieTimeout", "_setVar", "_setVisitorCookieTimeout", "_trackEvent", "_trackPageLoadTime", "_trackPageview", "_trackSocial", "_trackTiming", "_trackTrans", "_visitCode" ]; + var tracker = api.reduce((function(res, funcName) { + res[funcName] = noopFunc; + return res; + }), {}); + tracker._getLinkerUrl = function(a) { + return a; + }; + tracker._link = function(url) { + if (typeof url !== "string") { + return; + } + try { + window.location.assign(url); + } catch (e) { + logMessage(source, e); + } + }; + Gat.prototype._anonymizeIP = noopFunc; + Gat.prototype._createTracker = noopFunc; + Gat.prototype._forceSSL = noopFunc; + Gat.prototype._getPlugin = noopFunc; + Gat.prototype._getTracker = function() { + return tracker; + }; + Gat.prototype._getTrackerByName = function() { + return tracker; + }; + Gat.prototype._getTrackers = noopFunc; + Gat.prototype.aa = noopFunc; + Gat.prototype.ab = noopFunc; + Gat.prototype.hb = noopFunc; + Gat.prototype.la = noopFunc; + Gat.prototype.oa = noopFunc; + Gat.prototype.pa = noopFunc; + Gat.prototype.u = noopFunc; + var gat = new Gat; + window._gat = gat; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function logMessage(e, o) { + var r = arguments.length > 2 && void 0 !== arguments[2] && arguments[2], a = !(arguments.length > 3 && void 0 !== arguments[3]) || arguments[3], {name: n, verbose: g} = e; + if (r || g) { + var i = console.log; + a ? i(`${n}: ${o}`) : Array.isArray(o) ? i(`${n}:`, ...o) : i(`${n}:`, o); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + GoogleAnalyticsGa.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "google-analytics-ga", + args: [] + }, []); + file: google-analytics-ga.js + +- title: google-analytics + comment: Mocks Google's Analytics and Tag Manager APIs. + aliases: + - ubo-google-analytics_analytics.js + - google-analytics_analytics.js + - googletagmanager-gtm + - ubo-googletagmanager_gtm.js + - googletagmanager_gtm.js + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function GoogleAnalytics(source) { + var _window$googleAnalyti; + var Tracker = function Tracker() {}; + var proto = Tracker.prototype; + proto.get = noopFunc; + proto.set = noopFunc; + proto.send = noopFunc; + var googleAnalyticsName = window.GoogleAnalyticsObject || "ga"; + var queue = (_window$googleAnalyti = window[googleAnalyticsName]) === null || _window$googleAnalyti === void 0 ? void 0 : _window$googleAnalyti.q; + function ga(a) { + var len = arguments.length; + if (len === 0) { + return; + } + var lastArg = arguments[len - 1]; + var replacer; + if (lastArg instanceof Object && lastArg !== null && typeof lastArg.hitCallback === "function") { + replacer = lastArg.hitCallback; + } else if (typeof lastArg === "function") { + replacer = function replacer() { + lastArg(ga.create()); + }; + } + try { + setTimeout(replacer, 1); + } catch (ex) {} + } + ga.create = function() { + return new Tracker; + }; + ga.getByName = function() { + return new Tracker; + }; + ga.getAll = function() { + return [ new Tracker ]; + }; + ga.remove = noopFunc; + ga.loaded = true; + window[googleAnalyticsName] = ga; + if (Array.isArray(queue)) { + var push = function push(arg) { + ga(...arg); + }; + queue.push = push; + queue.forEach(push); + } + var {dataLayer: dataLayer, google_optimize: google_optimize} = window; + if (dataLayer instanceof Object === false) { + return; + } + if (dataLayer.hide instanceof Object && typeof dataLayer.hide.end === "function") { + dataLayer.hide.end(); + } + var handleCallback = function handleCallback(dataObj, funcName) { + if (dataObj && typeof dataObj[funcName] === "function") { + setTimeout(dataObj[funcName]); + } + }; + if (typeof dataLayer.push === "function") { + dataLayer.push = function(data) { + if (data instanceof Object) { + handleCallback(data, "eventCallback"); + for (var key in data) { + handleCallback(data[key], "event_callback"); + } + if (!data.hasOwnProperty("eventCallback") && !data.hasOwnProperty("eventCallback")) { + [].push.call(window.dataLayer, data); + } + } + if (Array.isArray(data)) { + data.forEach((function(arg) { + handleCallback(arg, "callback"); + })); + } + return noopFunc; + }; + } + if (google_optimize instanceof Object && typeof google_optimize.get === "function") { + var googleOptimizeWrapper = { + get: noopFunc + }; + window.google_optimize = googleOptimizeWrapper; + } + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopNull() { + return null; + } + function noopArray() { + return []; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + GoogleAnalytics.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "google-analytics", + args: [] + }, []); + file: google-analytics.js + +- title: google-ima3-dai + comment: Mocks the IMA DAI SDK of Google. + aliases: [] + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function GoogleIma3Dai(source) { + var streamEventTypes = { + AD_BREAK_ENDED: "adBreakEnded", + AD_BREAK_STARTED: "adBreakStarted", + AD_PERIOD_ENDED: "adPeriodEnded", + AD_PERIOD_STARTED: "adPeriodStarted", + AD_PROGRESS: "adProgress", + CLICK: "click", + COMPLETE: "complete", + CUEPOINTS_CHANGED: "cuepointsChanged", + ERROR: "error", + FIRST_QUARTILE: "firstquartile", + HIDE_AD_UI: "hideAdUi", + LOADED: "loaded", + MIDPOINT: "midpoint", + PAUSED: "paused", + RESUMED: "resumed", + SHOW_AD_UI: "showAdUi", + SKIPPABLE_STATE_CHANGED: "skippableStateChanged", + SKIPPED: "skip", + STARTED: "started", + STREAM_INITIALIZED: "streamInitialized", + THIRD_QUARTILE: "thirdquartile", + VIDEO_CLICKED: "videoClicked" + }; + var isRecord = function isRecord(value) { + return typeof value === "object" && value !== null; + }; + var schedule = function schedule(callback) { + if (typeof requestAnimationFrame === "function") { + requestAnimationFrame(callback); + return; + } + setTimeout(callback, 0); + }; + var toStringRecord = function toStringRecord(value) { + if (!isRecord(value)) { + return {}; + } + var result = {}; + var propertyNames = Object.keys(value); + for (var propertyIndex = 0; propertyIndex < propertyNames.length; propertyIndex += 1) { + var propertyName = propertyNames[propertyIndex]; + result[propertyName] = String(value[propertyName]); + } + return result; + }; + var getStringValue = function getStringValue(value) { + return typeof value === "string" && value.length > 0 ? value : null; + }; + var normalizeStreamRequestUi = function normalizeStreamRequestUi(value) { + if (!isRecord(value)) { + return { + custom: null + }; + } + var normalizedUi = Object.assign({ + custom: null + }, value); + normalizedUi.custom = isRecord(normalizedUi.custom) ? normalizedUi.custom : null; + return normalizedUi; + }; + var initializeEventHandler = function initializeEventHandler(instance) { + instance.listeners = new Map; + }; + var normalizeEventTypes = function normalizeEventTypes(type) { + if (typeof type === "string") { + return [ type ]; + } + if (!Array.isArray(type)) { + return []; + } + var eventTypes = []; + for (var eventTypeIndex = 0; eventTypeIndex < type.length; eventTypeIndex += 1) { + var eventType = type[eventTypeIndex]; + if (typeof eventType === "string") { + eventTypes.push(eventType); + } + } + return eventTypes; + }; + var initializeStreamRequest = function initializeStreamRequest(instance, streamRequest) { + instance.adTagParameters = {}; + instance.apiKey = null; + instance.authToken = null; + instance.format = "hls"; + instance.networkCode = null; + instance.omidAccessModeRules = null; + instance.streamActivityMonitorId = null; + instance.ui = { + custom: null + }; + if (isRecord(streamRequest)) { + Object.assign(instance, streamRequest); + } + instance.adTagParameters = toStringRecord(instance.adTagParameters); + instance.ui = normalizeStreamRequestUi(instance.ui); + if (typeof instance.format !== "string" || instance.format.length === 0) { + instance.format = "hls"; + } + }; + var initializePodStreamRequest = function initializePodStreamRequest(instance, podStreamRequest) { + initializeStreamRequest(instance, podStreamRequest); + instance.customAssetKey = typeof instance.customAssetKey === "string" ? instance.customAssetKey : ""; + }; + var EventHandler = function EventHandler() { + initializeEventHandler(this); + }; + EventHandler.prototype.addEventListener = function(type, listener) { + if (typeof listener !== "function") { + return; + } + var eventTypes = normalizeEventTypes(type); + for (var eventTypeIndex = 0; eventTypeIndex < eventTypes.length; eventTypeIndex += 1) { + var eventType = eventTypes[eventTypeIndex]; + if (!this.listeners.has(eventType)) { + this.listeners.set(eventType, new Set); + } + var listeners = this.listeners.get(eventType); + if (listeners) { + listeners.add(listener); + } + } + }; + EventHandler.prototype.removeEventListener = function(type, listener) { + if (typeof listener !== "function") { + return; + } + var eventTypes = normalizeEventTypes(type); + for (var eventTypeIndex = 0; eventTypeIndex < eventTypes.length; eventTypeIndex += 1) { + var listeners = this.listeners.get(eventTypes[eventTypeIndex]); + if (!listeners) { + continue; + } + listeners.delete(listener); + } + }; + EventHandler.prototype.dispatchEvent = function(streamEvent) { + var listeners = this.listeners.get(streamEvent.type); + if (!listeners) { + return; + } + for (var _i = 0, _Array$from = Array.from(listeners); _i < _Array$from.length; _i++) { + var _listener = _Array$from[_i]; + try { + _listener(streamEvent); + } catch (error) { + logMessage(source, error); + } + } + }; + var streamFormats = { + DASH: "dash", + HLS: "hls" + }; + var StreamRequest = function StreamRequest(streamRequest) { + initializeStreamRequest(this, streamRequest); + }; + StreamRequest.StreamFormat = streamFormats; + var LiveStreamRequest = function LiveStreamRequest(liveStreamRequest) { + initializeStreamRequest(this, liveStreamRequest); + this.assetKey = typeof this.assetKey === "string" ? this.assetKey : ""; + }; + Object.setPrototypeOf(LiveStreamRequest.prototype, StreamRequest.prototype); + var PodStreamRequest = function PodStreamRequest(podStreamRequest) { + initializePodStreamRequest(this, podStreamRequest); + }; + Object.setPrototypeOf(PodStreamRequest.prototype, StreamRequest.prototype); + var VideoStitcherLiveStreamRequest = function VideoStitcherLiveStreamRequest(videoStitcherLiveStreamRequest) { + initializePodStreamRequest(this, videoStitcherLiveStreamRequest); + this.liveStreamEventId = typeof this.liveStreamEventId === "string" ? this.liveStreamEventId : ""; + this.oAuthToken = typeof this.oAuthToken === "string" ? this.oAuthToken : null; + this.projectNumber = typeof this.projectNumber === "string" ? this.projectNumber : null; + this.region = typeof this.region === "string" ? this.region : null; + this.videoStitcherSessionOptions = isRecord(this.videoStitcherSessionOptions) ? this.videoStitcherSessionOptions : null; + }; + Object.setPrototypeOf(VideoStitcherLiveStreamRequest.prototype, PodStreamRequest.prototype); + var VideoStitcherVodStreamRequest = function VideoStitcherVodStreamRequest(videoStitcherVodStreamRequest) { + initializeStreamRequest(this, videoStitcherVodStreamRequest); + this.adTagUrl = typeof this.adTagUrl === "string" ? this.adTagUrl : ""; + this.contentSourceUrl = typeof this.contentSourceUrl === "string" ? this.contentSourceUrl : ""; + this.oAuthToken = typeof this.oAuthToken === "string" ? this.oAuthToken : null; + this.projectNumber = typeof this.projectNumber === "string" ? this.projectNumber : null; + this.region = typeof this.region === "string" ? this.region : null; + this.videoStitcherSessionOptions = isRecord(this.videoStitcherSessionOptions) ? this.videoStitcherSessionOptions : null; + this.vodConfigId = typeof this.vodConfigId === "string" ? this.vodConfigId : ""; + }; + Object.setPrototypeOf(VideoStitcherVodStreamRequest.prototype, StreamRequest.prototype); + var VODStreamRequest = function VODStreamRequest(vodStreamRequest) { + initializeStreamRequest(this, vodStreamRequest); + this.contentSourceId = typeof this.contentSourceId === "string" ? this.contentSourceId : ""; + this.videoId = typeof this.videoId === "string" ? this.videoId : ""; + }; + Object.setPrototypeOf(VODStreamRequest.prototype, StreamRequest.prototype); + var StreamData = function StreamData(streamData) { + this.adPeriodData = null; + this.adProgressData = null; + this.cuepoints = []; + this.errorMessage = null; + this.manifestFormat = "HLS"; + this.streamId = null; + this.subtitles = []; + this.url = ""; + if (isRecord(streamData)) { + Object.assign(this, streamData); + } + }; + var StreamEvent = function StreamEvent(type, streamData, ad) { + this.type = type; + this.streamData = streamData || new StreamData; + this.ad = ad || null; + }; + StreamEvent.Type = streamEventTypes; + StreamEvent.prototype.getAd = function() { + return this.ad; + }; + StreamEvent.prototype.getStreamData = function() { + return this.streamData; + }; + var UiSettings = function UiSettings() { + this.locale = "en"; + }; + UiSettings.prototype.getLocale = function() { + return this.locale; + }; + UiSettings.prototype.setLocale = function(locale) { + if (typeof locale === "string" && locale.length > 0) { + this.locale = locale; + } + }; + var uiKeys = { + ABOUT_THIS_AD_FALLBACK_IMAGE: "aboutThisAdFallbackImage", + ABOUT_THIS_AD_ICON: "aboutThisAdIcon", + AD_TITLE: "adTitle", + ATTRIBUTION: "attribution", + AUTHOR_ICON: "authorIcon", + AUTHOR_TITLE: "authorTitle", + CALL_TO_ACTION: "callToAction", + PRE_SKIP: "preSkip", + SKIP_BUTTON: "skipButton", + VIDEO_OVERLAY: "videoOverlay" + }; + var clickThroughNavigation = { + EXTERNAL: "external", + NOT_SUPPORTED: "notSupported" + }; + var UiImage = function UiImage(uiImage) { + this.altText = ""; + this.height = 0; + this.url = ""; + this.width = 0; + if (isRecord(uiImage)) { + Object.assign(this, uiImage); + } + this.altText = getStringValue(this.altText) || ""; + this.height = typeof this.height === "number" ? this.height : 0; + this.url = getStringValue(this.url) || ""; + this.width = typeof this.width === "number" ? this.width : 0; + }; + var UiData = function UiData(uiData) { + this.clickable = false; + this.required = false; + if (isRecord(uiData)) { + Object.assign(this, uiData); + } + this.clickable = Boolean(this.clickable); + this.required = Boolean(this.required); + if (Array.isArray(this.imageVariants)) { + var imageVariants = []; + for (var imageVariantIndex = 0; imageVariantIndex < this.imageVariants.length; imageVariantIndex += 1) { + imageVariants.push(new UiImage(this.imageVariants[imageVariantIndex])); + } + this.imageVariants = imageVariants; + } + }; + UiData.UiImage = UiImage; + var UiOptions = function UiOptions(uiOptions) { + this.aboutThisAdSupport = false; + this.clickThroughNavigation = clickThroughNavigation.NOT_SUPPORTED; + this.skippableSupport = false; + if (isRecord(uiOptions)) { + Object.assign(this, uiOptions); + } + this.aboutThisAdSupport = Boolean(this.aboutThisAdSupport); + this.clickThroughNavigation = this.clickThroughNavigation === clickThroughNavigation.EXTERNAL ? clickThroughNavigation.EXTERNAL : clickThroughNavigation.NOT_SUPPORTED; + this.skippableSupport = Boolean(this.skippableSupport); + }; + UiOptions.ClickThroughNavigation = clickThroughNavigation; + var CustomUiOptions = function CustomUiOptions(uiOptions) { + this.aboutThisAdSupport = false; + this.skippableSupport = false; + if (isRecord(uiOptions)) { + Object.assign(this, uiOptions); + } + this.aboutThisAdSupport = Boolean(this.aboutThisAdSupport); + this.skippableSupport = Boolean(this.skippableSupport); + }; + var uiDelegates = new WeakMap; + var Ui = function Ui(uiDelegate) { + uiDelegates.set(this, isRecord(uiDelegate) ? uiDelegate : {}); + }; + Ui.prototype.onClick = function(uiKey, eventData) { + var uiDelegate = uiDelegates.get(this); + if (uiDelegate && typeof uiDelegate.onClick === "function") { + uiDelegate.onClick(uiKey, eventData); + } + }; + Ui.prototype.setVisibleElements = function(uiElements) { + var uiDelegate = uiDelegates.get(this); + if (uiDelegate && typeof uiDelegate.setVisibleElements === "function") { + uiDelegate.setVisibleElements(uiElements); + } + }; + Ui.prototype.getConfig = function() { + var uiDelegate = uiDelegates.get(this); + if (!uiDelegate || typeof uiDelegate.getConfig !== "function") { + return new Map; + } + var uiConfig = uiDelegate.getConfig(); + return uiConfig instanceof Map ? uiConfig : new Map; + }; + Ui.UiData = UiData; + Ui.UiKey = uiKeys; + Ui.UiOptions = UiOptions; + var daiSdkFeatureFlagsStorage = new WeakMap; + var getStoredDaiSdkFeatureFlags = function getStoredDaiSdkFeatureFlags(instance) { + var storedFeatureFlags = daiSdkFeatureFlagsStorage.get(instance); + if (storedFeatureFlags) { + return storedFeatureFlags; + } + var nextFeatureFlags = {}; + daiSdkFeatureFlagsStorage.set(instance, nextFeatureFlags); + return nextFeatureFlags; + }; + var DaiSdkSettingsContainer = function DaiSdkSettingsContainer() { + daiSdkFeatureFlagsStorage.set(this, {}); + }; + DaiSdkSettingsContainer.prototype.getFeatureFlags = function() { + return getStoredDaiSdkFeatureFlags(this); + }; + DaiSdkSettingsContainer.prototype.setFeatureFlags = function(featureFlags) { + daiSdkFeatureFlagsStorage.set(this, Object.assign({}, featureFlags)); + }; + var normalizeStreamRequest = function normalizeStreamRequest(streamRequest) { + if (streamRequest instanceof StreamRequest) { + return streamRequest; + } + if (isRecord(streamRequest)) { + if (typeof streamRequest.liveStreamEventId === "string") { + return new VideoStitcherLiveStreamRequest(streamRequest); + } + if (typeof streamRequest.contentSourceUrl === "string" || typeof streamRequest.vodConfigId === "string" || typeof streamRequest.adTagUrl === "string") { + return new VideoStitcherVodStreamRequest(streamRequest); + } + if (typeof streamRequest.customAssetKey === "string") { + return new PodStreamRequest(streamRequest); + } + if (typeof streamRequest.assetKey === "string") { + return new LiveStreamRequest(streamRequest); + } + if (typeof streamRequest.contentSourceId === "string" || typeof streamRequest.videoId === "string") { + return new VODStreamRequest(streamRequest); + } + } + return new StreamRequest; + }; + var hasLiveIdentifiers = function hasLiveIdentifiers(streamRequest) { + var liveStreamRequest = streamRequest; + return typeof liveStreamRequest.assetKey === "string" && liveStreamRequest.assetKey.length > 0; + }; + var hasVideoStitcherLiveIdentifiers = function hasVideoStitcherLiveIdentifiers(streamRequest) { + var videoStitcherLiveStreamRequest = streamRequest; + return typeof videoStitcherLiveStreamRequest.liveStreamEventId === "string" && videoStitcherLiveStreamRequest.liveStreamEventId.length > 0; + }; + var hasPodIdentifiers = function hasPodIdentifiers(streamRequest) { + var podStreamRequest = streamRequest; + return typeof podStreamRequest.networkCode === "string" && podStreamRequest.networkCode.length > 0 && typeof podStreamRequest.customAssetKey === "string" && podStreamRequest.customAssetKey.length > 0; + }; + var hasVideoStitcherVodIdentifiers = function hasVideoStitcherVodIdentifiers(streamRequest) { + var videoStitcherVodStreamRequest = streamRequest; + var hasContentSourceUrl = typeof videoStitcherVodStreamRequest.contentSourceUrl === "string" && videoStitcherVodStreamRequest.contentSourceUrl.length > 0; + var hasVodConfigId = typeof videoStitcherVodStreamRequest.vodConfigId === "string" && videoStitcherVodStreamRequest.vodConfigId.length > 0; + return hasContentSourceUrl || hasVodConfigId; + }; + var hasVodIdentifiers = function hasVodIdentifiers(streamRequest) { + var vodStreamRequest = streamRequest; + return typeof vodStreamRequest.contentSourceId === "string" && vodStreamRequest.contentSourceId.length > 0 && typeof vodStreamRequest.videoId === "string" && vodStreamRequest.videoId.length > 0; + }; + var hasIdentifiers = function hasIdentifiers(streamRequest) { + return hasLiveIdentifiers(streamRequest) || hasPodIdentifiers(streamRequest) || hasVideoStitcherLiveIdentifiers(streamRequest) || hasVideoStitcherVodIdentifiers(streamRequest) || hasVodIdentifiers(streamRequest); + }; + var getFallbackStreamId = function getFallbackStreamId(streamRequest) { + var liveStreamRequest = streamRequest; + var videoStitcherLiveStreamRequest = streamRequest; + var videoStitcherVodStreamRequest = streamRequest; + var vodStreamRequest = streamRequest; + if (typeof videoStitcherVodStreamRequest.vodConfigId === "string" && videoStitcherVodStreamRequest.vodConfigId.length > 0) { + return `mock-video-stitcher-vod-${videoStitcherVodStreamRequest.vodConfigId}`; + } + if (typeof videoStitcherVodStreamRequest.contentSourceUrl === "string" && videoStitcherVodStreamRequest.contentSourceUrl.length > 0) { + return "mock-video-stitcher-vod"; + } + if (typeof videoStitcherLiveStreamRequest.liveStreamEventId === "string" && videoStitcherLiveStreamRequest.liveStreamEventId.length > 0) { + return `mock-video-stitcher-live-${videoStitcherLiveStreamRequest.liveStreamEventId}`; + } + if (typeof liveStreamRequest.assetKey === "string" && liveStreamRequest.assetKey.length > 0) { + return `mock-live-${liveStreamRequest.assetKey}`; + } + if (typeof vodStreamRequest.videoId === "string" && vodStreamRequest.videoId.length > 0) { + return `mock-vod-${vodStreamRequest.videoId}`; + } + return "mock-stream"; + }; + var getDefaultManifestFormat = function getDefaultManifestFormat(streamRequest) { + return typeof streamRequest.format === "string" && streamRequest.format.toLowerCase() === "dash" ? "DASH" : "HLS"; + }; + var createStreamData = function createStreamData(streamRequest, cuepoints, errorMessage, streamDataOverrides) { + var streamData = new StreamData({ + cuepoints: cuepoints.slice(), + errorMessage: errorMessage, + manifestFormat: getDefaultManifestFormat(streamRequest), + streamId: getFallbackStreamId(streamRequest), + url: "" + }); + if (isRecord(streamDataOverrides)) { + Object.assign(streamData, streamDataOverrides); + } + return streamData; + }; + var appendRequestParameters = function appendRequestParameters(requestUrl, streamRequest) { + var parameterNames = Object.keys(streamRequest.adTagParameters); + for (var parameterIndex = 0; parameterIndex < parameterNames.length; parameterIndex += 1) { + var parameterName = parameterNames[parameterIndex]; + requestUrl.searchParams.set(parameterName, streamRequest.adTagParameters[parameterName]); + } + if (streamRequest.apiKey) { + requestUrl.searchParams.set("api-key", streamRequest.apiKey); + } + if (streamRequest.authToken) { + requestUrl.searchParams.set("auth-token", streamRequest.authToken); + } + if (streamRequest.streamActivityMonitorId) { + requestUrl.searchParams.set("dai-sam-id", streamRequest.streamActivityMonitorId); + } + }; + var buildLiveRequestUrl = function buildLiveRequestUrl(streamRequest, hostName) { + var requestUrl = new URL(`${hostName}/ssai/event/${streamRequest.assetKey}/streams`); + appendRequestParameters(requestUrl, streamRequest); + return requestUrl.toString(); + }; + var buildPodRequestUrl = function buildPodRequestUrl(streamRequest, hostName) { + var requestUrl = new URL(`${hostName}/ssai/pods/api/v1/network/${streamRequest.networkCode}` + `/custom_asset/${streamRequest.customAssetKey}/stream`); + var manifestType = streamRequest.format.toLowerCase() === "dash" ? "dash" : "hls"; + appendRequestParameters(requestUrl, streamRequest); + requestUrl.searchParams.set("manifest-type", manifestType); + return requestUrl.toString(); + }; + var buildVodRequestUrl = function buildVodRequestUrl(streamRequest, hostName) { + var requestFormat = streamRequest.format.toLowerCase() === "dash" ? "dash" : "hls"; + var requestUrl = new URL(`${hostName}/ondemand/${requestFormat}/content/${streamRequest.contentSourceId}` + `/vid/${streamRequest.videoId}/streams`); + appendRequestParameters(requestUrl, streamRequest); + return requestUrl.toString(); + }; + var MAIN_HOST_NAME = "https://dai.google.com"; + var FALLBACK_HOST_NAME = "https://pubads.g.doubleclick.net"; + var getStreamRequestUrls = function getStreamRequestUrls(streamRequest) { + if (hasPodIdentifiers(streamRequest)) { + return [ buildPodRequestUrl(streamRequest, MAIN_HOST_NAME), buildPodRequestUrl(streamRequest, FALLBACK_HOST_NAME) ]; + } + if (hasLiveIdentifiers(streamRequest)) { + return [ buildLiveRequestUrl(streamRequest, MAIN_HOST_NAME), buildLiveRequestUrl(streamRequest, FALLBACK_HOST_NAME) ]; + } + if (hasVodIdentifiers(streamRequest)) { + return [ buildVodRequestUrl(streamRequest, MAIN_HOST_NAME), buildVodRequestUrl(streamRequest, FALLBACK_HOST_NAME) ]; + } + return []; + }; + var readFetchResponseData = async function readFetchResponseData(response) { + var typedResponse = response; + if (typedResponse && typedResponse.ok === false) { + throw new Error(`Stream initialization failed with status ${String(typedResponse.status || 0)}`); + } + if (typedResponse && typeof typedResponse.json === "function") { + var jsonResponse = await typedResponse.json(); + return isRecord(jsonResponse) ? jsonResponse : {}; + } + return isRecord(response) ? response : {}; + }; + var getResponseErrorMessage = function getResponseErrorMessage(responseData) { + return getStringValue(responseData.errorMessage) || getStringValue(responseData.error_message); + }; + var createStreamDataFromResponse = function createStreamDataFromResponse(streamRequest, cuepoints, responseData) { + var podManifestUrl = getStringValue(responseData.pod_manifest_url) || getStringValue(responseData.podManifestUrl) || ""; + var responseStreamId = getStringValue(responseData.stream_id) || getStringValue(responseData.streamId); + var streamUrl = getStringValue(responseData.stream_manifest) || getStringValue(responseData.streamUrl) || podManifestUrl || ""; + var responseErrorMessage = getResponseErrorMessage(responseData); + var hasInitializedStream = streamUrl.length > 0 || responseStreamId !== null && responseStreamId.length > 0; + var errorMessage = responseErrorMessage || (hasInitializedStream ? null : "Stream initialization response missing stream URL"); + var manifestFormat = getStringValue(responseData.manifest_format) || getStringValue(responseData.manifestFormat) || getDefaultManifestFormat(streamRequest); + var streamId = responseStreamId || getFallbackStreamId(streamRequest); + var subtitles = Array.isArray(responseData.subtitles) ? responseData.subtitles : []; + return createStreamData(streamRequest, cuepoints, errorMessage, { + manifestFormat: manifestFormat, + podManifestUrl: podManifestUrl, + pod_manifest_url: podManifestUrl, + streamId: streamId, + subtitles: subtitles, + url: streamUrl + }); + }; + var getErrorMessage = function getErrorMessage(error) { + if (isRecord(error) && typeof error.message === "string" && error.message.length > 0) { + return error.message; + } + return "Stream initialization failed"; + }; + var hideAdUiElement = function hideAdUiElement(streamManager) { + if (!streamManager.adUiElement) { + return; + } + streamManager.adUiElement.style.display = "none"; + }; + var showVideoControls = function showVideoControls(streamManager) { + if (!streamManager.videoElement || streamManager.videoElement.controls) { + return; + } + streamManager.videoElement.controls = true; + }; + var handleContentLoaded = function handleContentLoaded(streamManager) { + hideAdUiElement(streamManager); + showVideoControls(streamManager); + }; + var isContentLoadedEventType = function isContentLoadedEventType(eventType) { + return eventType === StreamEvent.Type.LOADED || eventType === StreamEvent.Type.STREAM_INITIALIZED; + }; + var StreamManager = function StreamManager(videoElement, adUiElement, uiSettings) { + initializeEventHandler(this); + this.videoElement = videoElement || null; + this.adUiElement = adUiElement || null; + this.uiSettings = uiSettings || new UiSettings; + this.clickElement = adUiElement || null; + this.streamData = new StreamData; + this.streamMonitor = {}; + this.streamRequest = null; + this.cuepoints = []; + this.lastMetadata = null; + this.lastTimedMetadata = null; + }; + Object.setPrototypeOf(StreamManager.prototype, EventHandler.prototype); + StreamManager.prototype.contentTimeForStreamTime = function(streamTime) { + return typeof streamTime === "number" ? streamTime : 0; + }; + StreamManager.prototype.destroy = function() { + this.reset(); + }; + StreamManager.prototype.focus = function() { + var clickElement = this.clickElement; + if (!clickElement || typeof clickElement.focus !== "function") { + return; + } + try { + clickElement.focus(); + } catch (error) { + logMessage(source, error); + } + }; + StreamManager.prototype.getAdSkippableState = function() { + return true; + }; + StreamManager.prototype.getStreamData = function() { + return this.streamData; + }; + StreamManager.prototype.loadStreamMetadata = function() { + handleContentLoaded(this); + this.dispatchEvent(new StreamEvent(StreamEvent.Type.LOADED, this.streamData)); + }; + StreamManager.prototype.onTimedMetadata = function(metadata) { + this.lastTimedMetadata = metadata; + }; + StreamManager.prototype.previousCuePointForStreamTime = function(streamTime) { + var previousCuePoint = null; + for (var cuepointIndex = 0; cuepointIndex < this.cuepoints.length; cuepointIndex += 1) { + var cuepoint = this.cuepoints[cuepointIndex]; + if (typeof cuepoint.start !== "number") { + continue; + } + if (cuepoint.start <= streamTime) { + previousCuePoint = cuepoint; + } + } + return previousCuePoint; + }; + StreamManager.prototype.processMetadata = function(type, data, timestamp) { + this.lastMetadata = { + data: data, + timestamp: timestamp, + type: type + }; + }; + StreamManager.prototype.replaceAdTagParameters = function(adTagParameters) { + if (!this.streamRequest) { + this.streamRequest = new StreamRequest; + } + this.streamRequest.adTagParameters = toStringRecord(adTagParameters); + }; + StreamManager.prototype.requestStream = function(streamRequest) { + var _this = this; + var normalizedRequest = normalizeStreamRequest(streamRequest); + this.streamRequest = normalizedRequest; + var dispatchStreamEvent = function dispatchStreamEvent(eventType, streamData) { + _this.streamData = streamData; + if (isContentLoadedEventType(eventType)) { + handleContentLoaded(_this); + } + schedule((function() { + _this.dispatchEvent(new StreamEvent(StreamEvent.Type.STREAM_INITIALIZED, streamData)); + _this.dispatchEvent(new StreamEvent(eventType, streamData)); + })); + }; + if (!hasIdentifiers(normalizedRequest)) { + dispatchStreamEvent(StreamEvent.Type.ERROR, createStreamData(normalizedRequest, this.cuepoints, "Missing stream request identifiers")); + return; + } + var requestUrls = getStreamRequestUrls(normalizedRequest); + if (requestUrls.length > 0) { + var activeRequest = normalizedRequest; + var _fetchStreamData = async function fetchStreamData(requestIndex) { + try { + var fetchResponse = await fetch(requestUrls[requestIndex], { + method: "POST", + credentials: "include" + }); + var responseData = await readFetchResponseData(fetchResponse); + if (_this.streamRequest !== activeRequest) { + return; + } + var _streamData = createStreamDataFromResponse(activeRequest, _this.cuepoints, responseData); + var eventType = _streamData.errorMessage ? StreamEvent.Type.ERROR : StreamEvent.Type.LOADED; + dispatchStreamEvent(eventType, _streamData); + } catch (error) { + if (_this.streamRequest !== activeRequest) { + return; + } + if (requestIndex + 1 < requestUrls.length) { + await _fetchStreamData(requestIndex + 1); + return; + } + dispatchStreamEvent(StreamEvent.Type.ERROR, createStreamData(activeRequest, _this.cuepoints, getErrorMessage(error))); + } + }; + _fetchStreamData(0); + return; + } + dispatchStreamEvent(StreamEvent.Type.LOADED, createStreamData(normalizedRequest, this.cuepoints, null)); + }; + StreamManager.prototype.reset = function() { + this.cuepoints = []; + this.lastMetadata = null; + this.lastTimedMetadata = null; + this.streamData = new StreamData; + this.streamRequest = null; + }; + StreamManager.prototype.setClickElement = function(clickElement) { + if (this.adUiElement) { + return; + } + this.clickElement = clickElement; + }; + StreamManager.prototype.streamTimeForContentTime = function(contentTime) { + return typeof contentTime === "number" ? contentTime : 0; + }; + var api = { + customUi: { + UiOptions: CustomUiOptions + }, + DaiSdkSettings: new DaiSdkSettingsContainer, + LiveStreamRequest: LiveStreamRequest, + PodStreamRequest: PodStreamRequest, + StreamData: StreamData, + StreamEvent: StreamEvent, + StreamManager: StreamManager, + StreamRequest: StreamRequest, + ui: Ui, + UiSettings: UiSettings, + VideoStitcherLiveStreamRequest: VideoStitcherLiveStreamRequest, + VideoStitcherVodStreamRequest: VideoStitcherVodStreamRequest, + VODStreamRequest: VODStreamRequest + }; + var globalWindow = window; + var googleNamespace = isRecord(globalWindow.google) ? globalWindow.google : {}; + if (!isRecord(globalWindow.google)) { + globalWindow.google = googleNamespace; + } + var imaNamespace = isRecord(googleNamespace.ima) ? googleNamespace.ima : {}; + googleNamespace.ima = imaNamespace; + var daiNamespace = isRecord(imaNamespace.dai) ? imaNamespace.dai : {}; + imaNamespace.dai = daiNamespace; + var apiNamespace = isRecord(daiNamespace.api) ? daiNamespace.api : {}; + daiNamespace.api = apiNamespace; + Object.assign(apiNamespace, api); + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function logMessage(e, o) { + var r = arguments.length > 2 && void 0 !== arguments[2] && arguments[2], a = !(arguments.length > 3 && void 0 !== arguments[3]) || arguments[3], {name: n, verbose: g} = e; + if (r || g) { + var i = console.log; + a ? i(`${n}: ${o}`) : Array.isArray(o) ? i(`${n}:`, ...o) : i(`${n}:`, o); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + GoogleIma3Dai.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "google-ima3-dai", + args: [] + }, []); + file: google-ima3-dai.js + +- title: google-ima3 + comment: Mocks the IMA SDK of Google. + aliases: + - ubo-google-ima.js + - google-ima.js + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function GoogleIma3(source) { + var _window$google$ima; + var VERSION = "3.746.0"; + var ima = {}; + var AdDisplayContainer = function AdDisplayContainer(containerElement) { + var divElement = document.createElement("div"); + divElement.style.setProperty("display", "none", "important"); + divElement.style.setProperty("visibility", "collapse", "important"); + if (containerElement) { + containerElement.appendChild(divElement); + } + }; + AdDisplayContainer.prototype.destroy = noopFunc; + AdDisplayContainer.prototype.initialize = noopFunc; + var ImaSdkSettings = function ImaSdkSettings() {}; + ImaSdkSettings.CompanionBackfillMode = { + ALWAYS: "always", + ON_MASTER_AD: "on_master_ad" + }; + ImaSdkSettings.VpaidMode = { + DISABLED: 0, + ENABLED: 1, + INSECURE: 2 + }; + ImaSdkSettings.prototype = { + c: true, + f: {}, + i: false, + l: "", + p: "", + r: 0, + t: "", + v: "", + getCompanionBackfill: noopFunc, + getDisableCustomPlaybackForIOS10Plus() { + return this.i; + }, + getDisabledFlashAds: function getDisabledFlashAds() { + return true; + }, + getFeatureFlags() { + return this.f; + }, + getLocale() { + return this.l; + }, + getNumRedirects() { + return this.r; + }, + getPlayerType() { + return this.t; + }, + getPlayerVersion() { + return this.v; + }, + getPpid() { + return this.p; + }, + getVpaidMode() { + return this.C; + }, + isCookiesEnabled() { + return this.c; + }, + isVpaidAdapter() { + return this.M; + }, + setCompanionBackfill: noopFunc, + setAutoPlayAdBreaks(a) { + this.K = a; + }, + setCookiesEnabled(c) { + this.c = !!c; + }, + setDisableCustomPlaybackForIOS10Plus(i) { + this.i = !!i; + }, + setDisableFlashAds: noopFunc, + setFeatureFlags(f) { + this.f = !!f; + }, + setIsVpaidAdapter(a) { + this.M = a; + }, + setLocale(l) { + this.l = !!l; + }, + setNumRedirects(r) { + this.r = !!r; + }, + setPageCorrelator(a) { + this.R = a; + }, + setPlayerType(t) { + this.t = !!t; + }, + setPlayerVersion(v) { + this.v = !!v; + }, + setPpid(p) { + this.p = !!p; + }, + setVpaidMode(a) { + this.C = a; + }, + setSessionId: noopFunc, + setStreamCorrelator: noopFunc, + setVpaidAllowed: noopFunc, + CompanionBackfillMode: { + ALWAYS: "always", + ON_MASTER_AD: "on_master_ad" + }, + VpaidMode: { + DISABLED: 0, + ENABLED: 1, + INSECURE: 2 + } + }; + var EventHandler = function EventHandler() { + this.listeners = new Map; + this._dispatch = function(e) { + var listeners = this.listeners.get(e.type); + listeners = listeners ? listeners.values() : []; + for (var _i = 0, _Array$from = Array.from(listeners); _i < _Array$from.length; _i++) { + var listener = _Array$from[_i]; + try { + listener(e); + } catch (r) { + logMessage(source, r); + } + } + }; + this.addEventListener = function(types, callback, options, context) { + if (!Array.isArray(types)) { + types = [ types ]; + } + for (var i = 0; i < types.length; i += 1) { + var type = types[i]; + if (!this.listeners.has(type)) { + this.listeners.set(type, new Map); + } + this.listeners.get(type).set(callback, callback.bind(context || this)); + } + }; + this.removeEventListener = function(types, callback) { + if (!Array.isArray(types)) { + types = [ types ]; + } + for (var i = 0; i < types.length; i += 1) { + var _this$listeners$get; + var type = types[i]; + (_this$listeners$get = this.listeners.get(type)) === null || _this$listeners$get === void 0 || _this$listeners$get.delete(callback); + } + }; + }; + var AdsManager = new EventHandler; + AdsManager.volume = 1; + AdsManager.collapse = noopFunc; + AdsManager.configureAdsManager = noopFunc; + AdsManager.destroy = noopFunc; + AdsManager.discardAdBreak = noopFunc; + AdsManager.expand = noopFunc; + AdsManager.focus = noopFunc; + AdsManager.getAdSkippableState = function() { + return false; + }; + AdsManager.getCuePoints = function() { + return [ 0 ]; + }; + AdsManager.getCurrentAd = function() { + return currentAd; + }; + AdsManager.getCurrentAdCuePoints = function() { + return []; + }; + AdsManager.getRemainingTime = function() { + return 0; + }; + AdsManager.getVolume = function() { + return this.volume; + }; + AdsManager.init = noopFunc; + AdsManager.isCustomClickTrackingUsed = function() { + return false; + }; + AdsManager.isCustomPlaybackUsed = function() { + return false; + }; + AdsManager.pause = noopFunc; + AdsManager.requestNextAdBreak = noopFunc; + AdsManager.resize = noopFunc; + AdsManager.resume = noopFunc; + AdsManager.setVolume = function(v) { + this.volume = v; + }; + AdsManager.skip = noopFunc; + AdsManager.start = function() { + for (var _i2 = 0, _arr = [ AdEvent.Type.ALL_ADS_COMPLETED, AdEvent.Type.CONTENT_RESUME_REQUESTED ]; _i2 < _arr.length; _i2++) { + var type = _arr[_i2]; + try { + this._dispatch(new ima.AdEvent(type)); + } catch (e) { + logMessage(source, e); + } + } + }; + AdsManager.stop = noopFunc; + AdsManager.updateAdsRenderingSettings = noopFunc; + var manager = Object.create(AdsManager); + var AdsManagerLoadedEvent = function AdsManagerLoadedEvent(type, adsRequest, userRequestContext) { + this.type = type; + this.adsRequest = adsRequest; + this.userRequestContext = userRequestContext; + }; + AdsManagerLoadedEvent.prototype = { + getAdsManager: function getAdsManager() { + return manager; + }, + getUserRequestContext() { + if (this.userRequestContext) { + return this.userRequestContext; + } + return {}; + } + }; + AdsManagerLoadedEvent.Type = { + ADS_MANAGER_LOADED: "adsManagerLoaded" + }; + var AdsLoader = EventHandler; + AdsLoader.prototype.settings = new ImaSdkSettings; + AdsLoader.prototype.contentComplete = noopFunc; + AdsLoader.prototype.destroy = noopFunc; + AdsLoader.prototype.getSettings = function() { + return this.settings; + }; + AdsLoader.prototype.getVersion = function() { + return VERSION; + }; + AdsLoader.prototype.requestAds = function(adsRequest, userRequestContext) { + var _this = this; + requestAnimationFrame((function() { + var {ADS_MANAGER_LOADED: ADS_MANAGER_LOADED} = AdsManagerLoadedEvent.Type; + var event = new ima.AdsManagerLoadedEvent(ADS_MANAGER_LOADED, adsRequest, userRequestContext); + _this._dispatch(event); + })); + var e = new ima.AdError("adPlayError", 1205, 1205, "The browser prevented playback initiated without user interaction.", adsRequest, userRequestContext); + requestAnimationFrame((function() { + _this._dispatch(new ima.AdErrorEvent(e)); + })); + }; + var AdsRenderingSettings = noopFunc; + var AdsRequest = function AdsRequest() {}; + AdsRequest.prototype = { + setAdWillAutoPlay: noopFunc, + setAdWillPlayMuted: noopFunc, + setContinuousPlayback: noopFunc + }; + var AdPodInfo = function AdPodInfo() {}; + AdPodInfo.prototype = { + getAdPosition: function getAdPosition() { + return 1; + }, + getIsBumper: function getIsBumper() { + return false; + }, + getMaxDuration: function getMaxDuration() { + return -1; + }, + getPodIndex: function getPodIndex() { + return 1; + }, + getTimeOffset: function getTimeOffset() { + return 0; + }, + getTotalAds: function getTotalAds() { + return 1; + } + }; + var UniversalAdIdInfo = function UniversalAdIdInfo() {}; + UniversalAdIdInfo.prototype.getAdIdRegistry = function() { + return ""; + }; + UniversalAdIdInfo.prototype.getAdIsValue = function() { + return ""; + }; + var Ad = function Ad() {}; + Ad.prototype = { + pi: new AdPodInfo, + getAdId: function getAdId() { + return ""; + }, + getAdPodInfo() { + return this.pi; + }, + getAdSystem: function getAdSystem() { + return ""; + }, + getAdvertiserName: function getAdvertiserName() { + return ""; + }, + getApiFramework: function getApiFramework() { + return null; + }, + getCompanionAds: function getCompanionAds() { + return []; + }, + getContentType: function getContentType() { + return ""; + }, + getCreativeId: function getCreativeId() { + return ""; + }, + getCreativeAdId: function getCreativeAdId() { + return ""; + }, + getDealId: function getDealId() { + return ""; + }, + getDescription: function getDescription() { + return ""; + }, + getDuration: function getDuration() { + return 8.5; + }, + getHeight: function getHeight() { + return 0; + }, + getMediaUrl: function getMediaUrl() { + return null; + }, + getMinSuggestedDuration: function getMinSuggestedDuration() { + return -2; + }, + getSkipTimeOffset: function getSkipTimeOffset() { + return -1; + }, + getSurveyUrl: function getSurveyUrl() { + return null; + }, + getTitle: function getTitle() { + return ""; + }, + getTraffickingParametersString: function getTraffickingParametersString() { + return ""; + }, + getUiElements: function getUiElements() { + return [ "" ]; + }, + getUniversalAdIdRegistry: function getUniversalAdIdRegistry() { + return "unknown"; + }, + getUniversalAdIds: function getUniversalAdIds() { + return [ new UniversalAdIdInfo ]; + }, + getUniversalAdIdValue: function getUniversalAdIdValue() { + return "unknown"; + }, + getVastMediaBitrate: function getVastMediaBitrate() { + return 0; + }, + getVastMediaHeight: function getVastMediaHeight() { + return 0; + }, + getVastMediaWidth: function getVastMediaWidth() { + return 0; + }, + getWidth: function getWidth() { + return 0; + }, + getWrapperAdIds: function getWrapperAdIds() { + return [ "" ]; + }, + getWrapperAdSystems: function getWrapperAdSystems() { + return [ "" ]; + }, + getWrapperCreativeIds: function getWrapperCreativeIds() { + return [ "" ]; + }, + isLinear: function isLinear() { + return true; + }, + isSkippable() { + return true; + } + }; + var CompanionAd = function CompanionAd() {}; + CompanionAd.prototype = { + getAdSlotId: function getAdSlotId() { + return ""; + }, + getContent: function getContent() { + return ""; + }, + getContentType: function getContentType() { + return ""; + }, + getHeight: function getHeight() { + return 1; + }, + getWidth: function getWidth() { + return 1; + } + }; + var AdError = function AdError(type, code, vast, message, adsRequest, userRequestContext) { + this.errorCode = code; + this.message = message; + this.type = type; + this.adsRequest = adsRequest; + this.userRequestContext = userRequestContext; + this.getErrorCode = function() { + return this.errorCode; + }; + this.getInnerError = function() { + return null; + }; + this.getMessage = function() { + return this.message; + }; + this.getType = function() { + return this.type; + }; + this.getVastErrorCode = function() { + return this.vastErrorCode; + }; + this.toString = function() { + return `AdError ${this.errorCode}: ${this.message}`; + }; + }; + AdError.ErrorCode = {}; + AdError.Type = {}; + var isEngadget = function isEngadget() { + try { + for (var _i3 = 0, _Object$values = Object.values(window.vidible._getContexts()); _i3 < _Object$values.length; _i3++) { + var _ctx$getPlayer; + var ctx = _Object$values[_i3]; + if ((_ctx$getPlayer = ctx.getPlayer()) !== null && _ctx$getPlayer !== void 0 && (_ctx$getPlayer = _ctx$getPlayer.div) !== null && _ctx$getPlayer !== void 0 && _ctx$getPlayer.innerHTML.includes("www.engadget.com")) { + return true; + } + } + } catch (e) {} + return false; + }; + var currentAd = isEngadget() ? undefined : new Ad; + var AdEvent = function AdEvent(type) { + this.type = type; + }; + AdEvent.prototype = { + getAd: function getAd() { + return currentAd; + }, + getAdData: function getAdData() {} + }; + AdEvent.Type = { + AD_BREAK_READY: "adBreakReady", + AD_BUFFERING: "adBuffering", + AD_CAN_PLAY: "adCanPlay", + AD_METADATA: "adMetadata", + AD_PROGRESS: "adProgress", + ALL_ADS_COMPLETED: "allAdsCompleted", + CLICK: "click", + COMPLETE: "complete", + CONTENT_PAUSE_REQUESTED: "contentPauseRequested", + CONTENT_RESUME_REQUESTED: "contentResumeRequested", + DURATION_CHANGE: "durationChange", + EXPANDED_CHANGED: "expandedChanged", + FIRST_QUARTILE: "firstQuartile", + IMPRESSION: "impression", + INTERACTION: "interaction", + LINEAR_CHANGE: "linearChange", + LINEAR_CHANGED: "linearChanged", + LOADED: "loaded", + LOG: "log", + MIDPOINT: "midpoint", + PAUSED: "pause", + RESUMED: "resume", + SKIPPABLE_STATE_CHANGED: "skippableStateChanged", + SKIPPED: "skip", + STARTED: "start", + THIRD_QUARTILE: "thirdQuartile", + USER_CLOSE: "userClose", + VIDEO_CLICKED: "videoClicked", + VIDEO_ICON_CLICKED: "videoIconClicked", + VIEWABLE_IMPRESSION: "viewable_impression", + VOLUME_CHANGED: "volumeChange", + VOLUME_MUTED: "mute" + }; + var AdErrorEvent = function AdErrorEvent(error) { + this.error = error; + this.type = "adError"; + this.getError = function() { + return this.error; + }; + this.getUserRequestContext = function() { + var _this$error; + if ((_this$error = this.error) !== null && _this$error !== void 0 && _this$error.userRequestContext) { + return this.error.userRequestContext; + } + return {}; + }; + }; + AdErrorEvent.Type = { + AD_ERROR: "adError" + }; + var CustomContentLoadedEvent = function CustomContentLoadedEvent() {}; + CustomContentLoadedEvent.Type = { + CUSTOM_CONTENT_LOADED: "deprecated-event" + }; + var CompanionAdSelectionSettings = function CompanionAdSelectionSettings() {}; + CompanionAdSelectionSettings.CreativeType = { + ALL: "All", + FLASH: "Flash", + IMAGE: "Image" + }; + CompanionAdSelectionSettings.ResourceType = { + ALL: "All", + HTML: "Html", + IFRAME: "IFrame", + STATIC: "Static" + }; + CompanionAdSelectionSettings.SizeCriteria = { + IGNORE: "IgnoreSize", + SELECT_EXACT_MATCH: "SelectExactMatch", + SELECT_NEAR_MATCH: "SelectNearMatch" + }; + var AdCuePoints = function AdCuePoints() {}; + AdCuePoints.prototype = { + getCuePoints: function getCuePoints() { + return []; + }, + getAdIdRegistry: function getAdIdRegistry() { + return ""; + }, + getAdIdValue: function getAdIdValue() { + return ""; + } + }; + var AdProgressData = noopFunc; + Object.assign(ima, { + AdCuePoints: AdCuePoints, + AdDisplayContainer: AdDisplayContainer, + AdError: AdError, + AdErrorEvent: AdErrorEvent, + AdEvent: AdEvent, + AdPodInfo: AdPodInfo, + AdProgressData: AdProgressData, + AdsLoader: AdsLoader, + AdsManager: manager, + AdsManagerLoadedEvent: AdsManagerLoadedEvent, + AdsRenderingSettings: AdsRenderingSettings, + AdsRequest: AdsRequest, + CompanionAd: CompanionAd, + CompanionAdSelectionSettings: CompanionAdSelectionSettings, + CustomContentLoadedEvent: CustomContentLoadedEvent, + gptProxyInstance: {}, + ImaSdkSettings: ImaSdkSettings, + OmidAccessMode: { + DOMAIN: "domain", + FULL: "full", + LIMITED: "limited" + }, + OmidVerificationVendor: { + 1: "OTHER", + 2: "MOAT", + 3: "DOUBLEVERIFY", + 4: "INTEGRAL_AD_SCIENCE", + 5: "PIXELATE", + 6: "NIELSEN", + 7: "COMSCORE", + 8: "MEETRICS", + 9: "GOOGLE", + OTHER: 1, + MOAT: 2, + DOUBLEVERIFY: 3, + INTEGRAL_AD_SCIENCE: 4, + PIXELATE: 5, + NIELSEN: 6, + COMSCORE: 7, + MEETRICS: 8, + GOOGLE: 9 + }, + settings: new ImaSdkSettings, + UiElements: { + AD_ATTRIBUTION: "adAttribution", + COUNTDOWN: "countdown" + }, + UniversalAdIdInfo: UniversalAdIdInfo, + VERSION: VERSION, + ViewMode: { + FULLSCREEN: "fullscreen", + NORMAL: "normal" + } + }); + if (!window.google) { + window.google = {}; + } + if ((_window$google$ima = window.google.ima) !== null && _window$google$ima !== void 0 && _window$google$ima.dai) { + ima.dai = window.google.ima.dai; + } + window.google.ima = ima; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function logMessage(e, o) { + var r = arguments.length > 2 && void 0 !== arguments[2] && arguments[2], a = !(arguments.length > 3 && void 0 !== arguments[3]) || arguments[3], {name: n, verbose: g} = e; + if (r || g) { + var i = console.log; + a ? i(`${n}: ${o}`) : Array.isArray(o) ? i(`${n}:`, ...o) : i(`${n}:`, o); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + GoogleIma3.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "google-ima3", + args: [] + }, []); + file: google-ima3.js + +- title: googlesyndication-adsbygoogle + comment: Mocks Google AdSense API. + aliases: + - ubo-googlesyndication_adsbygoogle.js + - googlesyndication_adsbygoogle.js + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function GoogleSyndicationAdsByGoogle(source) { + window.adsbygoogle = { + loaded: true, + push(arg) { + if (typeof this.length === "undefined") { + this.length = 0; + this.length += 1; + } + if (arg !== null && arg instanceof Object && arg.constructor.name === "Object") { + for (var _i = 0, _Object$keys = Object.keys(arg); _i < _Object$keys.length; _i++) { + var key = _Object$keys[_i]; + if (typeof arg[key] === "function") { + try { + arg[key].call(this, {}); + } catch (_unused) {} + } + } + } + } + }; + var adElems = document.querySelectorAll(".adsbygoogle"); + var css = "height:1px!important;max-height:1px!important;max-width:1px!important;width:1px!important;"; + var statusAttrName = "data-adsbygoogle-status"; + var ASWIFT_IFRAME_MARKER = "aswift_"; + var GOOGLE_ADS_IFRAME_MARKER = "google_ads_iframe_"; + var executed = false; + for (var i = 0; i < adElems.length; i += 1) { + var adElemChildNodes = adElems[i].childNodes; + var childNodesQuantity = adElemChildNodes.length; + var areIframesDefined = false; + if (childNodesQuantity > 0) { + areIframesDefined = childNodesQuantity === 2 && adElemChildNodes[0].nodeName.toLowerCase() === "iframe" && adElemChildNodes[0].id.includes(ASWIFT_IFRAME_MARKER) && adElemChildNodes[1].nodeName.toLowerCase() === "iframe" && adElemChildNodes[1].id.includes(GOOGLE_ADS_IFRAME_MARKER); + } + if (!areIframesDefined) { + adElems[i].setAttribute(statusAttrName, "done"); + var aswiftIframe = document.createElement("iframe"); + aswiftIframe.id = `${ASWIFT_IFRAME_MARKER}${i}`; + aswiftIframe.style = css; + adElems[i].appendChild(aswiftIframe); + var innerAswiftIframe = document.createElement("iframe"); + aswiftIframe.contentWindow.document.body.appendChild(innerAswiftIframe); + var googleadsIframe = document.createElement("iframe"); + googleadsIframe.id = `${GOOGLE_ADS_IFRAME_MARKER}${i}`; + googleadsIframe.style = css; + adElems[i].appendChild(googleadsIframe); + var innerGoogleadsIframe = document.createElement("iframe"); + googleadsIframe.contentWindow.document.body.appendChild(innerGoogleadsIframe); + executed = true; + } + } + if (executed) { + hit(source); + } + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + GoogleSyndicationAdsByGoogle.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "googlesyndication-adsbygoogle", + args: [] + }, []); + file: googlesyndication-adsbygoogle.js + +- title: googletagservices-gpt + comment: Mocks Google Publisher Tag API. + aliases: + - ubo-googletagservices_gpt.js + - googletagservices_gpt.js + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function GoogleTagServicesGpt(source) { + var slots = new Map; + var slotsById = new Map; + var slotsPerPath = new Map; + var slotCreatives = new Map; + var eventCallbacks = new Map; + var gTargeting = new Map; + var addEventListener = function addEventListener(name, listener) { + if (!eventCallbacks.has(name)) { + eventCallbacks.set(name, new Set); + } + eventCallbacks.get(name).add(listener); + return this; + }; + var removeEventListener = function removeEventListener(name, listener) { + if (eventCallbacks.has(name)) { + return eventCallbacks.get(name).delete(listener); + } + return false; + }; + var fireSlotEvent = function fireSlotEvent(name, slot) { + return new Promise((function(resolve) { + requestAnimationFrame((function() { + var size = [ 0, 0 ]; + var callbacksSet = eventCallbacks.get(name) || []; + var callbackArray = Array.from(callbacksSet); + for (var i = 0; i < callbackArray.length; i += 1) { + callbackArray[i]({ + isEmpty: true, + size: size, + slot: slot + }); + } + resolve(); + })); + })); + }; + var emptySlotElement = function emptySlotElement(slot) { + var node = document.getElementById(slot.getSlotElementId()); + while (node !== null && node !== void 0 && node.lastChild) { + node.lastChild.remove(); + } + }; + var recreateIframeForSlot = function recreateIframeForSlot(slot) { + var _document$getElementB; + var eid = `google_ads_iframe_${slot.getId()}`; + (_document$getElementB = document.getElementById(eid)) === null || _document$getElementB === void 0 || _document$getElementB.remove(); + var node = document.getElementById(slot.getSlotElementId()); + if (node) { + var f = document.createElement("iframe"); + f.id = eid; + f.srcdoc = "<body></body>"; + f.style = "position:absolute; width:0; height:0; left:0; right:0; z-index:-1; border:0"; + f.setAttribute("width", 0); + f.setAttribute("height", 0); + f.setAttribute("data-load-complete", true); + f.setAttribute("data-google-container-id", true); + f.setAttribute("sandbox", ""); + node.appendChild(f); + } + }; + var displaySlot = function displaySlot(slot) { + if (!slot) { + return; + } + var id = slot.getSlotElementId(); + if (!document.getElementById(id)) { + return; + } + var parent = document.getElementById(id); + if (parent) { + parent.appendChild(document.createElement("div")); + } + emptySlotElement(slot); + recreateIframeForSlot(slot); + fireSlotEvent("slotRenderEnded", slot); + fireSlotEvent("slotRequested", slot); + fireSlotEvent("slotResponseReceived", slot); + fireSlotEvent("slotOnload", slot); + fireSlotEvent("impressionViewable", slot); + }; + var companionAdsService = { + addEventListener: addEventListener, + removeEventListener: removeEventListener, + enableSyncLoading: noopFunc, + setRefreshUnfilledSlots: noopFunc, + getSlots: noopArray + }; + var contentService = { + addEventListener: addEventListener, + removeEventListener: removeEventListener, + setContent: noopFunc + }; + function PassbackSlot() {} + PassbackSlot.prototype.display = noopFunc; + PassbackSlot.prototype.get = noopNull; + PassbackSlot.prototype.set = noopThis; + PassbackSlot.prototype.setClickUrl = noopThis; + PassbackSlot.prototype.setTagForChildDirectedTreatment = noopThis; + PassbackSlot.prototype.setTargeting = noopThis; + PassbackSlot.prototype.updateTargetingFromMap = noopThis; + function SizeMappingBuilder() {} + SizeMappingBuilder.prototype.addSize = noopThis; + SizeMappingBuilder.prototype.build = noopNull; + var getTargetingValue = function getTargetingValue(v) { + if (typeof v === "string") { + return [ v ]; + } + try { + return Array.prototype.flat.call(v); + } catch (_unused) {} + return []; + }; + var updateTargeting = function updateTargeting(targeting, map) { + if (typeof map === "object") { + for (var key in map) { + if (Object.prototype.hasOwnProperty.call(map, key)) { + targeting.set(key, getTargetingValue(map[key])); + } + } + } + }; + var defineSlot = function defineSlot(adUnitPath, creatives, optDiv) { + if (slotsById.has(optDiv)) { + var _document$getElementB2; + (_document$getElementB2 = document.getElementById(optDiv)) === null || _document$getElementB2 === void 0 || _document$getElementB2.remove(); + return slotsById.get(optDiv); + } + var attributes = new Map; + var targeting = new Map; + var exclusions = new Set; + var response = { + advertiserId: undefined, + campaignId: undefined, + creativeId: undefined, + creativeTemplateId: undefined, + lineItemId: undefined + }; + var sizes = [ { + getHeight: function getHeight() { + return 2; + }, + getWidth: function getWidth() { + return 2; + } + } ]; + var num = (slotsPerPath.get(adUnitPath) || 0) + 1; + slotsPerPath.set(adUnitPath, num); + var id = `${adUnitPath}_${num}`; + var clickUrl = ""; + var collapseEmptyDiv = null; + var services = new Set; + var config = {}; + var slot = { + addService(e) { + services.add(e); + return slot; + }, + clearCategoryExclusions: noopThis, + clearTargeting(k) { + if (k === undefined) { + targeting.clear(); + } else { + targeting.delete(k); + } + }, + defineSizeMapping(mapping) { + slotCreatives.set(optDiv, mapping); + return this; + }, + get: function get(k) { + return attributes.get(k); + }, + getAdUnitPath: function getAdUnitPath() { + return adUnitPath; + }, + getAttributeKeys: function getAttributeKeys() { + return Array.from(attributes.keys()); + }, + getCategoryExclusions: function getCategoryExclusions() { + return Array.from(exclusions); + }, + getClickUrl: function getClickUrl() { + return clickUrl; + }, + getCollapseEmptyDiv: function getCollapseEmptyDiv() { + return collapseEmptyDiv; + }, + getConfig: function getConfig(keys) { + var configKeys = Array.isArray(keys) ? keys : [ keys ]; + var googleTagServicesConfig = {}; + for (var i = 0; i < configKeys.length; i += 1) { + var key = configKeys[i]; + if (key === "clickUrl") { + googleTagServicesConfig[key] = clickUrl; + } else if (key === "targeting") { + googleTagServicesConfig[key] = targeting; + } else { + googleTagServicesConfig[key] = config[key]; + } + } + return Object.freeze(googleTagServicesConfig); + }, + getContentUrl: function getContentUrl() { + return ""; + }, + getDivStartsCollapsed: function getDivStartsCollapsed() { + return null; + }, + getDomId: function getDomId() { + return optDiv; + }, + getEscapedQemQueryId: function getEscapedQemQueryId() { + return ""; + }, + getFirstLook: function getFirstLook() { + return 0; + }, + getId: function getId() { + return id; + }, + getHtml: function getHtml() { + return ""; + }, + getName: function getName() { + return id; + }, + getOutOfPage: function getOutOfPage() { + return false; + }, + getResponseInformation: function getResponseInformation() { + return response; + }, + getServices: function getServices() { + return Array.from(services); + }, + getSizes: function getSizes() { + return sizes; + }, + getSlotElementId: function getSlotElementId() { + return optDiv; + }, + getSlotId: function getSlotId() { + return slot; + }, + getTargeting: function getTargeting(k) { + return targeting.get(k) || gTargeting.get(k) || []; + }, + getTargetingKeys: function getTargetingKeys() { + return Array.from(new Set(Array.of(...gTargeting.keys(), ...targeting.keys()))); + }, + getTargetingMap: function getTargetingMap() { + return Object.assign(Object.fromEntries(gTargeting.entries()), Object.fromEntries(targeting.entries())); + }, + set(k, v) { + attributes.set(k, v); + return slot; + }, + setCategoryExclusion(e) { + exclusions.add(e); + return slot; + }, + setClickUrl(u) { + clickUrl = u; + return slot; + }, + setCollapseEmptyDiv(v) { + collapseEmptyDiv = !!v; + return slot; + }, + setConfig(obj) { + try { + var entries = Object.entries(obj); + for (var i = 0; i < entries.length; i += 1) { + var entry = entries[i]; + var key = entry[0]; + var value = entry[1]; + if (key === "clickUrl") { + clickUrl = value; + } else if (key === "targeting") { + updateTargeting(targeting, value); + } else { + config[key] = value; + } + } + } catch (ex) {} + }, + setSafeFrameConfig: noopThis, + setTagForChildDirectedTreatment: noopThis, + setTargeting(k, v) { + targeting.set(k, getTargetingValue(v)); + return slot; + }, + toString: function toString() { + return id; + }, + updateTargetingFromMap(map) { + updateTargeting(targeting, map); + return slot; + } + }; + slots.set(adUnitPath, slot); + slotsById.set(optDiv, slot); + slotCreatives.set(optDiv, creatives); + return slot; + }; + var initialLoadDisabled = false; + var pubAdsService = { + addEventListener: addEventListener, + removeEventListener: removeEventListener, + clear: noopFunc, + clearCategoryExclusions: noopThis, + clearTagForChildDirectedTreatment: noopThis, + clearTargeting(k) { + if (k === undefined) { + gTargeting.clear(); + } else { + gTargeting.delete(k); + } + }, + collapseEmptyDivs: noopFunc, + defineOutOfPagePassback() { + return new PassbackSlot; + }, + definePassback() { + return new PassbackSlot; + }, + disableInitialLoad() { + initialLoadDisabled = true; + }, + display: noopFunc, + enableAsyncRendering: noopFunc, + enableLazyLoad: noopFunc, + enableSingleRequest: noopFunc, + enableSyncRendering: noopFunc, + enableVideoAds: noopFunc, + get: noopNull, + getAttributeKeys: noopArray, + getTargeting: noopArray, + getTargetingKeys: noopArray, + getSlots: noopArray, + isInitialLoadDisabled: function isInitialLoadDisabled() { + return initialLoadDisabled; + }, + refresh: noopFunc, + set: noopThis, + setCategoryExclusion: noopThis, + setCentering: noopFunc, + setCookieOptions: noopThis, + setForceSafeFrame: noopThis, + setLocation: noopThis, + setPrivacySettings: noopThis, + setPublisherProvidedId: noopThis, + setRequestNonPersonalizedAds: noopThis, + setSafeFrameConfig: noopThis, + setTagForChildDirectedTreatment: noopThis, + setTargeting: noopThis, + setVideoContent: noopThis, + updateCorrelator: noopFunc + }; + var config = {}; + var {googletag: googletag = {}} = window; + var {cmd: cmd = []} = googletag; + googletag.apiReady = true; + googletag.cmd = []; + googletag.cmd.push = function(a) { + try { + a(); + } catch (ex) {} + return 1; + }; + googletag.companionAds = function() { + return companionAdsService; + }; + googletag.content = function() { + return contentService; + }; + googletag.defineOutOfPageSlot = defineSlot; + googletag.defineSlot = defineSlot; + googletag.destroySlots = function() { + slots.clear(); + slotsById.clear(); + }; + googletag.disablePublisherConsole = noopFunc; + googletag.display = function(arg) { + var id; + if (arg !== null && arg !== void 0 && arg.getSlotElementId) { + id = arg.getSlotElementId(); + } else if (arg !== null && arg !== void 0 && arg.nodeType) { + id = arg.id; + } else { + id = String(arg); + } + displaySlot(slotsById.get(id)); + }; + googletag.enableServices = noopFunc; + googletag.getConfig = function(keys) { + var configKeys = Array.isArray(keys) ? keys : [ keys ]; + var googleTagServicesConfig = {}; + for (var i = 0; i < configKeys.length; i += 1) { + var key = configKeys[i]; + if (key === "disableInitialLoad") { + googleTagServicesConfig[key] = initialLoadDisabled; + } else if (key === "targeting") { + googleTagServicesConfig[key] = gTargeting; + } else { + googleTagServicesConfig[key] = config[key]; + } + } + return Object.freeze(googleTagServicesConfig); + }; + googletag.getVersion = noopStr; + googletag.pubads = function() { + return pubAdsService; + }; + googletag.pubadsReady = true; + googletag.setAdIframeTitle = noopFunc; + googletag.setConfig = function(obj) { + try { + var entries = Object.entries(obj); + for (var i = 0; i < entries.length; i += 1) { + var entry = entries[i]; + var key = entry[0]; + var value = entry[1]; + if (key === "disableInitialLoad") { + initialLoadDisabled = !!value; + } else if (key === "targeting") { + updateTargeting(gTargeting, value); + } else { + config[key] = value; + } + } + } catch (ex) {} + }; + googletag.sizeMapping = function() { + return new SizeMappingBuilder; + }; + window.googletag = googletag; + while (cmd.length !== 0) { + googletag.cmd.push(cmd.shift()); + } + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopThis() { + return this; + } + function noopNull() { + return null; + } + function noopArray() { + return []; + } + function noopStr() { + return ""; + } + function trueFunc() { + return !0; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + GoogleTagServicesGpt.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "googletagservices-gpt", + args: [] + }, []); + file: googletagservices-gpt.js + +- title: matomo + comment: Mocks the piwik.js file of Matomo (formerly Piwik). + aliases: [] + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function Matomo(source) { + var Tracker = function Tracker() {}; + Tracker.prototype.setDoNotTrack = noopFunc; + Tracker.prototype.setDomains = noopFunc; + Tracker.prototype.setCustomDimension = noopFunc; + Tracker.prototype.trackPageView = noopFunc; + var AsyncTracker = function AsyncTracker() {}; + AsyncTracker.prototype.addListener = noopFunc; + var matomoWrapper = { + getTracker: Tracker, + getAsyncTracker: AsyncTracker + }; + window.Piwik = matomoWrapper; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + Matomo.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "matomo", + args: [] + }, []); + file: matomo.js + +- title: metrika-yandex-tag + comment: Mocks Yandex Metrika API. + aliases: [] + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function metrikaYandexTag(source) { + var asyncCallbackFromOptions = function asyncCallbackFromOptions(id, param) { + var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {}; + var {callback: callback} = options; + var {ctx: ctx} = options; + if (typeof callback === "function") { + callback = ctx !== undefined ? callback.bind(ctx) : callback; + setTimeout((function() { + return callback(); + })); + } + }; + var addFileExtension = noopFunc; + var extLink = asyncCallbackFromOptions; + var file = asyncCallbackFromOptions; + var getClientID = function getClientID(id, cb) { + if (!cb) { + return; + } + setTimeout(cb(null)); + }; + var hitFunc = asyncCallbackFromOptions; + var notBounce = asyncCallbackFromOptions; + var params = noopFunc; + var reachGoal = function reachGoal(id, target, params, callback, ctx) { + asyncCallbackFromOptions(null, null, { + callback: callback, + ctx: ctx + }); + }; + var setUserID = noopFunc; + var userParams = noopFunc; + var destruct = noopFunc; + var api = { + addFileExtension: addFileExtension, + extLink: extLink, + file: file, + getClientID: getClientID, + hit: hitFunc, + notBounce: notBounce, + params: params, + reachGoal: reachGoal, + setUserID: setUserID, + userParams: userParams, + destruct: destruct + }; + function init(id) { + window[`yaCounter${id}`] = api; + document.dispatchEvent(new Event(`yacounter${id}inited`)); + } + function ym(id, funcName) { + if (funcName === "init") { + return init(id); + } + for (var _len = arguments.length, args = new Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) { + args[_key - 2] = arguments[_key]; + } + return api[funcName] && api[funcName](id, ...args); + } + if (typeof window.ym === "undefined") { + window.ym = ym; + ym.a = []; + } else if (window.ym && window.ym.a) { + ym.a = window.ym.a; + window.ym = ym; + window.ym.a.forEach((function(params) { + var id = params[0]; + init(id); + })); + } + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + metrikaYandexTag.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "metrika-yandex-tag", + args: [] + }, []); + file: metrika-yandex-tag.js + +- title: metrika-yandex-watch + comment: Mocks the old Yandex Metrika API. + aliases: [] + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function metrikaYandexWatch(source) { + var cbName = "yandex_metrika_callbacks"; + var asyncCallbackFromOptions = function asyncCallbackFromOptions() { + var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; + var {callback: callback} = options; + var {ctx: ctx} = options; + if (typeof callback === "function") { + callback = ctx !== undefined ? callback.bind(ctx) : callback; + setTimeout((function() { + return callback(); + })); + } + }; + function Metrika() {} + Metrika.counters = noopArray; + Metrika.prototype.addFileExtension = noopFunc; + Metrika.prototype.getClientID = noopFunc; + Metrika.prototype.setUserID = noopFunc; + Metrika.prototype.userParams = noopFunc; + Metrika.prototype.params = noopFunc; + Metrika.prototype.counters = noopArray; + Metrika.prototype.extLink = function(url, options) { + asyncCallbackFromOptions(options); + }; + Metrika.prototype.file = function(url, options) { + asyncCallbackFromOptions(options); + }; + Metrika.prototype.hit = function(url, options) { + asyncCallbackFromOptions(options); + }; + Metrika.prototype.reachGoal = function(target, params, cb, ctx) { + asyncCallbackFromOptions({ + callback: cb, + ctx: ctx + }); + }; + Metrika.prototype.notBounce = asyncCallbackFromOptions; + if (window.Ya) { + window.Ya.Metrika = Metrika; + } else { + window.Ya = { + Metrika: Metrika + }; + } + if (window[cbName] && Array.isArray(window[cbName])) { + window[cbName].forEach((function(func) { + if (typeof func === "function") { + func(); + } + })); + } + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopArray() { + return []; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + metrikaYandexWatch.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "metrika-yandex-watch", + args: [] + }, []); + file: metrika-yandex-watch.js + +- title: naver-wcslog + comment: Mocks wcslog.js of Naver Analytics. + aliases: [] + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function NaverWcslog(source) { + window.wcs_add = {}; + window.wcs_do = noopFunc; + window.wcs = { + inflow: noopFunc + }; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + NaverWcslog.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "naver-wcslog", + args: [] + }, []); + file: naver-wcslog.js + +- title: noeval + comment: >- + Redirects request to the source which sets static properties to PopAds and + popns objects. + aliases: + - noeval.js + - silent-noeval.js + - ubo-noeval.js + - ubo-silent-noeval.js + - ubo-noeval + - ubo-silent-noeval + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function noeval(source) { + window.eval = function evalWrapper(s) { + hit(source); + logMessage(source, `AdGuard has prevented eval:\n${s}`, true); + }.bind(); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function logMessage(e, o) { + var r = arguments.length > 2 && void 0 !== arguments[2] && arguments[2], a = !(arguments.length > 3 && void 0 !== arguments[3]) || arguments[3], {name: n, verbose: g} = e; + if (r || g) { + var i = console.log; + a ? i(`${n}: ${o}`) : Array.isArray(o) ? i(`${n}:`, ...o) : i(`${n}:`, o); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + noeval.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "noeval", + args: [] + }, []); + file: noeval.js + +- title: pardot-1.0 + comment: Mocks the pd.js file of Salesforce. + aliases: [] + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function Pardot(source) { + window.piVersion = "1.0.2"; + window.piScriptNum = 0; + window.piScriptObj = []; + window.checkNamespace = noopFunc; + window.getPardotUrl = noopStr; + window.piGetParameter = noopNull; + window.piSetCookie = noopFunc; + window.piGetCookie = noopStr; + function piTracker() { + window.pi = { + tracker: { + visitor_id: "", + visitor_id_sign: "", + pi_opt_in: "", + campaign_id: "" + } + }; + window.piScriptNum += 1; + } + window.piResponse = noopFunc; + window.piTracker = piTracker; + piTracker(); + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopStr() { + return ""; + } + function noopNull() { + return null; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + Pardot.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "pardot-1.0", + args: [] + }, []); + file: pardot-1.0.js + +- title: prebid-ads + comment: 'Sets predefined constants on a page:' + aliases: + - ubo-prebid-ads.js + - prebid-ads.js + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function prebidAds(source) { + window.canRunAds = true; + window.isAdBlockActive = false; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + prebidAds.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "prebid-ads", + args: [] + }, []); + file: prebid-ads.js + +- title: prebid + comment: Mocks the prebid.js header bidding suit. + aliases: [] + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function Prebid(source) { + var pushFunction = function pushFunction(arg) { + if (typeof arg === "function") { + try { + arg.call(); + } catch (ex) {} + } + }; + var pbjsWrapper = { + addAdUnits() {}, + adServers: { + dfp: { + buildVideoUrl: noopStr + } + }, + adUnits: [], + aliasBidder() {}, + cmd: [], + enableAnalytics() {}, + getHighestCpmBids: noopArray, + libLoaded: true, + que: [], + requestBids(arg) { + if (arg instanceof Object && arg.bidsBackHandler) { + try { + arg.bidsBackHandler.call(); + } catch (ex) {} + } + }, + removeAdUnit() {}, + setBidderConfig() {}, + setConfig() {}, + setTargetingForGPTAsync() {} + }; + pbjsWrapper.cmd.push = pushFunction; + pbjsWrapper.que.push = pushFunction; + window.pbjs = pbjsWrapper; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopStr() { + return ""; + } + function noopArray() { + return []; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + Prebid.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "prebid", + args: [] + }, []); + file: prebid.js + +- title: prevent-bab + comment: Prevents BlockAdblock script from detecting an ad blocker. + aliases: [] + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function preventBab$1(source) { + var nativeSetTimeout = window.setTimeout; + var babRegex = /\.bab_elementid.$/; + var timeoutWrapper = function timeoutWrapper(callback) { + if (typeof callback !== "string" || !babRegex.test(callback)) { + for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { + args[_key - 1] = arguments[_key]; + } + return nativeSetTimeout.apply(window, [ callback, ...args ]); + } + hit(source); + }; + window.setTimeout = timeoutWrapper; + var signatures = [ [ "blockadblock" ], [ "babasbm" ], [ /getItem\('babn'\)/ ], [ "getElementById", "String.fromCharCode", "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789", "charAt", "DOMContentLoaded", "AdBlock", "addEventListener", "doScroll", "fromCharCode", "<<2|r>>4", "sessionStorage", "clientWidth", "localStorage", "Math", "random" ] ]; + var check = function check(str) { + if (typeof str !== "string") { + return false; + } + for (var i = 0; i < signatures.length; i += 1) { + var tokens = signatures[i]; + var match = 0; + for (var j = 0; j < tokens.length; j += 1) { + var token = tokens[j]; + var found = token instanceof RegExp ? token.test(str) : str.includes(token); + if (found) { + match += 1; + } + } + if (match / tokens.length >= .8) { + return true; + } + } + return false; + }; + var nativeEval = window.eval; + var evalWrapper = function evalWrapper(str) { + if (!check(str)) { + return nativeEval(str); + } + hit(source); + var bodyEl = document.body; + if (bodyEl) { + bodyEl.style.removeProperty("visibility"); + } + var el = document.getElementById("babasbmsgx"); + if (el) { + el.parentNode.removeChild(el); + } + }; + window.eval = evalWrapper.bind(window); + window.eval.toString = nativeEval.toString.bind(nativeEval); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + preventBab$1.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "prevent-bab", + args: [] + }, []); + file: prevent-bab.js + +- title: prevent-bab2 + comment: Prevents BlockAdblock script from detecting an ad blocker. + aliases: + - nobab2.js + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function preventBab2(source) { + var script = document.currentScript; + if (script === null) { + return; + } + var url = script.src; + if (typeof url !== "string") { + return; + } + var domainsStr = [ "adclixx\\.net", "adnetasia\\.com", "adtrackers\\.net", "bannertrack\\.net" ].join("|"); + var matchStr = `^https?://[\\w-]+\\.(${domainsStr})/.`; + var domainsRegex = new RegExp(matchStr); + if (domainsRegex.test(url) === false) { + return; + } + window.nH7eXzOsG = 858; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + preventBab2.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "prevent-bab2", + args: [] + }, []); + file: prevent-bab2.js + +- title: prevent-fab-3.2.0 + comment: Redirects fuckadblock script to the source js file. + aliases: + - nofab.js + - ubo-nofab.js + - fuckadblock.js-3.2.0 + - ubo-fuckadblock.js-3.2.0 + - ubo-nofab + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function preventFab(source) { + hit(source); + var Fab = function Fab() {}; + Fab.prototype.check = noopFunc; + Fab.prototype.clearEvent = noopFunc; + Fab.prototype.emitEvent = noopFunc; + Fab.prototype.on = function(a, b) { + if (!a) { + b(); + } + return this; + }; + Fab.prototype.onDetected = noopThis; + Fab.prototype.onNotDetected = function(a) { + a(); + return this; + }; + Fab.prototype.setOption = noopFunc; + Fab.prototype.options = { + set: noopFunc, + get: noopFunc + }; + var fab = new Fab; + var getSetFab = { + get() { + return Fab; + }, + set() {} + }; + var getsetfab = { + get() { + return fab; + }, + set() {} + }; + if (Object.prototype.hasOwnProperty.call(window, "FuckAdBlock")) { + window.FuckAdBlock = Fab; + } else { + Object.defineProperty(window, "FuckAdBlock", getSetFab); + } + if (Object.prototype.hasOwnProperty.call(window, "BlockAdBlock")) { + window.BlockAdBlock = Fab; + } else { + Object.defineProperty(window, "BlockAdBlock", getSetFab); + } + if (Object.prototype.hasOwnProperty.call(window, "SniffAdBlock")) { + window.SniffAdBlock = Fab; + } else { + Object.defineProperty(window, "SniffAdBlock", getSetFab); + } + if (Object.prototype.hasOwnProperty.call(window, "fuckAdBlock")) { + window.fuckAdBlock = fab; + } else { + Object.defineProperty(window, "fuckAdBlock", getsetfab); + } + if (Object.prototype.hasOwnProperty.call(window, "blockAdBlock")) { + window.blockAdBlock = fab; + } else { + Object.defineProperty(window, "blockAdBlock", getsetfab); + } + if (Object.prototype.hasOwnProperty.call(window, "sniffAdBlock")) { + window.sniffAdBlock = fab; + } else { + Object.defineProperty(window, "sniffAdBlock", getsetfab); + } + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopThis() { + return this; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + preventFab.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "prevent-fab-3.2.0", + args: [] + }, []); + file: prevent-fab-3.2.0.js + +- title: prevent-popads-net + comment: >- + Redirects request to the source which sets static properties to PopAds and + popns objects. + aliases: + - popads.net.js + - ubo-popads.net.js + - ubo-popads.net + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function preventPopadsNet(source) { + var rid = randomId(); + var throwError = function throwError() { + throw new ReferenceError(rid); + }; + delete window.PopAds; + delete window.popns; + Object.defineProperties(window, { + PopAds: { + set: throwError + }, + popns: { + set: throwError + } + }); + window.onerror = createOnErrorHandler(rid).bind(); + hit(source); + } + function createOnErrorHandler(r) { + var n = window.onerror; + return function(e) { + if ("string" == typeof e && e.includes(r)) return !0; + if (n instanceof Function) { + for (var t = arguments.length, o = new Array(t > 1 ? t - 1 : 0), i = 1; i < t; i++) o[i - 1] = arguments[i]; + return n.apply(window, [ e, ...o ]); + } + return !1; + }; + } + function randomId() { + return Math.random().toString(36).slice(2, 9); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + preventPopadsNet.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "prevent-popads-net", + args: [] + }, []); + file: prevent-popads-net.js + +- title: scorecardresearch-beacon + comment: Mocks Scorecard Research API. + aliases: + - ubo-scorecardresearch_beacon.js + - scorecardresearch_beacon.js + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function ScoreCardResearchBeacon(source) { + window.COMSCORE = { + purge() { + window._comscore = []; + }, + beacon() {} + }; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + ScoreCardResearchBeacon.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "scorecardresearch-beacon", + args: [] + }, []); + file: scorecardresearch-beacon.js + +- title: set-popads-dummy + comment: >- + Redirects request to the source which sets static properties to PopAds and + popns objects. + aliases: + - popads-dummy.js + - ubo-popads-dummy.js + - ubo-popads-dummy + contentType: application/javascript + content: |- + (function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function setPopadsDummy(source) { + delete window.PopAds; + delete window.popns; + Object.defineProperties(window, { + PopAds: { + get: function get() { + hit(source); + return {}; + } + }, + popns: { + get: function get() { + hit(source); + return {}; + } + } + }); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + setPopadsDummy.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } + })({ + name: "set-popads-dummy", + args: [] + }, []); + file: set-popads-dummy.js diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/1x1-transparent.gif b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/1x1-transparent.gif Binary files differnew file mode 100644 index 0000000..b3aa80d --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/1x1-transparent.gif diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/2x2-transparent.png b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/2x2-transparent.png Binary files differnew file mode 100644 index 0000000..3639dc7 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/2x2-transparent.png diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/32x32-transparent.png b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/32x32-transparent.png Binary files differnew file mode 100644 index 0000000..7bee0a0 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/32x32-transparent.png diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/3x2-transparent.png b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/3x2-transparent.png Binary files differnew file mode 100644 index 0000000..a056d86 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/3x2-transparent.png diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/amazon-apstag.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/amazon-apstag.js new file mode 100644 index 0000000..98b39c8 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/amazon-apstag.js @@ -0,0 +1,52 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function AmazonApstag(source) { + var apstagWrapper = { + fetchBids(a, b) { + if (typeof b === "function") { + b([]); + } + }, + init: noopFunc, + setDisplayBids: noopFunc, + targetingKeys: noopFunc + }; + window.apstag = apstagWrapper; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + AmazonApstag.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "amazon-apstag", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/ati-smarttag.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/ati-smarttag.js new file mode 100644 index 0000000..97fde28 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/ati-smarttag.js @@ -0,0 +1,112 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function ATInternetSmartTag(source) { + var setNoopFuncWrapper = { + set: noopFunc + }; + var sendNoopFuncWrapper = { + send: noopFunc + }; + var ecommerceWrapper = { + displayCart: { + products: setNoopFuncWrapper, + cart: setNoopFuncWrapper + }, + updateCart: { + cart: setNoopFuncWrapper + }, + displayProduct: { + products: setNoopFuncWrapper + }, + displayPageProduct: { + products: setNoopFuncWrapper + }, + addProduct: { + products: setNoopFuncWrapper + }, + removeProduct: { + products: setNoopFuncWrapper + } + }; + var tag = function tag() {}; + tag.prototype = { + setConfig: noopFunc, + setParam: noopFunc, + dispatch: noopFunc, + customVars: setNoopFuncWrapper, + publisher: setNoopFuncWrapper, + order: setNoopFuncWrapper, + click: sendNoopFuncWrapper, + clickListener: sendNoopFuncWrapper, + internalSearch: { + set: noopFunc, + send: noopFunc + }, + ecommerce: ecommerceWrapper, + identifiedVisitor: { + unset: noopFunc + }, + page: { + set: noopFunc, + send: noopFunc + }, + selfPromotion: { + add: noopFunc, + send: noopFunc + }, + privacy: { + setVisitorMode: noopFunc, + getVisitorMode: noopFunc, + hit: noopFunc + }, + richMedia: { + add: noopFunc, + send: noopFunc, + remove: noopFunc, + removeAll: noopFunc + } + }; + var smartTagWrapper = { + Tracker: { + Tag: tag + } + }; + window.ATInternet = smartTagWrapper; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + ATInternetSmartTag.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "ati-smarttag", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/click2load.html b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/click2load.html new file mode 100644 index 0000000..649734d --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/click2load.html @@ -0,0 +1,253 @@ +<!DOCTYPE html> +<html> + + <head> + <meta charset="utf-8"> + <title>AdGuard Click2Load</title> + <style> + html, + body, + .wrapper { + height: 100%; + } + + body { + margin: 0; + font-family: Roboto, "Open Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Ubuntu, Arial, sans-serif + } + + .wrapper { + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + } + + .content { + min-height: 160px; + padding: 50px 24px; + text-align: center; + } + + .logo { + background-image: url("data:image/svg+xml,%3Csvg fill='none' height='41' viewBox='0 0 41 41' width='41' xmlns='http://www.w3.org/2000/svg'%3E%3Cg clip-rule='evenodd' fill-rule='evenodd'%3E%3Cpath d='m20.4996.5c-6.2513 0-13.79186 1.43422-19.999594 4.59105 0 6.81785-.085687 23.80335 19.999594 35.40895 20.0856-11.6056 20.0004-28.5911 20.0004-35.40895-6.2082-3.15683-13.7488-4.59105-20.0004-4.59105z' fill='%2368bc71'/%3E%3Cpath d='m20.5.5c-.0001 0-.0003 0-.0004 0-6.2513 0-13.79186 1.43422-19.999594 4.59105 0 .02866-.000003.05751-.000003.08653-.000361 6.87412-.001248 23.76562 19.999597 35.32242.0001-.0001.0003-.0002.0004-.0003z' fill='%2367b279'/%3E%3Cpath d='m20.3236 26.2143 11.605-15.3766c-.8504-.6701-1.5963-.1972-2.0069.169l-.015.0012-9.6763 9.8957-3.6457-4.3132c-1.7393-1.9755-4.1038-.4686-4.6561-.0704z' fill='%23fff'/%3E%3C/g%3E%3C/svg%3E"); + background-size: contain; + width: 40px; + height: 40px; + margin: 0 auto 16px; + } + + .title { + font-weight: 700; + font-size: 20px; + line-height: 25px; + margin-bottom: 8px; + } + + .subtitle { + font-weight: 400; + font-size: 14px; + line-height: 16px; + max-height: 50px; + overflow: hidden; + word-break: break-all; + } + + .footer { + padding-top: 24px; + } + + .button { + display: inline-block; + min-width: 90px; + padding: 6px 15px; + border-radius: 3px; + border: none; + background: #4d4d4d; + color: #fff; + text-align: center; + font-weight: 400; + font-size: 16px; + line-height: 21px; + text-decoration: none; + } + </style> + </head> + + <body> + <div class="wrapper"> + <div class="content"> + <div class="logo"></div> + <div id="clickToLoadTitle" class="title"></div> + <div id="clickToLoadSubtitle" class="subtitle"></div> + <div class="footer"> + <a id="clickToLoadLink" class="button" href="" rel="noreferrer noopener"></a> + </div> + </div> + </div> + <!-- script injection --> + <script>(function () { + 'use strict'; + + function clickToLoad() { + var QUESTION_MARK = '?'; + var AMPERSAND = '&'; + var SEARCH_PARAMS_DIVIDER = '='; + var ORIGIN_URL_PARAM = '__origin'; + var EXT_UNBLOCK_PARAM = '__unblock'; + var CL_UNBLOCK_PARAM = '__adg_unblock_token'; + var CL_SPECIFIC_UNBLOCK_PARAM = '__adg_unblock'; + var BLOCKING_RULE_PARAM = '__adg_blocking_rule'; + var CLICK_EVENT = 'click'; + var CL_FORCE_EVENT = 'force'; + var neededParams = [ORIGIN_URL_PARAM, EXT_UNBLOCK_PARAM, CL_UNBLOCK_PARAM, BLOCKING_RULE_PARAM]; + var parseSearchParam = function parseSearchParam(rawQueryStr) { + var res = {}; + var pattern = /([^&=]+)=([^&]*)/g; + var matchedData; + var queryStr = rawQueryStr.substring(1); + while (matchedData = pattern.exec(queryStr)) { + if (neededParams.includes(matchedData[1])) { + res[matchedData[1]] = matchedData[2]; + } + queryStr = queryStr.substring(matchedData[0]); + } + return res; + }; + var paramsData = parseSearchParam(window.location.search); + var getParamByKey = function getParamByKey(key) { + return paramsData[key] || ''; + }; + var extUnblockToken = getParamByKey(EXT_UNBLOCK_PARAM); + var clUnblockToken = getParamByKey(CL_UNBLOCK_PARAM); + var blockingRule = getParamByKey(BLOCKING_RULE_PARAM); + var originUrl = clUnblockToken + ? window.location.href : decodeURIComponent(getParamByKey(ORIGIN_URL_PARAM)); + var clickTitleElem = document.getElementById('clickToLoadTitle'); + var clickSubtitleElem = document.getElementById('clickToLoadSubtitle'); + var clickButtonElem = document.getElementById('clickToLoadLink'); + var originUrlToDisplay = clUnblockToken ? originUrl.replace(/[&?]__adg_unblock_token=.*/, '') : originUrl; + clickSubtitleElem.textContent = originUrlToDisplay; + clickButtonElem.href = originUrlToDisplay; + clickButtonElem.title = originUrlToDisplay; + var translationsData = { + en: { + title: 'Content blocked by AdGuard', + button: 'Click to load' + }, + ru: { + title: 'AdGuard заблокировал загрузку контента', + button: 'Всё равно загрузить' + }, + es: { + title: 'Contenido bloqueado por AdGuard', + button: 'Pulsa para cargar' + }, + fr: { + title: 'Contenu bloqué par AdGuard', + button: 'Cliquez pour télécharger' + }, + it: { + title: 'Contenuti bloccati da AdGuard', + button: 'Clicca per scaricare' + }, + de: { + title: 'Inhalt blockiert durch AdGuard', + button: 'Trotzdem laden' + }, + 'zh-cn': { + title: 'AdGuard 已将该内容屏蔽', + button: '点击加载' + }, + 'zh-tw': { + title: 'AdGuard 已將該內容封鎖', + button: '點按載入' + }, + ko: { + title: 'AdGuard에 의해 차단된 콘텐츠', + button: '로드하려면 클릭하세요' + }, + ja: { + title: 'AdGuardがコンテンツをブロックしました。', + button: '読み込むにはこちらをクリック' + }, + uk: { + title: 'AdGuard заблокував завантаження вмісту', + button: 'Однаково завантажити' + } + }; + var getTranslations = function getTranslations() { + var baseLocaleData = translationsData.en; + try { + var currentLocale = navigator.language.toLowerCase(); + var localeData = translationsData[currentLocale]; + if (!localeData) { + var lang = currentLocale.split('-')[0]; + localeData = translationsData[lang]; + } + if (!localeData) { + localeData = baseLocaleData; + } + return localeData; + } catch (e) { + return baseLocaleData; + } + }; + var translations = getTranslations(); + clickTitleElem.textContent = translations.title; + clickButtonElem.textContent = translations.button; + var getReplaceUrl = function getReplaceUrl(originUrl, unblockTokenName, unblockTokenValue) { + var questionMarkIndex = originUrl.indexOf(QUESTION_MARK); + var divider = questionMarkIndex > -1 ? AMPERSAND : QUESTION_MARK; + if (originUrl.substring(questionMarkIndex).length === 1) { + divider = ''; + } + return `${originUrl}${divider}${unblockTokenName}${SEARCH_PARAMS_DIVIDER}${unblockTokenValue}`; + }; + var extRun = function extRun() { + var replaceUrl = getReplaceUrl(originUrl, EXT_UNBLOCK_PARAM, extUnblockToken); + window.location.replace(replaceUrl); + }; + var clRun = function clRun() { + var CL_SPECIFIC_UNBLOCK_VALUE = 1; + var replaceUrl = getReplaceUrl(originUrl, CL_SPECIFIC_UNBLOCK_PARAM, CL_SPECIFIC_UNBLOCK_VALUE); + window.location.replace(replaceUrl); + }; + clickButtonElem.addEventListener(CLICK_EVENT, function (e) { + if (e.isTrusted === false) { + return; + } + if (extUnblockToken) { + extRun(); + } else if (clUnblockToken) { + clRun(); + } + e.preventDefault(); + e.stopPropagation(); + }); + clickButtonElem.addEventListener(CL_FORCE_EVENT, function () { + clRun(); + }); + var hasFrameModifier = function hasFrameModifier(rule) { + var substringAfter = function substringAfter(str, separator) { + var index = str.indexOf(separator); + return index < 0 ? '' : str.substring(index + separator.length); + }; + var FRAME_MARKER = 'frame'; + var SUBDOCUMENT_MARKER = 'subdocument'; + var ruleModifiers = substringAfter(rule, '$').split(','); + return ruleModifiers.includes(FRAME_MARKER) || ruleModifiers.includes(SUBDOCUMENT_MARKER); + }; + var isInsideFrame = function isInsideFrame() { + return window.self !== window.top; + }; + if (clUnblockToken && blockingRule && hasFrameModifier(blockingRule) && !isInsideFrame()) { + clickButtonElem.dispatchEvent(CL_FORCE_EVENT); + } + } + clickToLoad(); + +})(); +</script> + </body> +</html> diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/didomi-loader.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/didomi-loader.js new file mode 100644 index 0000000..e74a244 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/didomi-loader.js @@ -0,0 +1,160 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function DidomiLoader(source) { + function UserConsentStatusForVendorSubscribe() {} + UserConsentStatusForVendorSubscribe.prototype.filter = function() { + return new UserConsentStatusForVendorSubscribe; + }; + UserConsentStatusForVendorSubscribe.prototype.subscribe = noopFunc; + function UserConsentStatusForVendor() {} + UserConsentStatusForVendor.prototype.first = function() { + return new UserConsentStatusForVendorSubscribe; + }; + UserConsentStatusForVendor.prototype.filter = function() { + return new UserConsentStatusForVendorSubscribe; + }; + UserConsentStatusForVendor.prototype.subscribe = noopFunc; + var DidomiWrapper = { + isConsentRequired: falseFunc, + getUserConsentStatusForPurpose: trueFunc, + getUserConsentStatus: trueFunc, + getUserStatus: noopFunc, + getRequiredPurposes: noopArray, + getUserConsentStatusForVendor: trueFunc, + Purposes: { + Cookies: "cookies" + }, + notice: { + configure: noopFunc, + hide: noopFunc, + isVisible: falseFunc, + show: noopFunc, + showDataProcessing: trueFunc + }, + isUserConsentStatusPartial: falseFunc, + on() { + return { + actions: {}, + emitter: {}, + services: {}, + store: {} + }; + }, + shouldConsentBeCollected: falseFunc, + getUserConsentStatusForAll: noopFunc, + getObservableOnUserConsentStatusForVendor() { + return new UserConsentStatusForVendor; + } + }; + window.Didomi = DidomiWrapper; + var didomiStateWrapper = { + didomiExperimentId: "", + didomiExperimentUserGroup: "", + didomiGDPRApplies: 1, + didomiIABConsent: "", + didomiPurposesConsent: "", + didomiPurposesConsentDenied: "", + didomiPurposesConsentUnknown: "", + didomiVendorsConsent: "", + didomiVendorsConsentDenied: "", + didomiVendorsConsentUnknown: "", + didomiVendorsRawConsent: "", + didomiVendorsRawConsentDenied: "", + didomiVendorsRawConsentUnknown: "" + }; + window.didomiState = didomiStateWrapper; + var tcData = { + eventStatus: "tcloaded", + gdprApplies: false, + listenerId: noopFunc, + vendor: { + consents: [] + }, + purpose: { + consents: [] + } + }; + var __tcfapiWrapper = function __tcfapiWrapper(command, version, callback) { + if (typeof callback !== "function" || command === "removeEventListener") { + return; + } + callback(tcData, true); + }; + window.__tcfapi = __tcfapiWrapper; + var didomiEventListenersWrapper = { + stub: true, + push: noopFunc + }; + window.didomiEventListeners = didomiEventListenersWrapper; + var didomiOnReadyWrapper = { + stub: true, + push(arg) { + if (typeof arg !== "function") { + return; + } + if (document.readyState !== "complete") { + window.addEventListener("load", (function() { + setTimeout(arg(window.Didomi)); + })); + } else { + setTimeout(arg(window.Didomi)); + } + } + }; + window.didomiOnReady = window.didomiOnReady || didomiOnReadyWrapper; + if (Array.isArray(window.didomiOnReady)) { + window.didomiOnReady.forEach((function(arg) { + if (typeof arg === "function") { + try { + setTimeout(arg(window.Didomi)); + } catch (e) {} + } + })); + } + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopArray() { + return []; + } + function trueFunc() { + return !0; + } + function falseFunc() { + return !1; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + DidomiLoader.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "didomi-loader", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/fingerprintjs.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/fingerprintjs.js new file mode 100644 index 0000000..61b3908 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/fingerprintjs.js @@ -0,0 +1,92 @@ +(function(source, args){ +function Fingerprintjs(source) { + var browserId = ''; + + for (var i = 0; i < 8; i += 1) { + browserId += (Math.random() * 0x10000 + 0x1000).toString(16).slice(-4); + } + + var Fingerprint = function Fingerprint() {}; + + Fingerprint.get = function (options, callback) { + if (!callback) { + callback = options; + } + + setTimeout(function () { + if (callback) { + callback(browserId, []); + } + }, 1); + }; + + Fingerprint.prototype = { + get: Fingerprint.get + }; + window.Fingerprint2 = Fingerprint; + hit(source); + } +function hit(source, message) { + if (source.verbose !== true) { + return; + } + + try { + var log = console.log.bind(console); + var trace = console.trace.bind(console); // eslint-disable-line compat/compat + + var prefix = source.ruleText || ''; + + if (source.domainName) { + var AG_SCRIPTLET_MARKER = '#%#//'; + var UBO_SCRIPTLET_MARKER = '##+js'; + var ruleStartIndex; + + if (source.ruleText.indexOf(AG_SCRIPTLET_MARKER) > -1) { + ruleStartIndex = source.ruleText.indexOf(AG_SCRIPTLET_MARKER); + } else if (source.ruleText.indexOf(UBO_SCRIPTLET_MARKER) > -1) { + ruleStartIndex = source.ruleText.indexOf(UBO_SCRIPTLET_MARKER); + } // delete all domains from ruleText and leave just rule part + + + var rulePart = source.ruleText.slice(ruleStartIndex); // prepare applied scriptlet rule for specific domain + + prefix = "".concat(source.domainName).concat(rulePart); + } // Used to check if scriptlet uses 'hit' function for logging + + + var LOG_MARKER = 'log: '; + + if (message) { + if (message.indexOf(LOG_MARKER) === -1) { + log("".concat(prefix, " message:\n").concat(message)); + } else { + log(message.slice(LOG_MARKER.length)); + } + } + + log("".concat(prefix, " trace start")); + + if (trace) { + trace(); + } + + log("".concat(prefix, " trace end")); + } catch (e) {// try catch for Edge 15 + // In according to this issue https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/14495220/ + // console.log throws an error + } // This is necessary for unit-tests only! + + + if (typeof window.__debug === 'function') { + window.__debug(source); + } + }; + const updatedArgs = args ? [].concat(source).concat(args) : [source]; + try { + Fingerprintjs.apply(this, updatedArgs); + } catch (e) { + console.log(e); + } + +})({"name":"fingerprintjs","args":[]}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/fingerprintjs2.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/fingerprintjs2.js new file mode 100644 index 0000000..69dd5d5 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/fingerprintjs2.js @@ -0,0 +1,60 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function Fingerprintjs2(source) { + var browserId = ""; + for (var i = 0; i < 8; i += 1) { + browserId += (Math.random() * 65536 + 4096).toString(16).slice(-4); + } + var Fingerprint2 = function Fingerprint2() {}; + Fingerprint2.get = function(options, callback) { + if (!callback) { + callback = options; + } + setTimeout((function() { + if (callback) { + callback(browserId, []); + } + }), 1); + }; + Fingerprint2.prototype = { + get: Fingerprint2.get + }; + window.Fingerprint2 = Fingerprint2; + window.Fingerprint = Fingerprint2; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + Fingerprintjs2.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "fingerprintjs2", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/fingerprintjs3.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/fingerprintjs3.js new file mode 100644 index 0000000..a97ccdf --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/fingerprintjs3.js @@ -0,0 +1,63 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function Fingerprintjs3(source) { + var visitorId = function() { + var id = ""; + for (var i = 0; i < 8; i += 1) { + id += (Math.random() * 65536 + 4096).toString(16).slice(-4); + } + return id; + }(); + var FingerprintJS = function FingerprintJS() {}; + FingerprintJS.prototype = { + load() { + return Promise.resolve(new FingerprintJS); + }, + get() { + return Promise.resolve({ + visitorId: visitorId + }); + }, + hashComponents: noopStr + }; + window.FingerprintJS = new FingerprintJS; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopStr() { + return ""; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + Fingerprintjs3.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "fingerprintjs3", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/freewheel-admanager.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/freewheel-admanager.js new file mode 100644 index 0000000..87b0b33 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/freewheel-admanager.js @@ -0,0 +1,94 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function FreewheelAdManager(source) { + var eventsMap = new Map; + var adManagerFunc = noopFunc; + adManagerFunc.prototype.addEventListener = function(type, callback) { + if (type) { + eventsMap.set(type, callback); + } + }; + adManagerFunc.prototype.addKeyValue = noopFunc; + adManagerFunc.prototype.addTemporalSlot = noopFunc; + adManagerFunc.prototype.dispose = noopFunc; + adManagerFunc.prototype.newContext = noopThis; + adManagerFunc.prototype.registerCustomPlayer = noopFunc; + adManagerFunc.prototype.registerVideoDisplayBase = noopFunc; + adManagerFunc.prototype.removeEventListener = noopFunc; + adManagerFunc.prototype.resize = noopFunc; + adManagerFunc.prototype.setCapability = noopFunc; + adManagerFunc.prototype.setContentVideoElement = noopFunc; + adManagerFunc.prototype.setLogLevel = noopFunc; + adManagerFunc.prototype.setNetwork = noopFunc; + adManagerFunc.prototype.setParameter = noopFunc; + adManagerFunc.prototype.setProfile = noopFunc; + adManagerFunc.prototype.setServer = noopFunc; + adManagerFunc.prototype.setSiteSection = noopFunc; + adManagerFunc.prototype.setVideoAsset = noopFunc; + adManagerFunc.prototype.setVideoDisplaySize = noopFunc; + adManagerFunc.prototype.submitRequest = function() { + var event = { + type: window.tv.freewheel.SDK.EVENT_SLOT_ENDED + }; + var callbackFunc = eventsMap.get("EVENT_SLOT_ENDED"); + if (callbackFunc && typeof callbackFunc === "function") { + setTimeout((function() { + try { + callbackFunc(event); + } catch (ex) {} + }), 1); + } + }; + window.tv = { + freewheel: { + SDK: { + _instanceQueue: {}, + Ad: noopFunc, + AdListener: noopFunc, + AdManager: adManagerFunc, + EVENT_SLOT_ENDED: "EVENT_SLOT_ENDED", + setLogLevel: noopFunc + } + } + }; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopThis() { + return this; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + FreewheelAdManager.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "freewheel-admanager", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/gemius.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/gemius.js new file mode 100644 index 0000000..46ab50a --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/gemius.js @@ -0,0 +1,50 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function Gemius(source) { + var GemiusPlayer = function GemiusPlayer() {}; + GemiusPlayer.prototype = { + setVideoObject: noopFunc, + newProgram: noopFunc, + programEvent: noopFunc, + newAd: noopFunc, + adEvent: noopFunc + }; + window.GemiusPlayer = GemiusPlayer; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + Gemius.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "gemius", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-analytics-ga.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-analytics-ga.js new file mode 100644 index 0000000..ddaf98f --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-analytics-ga.js @@ -0,0 +1,119 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function GoogleAnalyticsGa(source) { + function Gaq() {} + Gaq.prototype.Na = noopFunc; + Gaq.prototype.O = noopFunc; + Gaq.prototype.Sa = noopFunc; + Gaq.prototype.Ta = noopFunc; + Gaq.prototype.Va = noopFunc; + Gaq.prototype._createAsyncTracker = noopFunc; + Gaq.prototype._getAsyncTracker = noopFunc; + Gaq.prototype._getPlugin = noopFunc; + Gaq.prototype.push = function(data) { + if (typeof data === "function") { + data(); + return; + } + if (Array.isArray(data) === false) { + return; + } + if (typeof data[0] === "string" && /(^|\.)_link$/.test(data[0]) && typeof data[1] === "string") { + window.location.assign(data[1]); + } + if (data[0] === "_set" && data[1] === "hitCallback" && typeof data[2] === "function") { + data[2](); + } + }; + var gaq = new Gaq; + var asyncTrackers = window._gaq || []; + if (Array.isArray(asyncTrackers)) { + while (asyncTrackers[0]) { + gaq.push(asyncTrackers.shift()); + } + } + window._gaq = gaq.qf = gaq; + function Gat() {} + var api = [ "_addIgnoredOrganic", "_addIgnoredRef", "_addItem", "_addOrganic", "_addTrans", "_clearIgnoredOrganic", "_clearIgnoredRef", "_clearOrganic", "_cookiePathCopy", "_deleteCustomVar", "_getName", "_setAccount", "_getAccount", "_getClientInfo", "_getDetectFlash", "_getDetectTitle", "_getLinkerUrl", "_getLocalGifPath", "_getServiceMode", "_getVersion", "_getVisitorCustomVar", "_initData", "_link", "_linkByPost", "_setAllowAnchor", "_setAllowHash", "_setAllowLinker", "_setCampContentKey", "_setCampMediumKey", "_setCampNameKey", "_setCampNOKey", "_setCampSourceKey", "_setCampTermKey", "_setCampaignCookieTimeout", "_setCampaignTrack", "_setClientInfo", "_setCookiePath", "_setCookiePersistence", "_setCookieTimeout", "_setCustomVar", "_setDetectFlash", "_setDetectTitle", "_setDomainName", "_setLocalGifPath", "_setLocalRemoteServerMode", "_setLocalServerMode", "_setReferrerOverride", "_setRemoteServerMode", "_setSampleRate", "_setSessionTimeout", "_setSiteSpeedSampleRate", "_setSessionCookieTimeout", "_setVar", "_setVisitorCookieTimeout", "_trackEvent", "_trackPageLoadTime", "_trackPageview", "_trackSocial", "_trackTiming", "_trackTrans", "_visitCode" ]; + var tracker = api.reduce((function(res, funcName) { + res[funcName] = noopFunc; + return res; + }), {}); + tracker._getLinkerUrl = function(a) { + return a; + }; + tracker._link = function(url) { + if (typeof url !== "string") { + return; + } + try { + window.location.assign(url); + } catch (e) { + logMessage(source, e); + } + }; + Gat.prototype._anonymizeIP = noopFunc; + Gat.prototype._createTracker = noopFunc; + Gat.prototype._forceSSL = noopFunc; + Gat.prototype._getPlugin = noopFunc; + Gat.prototype._getTracker = function() { + return tracker; + }; + Gat.prototype._getTrackerByName = function() { + return tracker; + }; + Gat.prototype._getTrackers = noopFunc; + Gat.prototype.aa = noopFunc; + Gat.prototype.ab = noopFunc; + Gat.prototype.hb = noopFunc; + Gat.prototype.la = noopFunc; + Gat.prototype.oa = noopFunc; + Gat.prototype.pa = noopFunc; + Gat.prototype.u = noopFunc; + var gat = new Gat; + window._gat = gat; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function logMessage(e, o) { + var r = arguments.length > 2 && void 0 !== arguments[2] && arguments[2], a = !(arguments.length > 3 && void 0 !== arguments[3]) || arguments[3], {name: n, verbose: g} = e; + if (r || g) { + var i = console.log; + a ? i(`${n}: ${o}`) : Array.isArray(o) ? i(`${n}:`, ...o) : i(`${n}:`, o); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + GoogleAnalyticsGa.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "google-analytics-ga", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-analytics.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-analytics.js new file mode 100644 index 0000000..ca4b0b4 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-analytics.js @@ -0,0 +1,129 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function GoogleAnalytics(source) { + var _window$googleAnalyti; + var Tracker = function Tracker() {}; + var proto = Tracker.prototype; + proto.get = noopFunc; + proto.set = noopFunc; + proto.send = noopFunc; + var googleAnalyticsName = window.GoogleAnalyticsObject || "ga"; + var queue = (_window$googleAnalyti = window[googleAnalyticsName]) === null || _window$googleAnalyti === void 0 ? void 0 : _window$googleAnalyti.q; + function ga(a) { + var len = arguments.length; + if (len === 0) { + return; + } + var lastArg = arguments[len - 1]; + var replacer; + if (lastArg instanceof Object && lastArg !== null && typeof lastArg.hitCallback === "function") { + replacer = lastArg.hitCallback; + } else if (typeof lastArg === "function") { + replacer = function replacer() { + lastArg(ga.create()); + }; + } + try { + setTimeout(replacer, 1); + } catch (ex) {} + } + ga.create = function() { + return new Tracker; + }; + ga.getByName = function() { + return new Tracker; + }; + ga.getAll = function() { + return [ new Tracker ]; + }; + ga.remove = noopFunc; + ga.loaded = true; + window[googleAnalyticsName] = ga; + if (Array.isArray(queue)) { + var push = function push(arg) { + ga(...arg); + }; + queue.push = push; + queue.forEach(push); + } + var {dataLayer: dataLayer, google_optimize: google_optimize} = window; + if (dataLayer instanceof Object === false) { + return; + } + if (dataLayer.hide instanceof Object && typeof dataLayer.hide.end === "function") { + dataLayer.hide.end(); + } + var handleCallback = function handleCallback(dataObj, funcName) { + if (dataObj && typeof dataObj[funcName] === "function") { + setTimeout(dataObj[funcName]); + } + }; + if (typeof dataLayer.push === "function") { + dataLayer.push = function(data) { + if (data instanceof Object) { + handleCallback(data, "eventCallback"); + for (var key in data) { + handleCallback(data[key], "event_callback"); + } + if (!data.hasOwnProperty("eventCallback") && !data.hasOwnProperty("eventCallback")) { + [].push.call(window.dataLayer, data); + } + } + if (Array.isArray(data)) { + data.forEach((function(arg) { + handleCallback(arg, "callback"); + })); + } + return noopFunc; + }; + } + if (google_optimize instanceof Object && typeof google_optimize.get === "function") { + var googleOptimizeWrapper = { + get: noopFunc + }; + window.google_optimize = googleOptimizeWrapper; + } + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopNull() { + return null; + } + function noopArray() { + return []; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + GoogleAnalytics.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "google-analytics", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-ima3-dai.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-ima3-dai.js new file mode 100644 index 0000000..58d97a8 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-ima3-dai.js @@ -0,0 +1,746 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function GoogleIma3Dai(source) { + var streamEventTypes = { + AD_BREAK_ENDED: "adBreakEnded", + AD_BREAK_STARTED: "adBreakStarted", + AD_PERIOD_ENDED: "adPeriodEnded", + AD_PERIOD_STARTED: "adPeriodStarted", + AD_PROGRESS: "adProgress", + CLICK: "click", + COMPLETE: "complete", + CUEPOINTS_CHANGED: "cuepointsChanged", + ERROR: "error", + FIRST_QUARTILE: "firstquartile", + HIDE_AD_UI: "hideAdUi", + LOADED: "loaded", + MIDPOINT: "midpoint", + PAUSED: "paused", + RESUMED: "resumed", + SHOW_AD_UI: "showAdUi", + SKIPPABLE_STATE_CHANGED: "skippableStateChanged", + SKIPPED: "skip", + STARTED: "started", + STREAM_INITIALIZED: "streamInitialized", + THIRD_QUARTILE: "thirdquartile", + VIDEO_CLICKED: "videoClicked" + }; + var isRecord = function isRecord(value) { + return typeof value === "object" && value !== null; + }; + var schedule = function schedule(callback) { + if (typeof requestAnimationFrame === "function") { + requestAnimationFrame(callback); + return; + } + setTimeout(callback, 0); + }; + var toStringRecord = function toStringRecord(value) { + if (!isRecord(value)) { + return {}; + } + var result = {}; + var propertyNames = Object.keys(value); + for (var propertyIndex = 0; propertyIndex < propertyNames.length; propertyIndex += 1) { + var propertyName = propertyNames[propertyIndex]; + result[propertyName] = String(value[propertyName]); + } + return result; + }; + var getStringValue = function getStringValue(value) { + return typeof value === "string" && value.length > 0 ? value : null; + }; + var normalizeStreamRequestUi = function normalizeStreamRequestUi(value) { + if (!isRecord(value)) { + return { + custom: null + }; + } + var normalizedUi = Object.assign({ + custom: null + }, value); + normalizedUi.custom = isRecord(normalizedUi.custom) ? normalizedUi.custom : null; + return normalizedUi; + }; + var initializeEventHandler = function initializeEventHandler(instance) { + instance.listeners = new Map; + }; + var normalizeEventTypes = function normalizeEventTypes(type) { + if (typeof type === "string") { + return [ type ]; + } + if (!Array.isArray(type)) { + return []; + } + var eventTypes = []; + for (var eventTypeIndex = 0; eventTypeIndex < type.length; eventTypeIndex += 1) { + var eventType = type[eventTypeIndex]; + if (typeof eventType === "string") { + eventTypes.push(eventType); + } + } + return eventTypes; + }; + var initializeStreamRequest = function initializeStreamRequest(instance, streamRequest) { + instance.adTagParameters = {}; + instance.apiKey = null; + instance.authToken = null; + instance.format = "hls"; + instance.networkCode = null; + instance.omidAccessModeRules = null; + instance.streamActivityMonitorId = null; + instance.ui = { + custom: null + }; + if (isRecord(streamRequest)) { + Object.assign(instance, streamRequest); + } + instance.adTagParameters = toStringRecord(instance.adTagParameters); + instance.ui = normalizeStreamRequestUi(instance.ui); + if (typeof instance.format !== "string" || instance.format.length === 0) { + instance.format = "hls"; + } + }; + var initializePodStreamRequest = function initializePodStreamRequest(instance, podStreamRequest) { + initializeStreamRequest(instance, podStreamRequest); + instance.customAssetKey = typeof instance.customAssetKey === "string" ? instance.customAssetKey : ""; + }; + var EventHandler = function EventHandler() { + initializeEventHandler(this); + }; + EventHandler.prototype.addEventListener = function(type, listener) { + if (typeof listener !== "function") { + return; + } + var eventTypes = normalizeEventTypes(type); + for (var eventTypeIndex = 0; eventTypeIndex < eventTypes.length; eventTypeIndex += 1) { + var eventType = eventTypes[eventTypeIndex]; + if (!this.listeners.has(eventType)) { + this.listeners.set(eventType, new Set); + } + var listeners = this.listeners.get(eventType); + if (listeners) { + listeners.add(listener); + } + } + }; + EventHandler.prototype.removeEventListener = function(type, listener) { + if (typeof listener !== "function") { + return; + } + var eventTypes = normalizeEventTypes(type); + for (var eventTypeIndex = 0; eventTypeIndex < eventTypes.length; eventTypeIndex += 1) { + var listeners = this.listeners.get(eventTypes[eventTypeIndex]); + if (!listeners) { + continue; + } + listeners.delete(listener); + } + }; + EventHandler.prototype.dispatchEvent = function(streamEvent) { + var listeners = this.listeners.get(streamEvent.type); + if (!listeners) { + return; + } + for (var _i = 0, _Array$from = Array.from(listeners); _i < _Array$from.length; _i++) { + var _listener = _Array$from[_i]; + try { + _listener(streamEvent); + } catch (error) { + logMessage(source, error); + } + } + }; + var streamFormats = { + DASH: "dash", + HLS: "hls" + }; + var StreamRequest = function StreamRequest(streamRequest) { + initializeStreamRequest(this, streamRequest); + }; + StreamRequest.StreamFormat = streamFormats; + var LiveStreamRequest = function LiveStreamRequest(liveStreamRequest) { + initializeStreamRequest(this, liveStreamRequest); + this.assetKey = typeof this.assetKey === "string" ? this.assetKey : ""; + }; + Object.setPrototypeOf(LiveStreamRequest.prototype, StreamRequest.prototype); + var PodStreamRequest = function PodStreamRequest(podStreamRequest) { + initializePodStreamRequest(this, podStreamRequest); + }; + Object.setPrototypeOf(PodStreamRequest.prototype, StreamRequest.prototype); + var VideoStitcherLiveStreamRequest = function VideoStitcherLiveStreamRequest(videoStitcherLiveStreamRequest) { + initializePodStreamRequest(this, videoStitcherLiveStreamRequest); + this.liveStreamEventId = typeof this.liveStreamEventId === "string" ? this.liveStreamEventId : ""; + this.oAuthToken = typeof this.oAuthToken === "string" ? this.oAuthToken : null; + this.projectNumber = typeof this.projectNumber === "string" ? this.projectNumber : null; + this.region = typeof this.region === "string" ? this.region : null; + this.videoStitcherSessionOptions = isRecord(this.videoStitcherSessionOptions) ? this.videoStitcherSessionOptions : null; + }; + Object.setPrototypeOf(VideoStitcherLiveStreamRequest.prototype, PodStreamRequest.prototype); + var VideoStitcherVodStreamRequest = function VideoStitcherVodStreamRequest(videoStitcherVodStreamRequest) { + initializeStreamRequest(this, videoStitcherVodStreamRequest); + this.adTagUrl = typeof this.adTagUrl === "string" ? this.adTagUrl : ""; + this.contentSourceUrl = typeof this.contentSourceUrl === "string" ? this.contentSourceUrl : ""; + this.oAuthToken = typeof this.oAuthToken === "string" ? this.oAuthToken : null; + this.projectNumber = typeof this.projectNumber === "string" ? this.projectNumber : null; + this.region = typeof this.region === "string" ? this.region : null; + this.videoStitcherSessionOptions = isRecord(this.videoStitcherSessionOptions) ? this.videoStitcherSessionOptions : null; + this.vodConfigId = typeof this.vodConfigId === "string" ? this.vodConfigId : ""; + }; + Object.setPrototypeOf(VideoStitcherVodStreamRequest.prototype, StreamRequest.prototype); + var VODStreamRequest = function VODStreamRequest(vodStreamRequest) { + initializeStreamRequest(this, vodStreamRequest); + this.contentSourceId = typeof this.contentSourceId === "string" ? this.contentSourceId : ""; + this.videoId = typeof this.videoId === "string" ? this.videoId : ""; + }; + Object.setPrototypeOf(VODStreamRequest.prototype, StreamRequest.prototype); + var StreamData = function StreamData(streamData) { + this.adPeriodData = null; + this.adProgressData = null; + this.cuepoints = []; + this.errorMessage = null; + this.manifestFormat = "HLS"; + this.streamId = null; + this.subtitles = []; + this.url = ""; + if (isRecord(streamData)) { + Object.assign(this, streamData); + } + }; + var StreamEvent = function StreamEvent(type, streamData, ad) { + this.type = type; + this.streamData = streamData || new StreamData; + this.ad = ad || null; + }; + StreamEvent.Type = streamEventTypes; + StreamEvent.prototype.getAd = function() { + return this.ad; + }; + StreamEvent.prototype.getStreamData = function() { + return this.streamData; + }; + var UiSettings = function UiSettings() { + this.locale = "en"; + }; + UiSettings.prototype.getLocale = function() { + return this.locale; + }; + UiSettings.prototype.setLocale = function(locale) { + if (typeof locale === "string" && locale.length > 0) { + this.locale = locale; + } + }; + var uiKeys = { + ABOUT_THIS_AD_FALLBACK_IMAGE: "aboutThisAdFallbackImage", + ABOUT_THIS_AD_ICON: "aboutThisAdIcon", + AD_TITLE: "adTitle", + ATTRIBUTION: "attribution", + AUTHOR_ICON: "authorIcon", + AUTHOR_TITLE: "authorTitle", + CALL_TO_ACTION: "callToAction", + PRE_SKIP: "preSkip", + SKIP_BUTTON: "skipButton", + VIDEO_OVERLAY: "videoOverlay" + }; + var clickThroughNavigation = { + EXTERNAL: "external", + NOT_SUPPORTED: "notSupported" + }; + var UiImage = function UiImage(uiImage) { + this.altText = ""; + this.height = 0; + this.url = ""; + this.width = 0; + if (isRecord(uiImage)) { + Object.assign(this, uiImage); + } + this.altText = getStringValue(this.altText) || ""; + this.height = typeof this.height === "number" ? this.height : 0; + this.url = getStringValue(this.url) || ""; + this.width = typeof this.width === "number" ? this.width : 0; + }; + var UiData = function UiData(uiData) { + this.clickable = false; + this.required = false; + if (isRecord(uiData)) { + Object.assign(this, uiData); + } + this.clickable = Boolean(this.clickable); + this.required = Boolean(this.required); + if (Array.isArray(this.imageVariants)) { + var imageVariants = []; + for (var imageVariantIndex = 0; imageVariantIndex < this.imageVariants.length; imageVariantIndex += 1) { + imageVariants.push(new UiImage(this.imageVariants[imageVariantIndex])); + } + this.imageVariants = imageVariants; + } + }; + UiData.UiImage = UiImage; + var UiOptions = function UiOptions(uiOptions) { + this.aboutThisAdSupport = false; + this.clickThroughNavigation = clickThroughNavigation.NOT_SUPPORTED; + this.skippableSupport = false; + if (isRecord(uiOptions)) { + Object.assign(this, uiOptions); + } + this.aboutThisAdSupport = Boolean(this.aboutThisAdSupport); + this.clickThroughNavigation = this.clickThroughNavigation === clickThroughNavigation.EXTERNAL ? clickThroughNavigation.EXTERNAL : clickThroughNavigation.NOT_SUPPORTED; + this.skippableSupport = Boolean(this.skippableSupport); + }; + UiOptions.ClickThroughNavigation = clickThroughNavigation; + var CustomUiOptions = function CustomUiOptions(uiOptions) { + this.aboutThisAdSupport = false; + this.skippableSupport = false; + if (isRecord(uiOptions)) { + Object.assign(this, uiOptions); + } + this.aboutThisAdSupport = Boolean(this.aboutThisAdSupport); + this.skippableSupport = Boolean(this.skippableSupport); + }; + var uiDelegates = new WeakMap; + var Ui = function Ui(uiDelegate) { + uiDelegates.set(this, isRecord(uiDelegate) ? uiDelegate : {}); + }; + Ui.prototype.onClick = function(uiKey, eventData) { + var uiDelegate = uiDelegates.get(this); + if (uiDelegate && typeof uiDelegate.onClick === "function") { + uiDelegate.onClick(uiKey, eventData); + } + }; + Ui.prototype.setVisibleElements = function(uiElements) { + var uiDelegate = uiDelegates.get(this); + if (uiDelegate && typeof uiDelegate.setVisibleElements === "function") { + uiDelegate.setVisibleElements(uiElements); + } + }; + Ui.prototype.getConfig = function() { + var uiDelegate = uiDelegates.get(this); + if (!uiDelegate || typeof uiDelegate.getConfig !== "function") { + return new Map; + } + var uiConfig = uiDelegate.getConfig(); + return uiConfig instanceof Map ? uiConfig : new Map; + }; + Ui.UiData = UiData; + Ui.UiKey = uiKeys; + Ui.UiOptions = UiOptions; + var daiSdkFeatureFlagsStorage = new WeakMap; + var getStoredDaiSdkFeatureFlags = function getStoredDaiSdkFeatureFlags(instance) { + var storedFeatureFlags = daiSdkFeatureFlagsStorage.get(instance); + if (storedFeatureFlags) { + return storedFeatureFlags; + } + var nextFeatureFlags = {}; + daiSdkFeatureFlagsStorage.set(instance, nextFeatureFlags); + return nextFeatureFlags; + }; + var DaiSdkSettingsContainer = function DaiSdkSettingsContainer() { + daiSdkFeatureFlagsStorage.set(this, {}); + }; + DaiSdkSettingsContainer.prototype.getFeatureFlags = function() { + return getStoredDaiSdkFeatureFlags(this); + }; + DaiSdkSettingsContainer.prototype.setFeatureFlags = function(featureFlags) { + daiSdkFeatureFlagsStorage.set(this, Object.assign({}, featureFlags)); + }; + var normalizeStreamRequest = function normalizeStreamRequest(streamRequest) { + if (streamRequest instanceof StreamRequest) { + return streamRequest; + } + if (isRecord(streamRequest)) { + if (typeof streamRequest.liveStreamEventId === "string") { + return new VideoStitcherLiveStreamRequest(streamRequest); + } + if (typeof streamRequest.contentSourceUrl === "string" || typeof streamRequest.vodConfigId === "string" || typeof streamRequest.adTagUrl === "string") { + return new VideoStitcherVodStreamRequest(streamRequest); + } + if (typeof streamRequest.customAssetKey === "string") { + return new PodStreamRequest(streamRequest); + } + if (typeof streamRequest.assetKey === "string") { + return new LiveStreamRequest(streamRequest); + } + if (typeof streamRequest.contentSourceId === "string" || typeof streamRequest.videoId === "string") { + return new VODStreamRequest(streamRequest); + } + } + return new StreamRequest; + }; + var hasLiveIdentifiers = function hasLiveIdentifiers(streamRequest) { + var liveStreamRequest = streamRequest; + return typeof liveStreamRequest.assetKey === "string" && liveStreamRequest.assetKey.length > 0; + }; + var hasVideoStitcherLiveIdentifiers = function hasVideoStitcherLiveIdentifiers(streamRequest) { + var videoStitcherLiveStreamRequest = streamRequest; + return typeof videoStitcherLiveStreamRequest.liveStreamEventId === "string" && videoStitcherLiveStreamRequest.liveStreamEventId.length > 0; + }; + var hasPodIdentifiers = function hasPodIdentifiers(streamRequest) { + var podStreamRequest = streamRequest; + return typeof podStreamRequest.networkCode === "string" && podStreamRequest.networkCode.length > 0 && typeof podStreamRequest.customAssetKey === "string" && podStreamRequest.customAssetKey.length > 0; + }; + var hasVideoStitcherVodIdentifiers = function hasVideoStitcherVodIdentifiers(streamRequest) { + var videoStitcherVodStreamRequest = streamRequest; + var hasContentSourceUrl = typeof videoStitcherVodStreamRequest.contentSourceUrl === "string" && videoStitcherVodStreamRequest.contentSourceUrl.length > 0; + var hasVodConfigId = typeof videoStitcherVodStreamRequest.vodConfigId === "string" && videoStitcherVodStreamRequest.vodConfigId.length > 0; + return hasContentSourceUrl || hasVodConfigId; + }; + var hasVodIdentifiers = function hasVodIdentifiers(streamRequest) { + var vodStreamRequest = streamRequest; + return typeof vodStreamRequest.contentSourceId === "string" && vodStreamRequest.contentSourceId.length > 0 && typeof vodStreamRequest.videoId === "string" && vodStreamRequest.videoId.length > 0; + }; + var hasIdentifiers = function hasIdentifiers(streamRequest) { + return hasLiveIdentifiers(streamRequest) || hasPodIdentifiers(streamRequest) || hasVideoStitcherLiveIdentifiers(streamRequest) || hasVideoStitcherVodIdentifiers(streamRequest) || hasVodIdentifiers(streamRequest); + }; + var getFallbackStreamId = function getFallbackStreamId(streamRequest) { + var liveStreamRequest = streamRequest; + var videoStitcherLiveStreamRequest = streamRequest; + var videoStitcherVodStreamRequest = streamRequest; + var vodStreamRequest = streamRequest; + if (typeof videoStitcherVodStreamRequest.vodConfigId === "string" && videoStitcherVodStreamRequest.vodConfigId.length > 0) { + return `mock-video-stitcher-vod-${videoStitcherVodStreamRequest.vodConfigId}`; + } + if (typeof videoStitcherVodStreamRequest.contentSourceUrl === "string" && videoStitcherVodStreamRequest.contentSourceUrl.length > 0) { + return "mock-video-stitcher-vod"; + } + if (typeof videoStitcherLiveStreamRequest.liveStreamEventId === "string" && videoStitcherLiveStreamRequest.liveStreamEventId.length > 0) { + return `mock-video-stitcher-live-${videoStitcherLiveStreamRequest.liveStreamEventId}`; + } + if (typeof liveStreamRequest.assetKey === "string" && liveStreamRequest.assetKey.length > 0) { + return `mock-live-${liveStreamRequest.assetKey}`; + } + if (typeof vodStreamRequest.videoId === "string" && vodStreamRequest.videoId.length > 0) { + return `mock-vod-${vodStreamRequest.videoId}`; + } + return "mock-stream"; + }; + var getDefaultManifestFormat = function getDefaultManifestFormat(streamRequest) { + return typeof streamRequest.format === "string" && streamRequest.format.toLowerCase() === "dash" ? "DASH" : "HLS"; + }; + var createStreamData = function createStreamData(streamRequest, cuepoints, errorMessage, streamDataOverrides) { + var streamData = new StreamData({ + cuepoints: cuepoints.slice(), + errorMessage: errorMessage, + manifestFormat: getDefaultManifestFormat(streamRequest), + streamId: getFallbackStreamId(streamRequest), + url: "" + }); + if (isRecord(streamDataOverrides)) { + Object.assign(streamData, streamDataOverrides); + } + return streamData; + }; + var appendRequestParameters = function appendRequestParameters(requestUrl, streamRequest) { + var parameterNames = Object.keys(streamRequest.adTagParameters); + for (var parameterIndex = 0; parameterIndex < parameterNames.length; parameterIndex += 1) { + var parameterName = parameterNames[parameterIndex]; + requestUrl.searchParams.set(parameterName, streamRequest.adTagParameters[parameterName]); + } + if (streamRequest.apiKey) { + requestUrl.searchParams.set("api-key", streamRequest.apiKey); + } + if (streamRequest.authToken) { + requestUrl.searchParams.set("auth-token", streamRequest.authToken); + } + if (streamRequest.streamActivityMonitorId) { + requestUrl.searchParams.set("dai-sam-id", streamRequest.streamActivityMonitorId); + } + }; + var buildLiveRequestUrl = function buildLiveRequestUrl(streamRequest, hostName) { + var requestUrl = new URL(`${hostName}/ssai/event/${streamRequest.assetKey}/streams`); + appendRequestParameters(requestUrl, streamRequest); + return requestUrl.toString(); + }; + var buildPodRequestUrl = function buildPodRequestUrl(streamRequest, hostName) { + var requestUrl = new URL(`${hostName}/ssai/pods/api/v1/network/${streamRequest.networkCode}` + `/custom_asset/${streamRequest.customAssetKey}/stream`); + var manifestType = streamRequest.format.toLowerCase() === "dash" ? "dash" : "hls"; + appendRequestParameters(requestUrl, streamRequest); + requestUrl.searchParams.set("manifest-type", manifestType); + return requestUrl.toString(); + }; + var buildVodRequestUrl = function buildVodRequestUrl(streamRequest, hostName) { + var requestFormat = streamRequest.format.toLowerCase() === "dash" ? "dash" : "hls"; + var requestUrl = new URL(`${hostName}/ondemand/${requestFormat}/content/${streamRequest.contentSourceId}` + `/vid/${streamRequest.videoId}/streams`); + appendRequestParameters(requestUrl, streamRequest); + return requestUrl.toString(); + }; + var MAIN_HOST_NAME = "https://dai.google.com"; + var FALLBACK_HOST_NAME = "https://pubads.g.doubleclick.net"; + var getStreamRequestUrls = function getStreamRequestUrls(streamRequest) { + if (hasPodIdentifiers(streamRequest)) { + return [ buildPodRequestUrl(streamRequest, MAIN_HOST_NAME), buildPodRequestUrl(streamRequest, FALLBACK_HOST_NAME) ]; + } + if (hasLiveIdentifiers(streamRequest)) { + return [ buildLiveRequestUrl(streamRequest, MAIN_HOST_NAME), buildLiveRequestUrl(streamRequest, FALLBACK_HOST_NAME) ]; + } + if (hasVodIdentifiers(streamRequest)) { + return [ buildVodRequestUrl(streamRequest, MAIN_HOST_NAME), buildVodRequestUrl(streamRequest, FALLBACK_HOST_NAME) ]; + } + return []; + }; + var readFetchResponseData = async function readFetchResponseData(response) { + var typedResponse = response; + if (typedResponse && typedResponse.ok === false) { + throw new Error(`Stream initialization failed with status ${String(typedResponse.status || 0)}`); + } + if (typedResponse && typeof typedResponse.json === "function") { + var jsonResponse = await typedResponse.json(); + return isRecord(jsonResponse) ? jsonResponse : {}; + } + return isRecord(response) ? response : {}; + }; + var getResponseErrorMessage = function getResponseErrorMessage(responseData) { + return getStringValue(responseData.errorMessage) || getStringValue(responseData.error_message); + }; + var createStreamDataFromResponse = function createStreamDataFromResponse(streamRequest, cuepoints, responseData) { + var podManifestUrl = getStringValue(responseData.pod_manifest_url) || getStringValue(responseData.podManifestUrl) || ""; + var responseStreamId = getStringValue(responseData.stream_id) || getStringValue(responseData.streamId); + var streamUrl = getStringValue(responseData.stream_manifest) || getStringValue(responseData.streamUrl) || podManifestUrl || ""; + var responseErrorMessage = getResponseErrorMessage(responseData); + var hasInitializedStream = streamUrl.length > 0 || responseStreamId !== null && responseStreamId.length > 0; + var errorMessage = responseErrorMessage || (hasInitializedStream ? null : "Stream initialization response missing stream URL"); + var manifestFormat = getStringValue(responseData.manifest_format) || getStringValue(responseData.manifestFormat) || getDefaultManifestFormat(streamRequest); + var streamId = responseStreamId || getFallbackStreamId(streamRequest); + var subtitles = Array.isArray(responseData.subtitles) ? responseData.subtitles : []; + return createStreamData(streamRequest, cuepoints, errorMessage, { + manifestFormat: manifestFormat, + podManifestUrl: podManifestUrl, + pod_manifest_url: podManifestUrl, + streamId: streamId, + subtitles: subtitles, + url: streamUrl + }); + }; + var getErrorMessage = function getErrorMessage(error) { + if (isRecord(error) && typeof error.message === "string" && error.message.length > 0) { + return error.message; + } + return "Stream initialization failed"; + }; + var hideAdUiElement = function hideAdUiElement(streamManager) { + if (!streamManager.adUiElement) { + return; + } + streamManager.adUiElement.style.display = "none"; + }; + var showVideoControls = function showVideoControls(streamManager) { + if (!streamManager.videoElement || streamManager.videoElement.controls) { + return; + } + streamManager.videoElement.controls = true; + }; + var handleContentLoaded = function handleContentLoaded(streamManager) { + hideAdUiElement(streamManager); + showVideoControls(streamManager); + }; + var isContentLoadedEventType = function isContentLoadedEventType(eventType) { + return eventType === StreamEvent.Type.LOADED || eventType === StreamEvent.Type.STREAM_INITIALIZED; + }; + var StreamManager = function StreamManager(videoElement, adUiElement, uiSettings) { + initializeEventHandler(this); + this.videoElement = videoElement || null; + this.adUiElement = adUiElement || null; + this.uiSettings = uiSettings || new UiSettings; + this.clickElement = adUiElement || null; + this.streamData = new StreamData; + this.streamMonitor = {}; + this.streamRequest = null; + this.cuepoints = []; + this.lastMetadata = null; + this.lastTimedMetadata = null; + }; + Object.setPrototypeOf(StreamManager.prototype, EventHandler.prototype); + StreamManager.prototype.contentTimeForStreamTime = function(streamTime) { + return typeof streamTime === "number" ? streamTime : 0; + }; + StreamManager.prototype.destroy = function() { + this.reset(); + }; + StreamManager.prototype.focus = function() { + var clickElement = this.clickElement; + if (!clickElement || typeof clickElement.focus !== "function") { + return; + } + try { + clickElement.focus(); + } catch (error) { + logMessage(source, error); + } + }; + StreamManager.prototype.getAdSkippableState = function() { + return true; + }; + StreamManager.prototype.getStreamData = function() { + return this.streamData; + }; + StreamManager.prototype.loadStreamMetadata = function() { + handleContentLoaded(this); + this.dispatchEvent(new StreamEvent(StreamEvent.Type.LOADED, this.streamData)); + }; + StreamManager.prototype.onTimedMetadata = function(metadata) { + this.lastTimedMetadata = metadata; + }; + StreamManager.prototype.previousCuePointForStreamTime = function(streamTime) { + var previousCuePoint = null; + for (var cuepointIndex = 0; cuepointIndex < this.cuepoints.length; cuepointIndex += 1) { + var cuepoint = this.cuepoints[cuepointIndex]; + if (typeof cuepoint.start !== "number") { + continue; + } + if (cuepoint.start <= streamTime) { + previousCuePoint = cuepoint; + } + } + return previousCuePoint; + }; + StreamManager.prototype.processMetadata = function(type, data, timestamp) { + this.lastMetadata = { + data: data, + timestamp: timestamp, + type: type + }; + }; + StreamManager.prototype.replaceAdTagParameters = function(adTagParameters) { + if (!this.streamRequest) { + this.streamRequest = new StreamRequest; + } + this.streamRequest.adTagParameters = toStringRecord(adTagParameters); + }; + StreamManager.prototype.requestStream = function(streamRequest) { + var _this = this; + var normalizedRequest = normalizeStreamRequest(streamRequest); + this.streamRequest = normalizedRequest; + var dispatchStreamEvent = function dispatchStreamEvent(eventType, streamData) { + _this.streamData = streamData; + if (isContentLoadedEventType(eventType)) { + handleContentLoaded(_this); + } + schedule((function() { + _this.dispatchEvent(new StreamEvent(StreamEvent.Type.STREAM_INITIALIZED, streamData)); + _this.dispatchEvent(new StreamEvent(eventType, streamData)); + })); + }; + if (!hasIdentifiers(normalizedRequest)) { + dispatchStreamEvent(StreamEvent.Type.ERROR, createStreamData(normalizedRequest, this.cuepoints, "Missing stream request identifiers")); + return; + } + var requestUrls = getStreamRequestUrls(normalizedRequest); + if (requestUrls.length > 0) { + var activeRequest = normalizedRequest; + var _fetchStreamData = async function fetchStreamData(requestIndex) { + try { + var fetchResponse = await fetch(requestUrls[requestIndex], { + method: "POST", + credentials: "include" + }); + var responseData = await readFetchResponseData(fetchResponse); + if (_this.streamRequest !== activeRequest) { + return; + } + var _streamData = createStreamDataFromResponse(activeRequest, _this.cuepoints, responseData); + var eventType = _streamData.errorMessage ? StreamEvent.Type.ERROR : StreamEvent.Type.LOADED; + dispatchStreamEvent(eventType, _streamData); + } catch (error) { + if (_this.streamRequest !== activeRequest) { + return; + } + if (requestIndex + 1 < requestUrls.length) { + await _fetchStreamData(requestIndex + 1); + return; + } + dispatchStreamEvent(StreamEvent.Type.ERROR, createStreamData(activeRequest, _this.cuepoints, getErrorMessage(error))); + } + }; + _fetchStreamData(0); + return; + } + dispatchStreamEvent(StreamEvent.Type.LOADED, createStreamData(normalizedRequest, this.cuepoints, null)); + }; + StreamManager.prototype.reset = function() { + this.cuepoints = []; + this.lastMetadata = null; + this.lastTimedMetadata = null; + this.streamData = new StreamData; + this.streamRequest = null; + }; + StreamManager.prototype.setClickElement = function(clickElement) { + if (this.adUiElement) { + return; + } + this.clickElement = clickElement; + }; + StreamManager.prototype.streamTimeForContentTime = function(contentTime) { + return typeof contentTime === "number" ? contentTime : 0; + }; + var api = { + customUi: { + UiOptions: CustomUiOptions + }, + DaiSdkSettings: new DaiSdkSettingsContainer, + LiveStreamRequest: LiveStreamRequest, + PodStreamRequest: PodStreamRequest, + StreamData: StreamData, + StreamEvent: StreamEvent, + StreamManager: StreamManager, + StreamRequest: StreamRequest, + ui: Ui, + UiSettings: UiSettings, + VideoStitcherLiveStreamRequest: VideoStitcherLiveStreamRequest, + VideoStitcherVodStreamRequest: VideoStitcherVodStreamRequest, + VODStreamRequest: VODStreamRequest + }; + var globalWindow = window; + var googleNamespace = isRecord(globalWindow.google) ? globalWindow.google : {}; + if (!isRecord(globalWindow.google)) { + globalWindow.google = googleNamespace; + } + var imaNamespace = isRecord(googleNamespace.ima) ? googleNamespace.ima : {}; + googleNamespace.ima = imaNamespace; + var daiNamespace = isRecord(imaNamespace.dai) ? imaNamespace.dai : {}; + imaNamespace.dai = daiNamespace; + var apiNamespace = isRecord(daiNamespace.api) ? daiNamespace.api : {}; + daiNamespace.api = apiNamespace; + Object.assign(apiNamespace, api); + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function logMessage(e, o) { + var r = arguments.length > 2 && void 0 !== arguments[2] && arguments[2], a = !(arguments.length > 3 && void 0 !== arguments[3]) || arguments[3], {name: n, verbose: g} = e; + if (r || g) { + var i = console.log; + a ? i(`${n}: ${o}`) : Array.isArray(o) ? i(`${n}:`, ...o) : i(`${n}:`, o); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + GoogleIma3Dai.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "google-ima3-dai", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-ima3-dai.ts b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-ima3-dai.ts new file mode 100644 index 0000000..8b2233f --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-ima3-dai.ts @@ -0,0 +1,625 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function GoogleIma3Dai(source) { + var streamEventTypes = { + AD_BREAK_ENDED: "adBreakEnded", + AD_BREAK_STARTED: "adBreakStarted", + AD_PERIOD_ENDED: "adPeriodEnded", + AD_PERIOD_STARTED: "adPeriodStarted", + AD_PROGRESS: "adProgress", + CLICK: "click", + COMPLETE: "complete", + CUEPOINTS_CHANGED: "cuepointsChanged", + ERROR: "error", + FIRST_QUARTILE: "firstquartile", + HIDE_AD_UI: "hideAdUi", + LOADED: "loaded", + MIDPOINT: "midpoint", + PAUSED: "paused", + RESUMED: "resumed", + SHOW_AD_UI: "showAdUi", + SKIPPABLE_STATE_CHANGED: "skippableStateChanged", + SKIPPED: "skip", + STARTED: "started", + STREAM_INITIALIZED: "streamInitialized", + THIRD_QUARTILE: "thirdquartile", + VIDEO_CLICKED: "videoClicked" + }; + var isRecord = function isRecord(value) { + return typeof value === "object" && value !== null; + }; + var schedule = function schedule(callback) { + if (typeof requestAnimationFrame === "function") { + requestAnimationFrame(callback); + return; + } + setTimeout(callback, 0); + }; + var toStringRecord = function toStringRecord(value) { + if (!isRecord(value)) { + return {}; + } + var result = {}; + var propertyNames = Object.keys(value); + for (var propertyIndex = 0; propertyIndex < propertyNames.length; propertyIndex += 1) { + var propertyName = propertyNames[propertyIndex]; + result[propertyName] = String(value[propertyName]); + } + return result; + }; + var getStringValue = function getStringValue(value) { + return typeof value === "string" && value.length > 0 ? value : null; + }; + var initializeEventHandler = function initializeEventHandler(instance) { + instance.listeners = new Map; + }; + var normalizeEventTypes = function normalizeEventTypes(type) { + if (typeof type === "string") { + return [ type ]; + } + if (!Array.isArray(type)) { + return []; + } + var eventTypes = []; + for (var eventTypeIndex = 0; eventTypeIndex < type.length; eventTypeIndex += 1) { + var eventType = type[eventTypeIndex]; + if (typeof eventType === "string") { + eventTypes.push(eventType); + } + } + return eventTypes; + }; + var initializeStreamRequest = function initializeStreamRequest(instance, streamRequest) { + instance.adTagParameters = {}; + instance.apiKey = null; + instance.authToken = null; + instance.format = "hls"; + instance.networkCode = null; + instance.omidAccessModeRules = null; + instance.streamActivityMonitorId = null; + if (isRecord(streamRequest)) { + Object.assign(instance, streamRequest); + } + instance.adTagParameters = toStringRecord(instance.adTagParameters); + if (typeof instance.format !== "string" || instance.format.length === 0) { + instance.format = "hls"; + } + }; + var initializePodStreamRequest = function initializePodStreamRequest(instance, podStreamRequest) { + initializeStreamRequest(instance, podStreamRequest); + instance.customAssetKey = typeof instance.customAssetKey === "string" ? instance.customAssetKey : ""; + }; + var EventHandler = function EventHandler() { + initializeEventHandler(this); + }; + EventHandler.prototype.addEventListener = function(type, listener) { + if (typeof listener !== "function") { + return; + } + var eventTypes = normalizeEventTypes(type); + for (var eventTypeIndex = 0; eventTypeIndex < eventTypes.length; eventTypeIndex += 1) { + var eventType = eventTypes[eventTypeIndex]; + if (!this.listeners.has(eventType)) { + this.listeners.set(eventType, new Set); + } + var listeners = this.listeners.get(eventType); + if (listeners) { + listeners.add(listener); + } + } + }; + EventHandler.prototype.removeEventListener = function(type, listener) { + if (typeof listener !== "function") { + return; + } + var eventTypes = normalizeEventTypes(type); + for (var eventTypeIndex = 0; eventTypeIndex < eventTypes.length; eventTypeIndex += 1) { + var listeners = this.listeners.get(eventTypes[eventTypeIndex]); + if (!listeners) { + continue; + } + listeners.delete(listener); + } + }; + EventHandler.prototype.dispatchEvent = function(streamEvent) { + var listeners = this.listeners.get(streamEvent.type); + if (!listeners) { + return; + } + for (var _i = 0, _Array$from = Array.from(listeners); _i < _Array$from.length; _i++) { + var _listener = _Array$from[_i]; + try { + _listener(streamEvent); + } catch (error) { + logMessage(source, error); + } + } + }; + var StreamRequest = function StreamRequest(streamRequest) { + initializeStreamRequest(this, streamRequest); + }; + var LiveStreamRequest = function LiveStreamRequest(liveStreamRequest) { + initializeStreamRequest(this, liveStreamRequest); + this.assetKey = typeof this.assetKey === "string" ? this.assetKey : ""; + }; + Object.setPrototypeOf(LiveStreamRequest.prototype, StreamRequest.prototype); + var PodStreamRequest = function PodStreamRequest(podStreamRequest) { + initializePodStreamRequest(this, podStreamRequest); + }; + Object.setPrototypeOf(PodStreamRequest.prototype, StreamRequest.prototype); + var VideoStitcherLiveStreamRequest = function VideoStitcherLiveStreamRequest(videoStitcherLiveStreamRequest) { + initializePodStreamRequest(this, videoStitcherLiveStreamRequest); + this.liveStreamEventId = typeof this.liveStreamEventId === "string" ? this.liveStreamEventId : ""; + this.oAuthToken = typeof this.oAuthToken === "string" ? this.oAuthToken : null; + this.projectNumber = typeof this.projectNumber === "string" ? this.projectNumber : null; + this.region = typeof this.region === "string" ? this.region : null; + this.videoStitcherSessionOptions = isRecord(this.videoStitcherSessionOptions) ? this.videoStitcherSessionOptions : null; + }; + Object.setPrototypeOf(VideoStitcherLiveStreamRequest.prototype, PodStreamRequest.prototype); + var VideoStitcherVodStreamRequest = function VideoStitcherVodStreamRequest(videoStitcherVodStreamRequest) { + initializeStreamRequest(this, videoStitcherVodStreamRequest); + this.adTagUrl = typeof this.adTagUrl === "string" ? this.adTagUrl : ""; + this.contentSourceUrl = typeof this.contentSourceUrl === "string" ? this.contentSourceUrl : ""; + this.oAuthToken = typeof this.oAuthToken === "string" ? this.oAuthToken : null; + this.projectNumber = typeof this.projectNumber === "string" ? this.projectNumber : null; + this.region = typeof this.region === "string" ? this.region : null; + this.videoStitcherSessionOptions = isRecord(this.videoStitcherSessionOptions) ? this.videoStitcherSessionOptions : null; + this.vodConfigId = typeof this.vodConfigId === "string" ? this.vodConfigId : ""; + }; + Object.setPrototypeOf(VideoStitcherVodStreamRequest.prototype, StreamRequest.prototype); + var VODStreamRequest = function VODStreamRequest(vodStreamRequest) { + initializeStreamRequest(this, vodStreamRequest); + this.contentSourceId = typeof this.contentSourceId === "string" ? this.contentSourceId : ""; + this.videoId = typeof this.videoId === "string" ? this.videoId : ""; + }; + Object.setPrototypeOf(VODStreamRequest.prototype, StreamRequest.prototype); + var StreamData = function StreamData(streamData) { + this.adPeriodData = null; + this.adProgressData = null; + this.cuepoints = []; + this.errorMessage = null; + this.manifestFormat = "HLS"; + this.streamId = null; + this.subtitles = []; + this.url = ""; + if (isRecord(streamData)) { + Object.assign(this, streamData); + } + }; + var StreamEvent = function StreamEvent(type, streamData, ad) { + this.type = type; + this.streamData = streamData || new StreamData; + this.ad = ad || null; + }; + StreamEvent.Type = streamEventTypes; + StreamEvent.prototype.getAd = function() { + return this.ad; + }; + StreamEvent.prototype.getStreamData = function() { + return this.streamData; + }; + var UiSettings = function UiSettings() { + this.locale = ""; + }; + UiSettings.prototype.getLocale = function() { + return this.locale; + }; + UiSettings.prototype.setLocale = function(locale) { + this.locale = locale; + }; + var daiSdkFeatureFlagsStorage = new WeakMap; + var getStoredDaiSdkFeatureFlags = function getStoredDaiSdkFeatureFlags(instance) { + var storedFeatureFlags = daiSdkFeatureFlagsStorage.get(instance); + if (storedFeatureFlags) { + return storedFeatureFlags; + } + var nextFeatureFlags = {}; + daiSdkFeatureFlagsStorage.set(instance, nextFeatureFlags); + return nextFeatureFlags; + }; + var DaiSdkSettingsContainer = function DaiSdkSettingsContainer() { + daiSdkFeatureFlagsStorage.set(this, {}); + }; + DaiSdkSettingsContainer.prototype.getFeatureFlags = function() { + return getStoredDaiSdkFeatureFlags(this); + }; + DaiSdkSettingsContainer.prototype.setFeatureFlags = function(featureFlags) { + daiSdkFeatureFlagsStorage.set(this, Object.assign({}, featureFlags)); + }; + var normalizeStreamRequest = function normalizeStreamRequest(streamRequest) { + if (streamRequest instanceof StreamRequest) { + return streamRequest; + } + if (isRecord(streamRequest)) { + if (typeof streamRequest.liveStreamEventId === "string") { + return new VideoStitcherLiveStreamRequest(streamRequest); + } + if (typeof streamRequest.contentSourceUrl === "string" || typeof streamRequest.vodConfigId === "string" || typeof streamRequest.adTagUrl === "string") { + return new VideoStitcherVodStreamRequest(streamRequest); + } + if (typeof streamRequest.customAssetKey === "string") { + return new PodStreamRequest(streamRequest); + } + if (typeof streamRequest.assetKey === "string") { + return new LiveStreamRequest(streamRequest); + } + if (typeof streamRequest.contentSourceId === "string" || typeof streamRequest.videoId === "string") { + return new VODStreamRequest(streamRequest); + } + } + return new StreamRequest; + }; + var hasLiveIdentifiers = function hasLiveIdentifiers(streamRequest) { + var liveStreamRequest = streamRequest; + return typeof liveStreamRequest.assetKey === "string" && liveStreamRequest.assetKey.length > 0; + }; + var hasVideoStitcherLiveIdentifiers = function hasVideoStitcherLiveIdentifiers(streamRequest) { + var videoStitcherLiveStreamRequest = streamRequest; + return typeof videoStitcherLiveStreamRequest.liveStreamEventId === "string" && videoStitcherLiveStreamRequest.liveStreamEventId.length > 0; + }; + var hasPodIdentifiers = function hasPodIdentifiers(streamRequest) { + var podStreamRequest = streamRequest; + return typeof podStreamRequest.networkCode === "string" && podStreamRequest.networkCode.length > 0 && typeof podStreamRequest.customAssetKey === "string" && podStreamRequest.customAssetKey.length > 0; + }; + var hasVideoStitcherVodIdentifiers = function hasVideoStitcherVodIdentifiers(streamRequest) { + var videoStitcherVodStreamRequest = streamRequest; + var hasContentSourceUrl = typeof videoStitcherVodStreamRequest.contentSourceUrl === "string" && videoStitcherVodStreamRequest.contentSourceUrl.length > 0; + var hasVodConfigId = typeof videoStitcherVodStreamRequest.vodConfigId === "string" && videoStitcherVodStreamRequest.vodConfigId.length > 0; + return hasContentSourceUrl || hasVodConfigId; + }; + var hasVodIdentifiers = function hasVodIdentifiers(streamRequest) { + var vodStreamRequest = streamRequest; + return typeof vodStreamRequest.contentSourceId === "string" && vodStreamRequest.contentSourceId.length > 0 && typeof vodStreamRequest.videoId === "string" && vodStreamRequest.videoId.length > 0; + }; + var hasIdentifiers = function hasIdentifiers(streamRequest) { + return hasLiveIdentifiers(streamRequest) || hasPodIdentifiers(streamRequest) || hasVideoStitcherLiveIdentifiers(streamRequest) || hasVideoStitcherVodIdentifiers(streamRequest) || hasVodIdentifiers(streamRequest); + }; + var getFallbackStreamId = function getFallbackStreamId(streamRequest) { + var liveStreamRequest = streamRequest; + var videoStitcherLiveStreamRequest = streamRequest; + var videoStitcherVodStreamRequest = streamRequest; + var vodStreamRequest = streamRequest; + if (typeof videoStitcherVodStreamRequest.vodConfigId === "string" && videoStitcherVodStreamRequest.vodConfigId.length > 0) { + return `mock-video-stitcher-vod-${videoStitcherVodStreamRequest.vodConfigId}`; + } + if (typeof videoStitcherVodStreamRequest.contentSourceUrl === "string" && videoStitcherVodStreamRequest.contentSourceUrl.length > 0) { + return "mock-video-stitcher-vod"; + } + if (typeof videoStitcherLiveStreamRequest.liveStreamEventId === "string" && videoStitcherLiveStreamRequest.liveStreamEventId.length > 0) { + return `mock-video-stitcher-live-${videoStitcherLiveStreamRequest.liveStreamEventId}`; + } + if (typeof liveStreamRequest.assetKey === "string" && liveStreamRequest.assetKey.length > 0) { + return `mock-live-${liveStreamRequest.assetKey}`; + } + if (typeof vodStreamRequest.videoId === "string" && vodStreamRequest.videoId.length > 0) { + return `mock-vod-${vodStreamRequest.videoId}`; + } + return "mock-stream"; + }; + var getDefaultManifestFormat = function getDefaultManifestFormat(streamRequest) { + return typeof streamRequest.format === "string" && streamRequest.format.toLowerCase() === "dash" ? "DASH" : "HLS"; + }; + var createStreamData = function createStreamData(streamRequest, cuepoints, errorMessage, streamDataOverrides) { + var streamData = new StreamData({ + cuepoints: cuepoints.slice(), + errorMessage: errorMessage, + manifestFormat: getDefaultManifestFormat(streamRequest), + streamId: getFallbackStreamId(streamRequest), + url: "" + }); + if (isRecord(streamDataOverrides)) { + Object.assign(streamData, streamDataOverrides); + } + return streamData; + }; + var appendRequestParameters = function appendRequestParameters(requestUrl, streamRequest) { + var parameterNames = Object.keys(streamRequest.adTagParameters); + for (var parameterIndex = 0; parameterIndex < parameterNames.length; parameterIndex += 1) { + var parameterName = parameterNames[parameterIndex]; + requestUrl.searchParams.set(parameterName, streamRequest.adTagParameters[parameterName]); + } + if (streamRequest.apiKey) { + requestUrl.searchParams.set("api-key", streamRequest.apiKey); + } + if (streamRequest.authToken) { + requestUrl.searchParams.set("auth-token", streamRequest.authToken); + } + if (streamRequest.streamActivityMonitorId) { + requestUrl.searchParams.set("dai-sam-id", streamRequest.streamActivityMonitorId); + } + }; + var buildLiveRequestUrl = function buildLiveRequestUrl(streamRequest, hostName) { + var requestUrl = new URL(`${hostName}/ssai/event/${streamRequest.assetKey}/streams`); + appendRequestParameters(requestUrl, streamRequest); + return requestUrl.toString(); + }; + var buildPodRequestUrl = function buildPodRequestUrl(streamRequest, hostName) { + var requestUrl = new URL(`${hostName}/ssai/pods/api/v1/network/${streamRequest.networkCode}` + `/custom_asset/${streamRequest.customAssetKey}/stream`); + var manifestType = streamRequest.format.toLowerCase() === "dash" ? "dash" : "hls"; + appendRequestParameters(requestUrl, streamRequest); + requestUrl.searchParams.set("manifest-type", manifestType); + return requestUrl.toString(); + }; + var buildVodRequestUrl = function buildVodRequestUrl(streamRequest, hostName) { + var requestFormat = streamRequest.format.toLowerCase() === "dash" ? "dash" : "hls"; + var requestUrl = new URL(`${hostName}/ondemand/${requestFormat}/content/${streamRequest.contentSourceId}` + `/vid/${streamRequest.videoId}/streams`); + appendRequestParameters(requestUrl, streamRequest); + return requestUrl.toString(); + }; + var MAIN_HOST_NAME = "https://dai.google.com"; + var FALLBACK_HOST_NAME = "https://pubads.g.doubleclick.net"; + var getStreamRequestUrls = function getStreamRequestUrls(streamRequest) { + if (hasPodIdentifiers(streamRequest)) { + return [ buildPodRequestUrl(streamRequest, MAIN_HOST_NAME), buildPodRequestUrl(streamRequest, FALLBACK_HOST_NAME) ]; + } + if (hasLiveIdentifiers(streamRequest)) { + return [ buildLiveRequestUrl(streamRequest, MAIN_HOST_NAME), buildLiveRequestUrl(streamRequest, FALLBACK_HOST_NAME) ]; + } + if (hasVodIdentifiers(streamRequest)) { + return [ buildVodRequestUrl(streamRequest, MAIN_HOST_NAME), buildVodRequestUrl(streamRequest, FALLBACK_HOST_NAME) ]; + } + return []; + }; + var readFetchResponseData = async function readFetchResponseData(response) { + var typedResponse = response; + if (typedResponse && typedResponse.ok === false) { + throw new Error(`Stream initialization failed with status ${String(typedResponse.status || 0)}`); + } + if (typedResponse && typeof typedResponse.json === "function") { + var jsonResponse = await typedResponse.json(); + return isRecord(jsonResponse) ? jsonResponse : {}; + } + return isRecord(response) ? response : {}; + }; + var getResponseErrorMessage = function getResponseErrorMessage(responseData) { + return getStringValue(responseData.errorMessage) || getStringValue(responseData.error_message); + }; + var createStreamDataFromResponse = function createStreamDataFromResponse(streamRequest, cuepoints, responseData) { + var podManifestUrl = getStringValue(responseData.pod_manifest_url) || getStringValue(responseData.podManifestUrl) || ""; + var responseStreamId = getStringValue(responseData.stream_id) || getStringValue(responseData.streamId); + var streamUrl = getStringValue(responseData.stream_manifest) || getStringValue(responseData.streamUrl) || podManifestUrl || ""; + var responseErrorMessage = getResponseErrorMessage(responseData); + var hasInitializedStream = streamUrl.length > 0 || responseStreamId !== null && responseStreamId.length > 0; + var errorMessage = responseErrorMessage || (hasInitializedStream ? null : "Stream initialization response missing stream URL"); + var manifestFormat = getStringValue(responseData.manifest_format) || getStringValue(responseData.manifestFormat) || getDefaultManifestFormat(streamRequest); + var streamId = responseStreamId || getFallbackStreamId(streamRequest); + var subtitles = Array.isArray(responseData.subtitles) ? responseData.subtitles : []; + return createStreamData(streamRequest, cuepoints, errorMessage, { + manifestFormat: manifestFormat, + podManifestUrl: podManifestUrl, + pod_manifest_url: podManifestUrl, + streamId: streamId, + subtitles: subtitles, + url: streamUrl + }); + }; + var getErrorMessage = function getErrorMessage(error) { + if (isRecord(error) && typeof error.message === "string" && error.message.length > 0) { + return error.message; + } + return "Stream initialization failed"; + }; + var hideAdUiElement = function hideAdUiElement(streamManager) { + if (!streamManager.adUiElement) { + return; + } + streamManager.adUiElement.style.display = "none"; + }; + var showVideoControls = function showVideoControls(streamManager) { + if (!streamManager.videoElement || streamManager.videoElement.controls) { + return; + } + streamManager.videoElement.controls = true; + }; + var handleContentLoaded = function handleContentLoaded(streamManager) { + hideAdUiElement(streamManager); + showVideoControls(streamManager); + }; + var isContentLoadedEventType = function isContentLoadedEventType(eventType) { + return eventType === StreamEvent.Type.LOADED || eventType === StreamEvent.Type.STREAM_INITIALIZED; + }; + var StreamManager = function StreamManager(videoElement, adUiElement, uiSettings) { + initializeEventHandler(this); + this.videoElement = videoElement || null; + this.adUiElement = adUiElement || null; + this.uiSettings = uiSettings || new UiSettings; + this.clickElement = adUiElement || null; + this.streamData = new StreamData; + this.streamMonitor = {}; + this.streamRequest = null; + this.cuepoints = []; + this.lastMetadata = null; + this.lastTimedMetadata = null; + }; + Object.setPrototypeOf(StreamManager.prototype, EventHandler.prototype); + StreamManager.prototype.contentTimeForStreamTime = function(streamTime) { + return typeof streamTime === "number" ? streamTime : 0; + }; + StreamManager.prototype.destroy = function() { + this.reset(); + }; + StreamManager.prototype.focus = function() { + var clickElement = this.clickElement; + if (!clickElement || typeof clickElement.focus !== "function") { + return; + } + try { + clickElement.focus(); + } catch (error) { + logMessage(source, error); + } + }; + StreamManager.prototype.getAdSkippableState = function() { + return true; + }; + StreamManager.prototype.getStreamData = function() { + return this.streamData; + }; + StreamManager.prototype.loadStreamMetadata = function() { + handleContentLoaded(this); + this.dispatchEvent(new StreamEvent(StreamEvent.Type.LOADED, this.streamData)); + }; + StreamManager.prototype.onTimedMetadata = function(metadata) { + this.lastTimedMetadata = metadata; + }; + StreamManager.prototype.previousCuePointForStreamTime = function(streamTime) { + var previousCuePoint = null; + for (var cuepointIndex = 0; cuepointIndex < this.cuepoints.length; cuepointIndex += 1) { + var cuepoint = this.cuepoints[cuepointIndex]; + if (typeof cuepoint.start !== "number") { + continue; + } + if (cuepoint.start <= streamTime) { + previousCuePoint = cuepoint; + } + } + return previousCuePoint; + }; + StreamManager.prototype.processMetadata = function(type, data, timestamp) { + this.lastMetadata = { + data: data, + timestamp: timestamp, + type: type + }; + }; + StreamManager.prototype.replaceAdTagParameters = function(adTagParameters) { + if (!this.streamRequest) { + this.streamRequest = new StreamRequest; + } + this.streamRequest.adTagParameters = toStringRecord(adTagParameters); + }; + StreamManager.prototype.requestStream = function(streamRequest) { + var _this = this; + var normalizedRequest = normalizeStreamRequest(streamRequest); + this.streamRequest = normalizedRequest; + var dispatchStreamEvent = function dispatchStreamEvent(eventType, streamData) { + _this.streamData = streamData; + if (isContentLoadedEventType(eventType)) { + handleContentLoaded(_this); + } + schedule((function() { + _this.dispatchEvent(new StreamEvent(StreamEvent.Type.STREAM_INITIALIZED, streamData)); + _this.dispatchEvent(new StreamEvent(eventType, streamData)); + })); + }; + if (!hasIdentifiers(normalizedRequest)) { + dispatchStreamEvent(StreamEvent.Type.ERROR, createStreamData(normalizedRequest, this.cuepoints, "Missing stream request identifiers")); + return; + } + var requestUrls = getStreamRequestUrls(normalizedRequest); + if (requestUrls.length > 0) { + var activeRequest = normalizedRequest; + var _fetchStreamData = async function fetchStreamData(requestIndex) { + try { + var fetchResponse = await fetch(requestUrls[requestIndex], { + method: "POST", + credentials: "include" + }); + var responseData = await readFetchResponseData(fetchResponse); + if (_this.streamRequest !== activeRequest) { + return; + } + var _streamData = createStreamDataFromResponse(activeRequest, _this.cuepoints, responseData); + var eventType = _streamData.errorMessage ? StreamEvent.Type.ERROR : StreamEvent.Type.LOADED; + dispatchStreamEvent(eventType, _streamData); + } catch (error) { + if (_this.streamRequest !== activeRequest) { + return; + } + if (requestIndex + 1 < requestUrls.length) { + await _fetchStreamData(requestIndex + 1); + return; + } + dispatchStreamEvent(StreamEvent.Type.ERROR, createStreamData(activeRequest, _this.cuepoints, getErrorMessage(error))); + } + }; + _fetchStreamData(0); + return; + } + dispatchStreamEvent(StreamEvent.Type.LOADED, createStreamData(normalizedRequest, this.cuepoints, null)); + }; + StreamManager.prototype.reset = function() { + this.cuepoints = []; + this.lastMetadata = null; + this.lastTimedMetadata = null; + this.streamData = new StreamData; + this.streamRequest = null; + }; + StreamManager.prototype.setClickElement = function(clickElement) { + if (this.adUiElement) { + return; + } + this.clickElement = clickElement; + }; + StreamManager.prototype.streamTimeForContentTime = function(contentTime) { + return typeof contentTime === "number" ? contentTime : 0; + }; + var api = { + DaiSdkSettings: new DaiSdkSettingsContainer, + LiveStreamRequest: LiveStreamRequest, + PodStreamRequest: PodStreamRequest, + StreamData: StreamData, + StreamEvent: StreamEvent, + StreamManager: StreamManager, + StreamRequest: StreamRequest, + UiSettings: UiSettings, + VideoStitcherLiveStreamRequest: VideoStitcherLiveStreamRequest, + VideoStitcherVodStreamRequest: VideoStitcherVodStreamRequest, + VODStreamRequest: VODStreamRequest + }; + var globalWindow = window; + var googleNamespace = isRecord(globalWindow.google) ? globalWindow.google : {}; + if (!isRecord(globalWindow.google)) { + globalWindow.google = googleNamespace; + } + var imaNamespace = isRecord(googleNamespace.ima) ? googleNamespace.ima : {}; + googleNamespace.ima = imaNamespace; + var daiNamespace = isRecord(imaNamespace.dai) ? imaNamespace.dai : {}; + imaNamespace.dai = daiNamespace; + var apiNamespace = isRecord(daiNamespace.api) ? daiNamespace.api : {}; + daiNamespace.api = apiNamespace; + Object.assign(apiNamespace, api); + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function logMessage(e, o) { + var r = arguments.length > 2 && void 0 !== arguments[2] && arguments[2], a = !(arguments.length > 3 && void 0 !== arguments[3]) || arguments[3], {name: n, verbose: g} = e; + if (r || g) { + var i = console.log; + a ? i(`${n}: ${o}`) : Array.isArray(o) ? i(`${n}:`, ...o) : i(`${n}:`, o); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + GoogleIma3Dai.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "google-ima3-dai", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-ima3.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-ima3.js new file mode 100644 index 0000000..24b85bf --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/google-ima3.js @@ -0,0 +1,646 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function GoogleIma3(source) { + var _window$google$ima; + var VERSION = "3.746.0"; + var ima = {}; + var AdDisplayContainer = function AdDisplayContainer(containerElement) { + var divElement = document.createElement("div"); + divElement.style.setProperty("display", "none", "important"); + divElement.style.setProperty("visibility", "collapse", "important"); + if (containerElement) { + containerElement.appendChild(divElement); + } + }; + AdDisplayContainer.prototype.destroy = noopFunc; + AdDisplayContainer.prototype.initialize = noopFunc; + var ImaSdkSettings = function ImaSdkSettings() {}; + ImaSdkSettings.CompanionBackfillMode = { + ALWAYS: "always", + ON_MASTER_AD: "on_master_ad" + }; + ImaSdkSettings.VpaidMode = { + DISABLED: 0, + ENABLED: 1, + INSECURE: 2 + }; + ImaSdkSettings.prototype = { + c: true, + f: {}, + i: false, + l: "", + p: "", + r: 0, + t: "", + v: "", + getCompanionBackfill: noopFunc, + getDisableCustomPlaybackForIOS10Plus() { + return this.i; + }, + getDisabledFlashAds: function getDisabledFlashAds() { + return true; + }, + getFeatureFlags() { + return this.f; + }, + getLocale() { + return this.l; + }, + getNumRedirects() { + return this.r; + }, + getPlayerType() { + return this.t; + }, + getPlayerVersion() { + return this.v; + }, + getPpid() { + return this.p; + }, + getVpaidMode() { + return this.C; + }, + isCookiesEnabled() { + return this.c; + }, + isVpaidAdapter() { + return this.M; + }, + setCompanionBackfill: noopFunc, + setAutoPlayAdBreaks(a) { + this.K = a; + }, + setCookiesEnabled(c) { + this.c = !!c; + }, + setDisableCustomPlaybackForIOS10Plus(i) { + this.i = !!i; + }, + setDisableFlashAds: noopFunc, + setFeatureFlags(f) { + this.f = !!f; + }, + setIsVpaidAdapter(a) { + this.M = a; + }, + setLocale(l) { + this.l = !!l; + }, + setNumRedirects(r) { + this.r = !!r; + }, + setPageCorrelator(a) { + this.R = a; + }, + setPlayerType(t) { + this.t = !!t; + }, + setPlayerVersion(v) { + this.v = !!v; + }, + setPpid(p) { + this.p = !!p; + }, + setVpaidMode(a) { + this.C = a; + }, + setSessionId: noopFunc, + setStreamCorrelator: noopFunc, + setVpaidAllowed: noopFunc, + CompanionBackfillMode: { + ALWAYS: "always", + ON_MASTER_AD: "on_master_ad" + }, + VpaidMode: { + DISABLED: 0, + ENABLED: 1, + INSECURE: 2 + } + }; + var EventHandler = function EventHandler() { + this.listeners = new Map; + this._dispatch = function(e) { + var listeners = this.listeners.get(e.type); + listeners = listeners ? listeners.values() : []; + for (var _i = 0, _Array$from = Array.from(listeners); _i < _Array$from.length; _i++) { + var listener = _Array$from[_i]; + try { + listener(e); + } catch (r) { + logMessage(source, r); + } + } + }; + this.addEventListener = function(types, callback, options, context) { + if (!Array.isArray(types)) { + types = [ types ]; + } + for (var i = 0; i < types.length; i += 1) { + var type = types[i]; + if (!this.listeners.has(type)) { + this.listeners.set(type, new Map); + } + this.listeners.get(type).set(callback, callback.bind(context || this)); + } + }; + this.removeEventListener = function(types, callback) { + if (!Array.isArray(types)) { + types = [ types ]; + } + for (var i = 0; i < types.length; i += 1) { + var _this$listeners$get; + var type = types[i]; + (_this$listeners$get = this.listeners.get(type)) === null || _this$listeners$get === void 0 || _this$listeners$get.delete(callback); + } + }; + }; + var AdsManager = new EventHandler; + AdsManager.volume = 1; + AdsManager.collapse = noopFunc; + AdsManager.configureAdsManager = noopFunc; + AdsManager.destroy = noopFunc; + AdsManager.discardAdBreak = noopFunc; + AdsManager.expand = noopFunc; + AdsManager.focus = noopFunc; + AdsManager.getAdSkippableState = function() { + return false; + }; + AdsManager.getCuePoints = function() { + return [ 0 ]; + }; + AdsManager.getCurrentAd = function() { + return currentAd; + }; + AdsManager.getCurrentAdCuePoints = function() { + return []; + }; + AdsManager.getRemainingTime = function() { + return 0; + }; + AdsManager.getVolume = function() { + return this.volume; + }; + AdsManager.init = noopFunc; + AdsManager.isCustomClickTrackingUsed = function() { + return false; + }; + AdsManager.isCustomPlaybackUsed = function() { + return false; + }; + AdsManager.pause = noopFunc; + AdsManager.requestNextAdBreak = noopFunc; + AdsManager.resize = noopFunc; + AdsManager.resume = noopFunc; + AdsManager.setVolume = function(v) { + this.volume = v; + }; + AdsManager.skip = noopFunc; + AdsManager.start = function() { + for (var _i2 = 0, _arr = [ AdEvent.Type.ALL_ADS_COMPLETED, AdEvent.Type.CONTENT_RESUME_REQUESTED ]; _i2 < _arr.length; _i2++) { + var type = _arr[_i2]; + try { + this._dispatch(new ima.AdEvent(type)); + } catch (e) { + logMessage(source, e); + } + } + }; + AdsManager.stop = noopFunc; + AdsManager.updateAdsRenderingSettings = noopFunc; + var manager = Object.create(AdsManager); + var AdsManagerLoadedEvent = function AdsManagerLoadedEvent(type, adsRequest, userRequestContext) { + this.type = type; + this.adsRequest = adsRequest; + this.userRequestContext = userRequestContext; + }; + AdsManagerLoadedEvent.prototype = { + getAdsManager: function getAdsManager() { + return manager; + }, + getUserRequestContext() { + if (this.userRequestContext) { + return this.userRequestContext; + } + return {}; + } + }; + AdsManagerLoadedEvent.Type = { + ADS_MANAGER_LOADED: "adsManagerLoaded" + }; + var AdsLoader = EventHandler; + AdsLoader.prototype.settings = new ImaSdkSettings; + AdsLoader.prototype.contentComplete = noopFunc; + AdsLoader.prototype.destroy = noopFunc; + AdsLoader.prototype.getSettings = function() { + return this.settings; + }; + AdsLoader.prototype.getVersion = function() { + return VERSION; + }; + AdsLoader.prototype.requestAds = function(adsRequest, userRequestContext) { + var _this = this; + requestAnimationFrame((function() { + var {ADS_MANAGER_LOADED: ADS_MANAGER_LOADED} = AdsManagerLoadedEvent.Type; + var event = new ima.AdsManagerLoadedEvent(ADS_MANAGER_LOADED, adsRequest, userRequestContext); + _this._dispatch(event); + })); + var e = new ima.AdError("adPlayError", 1205, 1205, "The browser prevented playback initiated without user interaction.", adsRequest, userRequestContext); + requestAnimationFrame((function() { + _this._dispatch(new ima.AdErrorEvent(e)); + })); + }; + var AdsRenderingSettings = noopFunc; + var AdsRequest = function AdsRequest() {}; + AdsRequest.prototype = { + setAdWillAutoPlay: noopFunc, + setAdWillPlayMuted: noopFunc, + setContinuousPlayback: noopFunc + }; + var AdPodInfo = function AdPodInfo() {}; + AdPodInfo.prototype = { + getAdPosition: function getAdPosition() { + return 1; + }, + getIsBumper: function getIsBumper() { + return false; + }, + getMaxDuration: function getMaxDuration() { + return -1; + }, + getPodIndex: function getPodIndex() { + return 1; + }, + getTimeOffset: function getTimeOffset() { + return 0; + }, + getTotalAds: function getTotalAds() { + return 1; + } + }; + var UniversalAdIdInfo = function UniversalAdIdInfo() {}; + UniversalAdIdInfo.prototype.getAdIdRegistry = function() { + return ""; + }; + UniversalAdIdInfo.prototype.getAdIsValue = function() { + return ""; + }; + var Ad = function Ad() {}; + Ad.prototype = { + pi: new AdPodInfo, + getAdId: function getAdId() { + return ""; + }, + getAdPodInfo() { + return this.pi; + }, + getAdSystem: function getAdSystem() { + return ""; + }, + getAdvertiserName: function getAdvertiserName() { + return ""; + }, + getApiFramework: function getApiFramework() { + return null; + }, + getCompanionAds: function getCompanionAds() { + return []; + }, + getContentType: function getContentType() { + return ""; + }, + getCreativeId: function getCreativeId() { + return ""; + }, + getCreativeAdId: function getCreativeAdId() { + return ""; + }, + getDealId: function getDealId() { + return ""; + }, + getDescription: function getDescription() { + return ""; + }, + getDuration: function getDuration() { + return 8.5; + }, + getHeight: function getHeight() { + return 0; + }, + getMediaUrl: function getMediaUrl() { + return null; + }, + getMinSuggestedDuration: function getMinSuggestedDuration() { + return -2; + }, + getSkipTimeOffset: function getSkipTimeOffset() { + return -1; + }, + getSurveyUrl: function getSurveyUrl() { + return null; + }, + getTitle: function getTitle() { + return ""; + }, + getTraffickingParametersString: function getTraffickingParametersString() { + return ""; + }, + getUiElements: function getUiElements() { + return [ "" ]; + }, + getUniversalAdIdRegistry: function getUniversalAdIdRegistry() { + return "unknown"; + }, + getUniversalAdIds: function getUniversalAdIds() { + return [ new UniversalAdIdInfo ]; + }, + getUniversalAdIdValue: function getUniversalAdIdValue() { + return "unknown"; + }, + getVastMediaBitrate: function getVastMediaBitrate() { + return 0; + }, + getVastMediaHeight: function getVastMediaHeight() { + return 0; + }, + getVastMediaWidth: function getVastMediaWidth() { + return 0; + }, + getWidth: function getWidth() { + return 0; + }, + getWrapperAdIds: function getWrapperAdIds() { + return [ "" ]; + }, + getWrapperAdSystems: function getWrapperAdSystems() { + return [ "" ]; + }, + getWrapperCreativeIds: function getWrapperCreativeIds() { + return [ "" ]; + }, + isLinear: function isLinear() { + return true; + }, + isSkippable() { + return true; + } + }; + var CompanionAd = function CompanionAd() {}; + CompanionAd.prototype = { + getAdSlotId: function getAdSlotId() { + return ""; + }, + getContent: function getContent() { + return ""; + }, + getContentType: function getContentType() { + return ""; + }, + getHeight: function getHeight() { + return 1; + }, + getWidth: function getWidth() { + return 1; + } + }; + var AdError = function AdError(type, code, vast, message, adsRequest, userRequestContext) { + this.errorCode = code; + this.message = message; + this.type = type; + this.adsRequest = adsRequest; + this.userRequestContext = userRequestContext; + this.getErrorCode = function() { + return this.errorCode; + }; + this.getInnerError = function() { + return null; + }; + this.getMessage = function() { + return this.message; + }; + this.getType = function() { + return this.type; + }; + this.getVastErrorCode = function() { + return this.vastErrorCode; + }; + this.toString = function() { + return `AdError ${this.errorCode}: ${this.message}`; + }; + }; + AdError.ErrorCode = {}; + AdError.Type = {}; + var isEngadget = function isEngadget() { + try { + for (var _i3 = 0, _Object$values = Object.values(window.vidible._getContexts()); _i3 < _Object$values.length; _i3++) { + var _ctx$getPlayer; + var ctx = _Object$values[_i3]; + if ((_ctx$getPlayer = ctx.getPlayer()) !== null && _ctx$getPlayer !== void 0 && (_ctx$getPlayer = _ctx$getPlayer.div) !== null && _ctx$getPlayer !== void 0 && _ctx$getPlayer.innerHTML.includes("www.engadget.com")) { + return true; + } + } + } catch (e) {} + return false; + }; + var currentAd = isEngadget() ? undefined : new Ad; + var AdEvent = function AdEvent(type) { + this.type = type; + }; + AdEvent.prototype = { + getAd: function getAd() { + return currentAd; + }, + getAdData: function getAdData() {} + }; + AdEvent.Type = { + AD_BREAK_READY: "adBreakReady", + AD_BUFFERING: "adBuffering", + AD_CAN_PLAY: "adCanPlay", + AD_METADATA: "adMetadata", + AD_PROGRESS: "adProgress", + ALL_ADS_COMPLETED: "allAdsCompleted", + CLICK: "click", + COMPLETE: "complete", + CONTENT_PAUSE_REQUESTED: "contentPauseRequested", + CONTENT_RESUME_REQUESTED: "contentResumeRequested", + DURATION_CHANGE: "durationChange", + EXPANDED_CHANGED: "expandedChanged", + FIRST_QUARTILE: "firstQuartile", + IMPRESSION: "impression", + INTERACTION: "interaction", + LINEAR_CHANGE: "linearChange", + LINEAR_CHANGED: "linearChanged", + LOADED: "loaded", + LOG: "log", + MIDPOINT: "midpoint", + PAUSED: "pause", + RESUMED: "resume", + SKIPPABLE_STATE_CHANGED: "skippableStateChanged", + SKIPPED: "skip", + STARTED: "start", + THIRD_QUARTILE: "thirdQuartile", + USER_CLOSE: "userClose", + VIDEO_CLICKED: "videoClicked", + VIDEO_ICON_CLICKED: "videoIconClicked", + VIEWABLE_IMPRESSION: "viewable_impression", + VOLUME_CHANGED: "volumeChange", + VOLUME_MUTED: "mute" + }; + var AdErrorEvent = function AdErrorEvent(error) { + this.error = error; + this.type = "adError"; + this.getError = function() { + return this.error; + }; + this.getUserRequestContext = function() { + var _this$error; + if ((_this$error = this.error) !== null && _this$error !== void 0 && _this$error.userRequestContext) { + return this.error.userRequestContext; + } + return {}; + }; + }; + AdErrorEvent.Type = { + AD_ERROR: "adError" + }; + var CustomContentLoadedEvent = function CustomContentLoadedEvent() {}; + CustomContentLoadedEvent.Type = { + CUSTOM_CONTENT_LOADED: "deprecated-event" + }; + var CompanionAdSelectionSettings = function CompanionAdSelectionSettings() {}; + CompanionAdSelectionSettings.CreativeType = { + ALL: "All", + FLASH: "Flash", + IMAGE: "Image" + }; + CompanionAdSelectionSettings.ResourceType = { + ALL: "All", + HTML: "Html", + IFRAME: "IFrame", + STATIC: "Static" + }; + CompanionAdSelectionSettings.SizeCriteria = { + IGNORE: "IgnoreSize", + SELECT_EXACT_MATCH: "SelectExactMatch", + SELECT_NEAR_MATCH: "SelectNearMatch" + }; + var AdCuePoints = function AdCuePoints() {}; + AdCuePoints.prototype = { + getCuePoints: function getCuePoints() { + return []; + }, + getAdIdRegistry: function getAdIdRegistry() { + return ""; + }, + getAdIdValue: function getAdIdValue() { + return ""; + } + }; + var AdProgressData = noopFunc; + Object.assign(ima, { + AdCuePoints: AdCuePoints, + AdDisplayContainer: AdDisplayContainer, + AdError: AdError, + AdErrorEvent: AdErrorEvent, + AdEvent: AdEvent, + AdPodInfo: AdPodInfo, + AdProgressData: AdProgressData, + AdsLoader: AdsLoader, + AdsManager: manager, + AdsManagerLoadedEvent: AdsManagerLoadedEvent, + AdsRenderingSettings: AdsRenderingSettings, + AdsRequest: AdsRequest, + CompanionAd: CompanionAd, + CompanionAdSelectionSettings: CompanionAdSelectionSettings, + CustomContentLoadedEvent: CustomContentLoadedEvent, + gptProxyInstance: {}, + ImaSdkSettings: ImaSdkSettings, + OmidAccessMode: { + DOMAIN: "domain", + FULL: "full", + LIMITED: "limited" + }, + OmidVerificationVendor: { + 1: "OTHER", + 2: "MOAT", + 3: "DOUBLEVERIFY", + 4: "INTEGRAL_AD_SCIENCE", + 5: "PIXELATE", + 6: "NIELSEN", + 7: "COMSCORE", + 8: "MEETRICS", + 9: "GOOGLE", + OTHER: 1, + MOAT: 2, + DOUBLEVERIFY: 3, + INTEGRAL_AD_SCIENCE: 4, + PIXELATE: 5, + NIELSEN: 6, + COMSCORE: 7, + MEETRICS: 8, + GOOGLE: 9 + }, + settings: new ImaSdkSettings, + UiElements: { + AD_ATTRIBUTION: "adAttribution", + COUNTDOWN: "countdown" + }, + UniversalAdIdInfo: UniversalAdIdInfo, + VERSION: VERSION, + ViewMode: { + FULLSCREEN: "fullscreen", + NORMAL: "normal" + } + }); + if (!window.google) { + window.google = {}; + } + if ((_window$google$ima = window.google.ima) !== null && _window$google$ima !== void 0 && _window$google$ima.dai) { + ima.dai = window.google.ima.dai; + } + window.google.ima = ima; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function logMessage(e, o) { + var r = arguments.length > 2 && void 0 !== arguments[2] && arguments[2], a = !(arguments.length > 3 && void 0 !== arguments[3]) || arguments[3], {name: n, verbose: g} = e; + if (r || g) { + var i = console.log; + a ? i(`${n}: ${o}`) : Array.isArray(o) ? i(`${n}:`, ...o) : i(`${n}:`, o); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + GoogleIma3.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "google-ima3", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/googlesyndication-adsbygoogle.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/googlesyndication-adsbygoogle.js new file mode 100644 index 0000000..f4705ce --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/googlesyndication-adsbygoogle.js @@ -0,0 +1,91 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function GoogleSyndicationAdsByGoogle(source) { + window.adsbygoogle = { + loaded: true, + push(arg) { + if (typeof this.length === "undefined") { + this.length = 0; + this.length += 1; + } + if (arg !== null && arg instanceof Object && arg.constructor.name === "Object") { + for (var _i = 0, _Object$keys = Object.keys(arg); _i < _Object$keys.length; _i++) { + var key = _Object$keys[_i]; + if (typeof arg[key] === "function") { + try { + arg[key].call(this, {}); + } catch (_unused) {} + } + } + } + } + }; + var adElems = document.querySelectorAll(".adsbygoogle"); + var css = "height:1px!important;max-height:1px!important;max-width:1px!important;width:1px!important;"; + var statusAttrName = "data-adsbygoogle-status"; + var ASWIFT_IFRAME_MARKER = "aswift_"; + var GOOGLE_ADS_IFRAME_MARKER = "google_ads_iframe_"; + var executed = false; + for (var i = 0; i < adElems.length; i += 1) { + var adElemChildNodes = adElems[i].childNodes; + var childNodesQuantity = adElemChildNodes.length; + var areIframesDefined = false; + if (childNodesQuantity > 0) { + areIframesDefined = childNodesQuantity === 2 && adElemChildNodes[0].nodeName.toLowerCase() === "iframe" && adElemChildNodes[0].id.includes(ASWIFT_IFRAME_MARKER) && adElemChildNodes[1].nodeName.toLowerCase() === "iframe" && adElemChildNodes[1].id.includes(GOOGLE_ADS_IFRAME_MARKER); + } + if (!areIframesDefined) { + adElems[i].setAttribute(statusAttrName, "done"); + var aswiftIframe = document.createElement("iframe"); + aswiftIframe.id = `${ASWIFT_IFRAME_MARKER}${i}`; + aswiftIframe.style = css; + adElems[i].appendChild(aswiftIframe); + var innerAswiftIframe = document.createElement("iframe"); + aswiftIframe.contentWindow.document.body.appendChild(innerAswiftIframe); + var googleadsIframe = document.createElement("iframe"); + googleadsIframe.id = `${GOOGLE_ADS_IFRAME_MARKER}${i}`; + googleadsIframe.style = css; + adElems[i].appendChild(googleadsIframe); + var innerGoogleadsIframe = document.createElement("iframe"); + googleadsIframe.contentWindow.document.body.appendChild(innerGoogleadsIframe); + executed = true; + } + } + if (executed) { + hit(source); + } + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + GoogleSyndicationAdsByGoogle.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "googlesyndication-adsbygoogle", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/googletagservices-gpt.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/googletagservices-gpt.js new file mode 100644 index 0000000..5d53e25 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/googletagservices-gpt.js @@ -0,0 +1,496 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function GoogleTagServicesGpt(source) { + var slots = new Map; + var slotsById = new Map; + var slotsPerPath = new Map; + var slotCreatives = new Map; + var eventCallbacks = new Map; + var gTargeting = new Map; + var addEventListener = function addEventListener(name, listener) { + if (!eventCallbacks.has(name)) { + eventCallbacks.set(name, new Set); + } + eventCallbacks.get(name).add(listener); + return this; + }; + var removeEventListener = function removeEventListener(name, listener) { + if (eventCallbacks.has(name)) { + return eventCallbacks.get(name).delete(listener); + } + return false; + }; + var fireSlotEvent = function fireSlotEvent(name, slot) { + return new Promise((function(resolve) { + requestAnimationFrame((function() { + var size = [ 0, 0 ]; + var callbacksSet = eventCallbacks.get(name) || []; + var callbackArray = Array.from(callbacksSet); + for (var i = 0; i < callbackArray.length; i += 1) { + callbackArray[i]({ + isEmpty: true, + size: size, + slot: slot + }); + } + resolve(); + })); + })); + }; + var emptySlotElement = function emptySlotElement(slot) { + var node = document.getElementById(slot.getSlotElementId()); + while (node !== null && node !== void 0 && node.lastChild) { + node.lastChild.remove(); + } + }; + var recreateIframeForSlot = function recreateIframeForSlot(slot) { + var _document$getElementB; + var eid = `google_ads_iframe_${slot.getId()}`; + (_document$getElementB = document.getElementById(eid)) === null || _document$getElementB === void 0 || _document$getElementB.remove(); + var node = document.getElementById(slot.getSlotElementId()); + if (node) { + var f = document.createElement("iframe"); + f.id = eid; + f.srcdoc = "<body></body>"; + f.style = "position:absolute; width:0; height:0; left:0; right:0; z-index:-1; border:0"; + f.setAttribute("width", 0); + f.setAttribute("height", 0); + f.setAttribute("data-load-complete", true); + f.setAttribute("data-google-container-id", true); + f.setAttribute("sandbox", ""); + node.appendChild(f); + } + }; + var displaySlot = function displaySlot(slot) { + if (!slot) { + return; + } + var id = slot.getSlotElementId(); + if (!document.getElementById(id)) { + return; + } + var parent = document.getElementById(id); + if (parent) { + parent.appendChild(document.createElement("div")); + } + emptySlotElement(slot); + recreateIframeForSlot(slot); + fireSlotEvent("slotRenderEnded", slot); + fireSlotEvent("slotRequested", slot); + fireSlotEvent("slotResponseReceived", slot); + fireSlotEvent("slotOnload", slot); + fireSlotEvent("impressionViewable", slot); + }; + var companionAdsService = { + addEventListener: addEventListener, + removeEventListener: removeEventListener, + enableSyncLoading: noopFunc, + setRefreshUnfilledSlots: noopFunc, + getSlots: noopArray + }; + var contentService = { + addEventListener: addEventListener, + removeEventListener: removeEventListener, + setContent: noopFunc + }; + function PassbackSlot() {} + PassbackSlot.prototype.display = noopFunc; + PassbackSlot.prototype.get = noopNull; + PassbackSlot.prototype.set = noopThis; + PassbackSlot.prototype.setClickUrl = noopThis; + PassbackSlot.prototype.setTagForChildDirectedTreatment = noopThis; + PassbackSlot.prototype.setTargeting = noopThis; + PassbackSlot.prototype.updateTargetingFromMap = noopThis; + function SizeMappingBuilder() {} + SizeMappingBuilder.prototype.addSize = noopThis; + SizeMappingBuilder.prototype.build = noopNull; + var getTargetingValue = function getTargetingValue(v) { + if (typeof v === "string") { + return [ v ]; + } + try { + return Array.prototype.flat.call(v); + } catch (_unused) {} + return []; + }; + var updateTargeting = function updateTargeting(targeting, map) { + if (typeof map === "object") { + for (var key in map) { + if (Object.prototype.hasOwnProperty.call(map, key)) { + targeting.set(key, getTargetingValue(map[key])); + } + } + } + }; + var defineSlot = function defineSlot(adUnitPath, creatives, optDiv) { + if (slotsById.has(optDiv)) { + var _document$getElementB2; + (_document$getElementB2 = document.getElementById(optDiv)) === null || _document$getElementB2 === void 0 || _document$getElementB2.remove(); + return slotsById.get(optDiv); + } + var attributes = new Map; + var targeting = new Map; + var exclusions = new Set; + var response = { + advertiserId: undefined, + campaignId: undefined, + creativeId: undefined, + creativeTemplateId: undefined, + lineItemId: undefined + }; + var sizes = [ { + getHeight: function getHeight() { + return 2; + }, + getWidth: function getWidth() { + return 2; + } + } ]; + var num = (slotsPerPath.get(adUnitPath) || 0) + 1; + slotsPerPath.set(adUnitPath, num); + var id = `${adUnitPath}_${num}`; + var clickUrl = ""; + var collapseEmptyDiv = null; + var services = new Set; + var config = {}; + var slot = { + addService(e) { + services.add(e); + return slot; + }, + clearCategoryExclusions: noopThis, + clearTargeting(k) { + if (k === undefined) { + targeting.clear(); + } else { + targeting.delete(k); + } + }, + defineSizeMapping(mapping) { + slotCreatives.set(optDiv, mapping); + return this; + }, + get: function get(k) { + return attributes.get(k); + }, + getAdUnitPath: function getAdUnitPath() { + return adUnitPath; + }, + getAttributeKeys: function getAttributeKeys() { + return Array.from(attributes.keys()); + }, + getCategoryExclusions: function getCategoryExclusions() { + return Array.from(exclusions); + }, + getClickUrl: function getClickUrl() { + return clickUrl; + }, + getCollapseEmptyDiv: function getCollapseEmptyDiv() { + return collapseEmptyDiv; + }, + getConfig: function getConfig(keys) { + var configKeys = Array.isArray(keys) ? keys : [ keys ]; + var googleTagServicesConfig = {}; + for (var i = 0; i < configKeys.length; i += 1) { + var key = configKeys[i]; + if (key === "clickUrl") { + googleTagServicesConfig[key] = clickUrl; + } else if (key === "targeting") { + googleTagServicesConfig[key] = targeting; + } else { + googleTagServicesConfig[key] = config[key]; + } + } + return Object.freeze(googleTagServicesConfig); + }, + getContentUrl: function getContentUrl() { + return ""; + }, + getDivStartsCollapsed: function getDivStartsCollapsed() { + return null; + }, + getDomId: function getDomId() { + return optDiv; + }, + getEscapedQemQueryId: function getEscapedQemQueryId() { + return ""; + }, + getFirstLook: function getFirstLook() { + return 0; + }, + getId: function getId() { + return id; + }, + getHtml: function getHtml() { + return ""; + }, + getName: function getName() { + return id; + }, + getOutOfPage: function getOutOfPage() { + return false; + }, + getResponseInformation: function getResponseInformation() { + return response; + }, + getServices: function getServices() { + return Array.from(services); + }, + getSizes: function getSizes() { + return sizes; + }, + getSlotElementId: function getSlotElementId() { + return optDiv; + }, + getSlotId: function getSlotId() { + return slot; + }, + getTargeting: function getTargeting(k) { + return targeting.get(k) || gTargeting.get(k) || []; + }, + getTargetingKeys: function getTargetingKeys() { + return Array.from(new Set(Array.of(...gTargeting.keys(), ...targeting.keys()))); + }, + getTargetingMap: function getTargetingMap() { + return Object.assign(Object.fromEntries(gTargeting.entries()), Object.fromEntries(targeting.entries())); + }, + set(k, v) { + attributes.set(k, v); + return slot; + }, + setCategoryExclusion(e) { + exclusions.add(e); + return slot; + }, + setClickUrl(u) { + clickUrl = u; + return slot; + }, + setCollapseEmptyDiv(v) { + collapseEmptyDiv = !!v; + return slot; + }, + setConfig(obj) { + try { + var entries = Object.entries(obj); + for (var i = 0; i < entries.length; i += 1) { + var entry = entries[i]; + var key = entry[0]; + var value = entry[1]; + if (key === "clickUrl") { + clickUrl = value; + } else if (key === "targeting") { + updateTargeting(targeting, value); + } else { + config[key] = value; + } + } + } catch (ex) {} + }, + setSafeFrameConfig: noopThis, + setTagForChildDirectedTreatment: noopThis, + setTargeting(k, v) { + targeting.set(k, getTargetingValue(v)); + return slot; + }, + toString: function toString() { + return id; + }, + updateTargetingFromMap(map) { + updateTargeting(targeting, map); + return slot; + } + }; + slots.set(adUnitPath, slot); + slotsById.set(optDiv, slot); + slotCreatives.set(optDiv, creatives); + return slot; + }; + var initialLoadDisabled = false; + var pubAdsService = { + addEventListener: addEventListener, + removeEventListener: removeEventListener, + clear: noopFunc, + clearCategoryExclusions: noopThis, + clearTagForChildDirectedTreatment: noopThis, + clearTargeting(k) { + if (k === undefined) { + gTargeting.clear(); + } else { + gTargeting.delete(k); + } + }, + collapseEmptyDivs: noopFunc, + defineOutOfPagePassback() { + return new PassbackSlot; + }, + definePassback() { + return new PassbackSlot; + }, + disableInitialLoad() { + initialLoadDisabled = true; + }, + display: noopFunc, + enableAsyncRendering: noopFunc, + enableLazyLoad: noopFunc, + enableSingleRequest: noopFunc, + enableSyncRendering: noopFunc, + enableVideoAds: noopFunc, + get: noopNull, + getAttributeKeys: noopArray, + getTargeting: noopArray, + getTargetingKeys: noopArray, + getSlots: noopArray, + isInitialLoadDisabled: function isInitialLoadDisabled() { + return initialLoadDisabled; + }, + refresh: noopFunc, + set: noopThis, + setCategoryExclusion: noopThis, + setCentering: noopFunc, + setCookieOptions: noopThis, + setForceSafeFrame: noopThis, + setLocation: noopThis, + setPrivacySettings: noopThis, + setPublisherProvidedId: noopThis, + setRequestNonPersonalizedAds: noopThis, + setSafeFrameConfig: noopThis, + setTagForChildDirectedTreatment: noopThis, + setTargeting: noopThis, + setVideoContent: noopThis, + updateCorrelator: noopFunc + }; + var config = {}; + var {googletag: googletag = {}} = window; + var {cmd: cmd = []} = googletag; + googletag.apiReady = true; + googletag.cmd = []; + googletag.cmd.push = function(a) { + try { + a(); + } catch (ex) {} + return 1; + }; + googletag.companionAds = function() { + return companionAdsService; + }; + googletag.content = function() { + return contentService; + }; + googletag.defineOutOfPageSlot = defineSlot; + googletag.defineSlot = defineSlot; + googletag.destroySlots = function() { + slots.clear(); + slotsById.clear(); + }; + googletag.disablePublisherConsole = noopFunc; + googletag.display = function(arg) { + var id; + if (arg !== null && arg !== void 0 && arg.getSlotElementId) { + id = arg.getSlotElementId(); + } else if (arg !== null && arg !== void 0 && arg.nodeType) { + id = arg.id; + } else { + id = String(arg); + } + displaySlot(slotsById.get(id)); + }; + googletag.enableServices = noopFunc; + googletag.getConfig = function(keys) { + var configKeys = Array.isArray(keys) ? keys : [ keys ]; + var googleTagServicesConfig = {}; + for (var i = 0; i < configKeys.length; i += 1) { + var key = configKeys[i]; + if (key === "disableInitialLoad") { + googleTagServicesConfig[key] = initialLoadDisabled; + } else if (key === "targeting") { + googleTagServicesConfig[key] = gTargeting; + } else { + googleTagServicesConfig[key] = config[key]; + } + } + return Object.freeze(googleTagServicesConfig); + }; + googletag.getVersion = noopStr; + googletag.pubads = function() { + return pubAdsService; + }; + googletag.pubadsReady = true; + googletag.setAdIframeTitle = noopFunc; + googletag.setConfig = function(obj) { + try { + var entries = Object.entries(obj); + for (var i = 0; i < entries.length; i += 1) { + var entry = entries[i]; + var key = entry[0]; + var value = entry[1]; + if (key === "disableInitialLoad") { + initialLoadDisabled = !!value; + } else if (key === "targeting") { + updateTargeting(gTargeting, value); + } else { + config[key] = value; + } + } + } catch (ex) {} + }; + googletag.sizeMapping = function() { + return new SizeMappingBuilder; + }; + window.googletag = googletag; + while (cmd.length !== 0) { + googletag.cmd.push(cmd.shift()); + } + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopThis() { + return this; + } + function noopNull() { + return null; + } + function noopArray() { + return []; + } + function noopStr() { + return ""; + } + function trueFunc() { + return !0; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + GoogleTagServicesGpt.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "googletagservices-gpt", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/matomo.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/matomo.js new file mode 100644 index 0000000..adac114 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/matomo.js @@ -0,0 +1,53 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function Matomo(source) { + var Tracker = function Tracker() {}; + Tracker.prototype.setDoNotTrack = noopFunc; + Tracker.prototype.setDomains = noopFunc; + Tracker.prototype.setCustomDimension = noopFunc; + Tracker.prototype.trackPageView = noopFunc; + var AsyncTracker = function AsyncTracker() {}; + AsyncTracker.prototype.addListener = noopFunc; + var matomoWrapper = { + getTracker: Tracker, + getAsyncTracker: AsyncTracker + }; + window.Piwik = matomoWrapper; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + Matomo.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "matomo", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/metrika-yandex-tag.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/metrika-yandex-tag.js new file mode 100644 index 0000000..9b49645 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/metrika-yandex-tag.js @@ -0,0 +1,110 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function metrikaYandexTag(source) { + var asyncCallbackFromOptions = function asyncCallbackFromOptions(id, param) { + var options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {}; + var {callback: callback} = options; + var {ctx: ctx} = options; + if (typeof callback === "function") { + callback = ctx !== undefined ? callback.bind(ctx) : callback; + setTimeout((function() { + return callback(); + })); + } + }; + var addFileExtension = noopFunc; + var extLink = asyncCallbackFromOptions; + var file = asyncCallbackFromOptions; + var getClientID = function getClientID(id, cb) { + if (!cb) { + return; + } + setTimeout(cb(null)); + }; + var hitFunc = asyncCallbackFromOptions; + var notBounce = asyncCallbackFromOptions; + var params = noopFunc; + var reachGoal = function reachGoal(id, target, params, callback, ctx) { + asyncCallbackFromOptions(null, null, { + callback: callback, + ctx: ctx + }); + }; + var setUserID = noopFunc; + var userParams = noopFunc; + var destruct = noopFunc; + var api = { + addFileExtension: addFileExtension, + extLink: extLink, + file: file, + getClientID: getClientID, + hit: hitFunc, + notBounce: notBounce, + params: params, + reachGoal: reachGoal, + setUserID: setUserID, + userParams: userParams, + destruct: destruct + }; + function init(id) { + window[`yaCounter${id}`] = api; + document.dispatchEvent(new Event(`yacounter${id}inited`)); + } + function ym(id, funcName) { + if (funcName === "init") { + return init(id); + } + for (var _len = arguments.length, args = new Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) { + args[_key - 2] = arguments[_key]; + } + return api[funcName] && api[funcName](id, ...args); + } + if (typeof window.ym === "undefined") { + window.ym = ym; + ym.a = []; + } else if (window.ym && window.ym.a) { + ym.a = window.ym.a; + window.ym = ym; + window.ym.a.forEach((function(params) { + var id = params[0]; + init(id); + })); + } + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + metrikaYandexTag.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "metrika-yandex-tag", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/metrika-yandex-watch.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/metrika-yandex-watch.js new file mode 100644 index 0000000..456f8b5 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/metrika-yandex-watch.js @@ -0,0 +1,94 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function metrikaYandexWatch(source) { + var cbName = "yandex_metrika_callbacks"; + var asyncCallbackFromOptions = function asyncCallbackFromOptions() { + var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {}; + var {callback: callback} = options; + var {ctx: ctx} = options; + if (typeof callback === "function") { + callback = ctx !== undefined ? callback.bind(ctx) : callback; + setTimeout((function() { + return callback(); + })); + } + }; + function Metrika() {} + Metrika.counters = noopArray; + Metrika.prototype.addFileExtension = noopFunc; + Metrika.prototype.getClientID = noopFunc; + Metrika.prototype.setUserID = noopFunc; + Metrika.prototype.userParams = noopFunc; + Metrika.prototype.params = noopFunc; + Metrika.prototype.counters = noopArray; + Metrika.prototype.extLink = function(url, options) { + asyncCallbackFromOptions(options); + }; + Metrika.prototype.file = function(url, options) { + asyncCallbackFromOptions(options); + }; + Metrika.prototype.hit = function(url, options) { + asyncCallbackFromOptions(options); + }; + Metrika.prototype.reachGoal = function(target, params, cb, ctx) { + asyncCallbackFromOptions({ + callback: cb, + ctx: ctx + }); + }; + Metrika.prototype.notBounce = asyncCallbackFromOptions; + if (window.Ya) { + window.Ya.Metrika = Metrika; + } else { + window.Ya = { + Metrika: Metrika + }; + } + if (window[cbName] && Array.isArray(window[cbName])) { + window[cbName].forEach((function(func) { + if (typeof func === "function") { + func(); + } + })); + } + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopArray() { + return []; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + metrikaYandexWatch.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "metrika-yandex-watch", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/naver-wcslog.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/naver-wcslog.js new file mode 100644 index 0000000..7e0bf89 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/naver-wcslog.js @@ -0,0 +1,46 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function NaverWcslog(source) { + window.wcs_add = {}; + window.wcs_do = noopFunc; + window.wcs = { + inflow: noopFunc + }; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + NaverWcslog.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "naver-wcslog", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noeval.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noeval.js new file mode 100644 index 0000000..e08323f --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noeval.js @@ -0,0 +1,50 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function noeval(source) { + window.eval = function evalWrapper(s) { + hit(source); + logMessage(source, `AdGuard has prevented eval:\n${s}`, true); + }.bind(); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function logMessage(e, o) { + var r = arguments.length > 2 && void 0 !== arguments[2] && arguments[2], a = !(arguments.length > 3 && void 0 !== arguments[3]) || arguments[3], {name: n, verbose: g} = e; + if (r || g) { + var i = console.log; + a ? i(`${n}: ${o}`) : Array.isArray(o) ? i(`${n}:`, ...o) : i(`${n}:`, o); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + noeval.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "noeval", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopcss.css b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopcss.css new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopcss.css diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopframe.html b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopframe.html new file mode 100644 index 0000000..d5d0446 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopframe.html @@ -0,0 +1,5 @@ +<!DOCTYPE html> +<html> + <head><title></title></head> + <body></body> +</html>
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopjs.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopjs.js new file mode 100644 index 0000000..e6c6806 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopjs.js @@ -0,0 +1 @@ +(function() {})()
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopjson.json b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopjson.json new file mode 100644 index 0000000..9e26dfe --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopjson.json @@ -0,0 +1 @@ +{}
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopmp3.mp3 b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopmp3.mp3 Binary files differnew file mode 100644 index 0000000..147d71b --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopmp3.mp3 diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopmp4.mp4 b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopmp4.mp4 Binary files differnew file mode 100644 index 0000000..5689d4a --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopmp4.mp4 diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/nooptext.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/nooptext.js new file mode 100644 index 0000000..e69de29 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/nooptext.js diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopvast02.xml b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopvast02.xml new file mode 100644 index 0000000..3f045e8 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopvast02.xml @@ -0,0 +1 @@ +<VAST version="2.0"></VAST>
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopvast03.xml b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopvast03.xml new file mode 100644 index 0000000..a493468 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopvast03.xml @@ -0,0 +1 @@ +<VAST version="3.0"></VAST>
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopvast04.xml b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopvast04.xml new file mode 100644 index 0000000..376854d --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopvast04.xml @@ -0,0 +1 @@ +<VAST version="4.0"></VAST>
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopvmap01.xml b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopvmap01.xml new file mode 100644 index 0000000..1552ab8 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/noopvmap01.xml @@ -0,0 +1 @@ +<vmap:VMAP xmlns:vmap="http://www.iab.net/videosuite/vmap" version="1.0"></vmap:VMAP>
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/pardot-1.0.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/pardot-1.0.js new file mode 100644 index 0000000..38b877c --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/pardot-1.0.js @@ -0,0 +1,69 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function Pardot(source) { + window.piVersion = "1.0.2"; + window.piScriptNum = 0; + window.piScriptObj = []; + window.checkNamespace = noopFunc; + window.getPardotUrl = noopStr; + window.piGetParameter = noopNull; + window.piSetCookie = noopFunc; + window.piGetCookie = noopStr; + function piTracker() { + window.pi = { + tracker: { + visitor_id: "", + visitor_id_sign: "", + pi_opt_in: "", + campaign_id: "" + } + }; + window.piScriptNum += 1; + } + window.piResponse = noopFunc; + window.piTracker = piTracker; + piTracker(); + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopStr() { + return ""; + } + function noopNull() { + return null; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + Pardot.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "pardot-1.0", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prebid-ads.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prebid-ads.js new file mode 100644 index 0000000..00e5d4d --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prebid-ads.js @@ -0,0 +1,42 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function prebidAds(source) { + window.canRunAds = true; + window.isAdBlockActive = false; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + prebidAds.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "prebid-ads", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prebid.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prebid.js new file mode 100644 index 0000000..123f7df --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prebid.js @@ -0,0 +1,83 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function Prebid(source) { + var pushFunction = function pushFunction(arg) { + if (typeof arg === "function") { + try { + arg.call(); + } catch (ex) {} + } + }; + var pbjsWrapper = { + addAdUnits() {}, + adServers: { + dfp: { + buildVideoUrl: noopStr + } + }, + adUnits: [], + aliasBidder() {}, + cmd: [], + enableAnalytics() {}, + getHighestCpmBids: noopArray, + libLoaded: true, + que: [], + requestBids(arg) { + if (arg instanceof Object && arg.bidsBackHandler) { + try { + arg.bidsBackHandler.call(); + } catch (ex) {} + } + }, + removeAdUnit() {}, + setBidderConfig() {}, + setConfig() {}, + setTargetingForGPTAsync() {} + }; + pbjsWrapper.cmd.push = pushFunction; + pbjsWrapper.que.push = pushFunction; + window.pbjs = pbjsWrapper; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopStr() { + return ""; + } + function noopArray() { + return []; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + Prebid.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "prebid", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prevent-bab.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prevent-bab.js new file mode 100644 index 0000000..96ad0c9 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prevent-bab.js @@ -0,0 +1,89 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function preventBab$1(source) { + var nativeSetTimeout = window.setTimeout; + var babRegex = /\.bab_elementid.$/; + var timeoutWrapper = function timeoutWrapper(callback) { + if (typeof callback !== "string" || !babRegex.test(callback)) { + for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) { + args[_key - 1] = arguments[_key]; + } + return nativeSetTimeout.apply(window, [ callback, ...args ]); + } + hit(source); + }; + window.setTimeout = timeoutWrapper; + var signatures = [ [ "blockadblock" ], [ "babasbm" ], [ /getItem\('babn'\)/ ], [ "getElementById", "String.fromCharCode", "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789", "charAt", "DOMContentLoaded", "AdBlock", "addEventListener", "doScroll", "fromCharCode", "<<2|r>>4", "sessionStorage", "clientWidth", "localStorage", "Math", "random" ] ]; + var check = function check(str) { + if (typeof str !== "string") { + return false; + } + for (var i = 0; i < signatures.length; i += 1) { + var tokens = signatures[i]; + var match = 0; + for (var j = 0; j < tokens.length; j += 1) { + var token = tokens[j]; + var found = token instanceof RegExp ? token.test(str) : str.includes(token); + if (found) { + match += 1; + } + } + if (match / tokens.length >= .8) { + return true; + } + } + return false; + }; + var nativeEval = window.eval; + var evalWrapper = function evalWrapper(str) { + if (!check(str)) { + return nativeEval(str); + } + hit(source); + var bodyEl = document.body; + if (bodyEl) { + bodyEl.style.removeProperty("visibility"); + } + var el = document.getElementById("babasbmsgx"); + if (el) { + el.parentNode.removeChild(el); + } + }; + window.eval = evalWrapper.bind(window); + window.eval.toString = nativeEval.toString.bind(nativeEval); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + preventBab$1.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "prevent-bab", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prevent-bab2.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prevent-bab2.js new file mode 100644 index 0000000..b72fed7 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prevent-bab2.js @@ -0,0 +1,55 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function preventBab2(source) { + var script = document.currentScript; + if (script === null) { + return; + } + var url = script.src; + if (typeof url !== "string") { + return; + } + var domainsStr = [ "adclixx\\.net", "adnetasia\\.com", "adtrackers\\.net", "bannertrack\\.net" ].join("|"); + var matchStr = `^https?://[\\w-]+\\.(${domainsStr})/.`; + var domainsRegex = new RegExp(matchStr); + if (domainsRegex.test(url) === false) { + return; + } + window.nH7eXzOsG = 858; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + preventBab2.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "prevent-bab2", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prevent-fab-3.2.0.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prevent-fab-3.2.0.js new file mode 100644 index 0000000..3b51a27 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prevent-fab-3.2.0.js @@ -0,0 +1,107 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function preventFab(source) { + hit(source); + var Fab = function Fab() {}; + Fab.prototype.check = noopFunc; + Fab.prototype.clearEvent = noopFunc; + Fab.prototype.emitEvent = noopFunc; + Fab.prototype.on = function(a, b) { + if (!a) { + b(); + } + return this; + }; + Fab.prototype.onDetected = noopThis; + Fab.prototype.onNotDetected = function(a) { + a(); + return this; + }; + Fab.prototype.setOption = noopFunc; + Fab.prototype.options = { + set: noopFunc, + get: noopFunc + }; + var fab = new Fab; + var getSetFab = { + get() { + return Fab; + }, + set() {} + }; + var getsetfab = { + get() { + return fab; + }, + set() {} + }; + if (Object.prototype.hasOwnProperty.call(window, "FuckAdBlock")) { + window.FuckAdBlock = Fab; + } else { + Object.defineProperty(window, "FuckAdBlock", getSetFab); + } + if (Object.prototype.hasOwnProperty.call(window, "BlockAdBlock")) { + window.BlockAdBlock = Fab; + } else { + Object.defineProperty(window, "BlockAdBlock", getSetFab); + } + if (Object.prototype.hasOwnProperty.call(window, "SniffAdBlock")) { + window.SniffAdBlock = Fab; + } else { + Object.defineProperty(window, "SniffAdBlock", getSetFab); + } + if (Object.prototype.hasOwnProperty.call(window, "fuckAdBlock")) { + window.fuckAdBlock = fab; + } else { + Object.defineProperty(window, "fuckAdBlock", getsetfab); + } + if (Object.prototype.hasOwnProperty.call(window, "blockAdBlock")) { + window.blockAdBlock = fab; + } else { + Object.defineProperty(window, "blockAdBlock", getsetfab); + } + if (Object.prototype.hasOwnProperty.call(window, "sniffAdBlock")) { + window.sniffAdBlock = fab; + } else { + Object.defineProperty(window, "sniffAdBlock", getsetfab); + } + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + function noopFunc() {} + function noopThis() { + return this; + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + preventFab.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "prevent-fab-3.2.0", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prevent-popads-net.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prevent-popads-net.js new file mode 100644 index 0000000..4326422 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/prevent-popads-net.js @@ -0,0 +1,69 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function preventPopadsNet(source) { + var rid = randomId(); + var throwError = function throwError() { + throw new ReferenceError(rid); + }; + delete window.PopAds; + delete window.popns; + Object.defineProperties(window, { + PopAds: { + set: throwError + }, + popns: { + set: throwError + } + }); + window.onerror = createOnErrorHandler(rid).bind(); + hit(source); + } + function createOnErrorHandler(r) { + var n = window.onerror; + return function(e) { + if ("string" == typeof e && e.includes(r)) return !0; + if (n instanceof Function) { + for (var t = arguments.length, o = new Array(t > 1 ? t - 1 : 0), i = 1; i < t; i++) o[i - 1] = arguments[i]; + return n.apply(window, [ e, ...o ]); + } + return !1; + }; + } + function randomId() { + return Math.random().toString(36).slice(2, 9); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + preventPopadsNet.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "prevent-popads-net", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/scorecardresearch-beacon.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/scorecardresearch-beacon.js new file mode 100644 index 0000000..5e1c146 --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/scorecardresearch-beacon.js @@ -0,0 +1,46 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function ScoreCardResearchBeacon(source) { + window.COMSCORE = { + purge() { + window._comscore = []; + }, + beacon() {} + }; + hit(source); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + ScoreCardResearchBeacon.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "scorecardresearch-beacon", + args: [] +}, []);
\ No newline at end of file diff --git a/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/set-popads-dummy.js b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/set-popads-dummy.js new file mode 100644 index 0000000..91c264d --- /dev/null +++ b/raveos-app-installer/data/configs/vivaldi/Default/Extensions/bgnkhhnnamicmpeenaelnjfhikgbkllg/5.5.2.40_0/web-accessible-resources/redirects/set-popads-dummy.js @@ -0,0 +1,55 @@ +(function(source, args) { + const flag = "done"; + const uniqueIdentifier = source.uniqueId + source.name + "_" + (Array.isArray(args) ? args.join("_") : ""); + if (source.uniqueId) { + if (Window.prototype.toString[uniqueIdentifier] === flag) { + return; + } + } + function setPopadsDummy(source) { + delete window.PopAds; + delete window.popns; + Object.defineProperties(window, { + PopAds: { + get: function get() { + hit(source); + return {}; + } + }, + popns: { + get: function get() { + hit(source); + return {}; + } + } + }); + } + function hit(e) { + if (e.verbose) { + try { + var n = console.trace.bind(console), i = "[AdGuard] "; + "corelibs" === e.engine ? i += e.ruleText : (e.domainName && (i += `${e.domainName}`), + e.args ? i += `#%#//scriptlet('${e.name}', '${e.args.join("', '")}')` : i += `#%#//scriptlet('${e.name}')`), + n && n(i); + } catch (e) {} + "function" == typeof window.__debug && window.__debug(e); + } + } + const updatedArgs = args ? [].concat(source).concat(args) : [ source ]; + try { + setPopadsDummy.apply(this, updatedArgs); + if (source.uniqueId) { + Object.defineProperty(Window.prototype.toString, uniqueIdentifier, { + value: flag, + enumerable: false, + writable: false, + configurable: false + }); + } + } catch (e) { + console.log(e); + } +})({ + name: "set-popads-dummy", + args: [] +}, []);
\ No newline at end of file |