A code detection method and device, a storage medium and an electronic device
By generating a syntax tree and constructing a hybrid dependency graph of data dependency graph and control flow graph, the false positive and false negative problems of policy code detection in existing technologies are solved, achieving efficient and accurate code risk detection and improving the reliability of code quality.
Patent Information
- Application Number
- CN202610041404.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-01-13
- Publication Date
- 2026-06-09
- Estimated Expiration
- 2046-01-13
AI Technical Summary
In existing technologies, the detection of policy code relies on general code detection tools or simple rule matching methods, which are difficult to handle complex associations or logical relationships, leading to false positives or false negatives, long processing time, weak recognition capabilities, and inability to provide reliable quality assurance.
By generating a syntax tree, determining the data flow and control flow, constructing a data dependency graph and a control flow graph, merging them into a hybrid dependency graph, performing null value propagation, value domain conflict and redundant code detection, and generating a code risk detection report.
It improves the accuracy and efficiency of code detection, reduces false positives or false negatives, enhances the reliability of code quality assurance, and can efficiently locate risks caused by data flow and execution logic.