Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Code detection method, system and equipment based on open source component and storage medium

A code detection and source code technology, applied in program code conversion, neural learning methods, software testing/debugging, etc., can solve problems such as low accuracy and low detection efficiency, and achieve the effect of improving network security

Pending Publication Date: 2022-03-18
CHINA TELECOM CORP LTD
View PDF0 Cites 3 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] The current open source component detection methods for source code mainly include methods such as AST subtree matching, PDG matching, code hash search, etc. These methods have low detection efficiency or low accuracy

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
  • Code detection method, system and equipment based on open source component and storage medium
  • Code detection method, system and equipment based on open source component and storage medium
  • Code detection method, system and equipment based on open source component and storage medium

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0068] Embodiments of the present application are described below through specific examples, and those skilled in the art can easily understand other advantages and effects of the present application from the contents disclosed in the present application. The present application can also be implemented or applied in different specific implementation modes, and the details in the present application can also be modified or changed according to different viewpoints and application systems without departing from the spirit of the present application. It should be noted that, in the case of no conflict, the embodiments in the present application and the features in the embodiments can be combined with each other.

[0069] The embodiments of the present application will be described in detail below with reference to the accompanying drawings, so that those skilled in the art of the present application can easily implement them. The present application can be embodied in various for...

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 invention provides a code detection method, system and device based on an open source component and a storage medium, and the method comprises the steps: obtaining a first source code of a to-be-detected code; respectively segmenting a first source code of the to-be-tested code and a second source code of the open source component set to obtain a first code snippet and a second code snippet, and respectively converting the first code snippet and the second code snippet into abstract syntax trees; converting each statement tree of each abstract syntax tree into a statement vector through a traversal algorithm, extracting the statement vectors of the statement trees according to a preset sequence, and obtaining a group of ordered statement vectors corresponding to each code snippet; generating a representative vector from each group of statement vectors through node coding; and obtaining the similarity according to the representative vector corresponding to the first code snippet and the representative vector corresponding to the second code snippet. According to the invention, the similarity between the open source component and the code to be detected can be generated through the discrimination model, the detection of the open source component and the detection of the open source fragment are automatically realized, and the network security is improved.

Description

technical field [0001] The invention relates to the field of code detection, in particular to a code detection method, system, device and storage medium based on open source components. Background technique [0002] Open source code (Open source code), also known as open source code, refers to a software release model. Ordinary software can only obtain compiled binary executable files, and usually only the author or copyright owner of the software owns the source code of the program. The author of some software will disclose the source code, which is called "source code disclosure", but this does not necessarily meet the definition and conditions of "open source code", because the author may set conditions for the release of the source code, such as Restrict who can read the source code, restrict derivatives, etc. Open source is the foundation on which software applications are built, and without an effective way to track and manage it, enterprises will face the security, ...

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
Patent Type & Authority Applications(China)
IPC IPC(8): G06F11/36G06F8/53G06N3/08
CPCG06F11/3604G06F8/53G06N3/088
Inventor 高思雨闻剑峰殷铭
Owner CHINA TELECOM CORP LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products