Profiles/Surge/Module/Block/YouTubeAds.sgmodule
2021-12-31 21:40:45 +08:00

13 lines
614 B
Plaintext

#!name=Block YouTube(<=16.43.2) Advertising
#!desc=仅用于视频广告,不适用允许 UDP 转发的节点及 Premium
[URL Rewrite]
(^https?:\/\/[\w-]+\.googlevideo\.com\/(?!dclk_video_ads).+)&ctier=L(&.+) $1&ctier=A$2 header
^https?:\/\/[\w-]+\.googlevideo\.com\/(?!(dclk_video_ads|videoplayback\?)).+&oad - reject
^https?:\/\/(www|s)\.youtube\.com\/api\/stats\/ads - reject
^https?:\/\/(www|s)\.youtube\.com\/(pagead|ptracking) - reject
^https?:\/\/s\.youtube\.com\/api\/stats\/qoe\?adcontext - reject
[MITM]
hostname = %APPEND% -redirector*.googlevideo.com,*.googlevideo.com,www.youtube.com,s.youtube.com