Automatically deriving JavaScript static analyzers from specifications using Meta-level static analysis
Jihyeok Park, Seungmin An, Sukyoung Ryu
摘要
JavaScript is one of the most dominant programming languages. However, despite its popularity, it is a challenging task to correctly understand the behaviors of JavaScript programs because of their highly dynamic nature. Researchers have developed various static analyzers that strive to conform to ECMA-262, the standard specification of JavaScript. Unfortunately, all the existing JavaScript static analyzers require manual updates for new language features. This problem has become more critical since 2015 because the JavaScript language itself rapidly evolves with a yearly release cadence and open development process.
In this paper, we present JSAVER, the first tool that automatically derives JavaScript static analyzers from language specifications. The main idea of our approach is to extract a definitional interpreter from ECMA-262 and perform a meta-level static analysis with the extracted interpreter. A meta-level static analysis is a novel technique that indirectly analyzes programs by analyzing a definitional interpreter with the programs. We also describe how to indirectly configure abstract domains and analysis sensitivities in a meta-level static analysis. For evaluation, we derived a static analyzer from the latest ECMA-262 (ES12, 2021) using JSAVER. The derived analyzer soundly analyzed all applicable 18,556 official conformance tests with 99.0% of precision in 590 ms on average. In addition, we demonstrate the configurability and adaptability of JSAVER with several case studies.
问 Lune
几分钟读透这篇 Paper,不用再花一下午。
Lune 能读完全文,也能读引用它的顶会 Paper,讲清它的结论、证据和局限,每一点都注明出自哪篇 Paper。不用硬啃,也不靠猜。
已有 5 篇顶会 Paper 引用了它。别等审稿人问起,先弄清它们发现了什么。
脉络
- Bringing the WebAssembly Standard up to Speed with SpecTec 引用了 JISET: JavaScript IR-based Semantics Extraction Toolchain
- Bringing the WebAssembly Standard up to Speed with SpecTec 引用了 JEST: N+1 -version Differential Testing of Both JavaScript Engines and Specification
- Bringing the WebAssembly Standard up to Speed with SpecTec 引用了 JSTAR: JavaScript Specification Type Analyzer using Refinement
- Detecting Inconsistencies in Arm CCA's Formally Verified Specification 引用了 JEST: N+1 -version Differential Testing of Both JavaScript Engines and Specification
- Detecting Inconsistencies in Arm CCA's Formally Verified Specification 引用了 JSTAR: JavaScript Specification Type Analyzer using Refinement
- JEST: N+1 -version Differential Testing of Both JavaScript Engines and Specification 引用了 JISET: JavaScript IR-based Semantics Extraction Toolchain
- Feature-Sensitive Coverage for Conformance Testing of Programming Language Implementations 引用了 JISET: JavaScript IR-based Semantics Extraction Toolchain
- Feature-Sensitive Coverage for Conformance Testing of Programming Language Implementations 引用了 JEST: N+1 -version Differential Testing of Both JavaScript Engines and Specification
- Feature-Sensitive Coverage for Conformance Testing of Programming Language Implementations 引用了 JSTAR: JavaScript Specification Type Analyzer using Refinement
- P4-SpecTec: Integrating a Language Mechanization Framework into the Real-World P4 Specification 引用了 JISET: JavaScript IR-based Semantics Extraction Toolchain
- P4-SpecTec: Integrating a Language Mechanization Framework into the Real-World P4 Specification 引用了 JEST: N+1 -version Differential Testing of Both JavaScript Engines and Specification
- P4-SpecTec: Integrating a Language Mechanization Framework into the Real-World P4 Specification 引用了 JSTAR: JavaScript Specification Type Analyzer using Refinement
- JSTAR: JavaScript Specification Type Analyzer using Refinement 引用了 JISET: JavaScript IR-based Semantics Extraction Toolchain
- JSTAR: JavaScript Specification Type Analyzer using Refinement 引用了 JEST: N+1 -version Differential Testing of Both JavaScript Engines and Specification
引用它的顶会 Paper5
- Bringing the WebAssembly Standard up to Speed with SpecTecDongjun Youn, Wonho Shin, Jaehyun Lee, Sukyoung Ryu 等PLDI 2024 · 30 次引用
- Feature-Sensitive Coverage for Conformance Testing of Programming Language ImplementationsJihyeok Park, Dongjun Youn, Kanguk Lee, Sukyoung RyuPLDI 2023 · 3 次引用
- The Incredible Shrinking Context... in a Decompiler Near YouSifis Lagouvardos, Yannis Bollanos, Neville Grech, Yannis SmaragdakisISSTA 2025 · 1 次引用
- Detecting Inconsistencies in Arm CCA's Formally Verified SpecificationChangho Choi, Xiang Cheng, Bokdeuk Jeong, Taesoo KimASPLOS 2026
- P4-SpecTec: Integrating a Language Mechanization Framework into the Real-World P4 SpecificationJaehyun Lee, Seokhun Jeong, Sehyuk Ahn, Haechan Kwon 等OOPSLA 2026
它引用的 Paper4
- JEST: N+1 -version Differential Testing of Both JavaScript Engines and SpecificationJihyeok Park, Seungmin An, Dongjun Youn, Gyeongwon Kim 等ICSE 2021 · 24 次引用
- JISET: JavaScript IR-based Semantics Extraction ToolchainJihyeok Park, Jihee Park, Seungmin An, Sukyoung RyuASE 2020 · 20 次引用
- Accelerating JavaScript static analysis via dynamic shortcutsJoonyoung Park, Jihyeok Park, Dongjun Youn, Sukyoung RyuFSE 2021 · 15 次引用
- JSTAR: JavaScript Specification Type Analyzer using RefinementJihyeok Park, Seungmin An, Wonho Shin, Yusung Sim 等ASE 2021 · 7 次引用
相关 Paper
- Reducing Static Analysis Unsoundness with Approximate InterpretationMathias Rud Laursen, Wenyuan Xu, Anders MøllerPLDI 2024 · 5 次引用
- IRIDIUM: A Framework for Statically Optimizing JavaScript ProgramsMeetesh Kalpesh Mehta, Anirudh Garg, Aneeket Yadav, Manas ThakurOOPSLA 2026
- Semantic Patches for Adaptation of JavaScript Programs to Evolving LibrariesBenjamin Barslev Nielsen, Martin Toldam Torp, Anders MøllerICSE 2021 · 17 次引用
- CodeAlchemist: Semantics-Aware Code Generation to Find Vulnerabilities in JavaScript EnginesHyungSeok Han, DongHyeon Oh, Sang Kil ChaNDSS 2019 · 178 次引用
- JavaScript Pointer Analysis with Adaptive Heap AbstractionWenyuan Xu, Anders MøllerFSE 2026
