From 884417613bbf42eba1a84f5c2fa19ebdf9bd3a69 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=B9=9D=E4=BD=9B?= Date: Fri, 17 Apr 2026 15:28:42 +0800 Subject: [PATCH] fix readme --- README.md | 91 +++++++++++++++++++++++++++++++++++++++++-------------- 1 file changed, 69 insertions(+), 22 deletions(-) diff --git a/README.md b/README.md index 71b09688..3bd2feed 100644 --- a/README.md +++ b/README.md @@ -1,31 +1,78 @@ -# 项目简介 -统一多语言程序分析是一个面向工业界大规模落地的静态程序分析工具。它为多语言定义了统一的抽象语法树(UAST)中间表示,基于UAST和模拟执行技术,实现了高精度的数据流、指针分析和污点分析,并同时提供了命令式和声明式两种规则扩展能力供用户灵活、低成本使用,可广泛应用于代码安全等场景。 + -# 核心功能 -+ 定义了统一的多语言的抽象语法树(UAST)中间表示,并提供了各语言向UAST转换的工具 -+ 高精度的数据流、指针分析和污点分析 -+ 可扩展的规则定制化能力,包括命令式规则和声明式查询语言 -+ 内置常见的安全检测规则,面向安全检测场景可开箱即用 +#### [简体中文](README_ZH.md) / [English](README.md) -# 项目架构 -![](https://intranetproxy.alipay.com/skylark/lark/0/2025/png/178787/1743992792193-33a83234-5229-481d-a4b6-e99a796a2fc0.png) +**YASA** (**Y**et **A**nother **S**tatic **A**nalyzer, pronounced “**YA-sa**”) is an open-source static program analysis project. Its core innovation lies in a unified intermediate representation called the **U**nified **A**bstract **S**yntax **T**ree (UAST), designed to support multiple programming languages. Built on top of UAST, YASA provides a highly accurate static analysis framework. Users can extend its capabilities by writing custom checkers to perform various program analysis tasks—such as AST queries, data flow analysis, and function call graph analysis—and expose functionality through SDK, declarative query language (QL), or MCP. -**QL**:Query Language +As a project originally developed within a security team, YASA also comes with built-in taint analysis capabilities, implemented as a checker, to detect security vulnerabilities. -**UAST**:Unify Abstract Syntax Tree **统一抽象语法树** +## Components + -**YASA** :Yet Another Static Analyzer +### YASA-UAST: Unified Abstract Syntax Tree +[YASA-UAST](https://github.com/antgroup/YASA-UAST) is an intermediate representation structure for multi-language program analysis. The UAST-Parser parses code from different programming languages into a unified abstract syntax format. Through UAST, source code in different languages can be converted into a standardized tree structure, enabling unified analysis and processing across multiple languages. -# 技术优势 -+ 【统一】统一多语言抽象语法树(UAST)中间表示,可低成本支持新语言,便于跨语言的分析 -+ 【高精度】多语言程序模拟执行技术,还原了真实的程序运行上下文,可提供更高的分析精度 -+ 【工业界落地】经过蚂蚁内部大规模落地和业界首个程序分析评价体系开源项目[xast](https://xastbenchmark.github.io/)的“双重认证”,多语言场景下的分析完整度、准确度和性能都有较高保障 -+ 【低使用成本】命令式程序分析combine声明式查询语句 - - 兼容[Github codeql](https://github.com/github/codeql)的语法和规则,用户使用门槛低 - - 提供了灵活的规则定制能力 +### YASA-Engine: Unified multi-language Analysis Engine +The unified multi-language analysis engine is the core component of a modern program analysis platform. It aims to achieve efficient and precise analysis of multiple programming languages through a unified analysis framework and methodology. Also, with the help of AI capabilities, it addresses issues such as broken chains in traditional program analysis and high adaptation costs for new scenarios. (The AI part is not open-sourced yet.) -# 支持的语言 -Java、JS、Go、Python...... +### YASA-UQL: Unified Declarative Rule Query Language +Supports declarative unified query rule writing for multiple languages, compatible with CodeQL syntax, lowering the barrier to rule writing while unifying rule sets across languages. -其他语言的支持为开源社区共建“留白” +### YASA-MCP: Unified multi-language Program Analysis MCP +Provides atomic analysis APIs for LLM, offering program analysis services that are LLM-friendly. +### YASA-SDK: Unified multi-language Program Analysis SDK +Provides SDK packages supporting multiple programming languages for traditional applications. It provides a variety of granular program analysis APIs, making integration easier and enabling efficient and user-friendly program analysis services within applications. + +### xAST +[xAST](https://github.com/alipay/ant-application-security-testing-benchmark) is an open-source evaluation system for SAST/IAST/DAST tool capabilities. In YASA-Engine, it serves as the regression target for post-change testing, and during the process of multi-language adaptation, it provides positive guidance on language syntax support. + +## Technical Advantages +### Low Cost for New Language Support +- YASA is directly modeled and analyzed based on UAST. When adapting to a new language, once it is parsed into UAST, the general-layer analyzer's capabilities can be used. After supporting the new language's package structure, the new language's analysis is already supported. + + + + +### High Analysis Accuracy, Measurable, and Unified Multi-Languages +- YASA is based on unified multi-language symbolic interpretation capabilities, offering high precision and scalability in static code analysis. It naturally supports field-sensitive, context-sensitive, object-sensitive, path-sensitive, and flow-sensitive capabilities in the field of static analysis. + +- During YASA's development, we used [xAST](https://github.com/alipay/ant-application-security-testing-benchmark) to evaluate and verify our capabilities, achieving "measurable capabilities." We compared YASA's performance with other open-source program analysis tools under the xAST evaluation system: + + + +### Open and Friendly +- Introduced the unified declarative rule query language YASA-UQL, compatible with CodeQL syntax, and pioneered a unified QL rule library for multiple languages, making program analysis more engineer-friendly. + +- Launched YASA MCP (LLM-friendly) and SDK (App development-friendly). + +## Quick Start + +[Getting Started](https://www.yuque.com/u22090306/bebf6g/evyf4chw26deq8xq) + +[Installation and Deployment](https://www.yuque.com/u22090306/bebf6g/gm7b32tcn9vosgll) + +## Join Us +Welcome to submit issues if you encounter any problems! + +For code contributions, please refer to [CONTRIBUTION](CONTRIBUTION.md) + +## Resource Links +[Official Documentation](https://www.yuque.com/u22090306/bebf6g) + +[Learning Resources](https://www.yuque.com/u22090306/bebf6g/sr0y5fqg0kcua5nf) + +[Community Activities](https://www.yuque.com/u22090306/bebf6g/fn1rauxwtp7z0l1u) + +## Open Source License +Apache License 2.0 - Details in LICENSE Apache-2.0. + +## Acknowledgments +Thanks to all developers who have contributed to the YASA project! Special thanks to the open-source community for their support and feedback, enabling us to jointly advance the development of program analysis technology. + +YASA - Making code analysis more precise, easier, and smarter. + +## Contact Us +[Official Website](https://cybersec.antgroup.com/station) + +