Source code scanning method, device, electronic equipment and storage medium

A scanning method and source code technology, applied in the fields of electronic equipment and storage media, source code scanning methods and devices, can solve the problems of false negatives and low efficiency of source code scanning methods, and achieve the effect of improving efficiency

Pending Publication Date: 2021-04-30
TENCENT TECH (SHENZHEN) CO LTD
View PDF0 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] However, the current static source code scanning methods often have problems such as false negatives, so the current source code scanning methods are inefficient

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Source code scanning method, device, electronic equipment and storage medium
  • Source code scanning method, device, electronic equipment and storage medium
  • Source code scanning method, device, electronic equipment and storage medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0075] The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only some, not all, embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative efforts fall within the protection scope of the present invention.

[0076] Embodiments of the present invention provide a source code scanning method, device, electronic equipment and storage medium.

[0077] Wherein, the source code scanning device may specifically be integrated in an electronic device, and the electronic device may be a terminal, a server, or other equipment. Wherein, the terminal can be mobile phone, tablet computer, smart bluetooth device, notebook computer, vehicle-mounted terminal or personal computer (Personal Computer,...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The embodiment of the invention discloses a source code scanning method, a device, electronic equipment and a storage medium. According to the embodiment of the invention, the method comprises the steps of obtaining a source code , wherein the source code comprises a target function; performing equivalent conversion processing on the target function to obtain at least one conversion function corresponding to the target function; performing substitution processing on a target function in the source code by adopting a conversion function to obtain a substitution code; constructing an abstract syntax tree based on the replacement code; and performing defect scanning on the abstract syntax tree based on a preset defect detection rule to obtain a scanning result of defects in the source code. In the embodiment of the invention, the unknown or difficult-to-process target function in the source code is replaced with the conversion function which is equivalent to the target function, known and convenient to scan, so that the defects related to the target function can be detected when the defects are scanned. The scheme can be applied to a cloud server to improve the defect detection efficiency, so that the source code scanning efficiency can be improved.

Description

technical field [0001] The invention relates to the field of computers, in particular to a source code scanning method, device, electronic equipment and storage medium. Background technique [0002] Static Code Analysis (Static Code Analysis) is one of the software application security solutions that have been mentioned more in recent years. It means that in software engineering, the source code is directly scanned by some scanning tools without being compiled by a compiler. Some defects, loopholes, etc., to help developers quickly find, locate, repair and manage security risks in source code. [0003] However, the current static source code scanning methods often have problems such as false negatives, and therefore, the current source code scanning methods are inefficient. Contents of the invention [0004] Embodiments of the present invention provide a source code scanning method, device, electronic equipment, and storage medium, which can improve the efficiency of sour...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
IPC IPC(8): G06F21/57
CPCG06F21/577
Inventor钱文祥
OwnerTENCENT TECH (SHENZHEN) CO LTD