Method and apparatus for judging PE file source code consistency

A judging method and judging device technology, applied in the direction of program control design, instrument, electrical digital data processing, etc., can solve the problems of threatening the confidentiality and security of the source code library, high source code library authority, etc., and achieve the effect of convenient operation

Active Publication Date: 2009-07-01
ZHUHAI KINGSOFT SOFTWARE CO LTD
View PDF0 Cites 8 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] In the prior art, when judging whether two PE files are based on the same source code, it is usually to compare all the source code files corresponding to the two PE files when compiling twice to judge whether the contents of these source codes are the same, if The source code is the same, it is based on the same source code, this judgment method, to access all the source code that generates the PE file, requires a higher source code library authority, and even threatens the confidentiality of the source code library

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
  • Method and apparatus for judging PE file source code consistency
  • Method and apparatus for judging PE file source code consistency
  • Method and apparatus for judging PE file source code consistency

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0051] Such as figure 1 Shown is a schematic flow chart of Embodiment 1 of the present invention. In this embodiment, the method of the present invention includes the steps:

[0052] Step S101: Analyze whether the current file to be analyzed is a PE file, if yes, go to step S102, if not, directly end the analysis process;

[0053] Since the purpose of the present invention is to detect whether the contents of two or more PE files are based on the same source code, and in some cases, for example, the purpose is to find out whether the PE file is from the same source code as the pending PE file. For other PE files, it may not be possible to determine whether the file added to the detection queue is a PE file. Therefore, you can first determine whether the current file to be analyzed is a PE file, if not, you can directly end the process of judging the current file to be analyzed To save time;

[0054] Step S102: Determine whether the number of segments contained in each PE file to ...

Embodiment 2

[0065] In this embodiment, the difference from the first embodiment is that the content of the custom segment contained in each PE file is also judged, such as figure 2 As shown, it includes the steps:

[0066] Step S201: Analyze whether the file to be analyzed is a PE file, if yes, go to step S202, if not, end the current judgment process;

[0067] Step S202: Determine whether the number of segments contained in the current PE files to be analyzed is the same, if they are the same, go to step S203, if they are different, directly determine that each PE file is based on different source codes;

[0068] Step S203: Enumerate the segments contained in each PE file to be analyzed. When there are still segments that need to be enumerated, go to step S204, and if there are no segments that need to be enumerated, go to step S212;

[0069] Step S204: Determine whether the current enumerated segment is a custom segment, if yes, go to step S205, if not, go to step S206;

[0070] Step S205:...

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 discloses a method for judging the consistency of PE file source codes and a device, through analyzing a public structure of a PE file, whether various PE files awaiting to analyze are based on same source codes can be judged when the PE files awaiting to analyze comprise same number of segments and same content of critical segments. The method for judging the consistency of PE filesource codes does not depend on the content of original source codes, thereby being capable of not accessing a source code library, and guaranteeing the security safety of the source code library.

Description

Technical field [0001] The invention relates to a method and device for judging the consistency of PE file source codes. Background technique [0002] In the process of software development, developers will periodically or irregularly compile the source code in the code base. With the introduction of dailybuild (daily compilation) technology, products can be compiled continuously, resulting in a large number of Because some information related to compilation time, compiler version, etc. is embedded during compilation, this information is compiled into the PE file, resulting in a comparison of binary files after multiple compilations even if they are based on the same source code. The product version numbers are not the same. In addition, after adding digital signature technology, the digital signature mechanism and hash mechanism will also cause changes to the binary format of the PE file. Although some technical test guarantees can be carried out through automated testing techno...

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): G06F9/45
Inventor 张康宗王钊
Owner ZHUHAI KINGSOFT SOFTWARE CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products