论文标题
通过事件环形粒度JavaScript签名改善Web内容阻止
Improving Web Content Blocking With Event-Loop-Turn Granularity JavaScript Signatures
论文作者
论文摘要
内容阻止是尊重Web的表演者,用户服务,隐私的重要组成部分。大多数内容阻滞剂在URL上建立信任标签。尽管有用,但这种方法已经充分理解了缺点。攻击者可以通过更改URL或域,用良性代码捆绑不需要的代码或在页面中内部代码来避免检测。现有方法中的常见缺陷是,它们根据其交付机制而不是其行为来评估代码。在这项工作中,我们通过一个系统来解决此问题,以生成执行JavaScript的隐私和安全相关行为的签名。我们的系统在每次打入JavaScript事件循环中都考虑脚本行为。专注于事件循环回合使我们能够构建与代码混淆,代码捆绑,URL修改和其他常见逃避以及处理Web应用程序的独特方面的签名。这项工作为改进内容阻塞做出了以下贡献:首先,实施一个新型的系统,通过启动眨眼和V8 Runtimes来构建JavaScript代码的每循环签名。其次,我们将这些签名应用于避免过滤器列表,将EasyList和Easy Privacy用作地面真理并找到其他行为相同的代码。我们从11,212个独特脚本中构建了约2m的隐私和安全行为签名,这些脚本被过滤器列表阻止,并找到3,589个独特的脚本,包括相同的有害代码,影响了12.48%的测量网站。第三,我们将常见过滤器列表逃避技术分类。最后,我们提出防御。在可能的情况下,在可能的情况下增加了过滤列表,并在其他情况下是基于签名的系统。我们共享我们的签名生成系统的实现,从将系统应用于Alexa 100k的数据集以及586 Adblock Plus兼容过滤器列表规则,以阻止将当前封锁代码移至新URL的实例。
Content blocking is an important part of a performant, user-serving, privacy respecting web. Most content blockers build trust labels over URLs. While useful, this approach has well understood shortcomings. Attackers may avoid detection by changing URLs or domains, bundling unwanted code with benign code, or inlining code in pages. The common flaw in existing approaches is that they evaluate code based on its delivery mechanism, not its behavior. In this work we address this problem with a system for generating signatures of the privacy-and-security relevant behavior of executed JavaScript. Our system considers script behavior during each turn on the JavaScript event loop. Focusing on event loop turns allows us to build signatures that are robust against code obfuscation, code bundling, URL modification, and other common evasions, as well as handle unique aspects of web applications. This work makes the following contributions to improving content blocking: First, implement a novel system to build per-event-loop-turn signatures of JavaScript code by instrumenting the Blink and V8 runtimes. Second, we apply these signatures to measure filter list evasion, by using EasyList and EasyPrivacy as ground truth and finding other code that behaves identically. We build ~2m signatures of privacy-and-security behaviors from 11,212 unique scripts blocked by filter lists, and find 3,589 more unique scripts including the same harmful code, affecting 12.48% of websites measured. Third, we taxonomize common filter list evasion techniques. Finally, we present defenses; filter list additions where possible, and a proposed, signature based system in other cases. We share the implementation of our signature-generation system, the dataset from applying our system to the Alexa 100K, and 586 AdBlock Plus compatible filter list rules to block instances of currently blocked code being moved to new URLs.