[go: up one dir, main page]

CN118445209A - Software detection method, device, equipment, medium and program product - Google Patents

Software detection method, device, equipment, medium and program product Download PDF

Info

Publication number
CN118445209A
CN118445209A CN202410701073.7A CN202410701073A CN118445209A CN 118445209 A CN118445209 A CN 118445209A CN 202410701073 A CN202410701073 A CN 202410701073A CN 118445209 A CN118445209 A CN 118445209A
Authority
CN
China
Prior art keywords
detection
product
rules
source
comparison
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202410701073.7A
Other languages
Chinese (zh)
Inventor
唐晓勇
刘世捷
施政益
邹龙
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Industrial and Commercial Bank of China Ltd ICBC
Original Assignee
Industrial and Commercial Bank of China Ltd ICBC
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Industrial and Commercial Bank of China Ltd ICBC filed Critical Industrial and Commercial Bank of China Ltd ICBC
Priority to CN202410701073.7A priority Critical patent/CN118445209A/en
Publication of CN118445209A publication Critical patent/CN118445209A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Prevention of errors by analysis, debugging or testing of software
    • G06F11/3668Testing of software
    • G06F11/3672Test management
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Prevention of errors by analysis, debugging or testing of software
    • G06F11/3698Environments for analysis, debugging or testing of software
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Software Systems (AREA)
  • Computer Security & Cryptography (AREA)
  • Stored Programmes (AREA)

Abstract

本公开提供了一种软件检测方法,可以应用于软件开发及金融科技技术领域。该软件检测方法包括:响应于软件检测请求,向检测环境导入目标软件制品;生成所述目标软件制品的制品结构清单,基于所述制品结构清单制定标准化检测规则,所述标准化检测规则包括规范检测规则、比对检测规则和来源检测规则;基于所述规范检测规则检测所述制品结构清单中不符合预设规则的文件和不符合预设条件的技术栈;基于所述比对检测规则检测所述目标软件制品与对比软件制品的差异;基于所述来源检测规则检测所述目标软件制品的内容来源。本公开还提供了一种软件检测装置、设备、存储介质和程序产品。

The present disclosure provides a software detection method, which can be applied to the fields of software development and financial technology. The software detection method includes: in response to a software detection request, importing a target software product into a detection environment; generating a product structure list of the target software product, formulating standardized detection rules based on the product structure list, the standardized detection rules including specification detection rules, comparison detection rules and source detection rules; detecting files that do not conform to preset rules and technology stacks that do not conform to preset conditions in the product structure list based on the specification detection rules; detecting the difference between the target software product and the comparison software product based on the comparison detection rules; detecting the content source of the target software product based on the source detection rules. The present disclosure also provides a software detection device, equipment, storage medium and program product.

Description

软件检测方法、装置、设备、介质及程序产品Software detection method, device, equipment, medium and program product

技术领域Technical Field

本公开涉及软件开发及金融科技技术领域,具体地涉及一种软件检测方法、装置、设备、介质和程序产品。The present disclosure relates to the fields of software development and financial technology, and specifically to a software detection method, device, equipment, medium and program product.

背景技术Background technique

在软件产品持续交付的过程中,软件版本发布模式通常遵循工程编译、版本构建、制品部署等流程。在软件发布流程当中,软件资产形态从工程源码转变为版本制品,进而参与后续的部署上线。作为价值交付的资产实体,版本制品承载着业务可信上线的关键作用。当前,面向工程源码资产的检测方案比较丰富,而对版本制品资产的检测方案相对不足。主流的制品管理相关解决方案局限于制品存储,缺乏对制品可信、可用能力的检测。In the process of continuous delivery of software products, the software version release model usually follows the process of engineering compilation, version building, and product deployment. In the software release process, the software asset form is transformed from engineering source code to version products, and then participates in the subsequent deployment and launch. As an asset entity for value delivery, version products play a key role in the trusted launch of business. At present, there are many detection solutions for engineering source code assets, but there are relatively few detection solutions for version product assets. Mainstream product management-related solutions are limited to product storage and lack detection of product trust and availability.

当前,版本制品缺乏有效的可信可用力检测手段,其主要瓶颈在于:其一,版本未采用标准化发布模式,由于应用版本构建过程未实行统一的标准和规范,应用版本库源码工程结构、版本构建方法定义等各方面存在差异,导致各应用制品的内容组成杂乱无章,无法开展细粒度的检测;其二,版本制品检测维度单一,对于制品检测管理的对象仅局限于制品本身,缺乏对版本集成流程中构建、部署等上下游环节的联动结合。At present, there is a lack of effective, reliable and usable detection methods for version products. The main bottlenecks are: first, the version does not adopt a standardized release model. Since the application version building process does not implement unified standards and specifications, there are differences in the source code engineering structure of the application version library, the definition of the version building method, etc., resulting in a disorganized content composition of each application product and the inability to carry out fine-grained detection; second, the version product detection dimension is single, and the object of product detection management is limited to the product itself, lacking the linkage and combination of upstream and downstream links such as construction and deployment in the version integration process.

发明内容Summary of the invention

鉴于上述问题,本公开提供了提高检测质量的软件检测方法、装置、设备、介质和程序产品。In view of the above problems, the present disclosure provides a software detection method, apparatus, device, medium and program product for improving detection quality.

根据本公开的第一个方面,提供了一种软件检测方法,所述方法包括:响应于软件检测请求,向检测环境导入目标软件制品;生成所述目标软件制品的制品结构清单,基于所述制品结构清单制定标准化检测规则,所述标准化检测规则包括规范检测规则、比对检测规则和来源检测规则;基于所述规范检测规则检测所述制品结构清单中不符合预设规则的文件和不符合预设条件的技术栈;基于所述比对检测规则检测所述目标软件制品与对比软件制品的差异;基于所述来源检测规则检测所述目标软件制品的内容来源。According to a first aspect of the present disclosure, a software detection method is provided, the method comprising: in response to a software detection request, importing a target software product into a detection environment; generating a product structure list of the target software product, formulating standardized detection rules based on the product structure list, the standardized detection rules comprising specification detection rules, comparison detection rules and source detection rules; detecting files that do not comply with preset rules and technology stacks that do not comply with preset conditions in the product structure list based on the specification detection rules; detecting differences between the target software product and the comparison software product based on the comparison detection rules; and detecting the content source of the target software product based on the source detection rules.

根据本公开的实施例,所述响应于软件检测请求,导入目标软件制品包括:响应于所述软件检测请求,获取所述目标软件制品的制品对象信息;从预设的制品信息库获取与所述制品对象信息匹配的所述目标软件制品,向检测环境导入所述目标软件制品。According to an embodiment of the present disclosure, importing a target software product in response to a software detection request includes: obtaining product object information of the target software product in response to the software detection request; obtaining the target software product that matches the product object information from a preset product information library, and importing the target software product into a detection environment.

根据本公开的实施例,所述生成所述目标软件制品的制品结构清单,基于所述制品结构清单制定标准化检测规则,所述标准化检测规则包括规范检测规则、比对检测规则和来源检测规则包括:遍历所述目标软件制品的目录结构并提取内容属性,生成制品结构清单;基于所述制品结构清单获取所述目标软件制品包括的文件的文件属性和所述内容属性中包括的技术栈属性,基于所述文件属性和技术栈属性在预设的标准化规则库中匹配获取规范检测规则;基于用户的需求选择指令从所述制品结构清单中选择比对项目,形成至少包括所述目标软件制品与对比软件制品的目录结构比对项目、内容属性比项目对及构建过程比对项目中的其中一种的比对检测规则;基于用户的需求选择指令从所述制品结构清单中获取来源检测对象,生成检测所述来源检测对象的源码来源、依赖来源及通用结构来源的来源检测规则。According to an embodiment of the present disclosure, the product structure list of the target software product is generated, and standardized detection rules are formulated based on the product structure list, wherein the standardized detection rules include standard detection rules, comparison detection rules and source detection rules, including: traversing the directory structure of the target software product and extracting content attributes to generate a product structure list; obtaining file attributes of files included in the target software product and technology stack attributes included in the content attributes based on the product structure list, and obtaining standard detection rules by matching in a preset standardized rule library based on the file attributes and technology stack attributes; selecting comparison items from the product structure list based on user demand selection instructions to form comparison detection rules that include at least one of a directory structure comparison item, a content attribute comparison item and a construction process comparison item between the target software product and the comparison software product; obtaining a source detection object from the product structure list based on the user demand selection instructions to generate a source detection rule for detecting the source code source, dependency source and common structure source of the source detection object.

根据本公开的实施例,所述基于所述规范检测规则检测所述制品结构清单中不符合预设规则的文件和不符合预设条件的技术栈包括:基于所述规范检测规则规定的白名单,检出所述制品结构清单相比所述白名单缺失的文件属性对应的文件;基于所述规范检测规则规定的黑名单,检出所述制品结构清单中所述黑名单不允许包括的文件属性对应的文件;基于所述规范检测规则规定的技术栈规则,检出所述制品结构清单中不符合预设条件的技术栈属性,所述预设条件为所述制品结构清单包括与所述技术栈属性对应的校验模板文件。According to an embodiment of the present disclosure, the detection of files that do not comply with preset rules and technology stacks that do not comply with preset conditions in the product structure list based on the specification detection rules includes: based on the white list specified by the specification detection rules, detecting files corresponding to file attributes that are missing from the product structure list compared to the white list; based on the black list specified by the specification detection rules, detecting files in the product structure list corresponding to file attributes that are not allowed to be included in the black list; based on the technology stack rules specified by the specification detection rules, detecting technology stack attributes that do not comply with preset conditions in the product structure list, the preset condition being that the product structure list includes a verification template file corresponding to the technology stack attributes.

根据本公开的实施例,所述基于所述比对检测规则检测所述目标软件制品与对比软件制品的差异包括:基于所述比对检测规则比对所述目标软件制品与对比软件制品的目录结构、内容属性和构建日志,生成结构差异清单、内容差异清单及建构过程清单。According to an embodiment of the present disclosure, detecting the difference between the target software product and the comparison software product based on the comparison detection rules includes: comparing the directory structure, content attributes and build log of the target software product and the comparison software product based on the comparison detection rules, and generating a structure difference list, a content difference list and a construction process list.

根据本公开的实施例,所述基于所述来源检测规则检测所述目标软件制品的内容来源包括:基于所述来源检测规则筛选所述制品关联信息清单中与所述目标软件制品相关的内容属性;基于所述内容属性获取所述目标软件制品的源码来源信息、依赖来源信息及通用结构来源信息。According to an embodiment of the present disclosure, detecting the content source of the target software product based on the source detection rules includes: filtering content attributes related to the target software product in the product association information list based on the source detection rules; and obtaining source code source information, dependency source information and common structure source information of the target software product based on the content attributes.

根据本公开的实施例,所述方法还包括:在所述标准化检测规则制定完成后,生成所述目标软件制品的规范检测任务、比对检测任务和来源检测任务;分配所述规范检测任务、所述比对检测任务和所述来源检测任务的计算资源,以分别执行所述规范检测规则、所述比对检测规则和所述来源检测规则的检测。According to an embodiment of the present disclosure, the method also includes: after the standardized detection rules are formulated, generating a standard detection task, a comparison detection task and a source detection task for the target software product; allocating computing resources for the standard detection task, the comparison detection task and the source detection task to respectively execute the detection of the standard detection rules, the comparison detection rules and the source detection rules.

根据本公开的实施例,所述方法还包括:生成所述规范检测任务、所述比对检测任务和所述来源检测任务后,调用所述目标软件制品的外联数据库获取执行所述规范检测规则、所述比对检测规则和所述来源检测规则的检测涉及的数据。According to an embodiment of the present disclosure, the method also includes: after generating the specification detection task, the comparison detection task and the source detection task, calling the external database of the target software product to obtain data involved in executing the detection of the specification detection rules, the comparison detection rules and the source detection rules.

根据本公开的实施例,所述方法还包括:基于所述规范检测规则、所述比对检测规则和所述来源检测规则检测所述目标软件制品生成的检测数据,生成检测报告进行备份和用户反馈。According to an embodiment of the present disclosure, the method further includes: detecting the detection data generated by the target software product based on the standard detection rules, the comparison detection rules and the source detection rules, and generating a detection report for backup and user feedback.

本公开的第二方面提供了一种软件检测装置,所述装置包括:制品导入模块,用于响应于软件检测请求,向检测环境导入目标软件制品;规则生成模块,用于生成所述目标软件制品的制品结构清单,基于所述制品结构清单制定标准化检测规则,所述标准化检测规则包括规范检测规则、比对检测规则和来源检测规则;规范检测模块,用于基于所述规范检测规则检测所述制品结构清单中不符合预设规则的文件和不符合预设条件的技术栈;比对检测模块,用于基于所述比对检测规则检测所述目标软件制品与对比软件制品的差异;来源检测模块,用于基于所述来源检测规则检测所述目标软件制品的内容来源。A second aspect of the present disclosure provides a software detection device, the device comprising: a product import module, for importing a target software product into a detection environment in response to a software detection request; a rule generation module, for generating a product structure list of the target software product, and formulating standardized detection rules based on the product structure list, the standardized detection rules including specification detection rules, comparison detection rules and source detection rules; a specification detection module, for detecting files that do not comply with preset rules and technology stacks that do not comply with preset conditions in the product structure list based on the specification detection rules; a comparison detection module, for detecting differences between the target software product and the comparison software product based on the comparison detection rules; and a source detection module, for detecting the content source of the target software product based on the source detection rules.

本公开的第三方面提供了一种电子设备,包括:一个或多个处理器;存储器,用于存储一个或多个程序,其中,当所述一个或多个程序被所述一个或多个处理器执行时,使得一个或多个处理器执行上述软件检测方法。A third aspect of the present disclosure provides an electronic device, comprising: one or more processors; and a memory for storing one or more programs, wherein when the one or more programs are executed by the one or more processors, the one or more processors execute the above-mentioned software detection method.

本公开的第四方面还提供了一种计算机可读存储介质,其上存储有可执行指令,该指令被处理器执行时使处理器执行上述软件检测方法。A fourth aspect of the present disclosure further provides a computer-readable storage medium having executable instructions stored thereon, which, when executed by a processor, causes the processor to execute the above-mentioned software detection method.

本公开的第五方面还提供了一种计算机程序产品,包括计算机程序,该计算机程序被处理器执行时实现上述软件检测方法。The fifth aspect of the present disclosure also provides a computer program product, including a computer program, which implements the above-mentioned software detection method when executed by a processor.

附图说明BRIEF DESCRIPTION OF THE DRAWINGS

通过以下参照附图对本公开实施例的描述,本公开的上述内容以及其他目的、特征和优点将更为清楚,在附图中:The above contents and other purposes, features and advantages of the present disclosure will become more apparent through the following description of the embodiments of the present disclosure with reference to the accompanying drawings, in which:

图1示意性示出了根据本公开实施例的软件检测方法、装置、设备、介质和程序产品的应用场景图;FIG1 schematically shows an application scenario diagram of a software detection method, apparatus, device, medium, and program product according to an embodiment of the present disclosure;

图2示意性示出了根据本公开实施例的软件检测方法的流程图;FIG2 schematically shows a flow chart of a software detection method according to an embodiment of the present disclosure;

图3A示意性示出了根据本公开实施例的标准化检测规则;FIG3A schematically illustrates a standardized detection rule according to an embodiment of the present disclosure;

图3B示意性示出了根据本公开实施例的规范检测规则;FIG3B schematically illustrates a specification detection rule according to an embodiment of the present disclosure;

图3C示意性示出了根据本公开实施例的比对检测规则;FIG3C schematically shows a comparison detection rule according to an embodiment of the present disclosure;

图3D示意性示出了根据本公开实施例的来源检测规则;FIG3D schematically illustrates a source detection rule according to an embodiment of the present disclosure;

图3E示意性示出了根据本公开实施例的标准化发布技术栈类型;FIG3E schematically illustrates a standardized publishing technology stack type according to an embodiment of the present disclosure;

图4示意性示出了根据本公开实施例的软件检测方法的详细流程;FIG4 schematically shows a detailed process of a software detection method according to an embodiment of the present disclosure;

图5示意性示出了根据本公开实施例的软件检测装置的结构框图;FIG5 schematically shows a structural block diagram of a software detection device according to an embodiment of the present disclosure;

图6示意性示出了根据本公开实施例的制品检测系统的结构框图;FIG6 schematically shows a structural block diagram of a product detection system according to an embodiment of the present disclosure;

图7示意性示出了根据本公开实施例的适于实现软件检测方法的电子设备的方框图。FIG. 7 schematically shows a block diagram of an electronic device suitable for implementing a software detection method according to an embodiment of the present disclosure.

具体实施方式Detailed ways

以下,将参照附图来描述本公开的实施例。但是应该理解,这些描述只是示例性的,而并非要限制本公开的范围。在下面的详细描述中,为便于解释,阐述了许多具体的细节以提供对本公开实施例的全面理解。然而,明显地,一个或多个实施例在没有这些具体细节的情况下也可以被实施。此外,在以下说明中,省略了对公知结构和技术的描述,以避免不必要地混淆本公开的概念。Hereinafter, embodiments of the present disclosure will be described with reference to the accompanying drawings. However, it should be understood that these descriptions are exemplary only and are not intended to limit the scope of the present disclosure. In the following detailed description, for ease of explanation, many specific details are set forth to provide a comprehensive understanding of the embodiments of the present disclosure. However, it is apparent that one or more embodiments may also be implemented without these specific details. In addition, in the following description, descriptions of known structures and technologies are omitted to avoid unnecessary confusion of the concepts of the present disclosure.

在此使用的术语仅仅是为了描述具体实施例,而并非意在限制本公开。在此使用的术语“包括”、“包含”等表明了所述特征、步骤、操作和/或部件的存在,但是并不排除存在或添加一个或多个其他特征、步骤、操作或部件。The terms used herein are only for describing specific embodiments and are not intended to limit the present disclosure. The terms "include", "comprising", etc. used herein indicate the existence of the features, steps, operations and/or components, but do not exclude the existence or addition of one or more other features, steps, operations or components.

在此使用的所有术语(包括技术和科学术语)具有本领域技术人员通常所理解的含义,除非另外定义。应注意,这里使用的术语应解释为具有与本说明书的上下文相一致的含义,而不应以理想化或过于刻板的方式来解释。All terms (including technical and scientific terms) used herein have the meanings commonly understood by those skilled in the art unless otherwise defined. It should be noted that the terms used herein should be interpreted as having a meaning consistent with the context of this specification and should not be interpreted in an idealized or overly rigid manner.

在使用类似于“A、B和C等中至少一个”这样的表述的情况下,一般来说应该按照本领域技术人员通常理解该表述的含义来予以解释(例如,“具有A、B和C中至少一个的系统”应包括但不限于单独具有A、单独具有B、单独具有C、具有A和B、具有A和C、具有B和C、和/或具有A、B、C的系统等)。When using expressions such as "at least one of A, B, and C, etc.", they should generally be interpreted according to the meaning of the expression commonly understood by those skilled in the art (for example, "a system having at least one of A, B, and C" should include but is not limited to a system having A alone, B alone, C alone, A and B, A and C, B and C, and/or A, B, C, etc.).

需要说明的是,本公开提供的软件检测方法和装置可用于金融领域在软件开发中版本迭代的检测应用中,也可用于除金融领域之外的任意领域,本公开提供的软件检测方法和装置的应用领域不做限定。It should be noted that the software detection method and device provided by the present disclosure can be used in the detection application of version iteration in software development in the financial field, and can also be used in any field other than the financial field. The application field of the software detection method and device provided by the present disclosure is not limited.

在本发明的技术方案中,所涉及的用户信息(包括但不限于用户个人信息、用户图像信息、用户设备信息,例如位置信息等)和数据(包括但不限于用于分析的数据、存储的数据、展示的数据等),均为经用户授权或者经过各方充分授权的信息和数据,并且相关数据的收集、存储、使用、加工、传输、提供、公开和应用等处理,均遵守相关法律法规和标准,采取了必要保密措施,不违背公序良俗,并提供有相应的操作入口,供用户选择授权或者拒绝。In the technical solution of the present invention, the user information (including but not limited to user personal information, user image information, user device information, such as location information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved are all information and data authorized by the user or fully authorized by all parties, and the collection, storage, use, processing, transmission, provision, disclosure and application of the relevant data comply with relevant laws, regulations and standards, take necessary confidentiality measures, do not violate public order and good morals, and provide corresponding operation entrances for users to choose to authorize or refuse.

在利用个人信息进行自动化决策的场景下,本发明实施例提供的方法、设备和系统均为用户提供相应的操作入口,供用户选择同意或者拒绝自动化决策结果;若用户选择拒绝,则进入专家决策流程。此处的表述“自动化决策”是指通过计算机程序自动分析、评估个人的行为习惯、兴趣爱好或者经济、健康、信用状况等,并进行决策的活动。此处的表述“专家决策”是指专门从事某一领域的工作、具有专门的经验、知识和技能并达到一定的专业水平的人员进行决策的活动。In the scenario of using personal information for automated decision-making, the methods, devices, and systems provided by the embodiments of the present invention provide users with corresponding operation portals for users to choose to agree or reject the automated decision-making results; if the user chooses to reject, the expert decision-making process will be entered. The expression "automated decision-making" here refers to the activity of automatically analyzing and evaluating an individual's behavioral habits, interests and hobbies, or economic, health, credit status, etc. through computer programs, and making decisions. The expression "expert decision-making" here refers to the activity of making decisions by people who specialize in a certain field, have specialized experience, knowledge and skills, and have reached a certain level of professionalism.

关键术语定义:Definitions of Key Terms:

标准化发布:在持续交付领域中,针对版本存在重复冗余、无法复用的差异化发布方式,根据技术栈类型设计定制的统一通用的发布实施标准。Standardized release: In the field of continuous delivery, a unified and universal release implementation standard is designed and customized according to the technology stack type to address the differentiated release methods that are redundant and non-reusable.

软件制品:软件制品是指由源码工程经过编译打包等持续集成构建过程后生成用于部署的软件包。Software products: Software products refer to software packages for deployment generated by source code projects after continuous integration and construction processes such as compilation and packaging.

本公开的实施例提供了一种软件检测方法,响应于软件检测请求,向检测环境导入目标软件制品;生成所述目标软件制品的制品结构清单,基于所述制品结构清单制定标准化检测规则,所述标准化检测规则包括规范检测规则、比对检测规则和来源检测规则;基于所述规范检测规则检测所述制品结构清单中不符合预设规则的文件和不符合预设条件的技术栈;基于所述比对检测规则检测所述目标软件制品与对比软件制品的差异;基于所述来源检测规则检测所述目标软件制品的内容来源。An embodiment of the present disclosure provides a software detection method, which imports a target software product into a detection environment in response to a software detection request; generates a product structure list of the target software product, formulates standardized detection rules based on the product structure list, and the standardized detection rules include specification detection rules, comparison detection rules and source detection rules; detects files that do not comply with preset rules and technology stacks that do not comply with preset conditions in the product structure list based on the specification detection rules; detects the difference between the target software product and the comparison software product based on the comparison detection rules; and detects the content source of the target software product based on the source detection rules.

图1示意性示出了根据本公开实施例的软件检测方法及装置的应用场景图。FIG1 schematically shows an application scenario diagram of a software detection method and device according to an embodiment of the present disclosure.

如图1所示,根据该实施例的应用场景100可以包括银行软件开发的版本测试场景。网络104用以在终端设备101、102、103和服务器105之间提供通信链路的介质。网络104可以包括各种连接类型,例如有线、无线通信链路或者光纤电缆等等。As shown in Figure 1, the application scenario 100 according to this embodiment may include a version test scenario for bank software development. A network 104 is used to provide a medium for a communication link between terminal devices 101, 102, 103 and a server 105. The network 104 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.

用户可以使用终端设备101、102、103通过网络104与服务器105交互,以接收或发送消息等。终端设备101、102、103上可以安装有各种通讯客户端应用,例如购物类应用、网页浏览器应用、搜索类应用、即时通信工具、邮箱客户端、社交平台软件等(仅为示例)。Users can use terminal devices 101, 102, 103 to interact with server 105 through network 104 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 101, 102, 103, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social platform software, etc. (only examples).

终端设备101、102、103可以是具有显示屏并且支持网页浏览的各种电子设备,包括但不限于智能手机、平板电脑、膝上型便携计算机和台式计算机等等。The terminal devices 101 , 102 , and 103 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop computers, and desktop computers.

服务器105可以是提供各种服务的服务器,例如对用户利用终端设备101、102、103所浏览的网站提供支持的后台管理服务器(仅为示例)。后台管理服务器可以对接收到的用户请求等数据进行分析等处理,并将处理结果(例如根据用户请求获取或生成的网页、信息、或数据等)反馈给终端设备。The server 105 may be a server that provides various services, such as a background management server (only an example) that provides support for websites browsed by users using the terminal devices 101, 102, and 103. The background management server may analyze and process the received data such as user requests, and feed back the processing results (such as web pages, information, or data obtained or generated according to user requests) to the terminal device.

需要说明的是,本公开实施例所提供的软件检测方法一般可以由服务器105执行。相应地,本公开实施例所提供的软件检测装置一般可以设置于服务器105中。本公开实施例所提供的软件检测方法也可以由不同于服务器105且能够与终端设备101、102、103和/或服务器105通信的服务器或服务器集群执行。相应地,本公开实施例所提供的软件检测装置也可以设置于不同于服务器105且能够与终端设备101、102、103和/或服务器105通信的服务器或服务器集群中。It should be noted that the software detection method provided in the embodiment of the present disclosure can generally be executed by the server 105. Accordingly, the software detection device provided in the embodiment of the present disclosure can generally be set in the server 105. The software detection method provided in the embodiment of the present disclosure can also be executed by a server or server cluster that is different from the server 105 and can communicate with the terminal devices 101, 102, 103 and/or the server 105. Accordingly, the software detection device provided in the embodiment of the present disclosure can also be set in a server or server cluster that is different from the server 105 and can communicate with the terminal devices 101, 102, 103 and/or the server 105.

应该理解,图1中的终端设备、网络和服务器的数目仅仅是示意性的。根据实现需要,可以具有任意数目的终端设备、网络和服务器。It should be understood that the number of terminal devices, networks and servers in Figure 1 is only illustrative. Any number of terminal devices, networks and servers may be provided according to implementation requirements.

以下将基于图1描述的场景,通过图2~图6对公开实施例的软件检测方法进行详细描述。The following will describe the software detection method of the disclosed embodiment in detail based on the scenario described in FIG. 1 through FIGS. 2 to 6 .

图2示意性示出了根据本公开实施例的软件检测方法的流程图。FIG2 schematically shows a flow chart of a software detection method according to an embodiment of the present disclosure.

如图2所示,该实施例的软件检测方法包括操作S210~操作S250,该交易处理方法可以顺序执行。As shown in FIG. 2 , the software detection method of this embodiment includes operations S210 to S250 , and the transaction processing method can be executed sequentially.

在操作S210中,响应于软件检测请求,向检测环境导入目标软件制品。In operation S210 , in response to a software detection request, a target software artifact is imported into a detection environment.

在本公开实施例中,一方面,用户可以通过交互界面选择需要进行检测的目标软件制品,并在选中目标软件制品后,发起软件检测请求;另一方面,在存在多种软件制品的条件下,可以通过自动化的手段,基于现存或用户提供的软件制品对象信息,与软件制品进行匹配,获取目标软件制品后,自动发起软件检测请求。响应于软件检测请求,获取目标软件制品的制品对象信息;从预设的制品信息库获取与制品对象信息匹配的目标软件制品,确认该软件制品为目标软件制品后,向检测环境导入目标软件制品,确保目标软件制品正确导入。In the disclosed embodiment, on the one hand, the user can select the target software product to be detected through the interactive interface, and initiate a software detection request after selecting the target software product; on the other hand, under the condition that there are multiple software products, the software product can be matched with the software product through automated means based on the existing or user-provided software product object information, and the software detection request is automatically initiated after the target software product is obtained. In response to the software detection request, the product object information of the target software product is obtained; the target software product matching the product object information is obtained from the preset product information library, and after confirming that the software product is the target software product, the target software product is imported into the detection environment to ensure that the target software product is correctly imported.

在操作S220中,生成目标软件制品的制品结构清单,基于制品结构清单制定标准化检测规则,标准化检测规则包括规范检测规则、比对检测规则和来源检测规则。In operation S220, a product structure list of the target software product is generated, and standardized detection rules are formulated based on the product structure list. The standardized detection rules include specification detection rules, comparison detection rules, and source detection rules.

在本公开实施例中,根据目标软件制品的制品结构遍历及内容属性进行提取,形成制品结构清单。具体的,制品结构清单可以包括目标软件制品的目录结构、内容属性、建构过程等,其中,目录结构反应目标软件制品包括的文件组成及依赖关系等信息,内容属性包括例如MD5值等,构建过程具体可以记录在构建日志中。In the disclosed embodiment, the product structure list is formed by extracting the product structure traversal and content attributes of the target software product. Specifically, the product structure list may include the directory structure, content attributes, and construction process of the target software product, wherein the directory structure reflects the file composition and dependency relationship of the target software product, and the content attributes include, for example, MD5 values, etc. The construction process may be specifically recorded in the construction log.

通过定制标准化检测规则,可以对基于标准化发布的软件制品进行质量检测,提高软件制品版本质量。本公开提供的检测方法,制定了多种维度定制标准化检测规则,限定了规范检测、比对检测和来源检测的内容,通过细粒度的多种检测规则,协助用户检出软件版本迭代中多维度的问题。By customizing standardized detection rules, quality detection can be performed on software products based on standardization releases to improve the quality of software product versions. The detection method provided by the present disclosure formulates customized standardized detection rules in multiple dimensions, limits the content of standard detection, comparison detection and source detection, and assists users in detecting multi-dimensional problems in software version iteration through fine-grained multiple detection rules.

在操作S230中,基于规范检测规则检测制品结构清单中不符合预设规则的文件和不符合预设条件的技术栈。In operation S230 , files that do not conform to preset rules and technology stacks that do not conform to preset conditions in the artifact structure list are detected based on the specification detection rules.

通过检测文件和技术栈,可以检测出软件制品内容遗漏、夹带、带错等问题。By checking files and technology stacks, problems such as missing, included, and incorrect content in software products can be detected.

在操作S240中,基于比对检测规则检测目标软件制品与对比软件制品的差异。In operation S240 , the difference between the target software artifact and the comparison software artifact is detected based on the comparison detection rule.

通过将目标软件制品与对比软件制品比对,可以检测软件制品在迭代过程中的变化,可以解决持续集成过程中软件制品迭代变化感知不明显的痛点。By comparing the target software artifact with the comparison software artifact, the changes in the software artifact during the iteration process can be detected, which can solve the pain point that the iterative changes of the software artifact in the continuous integration process are not obvious.

在操作S250中,基于来源检测规则检测目标软件制品的内容来源。In operation S250 , the content source of the target software product is detected based on the source detection rule.

通过检测内容来源,可以协助用户高效排查软件制品的内容版本问题。By detecting the source of content, users can be assisted in efficiently troubleshooting content version issues of software products.

根据本公开实施例提供的软件检测方法,可以实现对软件制品的可信、可用能力的检测,为后续流程使用软件制品包部署上线提供了有力保障。如经过制品检测的软件制品,不容易发生制品内容遗漏、夹带、带错等情况,版本质量高;且对于软件制品的内容组成而言,具备差异比对,来源追溯的功能,为用户提供了一种清晰、高效的制品级过程管理能力。According to the software detection method provided by the embodiment of the present disclosure, the software product's trustworthiness and usability can be detected, providing a strong guarantee for the subsequent process to use the software product package to deploy and go online. For example, software products that have passed product detection are not prone to omission, inclusion, or errors in product content, and have high version quality; and for the content composition of software products, they have the functions of difference comparison and source tracing, providing users with a clear and efficient product-level process management capability.

图3A示意性示出了根据本公开实施例的标准化检测规则。FIG. 3A schematically illustrates a standardized detection rule according to an embodiment of the present disclosure.

如图3A所示,基于制品目录结构遍历及内容属性提取,本公开实施例的标准化检测规则包括规范检测规则、比对检测规则和来源检测规则三种检测方法。As shown in FIG. 3A , based on the product directory structure traversal and content attribute extraction, the standardized detection rules of the embodiment of the present disclosure include three detection methods: specification detection rules, comparison detection rules, and source detection rules.

在本公开实施例中,遍历目标软件制品的目录结构并提取内容属性,生成制品结构清单。基于制品结构清单制定标准化检测规则,标准化检测规则包括规范检测规则、比对检测规则和来源检测规则包括S310~S330。In the disclosed embodiment, the directory structure of the target software product is traversed and content attributes are extracted to generate a product structure list. Based on the product structure list, standardized detection rules are formulated, and the standardized detection rules include standard detection rules, comparison detection rules and source detection rules, including S310~S330.

在操作S310中,基于制品结构清单获取目标软件制品包括的文件的文件属性和内容属性中包括的技术栈属性,基于文件属性和技术栈属性在预设的标准化规则库中匹配获取规范检测规则。In operation S310, the technology stack attributes included in the file attributes and content attributes of the files included in the target software product are obtained based on the product structure list, and the standard detection rules are matched in a preset standardized rule library based on the file attributes and the technology stack attributes.

在持续交付领域中,针对版本存在重复冗余、无法复用的差异化发布方式,根据技术栈类型设计定制的统一通用的发布实施标准。软件制品的文件属性和技术栈属性必须在标准化要求的范围内,因此需要通过设置限制条件,如定义规则检测中的黑白名单,检测目标软件制品的文件属性和技术栈是否符合标准化需求,检测文件中遗漏、夹带或错带等问题,以提高版本质量。In the field of continuous delivery, for versions with redundant and non-reusable differentiated release methods, a unified and universal release implementation standard is designed and customized according to the technology stack type. The file attributes and technology stack attributes of software products must be within the scope of standardization requirements, so it is necessary to set restrictions, such as defining black and white lists in rule detection, to detect whether the file attributes and technology stack of the target software product meet the standardization requirements, and to detect omissions, inclusions or errors in the file, so as to improve the quality of the version.

在操作S320中,基于用户的需求选择指令从制品结构清单中选择比对项目,形成至少包括目标软件制品与对比软件制品的目录结构比对项目、内容属性比项目对及构建过程比对项目中的其中一种的比对检测规则。In operation S320, a comparison item is selected from the artifact structure list based on the user's requirement selection instruction to form a comparison detection rule including at least one of a directory structure comparison item, a content attribute comparison item, and a construction process comparison item between the target software artifact and the comparison software artifact.

在比对检测中,通过差异可视化展示的方式,揭示出软件制品迭代变化的情况,解决持续集成过程中软件制品迭代变化感知不明显的痛点。In the comparison test, the iterative changes of software products are revealed through the visualization of differences, solving the pain point of unclear iterative changes of software products in the continuous integration process.

在操作S330中,基于用户的需求选择指令从制品结构清单中获取来源检测对象,生成检测来源检测对象的源码来源、依赖来源及通用结构来源的来源检测规则。In operation S330 , a source detection object is obtained from the artifact structure list based on the user's requirement selection instruction, and a source detection rule for detecting the source code source, dependency source, and common structure source of the source detection object is generated.

在持续版本迭代的过程中,软件制品的源码、依赖和通用结构对着迭代进行不同程度的更新。源码来源、依赖来源和通用结构在迭代过程中可能引发产品质量问题。因此进行来源追溯,并与迭代前的版本进行比对,可以辅助用户发现软件制品在迭代过程中由于来源变化导致的问题。In the process of continuous version iteration, the source code, dependencies and common structure of the software product are updated to varying degrees. The source of the source code, the source of the dependency and the common structure may cause product quality problems during the iteration process. Therefore, tracing the source and comparing it with the version before the iteration can help users find problems caused by source changes during the iteration process of the software product.

制定标准化检测规则的过程为交互流程。由用户定义并确认制品检测的具体规则,确认本次检测需要执行规则检测及来源检测。定义过的制品检测规则将存储到数据端。The process of formulating standardized detection rules is an interactive process. The user defines and confirms the specific rules for product detection and confirms that rule detection and source detection need to be performed for this detection. The defined product detection rules will be stored in the data end.

图3B示意性示出了根据本公开实施例的规范检测规则。FIG. 3B schematically illustrates a specification detection rule according to an embodiment of the present disclosure.

如图3B所示,本公开实施例的规范检测规则包含黑名单规则、白名单规则、技术栈规则。进行规范检测包括操作S311~S313。As shown in Fig. 3B, the specification detection rules of the embodiment of the present disclosure include blacklist rules, whitelist rules, and technology stack rules. Performing specification detection includes operations S311 to S313.

在操作S311中,基于规范检测规则规定的白名单,检出制品结构清单相比白名单缺失的文件属性对应的文件。In operation S311, based on the white list specified by the standard detection rule, files corresponding to the file attributes missing from the product structure list compared to the white list are detected.

白名单规则指用户可指定制品结构清单中,必须存在的文件属性作为检测必要条件。如在检测过程中,通过人为设置白名单的方式,对制品结构中的文件名称进行正则匹配校验,防止制品中漏带程序或配置文件。Whitelist rules mean that users can specify file attributes that must exist in the product structure list as a necessary condition for detection. For example, during the detection process, by manually setting a whitelist, the file names in the product structure are checked for regular matching to prevent missing programs or configuration files in the product.

在操作S312中,基于规范检测规则规定的黑名单,检出制品结构清单中黑名单不允许包括的文件属性对应的文件。In operation S312, based on the blacklist specified by the specification detection rule, files corresponding to file attributes that are not allowed to be included in the blacklist in the artifact structure list are detected.

黑名单规则指用户可指定制品结构清单中,不得存在的文件属性作为检测必要条件。如在检测过程中,通过人为设置黑名单的方式,对制品结构中的文件名称进行正则匹配校验,防止制品中夹带程序或配置文件。Blacklist rules mean that users can specify file attributes that must not exist in the product structure list as a necessary condition for detection. For example, during the detection process, by manually setting a blacklist, the file names in the product structure are checked for regular matching to prevent programs or configuration files from being included in the product.

在操作S313中基于规范检测规则规定的技术栈规则,检出制品结构清单中不符合预设条件的技术栈属性,预设条件为制品结构清单包括与技术栈属性对应的校验模板文件。In operation S313, based on the technology stack rules specified in the specification detection rules, technology stack attributes that do not meet the preset conditions in the artifact structure list are detected, and the preset condition is that the artifact structure list includes a verification template file corresponding to the technology stack attribute.

技术栈规则指从构建信息库获取制品所属技术栈信息,根据制品所属技术栈信息自动匹配对应的技术栈规则,用户无需进行指定。如在检测过程中,通过制品信息与技术栈规则匹配,开展技术栈规则检测,确保制品中带出的程序或配置文件符合技术栈要求。Technology stack rules refer to obtaining the technology stack information of the artifact from the build information library, and automatically matching the corresponding technology stack rules according to the technology stack information of the artifact, without the need for users to specify. For example, during the detection process, the product information is matched with the technology stack rules, and the technology stack rule detection is carried out to ensure that the program or configuration file brought out by the artifact meets the technology stack requirements.

图3C示意性示出了根据本公开实施例的比对检测规则。FIG. 3C schematically illustrates a comparison detection rule according to an embodiment of the present disclosure.

如图3C所示,在本实施例中,比对检测规则包括目录结构比对S321、内容属性比对S322和构建过程比对S323。As shown in FIG. 3C , in this embodiment, the comparison detection rules include directory structure comparison S321 , content attribute comparison S322 , and construction process comparison S323 .

目录结构比对S321是指用户可指定两个不同的制品,通过比对两者的制品结构清单,可视化展示制品结构差异。Catalog structure comparison S321 means that a user can specify two different products and compare the product structure lists of the two to visualize the differences in the product structures.

内容属性比对S322是指用户可指定两个不同的制品,通过比对两者的制品结构清单,可视化展示制品内容属性的差异,如MD5值。Content attribute comparison S322 means that a user can specify two different products, and by comparing the product structure lists of the two, the differences in product content attributes, such as MD5 values, are visually displayed.

构建过程比对S323是指用户可指定两个不同的制品,通过比对两者构建日志,可视化展示制品构建过程的差异。Build process comparison S323 means that the user can specify two different artifacts and compare the build logs of the two to visualize the differences in the artifact build processes.

基于比对检测规则比对目标软件制品与对比软件制品的目录结构、内容属性和构建日志,生成结构差异清单、内容差异清单及建构过程清单。在比对检测中,比对目标软件制品和对比软件制品的结构差异清单、内容差异清单及建构过程清单,通过差异可视化展示的方式,揭示出软件制品迭代变化的情况。Based on the comparison detection rules, the directory structure, content attributes and build log of the target software product and the comparison software product are compared to generate a structure difference list, a content difference list and a construction process list. In the comparison detection, the structure difference list, content difference list and construction process list of the target software product and the comparison software product are compared to reveal the iterative changes of the software product through the visual display of the differences.

图3D示意性示出了根据本公开实施例的来源检测规则。FIG3D schematically illustrates a source detection rule according to an embodiment of the present disclosure.

如图3D所示,在本公开实施例中,来源检测规则检测的内容包括源码来源检测S331、依赖来源检测S332和通用来源检测S333。As shown in FIG. 3D , in the embodiment of the present disclosure, the content detected by the source detection rule includes source code source detection S331 , dependent source detection S332 , and general source detection S333 .

源码来源指根据制品关联信息清单,将制品内容中程序部分的来源,可视化的表示出来。如溯源制品中的某个class二进制文件是由具体某个java程序编译出来,并联动查询提交记录,找出是某个开发人员什么时间提交的java程序。Source code source refers to visually representing the source of the program part in the product content based on the product-related information list. For example, a class binary file in the source product is compiled from a specific Java program, and the submission record is linked to find out when a developer submitted the Java program.

依赖来源指根据制品关联信息清单,将制品内容中依赖部分的来源,可视化的表示出来。如溯源制品中lib目录下的某个jar包,是经过Maven构建引用公共依赖后带出。Dependency source refers to visually representing the source of the dependency part in the artifact content based on the artifact association information list. For example, a jar package in the lib directory of the traceable artifact is brought out after Maven builds and references the public dependency.

通用结构指根据制品关联信息清单,将制品内容中通用结构,可视化的表示出来。如溯源制品中的配置变量文件,是经过配置中心平台引入的。The general structure refers to the visual representation of the general structure in the product content based on the product-related information list. For example, the configuration variable file in the traceability product is introduced through the configuration center platform.

在来源检测中,基于来源检测规则筛选制品关联信息清单中与目标软件制品相关的内容属性;基于内容属性从外联数据库中获取目标软件制品的源码来源信息、依赖来源信息及通用结构来源信息,通过溯源可视化展示的方式,揭示出软件制品的内容组成来源的情况。In source detection, the content attributes related to the target software product in the product association information list are filtered based on the source detection rules; the source code source information, dependency source information and common structure source information of the target software product are obtained from the external database based on the content attributes, and the source of the content composition of the software product is revealed through traceability visualization.

图3E示意性示出了根据本公开实施例的标准化发布技术栈类型。FIG. 3E schematically shows a standardized publishing technology stack type according to an embodiment of the present disclosure.

如图3E所示,在本公开实施例中,制品检测支持多种标准化技术栈,MAVEN、NODEJS、DB、SLB、APIP、COPY、PAAS、DMQS、ETRAN、DBF。各种技术栈有专属的技术栈规则校验模板,根据校验模板要求,对制品内容及其属性进行检测。如MAVEN技术栈校验模板,校验target产物目录下是否存在jar、war、class等编译后的二进制文件、NODEJS技术栈校验模板,校验dist产物目录下是否存在html、js等前端相关文件、DB技术栈校验模板,校验是否存在ddl、dml、存储过程等相关sql文件、SLB、APIP、COPY、PAAS、DMQS、ETRAN、DBF技术栈校验模板,校验是否存在xls模板等相关文件。As shown in FIG. 3E , in the disclosed embodiment, product detection supports a variety of standardized technology stacks, including MAVEN, NODEJS, DB, SLB, APIP, COPY, PAAS, DMQS, ETRAN, and DBF. Various technology stacks have exclusive technology stack rule verification templates, and the product content and its attributes are detected according to the verification template requirements. For example, the MAVEN technology stack verification template verifies whether there are compiled binary files such as jar, war, and class in the target product directory, the NODEJS technology stack verification template verifies whether there are front-end related files such as html and js in the dist product directory, the DB technology stack verification template verifies whether there are related sql files such as ddl, dml, and stored procedures, and the SLB, APIP, COPY, PAAS, DMQS, ETRAN, and DBF technology stack verification templates verify whether there are related files such as xls templates.

在规则检测中,若满足规则检测条件视为检测通过,不满足条件则视为检测不通过。通过规则检测的方式,揭示出软件制品符合要求的情况。In rule testing, if the rule testing conditions are met, the test is considered to have passed, and if the conditions are not met, the test is considered to have failed. The rule testing method can reveal whether the software product meets the requirements.

图4示意性示出了根据本公开实施例的软件检测方法的详细流程。FIG4 schematically shows a detailed process of a software detection method according to an embodiment of the present disclosure.

如图4所示,本公开实施例的软件检测方法的详细流程包括操作S410~S460。As shown in FIG. 4 , the detailed process of the software detection method according to the embodiment of the present disclosure includes operations S410 to S460 .

在操作S410,确认制品检测对象,该过程为交互流程。由用户确认待检测的制品对象。在本公开实施例中,支持两种确认模式:一,用户导入指定的待检测的制品对象;二,联动制品信息库,根据用户选择制品对象信息,确认待检测的制品对象。In operation S410, the product inspection object is confirmed. This process is an interactive process. The user confirms the product object to be inspected. In the embodiment of the present disclosure, two confirmation modes are supported: one, the user imports the specified product object to be inspected; the other is to link the product information library and confirm the product object to be inspected according to the product object information selected by the user.

在操作S420,定义制品检测规则,该过程为交互流程。由用户定义并确认制品检测的具体规则。如定义规则检测中的黑白名单,确认本次检测需要执行规则检测及来源检测。定义过的制品检测规则将存储到数据端。In operation S420, product detection rules are defined. This process is an interactive process. The user defines and confirms the specific rules for product detection. For example, the blacklist and whitelist in the rule detection are defined, and it is confirmed that the rule detection and source detection need to be performed in this detection. The defined product detection rules will be stored in the data terminal.

在操作S430,发起制品检测作业,该流程为执行流程。当用户完成制品检测对象的确认及制品检测规则的定义后,可以发起制品检测作业。制品检测系统会根据用户请求,进行制品检测作业任务分配及资源调度。具体地,在标准化检测规则制定完成后,生成目标软件制品的规范检测任务、比对检测任务和来源检测任务;分配规范检测任务、比对检测任务和来源检测任务的计算资源,以分别执行规范检测规则、比对检测规则和来源检测规则的检测。In operation S430, a product detection operation is initiated, and this process is an execution process. When the user completes the confirmation of the product detection object and the definition of the product detection rules, the product detection operation can be initiated. The product detection system will perform product detection operation task allocation and resource scheduling according to the user's request. Specifically, after the standardized detection rules are formulated, the standard detection task, comparison detection task and source detection task of the target software product are generated; the computing resources of the standard detection task, comparison detection task and source detection task are allocated to respectively execute the detection of the standard detection rules, comparison detection rules and source detection rules.

在操作S440,获取制品相关资源,该流程为执行流程。当制品检测作业发起后,根据待检测的制品对象信息,调用目标软件制品的外联数据库获取执行规范检测规则、比对检测规则和来源检测规则的检测涉及的数据,如通过源码信息库、构建信息库、制品信息库获取版本库信息及构建过程信息等。In operation S440, the product-related resources are obtained, and this process is the execution process. When the product detection job is initiated, according to the product object information to be detected, the external database of the target software product is called to obtain the data involved in the detection of the execution specification detection rules, comparison detection rules and source detection rules, such as obtaining the version library information and the construction process information through the source code information library, the build information library and the product information library.

在操作S450,执行制品检测作业,该流程为执行流程。当制品相关资源获取完毕后,由制品检测执行机根据制品检测相关规则执行制品检测作业。In operation S450, the product inspection operation is executed. This process is the execution process. After the product-related resources are acquired, the product inspection execution machine executes the product inspection operation according to the product inspection-related rules.

在操作S460,当制品检测作业执行完毕后,制品检测作业的执行数据会进行持久化存储。基于规范检测规则、比对检测规则和来源检测规则检测目标软件制品生成的检测数据,生成检测报告进行备份,将制品检测报告返回交互端展示给用户。In operation S460, when the product detection operation is completed, the execution data of the product detection operation will be persistently stored. The detection data generated by the target software product is detected based on the standard detection rules, the comparison detection rules and the source detection rules, and a detection report is generated for backup, and the product detection report is returned to the interactive terminal for display to the user.

本公开提供了一种基于标准化发布的软件检测方法,实现了对软件制品的可信、可用能力的检测,为后续流程使用软件制品包部署上线提供了有力保障。经过制品检测的软件制品,不容易发生制品内容遗漏、夹带、带错等情况,版本质量高;且对于软件制品的内容组成而言,具备差异比对,来源追溯的功能,为用户提供了一种清晰、高效的制品级过程管理能力。The present disclosure provides a software detection method based on standardized release, which realizes the detection of the trustworthiness and usability of software products, and provides a strong guarantee for the subsequent process to use the software product package to deploy and go online. Software products that have passed product detection are not prone to omission, inclusion, or errors in product content, and have high version quality; and for the content composition of software products, they have the functions of difference comparison and source tracing, providing users with a clear and efficient product-level process management capability.

基于上述软件检测方法,本公开还提供了一种软件检测装置。以下将结合图5对该装置进行详细描述。Based on the above software detection method, the present disclosure further provides a software detection device, which will be described in detail below in conjunction with FIG. 5 .

图5示意性示出了根据本公开实施例的软件检测装置的结构框图。FIG5 schematically shows a structural block diagram of a software detection device according to an embodiment of the present disclosure.

如图5所示,该实施例的软件检测装置500包括制品导入模块510、规则生成模块520、规范检测模块530、比对检测模块540和来源检测模块550。As shown in FIG. 5 , the software detection device 500 of this embodiment includes a product import module 510 , a rule generation module 520 , a specification detection module 530 , a comparison detection module 540 and a source detection module 550 .

制品导入模块510用于响应于软件检测请求,向检测环境导入目标软件制品。在一实施例中,制品导入模块510可以用于执行前文描述的操作S210,在此不再赘述。The artifact importing module 510 is used to import the target software artifact into the detection environment in response to the software detection request. In one embodiment, the artifact importing module 510 can be used to perform the operation S210 described above, which will not be described in detail here.

规则生成模块520用于生成目标软件制品的制品结构清单,基于制品结构清单制定标准化检测规则,标准化检测规则包括规范检测规则、比对检测规则和来源检测规则。在一实施例中,规则生成模块520可以用于执行前文描述的操作S220,在此不再赘述。The rule generation module 520 is used to generate a product structure list of the target software product, and formulate standardized detection rules based on the product structure list, wherein the standardized detection rules include specification detection rules, comparison detection rules, and source detection rules. In one embodiment, the rule generation module 520 can be used to perform the operation S220 described above, which will not be repeated here.

规范检测模块530用于基于规范检测规则检测制品结构清单中不符合预设规则的文件和不符合预设条件的技术栈。在一实施例中,规范检测模块530可以用于执行前文描述的操作S230,在此不再赘述。The specification detection module 530 is used to detect files that do not conform to preset rules and technology stacks that do not conform to preset conditions in the product structure list based on the specification detection rules. In one embodiment, the specification detection module 530 can be used to perform the operation S230 described above, which will not be repeated here.

比对检测模块540用于基于比对检测规则检测目标软件制品与对比软件制品的差异。在一实施例中,比对检测模块540可以用于执行前文描述的操作S240,在此不再赘述。The comparison and detection module 540 is used to detect the difference between the target software product and the comparison software product based on the comparison and detection rules. In one embodiment, the comparison and detection module 540 can be used to perform the operation S240 described above, which will not be described in detail here.

来源检测模块550用于基于来源检测规则检测目标软件制品的内容来源。在一实施例中,来源检测模块550可以用于执行前文描述的操作S250,在此不再赘述。The source detection module 550 is used to detect the content source of the target software product based on the source detection rule. In one embodiment, the source detection module 550 can be used to perform the operation S250 described above, which will not be described in detail here.

根据本公开的实施例,制品导入模块510、规则生成模块520、规范检测模块530、比对检测模块540和来源检测模块550中的任意多个模块可以合并在一个模块中实现,或者其中的任意一个模块可以被拆分成多个模块。或者,这些模块中的一个或多个模块的至少部分功能可以与其他模块的至少部分功能相结合,并在一个模块中实现。根据本公开的实施例,制品导入模块510、规则生成模块520、规范检测模块530、比对检测模块540和来源检测模块550中的至少一个可以至少被部分地实现为硬件电路,例如现场可编程门阵列(FPGA)、可编程逻辑阵列(PLA)、片上系统、基板上的系统、封装上的系统、专用集成电路(ASIC),或可以通过对电路进行集成或封装的任何其他的合理方式等硬件或固件来实现,或以软件、硬件以及固件三种实现方式中任意一种或以其中任意几种的适当组合来实现。或者,制品导入模块510、规则生成模块520、规范检测模块530、比对检测模块540和来源检测模块550中的至少一个可以至少被部分地实现为计算机程序模块,当该计算机程序模块被运行时,可以执行相应的功能。According to an embodiment of the present disclosure, any multiple modules of the product import module 510, the rule generation module 520, the specification detection module 530, the comparison detection module 540 and the source detection module 550 can be combined in one module, or any one of them can be split into multiple modules. Alternatively, at least part of the functions of one or more of these modules can be combined with at least part of the functions of other modules and implemented in one module. According to an embodiment of the present disclosure, at least one of the product import module 510, the rule generation module 520, the specification detection module 530, the comparison detection module 540 and the source detection module 550 can be at least partially implemented as a hardware circuit, such as a field programmable gate array (FPGA), a programmable logic array (PLA), a system on a chip, a system on a substrate, a system on a package, an application specific integrated circuit (ASIC), or can be implemented by hardware or firmware such as any other reasonable way of integrating or packaging the circuit, or implemented in any one of the three implementation methods of software, hardware and firmware or in an appropriate combination of any of them. Alternatively, at least one of the product import module 510, the rule generation module 520, the specification detection module 530, the comparison detection module 540 and the source detection module 550 can be at least partially implemented as a computer program module, which can perform corresponding functions when executed.

图6示意性示出了根据本公开实施例的制品检测系统的结构框图。FIG6 schematically shows a structural block diagram of a product detection system according to an embodiment of the present disclosure.

如图6所示,在本公开实施例中,还提供了一种制品检测系统,包括如图5所示的软件检测装置500和外联数据库600。As shown in FIG. 6 , in an embodiment of the present disclosure, a product detection system is further provided, including the software detection device 500 and the external database 600 as shown in FIG. 5 .

软件检测装置500是实现制品检测系统的核心,其组成部分可以包含制品检测交互端、制品检测执行端、制品检测数据端三个模块,制品检测交互端负责制品检测的交互能力域,包含制品检测规则定义、制品检测作业发起、制品检测报告查询等功能。制品检测执行端负责制品检测的执行能力域,包含制品检测作业任务分配、制品检测作业资源调度、制品检测外联资源获取、制品检测规则执行等功能。制品检测数据端负责制品检测的数据能力域,包含制品检测规则存储、制品检测作业数据持久化存储、制品检测报告生成等功能。制品导入模块510、规则生成模块520可以与制品检测交互端集成,规范检测模块530、比对检测模块540和来源检测模块550可以与制品检测执行端集成。The software detection device 500 is the core of the product detection system. Its components may include three modules: the product detection interactive terminal, the product detection execution terminal, and the product detection data terminal. The product detection interactive terminal is responsible for the interactive capability domain of product detection, including product detection rule definition, product detection job initiation, product detection report query and other functions. The product detection execution terminal is responsible for the execution capability domain of product detection, including product detection job task allocation, product detection job resource scheduling, product detection external resource acquisition, product detection rule execution and other functions. The product detection data terminal is responsible for the data capability domain of product detection, including product detection rule storage, product detection job data persistent storage, product detection report generation and other functions. The product import module 510 and the rule generation module 520 can be integrated with the product detection interactive terminal, and the specification detection module 530, the comparison detection module 540 and the source detection module 550 can be integrated with the product detection execution terminal.

外联数据库600为软件制品检测提供了必要检测条件,其组成部分包括源码信息库610、构建信息库620及制品信息库630。源码信息库包含软件制品的版本库地址、分支、标签、提交记录等要素。构建信息库包含软件制品的构建记录、构建日志等要素。制品信息库包含软件制品实体、软件制品MD5等要素。The external database 600 provides necessary detection conditions for software product detection, and its components include a source code information library 610, a build information library 620, and a product information library 630. The source code information library contains software product version library addresses, branches, tags, submission records, and other elements. The build information library contains software product build records, build logs, and other elements. The product information library contains software product entities, software product MD5, and other elements.

图2~图4所示的软件检测方法的可以基于制品检测系统实现。The software detection method shown in FIG. 2 to FIG. 4 can be implemented based on a product detection system.

图7示意性示出了根据本公开实施例的适于实现软件检测方法的电子设备的方框图。FIG. 7 schematically shows a block diagram of an electronic device suitable for implementing a software detection method according to an embodiment of the present disclosure.

如图7所示,根据本公开实施例的电子设备700包括处理器701,其可以根据存储在只读存储器(ROM)702中的程序或者从存储部分708加载到随机访问存储器(RAM)703中的程序而执行各种适当的动作和处理。处理器701例如可以包括通用微处理器(例如CPU)、指令集处理器和/或相关芯片组和/或专用微处理器(例如,专用集成电路(ASIC))等等。处理器701还可以包括用于缓存用途的板载存储器。处理器701可以包括用于执行根据本公开实施例的方法流程的不同动作的单一处理单元或者是多个处理单元。As shown in FIG7 , the electronic device 700 according to an embodiment of the present disclosure includes a processor 701, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 702 or a program loaded from a storage part 708 to a random access memory (RAM) 703. The processor 701 may include, for example, a general-purpose microprocessor (e.g., a CPU), an instruction set processor and/or a related chipset and/or a dedicated microprocessor (e.g., an application-specific integrated circuit (ASIC)), etc. The processor 701 may also include an onboard memory for caching purposes. The processor 701 may include a single processing unit or multiple processing units for performing different actions of the method flow according to an embodiment of the present disclosure.

在RAM 703中,存储有电子设备700操作所需的各种程序和数据。处理器 701、ROM702以及RAM 703通过总线704彼此相连。处理器701通过执行ROM 702和/或RAM 703中的程序来执行根据本公开实施例的方法流程的各种操作。需要注意,所述程序也可以存储在除ROM 702和RAM 703以外的一个或多个存储器中。处理器701也可以通过执行存储在所述一个或多个存储器中的程序来执行根据本公开实施例的方法流程的各种操作。In RAM 703, various programs and data required for the operation of electronic device 700 are stored. Processor 701, ROM 702 and RAM 703 are connected to each other through bus 704. Processor 701 performs various operations of the method flow according to the embodiment of the present disclosure by executing the program in ROM 702 and/or RAM 703. It should be noted that the program can also be stored in one or more memories other than ROM 702 and RAM 703. Processor 701 can also perform various operations of the method flow according to the embodiment of the present disclosure by executing the program stored in the one or more memories.

根据本公开的实施例,电子设备700还可以包括输入/输出(I/O)接口705,输入/输出(I/O)接口705也连接至总线704。电子设备700还可以包括连接至I/O接口705的以下部件中的一项或多项:包括键盘、鼠标等的输入部分706;包括诸如阴极射线管(CRT)、液晶显示器(LCD)等以及扬声器等的输出部分707;包括硬盘等的存储部分708;以及包括诸如LAN卡、调制解调器等的网络接口卡的通信部分709。通信部分709经由诸如因特网的网络执行通信处理。驱动器710也根据需要连接至I/O接口705。可拆卸介质711,诸如磁盘、光盘、磁光盘、半导体存储器等等,根据需要安装在驱动器710上,以便于从其上读出的计算机程序根据需要被安装入存储部分708。According to an embodiment of the present disclosure, the electronic device 700 may further include an input/output (I/O) interface 705, which is also connected to the bus 704. The electronic device 700 may further include one or more of the following components connected to the I/O interface 705: an input portion 706 including a keyboard, a mouse, etc.; an output portion 707 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage portion 708 including a hard disk, etc.; and a communication portion 709 including a network interface card such as a LAN card, a modem, etc. The communication portion 709 performs communication processing via a network such as the Internet. A drive 710 is also connected to the I/O interface 705 as needed. A removable medium 711, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 710 as needed, so that a computer program read therefrom is installed into the storage portion 708 as needed.

本公开还提供了一种计算机可读存储介质,该计算机可读存储介质可以是上述实施例中描述的设备/装置/系统中所包含的;也可以是单独存在,而未装配入该设备/装置/系统中。上述计算机可读存储介质承载有一个或者多个程序,当上述一个或者多个程序被执行时,实现根据本公开实施例的方法。The present disclosure also provides a computer-readable storage medium, which may be included in the device/apparatus/system described in the above embodiments; or may exist independently without being assembled into the device/apparatus/system. The above computer-readable storage medium carries one or more programs, and when the above one or more programs are executed, the method according to the embodiment of the present disclosure is implemented.

根据本公开的实施例,计算机可读存储介质可以是非易失性的计算机可读存储介质,例如可以包括但不限于:便携式计算机磁盘、硬盘、随机访问存储器(RAM)、只读存储器(ROM)、可擦式可编程只读存储器(EPROM或闪存)、便携式紧凑磁盘只读存储器(CD-ROM)、光存储器件、磁存储器件、或者上述的任意合适的组合。在本公开中,计算机可读存储介质可以是任何包含或存储程序的有形介质,该程序可以被指令执行系统、装置或者器件使用或者与其结合使用。例如,根据本公开的实施例,计算机可读存储介质可以包括上文描述的ROM 702和/或RAM 703和/或ROM 702和RAM 703以外的一个或多个存储器。According to an embodiment of the present disclosure, the computer-readable storage medium may be a non-volatile computer-readable storage medium, for example, it may include but is not limited to: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination thereof. In the present disclosure, a computer-readable storage medium may be any tangible medium containing or storing a program, which may be used by or in combination with an instruction execution system, an apparatus or a device. For example, according to an embodiment of the present disclosure, the computer-readable storage medium may include the ROM 702 and/or RAM 703 described above and/or one or more memories other than ROM 702 and RAM 703.

本公开的实施例还包括一种计算机程序产品,其包括计算机程序,该计算机程序包含用于执行流程图所示的方法的程序代码。当计算机程序产品在计算机系统中运行时,该程序代码用于使计算机系统实现本公开实施例所提供的软件检测方法。The embodiment of the present disclosure also includes a computer program product, which includes a computer program, and the computer program contains program code for executing the method shown in the flowchart. When the computer program product is run in a computer system, the program code is used to enable the computer system to implement the software detection method provided by the embodiment of the present disclosure.

在该计算机程序被处理器701执行时执行本公开实施例的系统/装置中限定的上述功能。根据本公开的实施例,上文描述的系统、装置、模块、单元等可以通过计算机程序模块来实现。The above functions defined in the system/device of the embodiment of the present disclosure are performed when the computer program is executed by the processor 701. According to the embodiment of the present disclosure, the system, device, module, unit, etc. described above can be implemented by a computer program module.

在一种实施例中,该计算机程序可以依托于光存储器件、磁存储器件等有形存储介质。在另一种实施例中,该计算机程序也可以在网络介质上以信号的形式进行传输、分发,并通过通信部分709被下载和安装,和/或从可拆卸介质711被安装。该计算机程序包含的程序代码可以用任何适当的网络介质传输,包括但不限于:无线、有线等等,或者上述的任意合适的组合。In one embodiment, the computer program may rely on tangible storage media such as optical storage devices, magnetic storage devices, etc. In another embodiment, the computer program may also be transmitted and distributed in the form of signals on a network medium, and downloaded and installed through the communication part 709, and/or installed from the removable medium 711. The program code contained in the computer program may be transmitted using any appropriate network medium, including but not limited to: wireless, wired, etc., or any suitable combination of the above.

在这样的实施例中,该计算机程序可以通过通信部分709从网络上被下载和安装,和/或从可拆卸介质711被安装。在该计算机程序被处理器701执行时,执行本公开实施例的系统中限定的上述功能。根据本公开的实施例,上文描述的系统、设备、装置、模块、单元等可以通过计算机程序模块来实现。In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 709, and/or installed from the removable medium 711. When the computer program is executed by the processor 701, the above functions defined in the system of the embodiment of the present disclosure are performed. According to the embodiment of the present disclosure, the system, device, apparatus, module, unit, etc. described above can be implemented by a computer program module.

根据本公开的实施例,可以以一种或多种程序设计语言的任意组合来编写用于执行本公开实施例提供的计算机程序的程序代码,具体地,可以利用高级过程和/或面向对象的编程语言、和/或汇编/机器语言来实施这些计算程序。程序设计语言包括但不限于诸如Java,C++,python,“C”语言或类似的程序设计语言。程序代码可以完全地在用户计算设备上执行、部分地在用户设备上执行、部分在远程计算设备上执行、或者完全在远程计算设备或服务器上执行。在涉及远程计算设备的情形中,远程计算设备可以通过任意种类的网络,包括局域网(LAN)或广域网(WAN),连接到用户计算设备,或者,可以连接到外部计算设备(例如利用因特网服务提供商来通过因特网连接)。According to an embodiment of the present disclosure, the program code for executing the computer program provided by the embodiment of the present disclosure can be written in any combination of one or more programming languages. Specifically, these computing programs can be implemented using high-level process and/or object-oriented programming languages, and/or assembly/machine languages. Programming languages include, but are not limited to, Java, C++, python, "C" language or similar programming languages. The program code can be executed entirely on the user computing device, partially on the user device, partially on the remote computing device, or entirely on the remote computing device or server. In the case of a remote computing device, the remote computing device can be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computing device (for example, using an Internet service provider to connect through the Internet).

附图中的流程图和框图,图示了按照本公开各种实施例的系统、方法和计算机程序产品的可能实现的体系架构、功能和操作。在这点上,流程图或框图中的每个方框可以代表一个模块、程序段、或代码的一部分,上述模块、程序段、或代码的一部分包含一个或多个用于实现规定的逻辑功能的可执行指令。也应当注意,在有些作为替换的实现中,方框中所标注的功能也可以以不同于附图中所标注的顺序发生。例如,两个接连地表示的方框实际上可以基本并行地执行,它们有时也可以按相反的顺序执行,这依所涉及的功能而定。也要注意的是,框图或流程图中的每个方框、以及框图或流程图中的方框的组合,可以用执行规定的功能或操作的专用的基于硬件的系统来实现,或者可以用专用硬件与计算机指令的组合来实现。The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present disclosure. In this regard, each box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.

本领域技术人员可以理解,本公开的各个实施例和/或权利要求中记载的特征可以进行多种组合或/或结合,即使这样的组合或结合没有明确记载于本公开中。特别地,在不脱离本公开精神和教导的情况下,本公开的各个实施例和/或权利要求中记载的特征可以进行多种组合和/或结合。所有这些组合和/或结合均落入本公开的范围。It will be appreciated by those skilled in the art that the features described in the various embodiments and/or claims of the present disclosure may be combined and/or combined in various ways, even if such combinations and/or combinations are not explicitly described in the present disclosure. In particular, the features described in the various embodiments and/or claims of the present disclosure may be combined and/or combined in various ways without departing from the spirit and teachings of the present disclosure. All of these combinations and/or combinations fall within the scope of the present disclosure.

以上对本公开的实施例进行了描述。但是,这些实施例仅仅是为了说明的目的,而并非为了限制本公开的范围。尽管在以上分别描述了各实施例,但是这并不意味着各个实施例中的措施不能有利地结合使用。本公开的范围由所附权利要求及其等同物限定。不脱离本公开的范围,本领域技术人员可以做出多种替代和修改,这些替代和修改都应落在本公开的范围之内。The embodiments of the present disclosure are described above. However, these embodiments are only for the purpose of illustration and are not intended to limit the scope of the present disclosure. Although the embodiments are described above separately, this does not mean that the measures in the various embodiments cannot be used in combination to advantage. The scope of the present disclosure is defined by the attached claims and their equivalents. Without departing from the scope of the present disclosure, those skilled in the art may make a variety of substitutions and modifications, which should all fall within the scope of the present disclosure.

Claims (13)

1.一种软件检测方法,其特征在于,所述方法包括:1. A software detection method, characterized in that the method comprises: 响应于软件检测请求,向检测环境导入目标软件制品;In response to the software detection request, importing the target software artifact into the detection environment; 生成所述目标软件制品的制品结构清单,基于所述制品结构清单制定标准化检测规则,所述标准化检测规则包括规范检测规则、比对检测规则和来源检测规则;Generate a product structure list of the target software product, and formulate standardized detection rules based on the product structure list, wherein the standardized detection rules include specification detection rules, comparison detection rules and source detection rules; 基于所述规范检测规则检测所述制品结构清单中不符合预设规则的文件和不符合预设条件的技术栈;Detecting files that do not conform to preset rules and technology stacks that do not conform to preset conditions in the product structure list based on the specification detection rules; 基于所述比对检测规则检测所述目标软件制品与对比软件制品的差异;Detecting the difference between the target software product and the comparison software product based on the comparison detection rule; 基于所述来源检测规则检测所述目标软件制品的内容来源。The content source of the target software product is detected based on the source detection rule. 2.根据权利要求1所述的方法,其特征在于,所述响应于软件检测请求,导入目标软件制品包括:2. The method according to claim 1, wherein in response to the software detection request, importing the target software product comprises: 响应于所述软件检测请求,获取所述目标软件制品的制品对象信息;In response to the software detection request, obtaining product object information of the target software product; 从预设的制品信息库获取与所述制品对象信息匹配的所述目标软件制品,向检测环境导入所述目标软件制品。The target software product matching the product object information is obtained from a preset product information library, and the target software product is imported into the detection environment. 3.根据权利要求1所述的方法,其特征在于,所述生成所述目标软件制品的制品结构清单,基于所述制品结构清单制定标准化检测规则,所述标准化检测规则包括规范检测规则、比对检测规则和来源检测规则包括:3. The method according to claim 1, characterized in that the generating of the product structure list of the target software product and formulating standardized detection rules based on the product structure list, wherein the standardized detection rules include specification detection rules, comparison detection rules and source detection rules, including: 遍历所述目标软件制品的目录结构并提取内容属性,生成制品结构清单;Traversing the directory structure of the target software product and extracting content attributes to generate a product structure list; 基于所述制品结构清单获取所述目标软件制品包括的文件的文件属性和所述内容属性中包括的技术栈属性,基于所述文件属性和技术栈属性在预设的标准化规则库中匹配获取规范检测规则;Based on the product structure list, file attributes of files included in the target software product and technology stack attributes included in the content attributes are obtained, and based on the file attributes and technology stack attributes, standard detection rules are obtained by matching in a preset standardization rule library; 基于用户的需求选择指令从所述制品结构清单中选择比对项目,形成至少包括所述目标软件制品与对比软件制品的目录结构比对项目、内容属性比项目对及构建过程比对项目中的其中一种的比对检测规则;Selecting a comparison item from the artifact structure list based on a user's demand selection instruction, and forming a comparison detection rule including at least one of a directory structure comparison item, a content attribute comparison item, and a construction process comparison item between the target software artifact and the comparison software artifact; 基于用户的需求选择指令从所述制品结构清单中获取来源检测对象,生成检测所述来源检测对象的源码来源、依赖来源及通用结构来源的来源检测规则。Based on the user's demand selection instruction, a source detection object is obtained from the product structure list, and a source detection rule for detecting the source code source, dependency source and common structure source of the source detection object is generated. 4.根据权利要求1所述的方法,其特征在于,所述基于所述规范检测规则检测所述制品结构清单中不符合预设规则的文件和不符合预设条件的技术栈包括:4. The method according to claim 1, characterized in that the detecting, based on the specification detection rule, the files that do not conform to the preset rules and the technology stacks that do not conform to the preset conditions in the product structure list comprises: 基于所述规范检测规则规定的白名单,检出所述制品结构清单相比所述白名单缺失的文件属性对应的文件;Based on the whitelist specified by the specification detection rule, detecting files corresponding to the file attributes missing from the product structure list compared to the whitelist; 基于所述规范检测规则规定的黑名单,检出所述制品结构清单中所述黑名单不允许包括的文件属性对应的文件;Based on the blacklist specified by the specification detection rule, detect the files corresponding to the file attributes not allowed by the blacklist in the product structure list; 基于所述规范检测规则规定的技术栈规则,检出所述制品结构清单中不符合预设条件的技术栈属性,所述预设条件为所述制品结构清单包括与所述技术栈属性对应的校验模板文件。Based on the technology stack rules specified in the specification detection rules, technology stack attributes in the product structure list that do not meet preset conditions are detected, and the preset condition is that the product structure list includes a verification template file corresponding to the technology stack attribute. 5.根据权利要求1所述的方法,其特征在于,所述基于所述比对检测规则检测所述目标软件制品与对比软件制品的差异包括:5. The method according to claim 1, wherein detecting the difference between the target software product and the comparison software product based on the comparison detection rule comprises: 基于所述比对检测规则比对所述目标软件制品与对比软件制品的目录结构、内容属性和构建日志,生成结构差异清单、内容差异清单及建构过程清单。The directory structure, content attributes and build log of the target software product and the comparison software product are compared based on the comparison detection rules to generate a structure difference list, a content difference list and a build process list. 6.根据权利要求1所述的方法,其特征在于,所述基于所述来源检测规则检测所述目标软件制品的内容来源包括:6. The method according to claim 1, wherein detecting the content source of the target software product based on the source detection rule comprises: 基于所述来源检测规则筛选所述制品关联信息清单中与所述目标软件制品相关的内容属性;Filtering content attributes related to the target software product in the product association information list based on the source detection rule; 基于所述内容属性获取所述目标软件制品的源码来源信息、依赖来源信息及通用结构来源信息。The source code source information, dependency source information and general structure source information of the target software product are obtained based on the content attributes. 7.根据权利要求1所述的方法,其特征在于,所述方法还包括:7. The method according to claim 1, characterized in that the method further comprises: 在所述标准化检测规则制定完成后,生成所述目标软件制品的规范检测任务、比对检测任务和来源检测任务;After the standardized detection rules are formulated, a standard detection task, a comparison detection task and a source detection task of the target software product are generated; 分配所述规范检测任务、所述比对检测任务和所述来源检测任务的计算资源,以分别执行所述规范检测规则、所述比对检测规则和所述来源检测规则的检测。The computing resources of the specification detection task, the comparison detection task and the source detection task are allocated to respectively execute the detection of the specification detection rules, the comparison detection rules and the source detection rules. 8.根据权利要求7所述的方法,其特征在于,所述方法还包括:8. The method according to claim 7, characterized in that the method further comprises: 生成所述规范检测任务、所述比对检测任务和所述来源检测任务后,调用所述目标软件制品的外联数据库获取执行所述规范检测规则、所述比对检测规则和所述来源检测规则的检测涉及的数据。After generating the specification detection task, the comparison detection task and the source detection task, the external database of the target software product is called to obtain data involved in executing the detection of the specification detection rules, the comparison detection rules and the source detection rules. 9.根据权利要求1所述的方法,其特征在于,所述方法还包括:9. The method according to claim 1, characterized in that the method further comprises: 基于所述规范检测规则、所述比对检测规则和所述来源检测规则检测所述目标软件制品生成的检测数据,生成检测报告进行备份和用户反馈。The detection data generated by detecting the target software product is detected based on the standard detection rules, the comparison detection rules and the source detection rules, and a detection report is generated for backup and user feedback. 10.一种软件检测装置,其特征在于,所述装置包括:10. A software detection device, characterized in that the device comprises: 制品导入模块,用于响应于软件检测请求,向检测环境导入目标软件制品;The product import module is used to import the target software product into the detection environment in response to the software detection request; 规则生成模块,用于生成所述目标软件制品的制品结构清单,基于所述制品结构清单制定标准化检测规则,所述标准化检测规则包括规范检测规则、比对检测规则和来源检测规则;A rule generation module, used to generate a product structure list of the target software product, and formulate standardized detection rules based on the product structure list, wherein the standardized detection rules include specification detection rules, comparison detection rules and source detection rules; 规范检测模块,用于基于所述规范检测规则检测所述制品结构清单中不符合预设规则的文件和不符合预设条件的技术栈;A specification detection module, used for detecting files that do not conform to preset rules and technology stacks that do not conform to preset conditions in the product structure list based on the specification detection rules; 比对检测模块,用于基于所述比对检测规则检测所述目标软件制品与对比软件制品的差异;A comparison and detection module, used for detecting the difference between the target software product and the comparison software product based on the comparison and detection rules; 来源检测模块,用于基于所述来源检测规则检测所述目标软件制品的内容来源。A source detection module is used to detect the content source of the target software product based on the source detection rule. 11.一种电子设备,包括:11. An electronic device, comprising: 一个或多个处理器;one or more processors; 存储装置,用于存储一个或多个计算机程序,a storage device for storing one or more computer programs, 其特征在于,所述一个或多个处理器执行所述一个或多个计算机程序以实现根据权利要求1~9中任一项所述方法的步骤。It is characterized in that the one or more processors execute the one or more computer programs to implement the steps of the method according to any one of claims 1 to 9. 12.一种计算机可读存储介质,其上存储有计算机程序/指令,其特征在于,该计算机程序/指令被处理器执行时实现根据权利要求1~9中任一项所述方法的步骤。12. A computer-readable storage medium having a computer program/instruction stored thereon, wherein the computer program/instruction, when executed by a processor, implements the steps of the method according to any one of claims 1 to 9. 13.一种计算机程序产品,包括计算机程序/指令,其特征在于,所述计算机程序/指令被处理器执行时实现根据权利要求1~9中任一项所述方法的步骤。13. A computer program product, comprising a computer program/instruction, wherein the computer program/instruction, when executed by a processor, implements the steps of the method according to any one of claims 1 to 9.
CN202410701073.7A 2024-05-31 2024-05-31 Software detection method, device, equipment, medium and program product Pending CN118445209A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202410701073.7A CN118445209A (en) 2024-05-31 2024-05-31 Software detection method, device, equipment, medium and program product

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202410701073.7A CN118445209A (en) 2024-05-31 2024-05-31 Software detection method, device, equipment, medium and program product

Publications (1)

Publication Number Publication Date
CN118445209A true CN118445209A (en) 2024-08-06

Family

ID=92314064

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202410701073.7A Pending CN118445209A (en) 2024-05-31 2024-05-31 Software detection method, device, equipment, medium and program product

Country Status (1)

Country Link
CN (1) CN118445209A (en)

Similar Documents

Publication Publication Date Title
US11570214B2 (en) Crowdsourced innovation laboratory and process implementation system
US20210383370A1 (en) Enhanced multi-party user data deletion
US8843943B2 (en) Generating a service definition in view of service activity events
EP2667301A1 (en) Decision service manager
US20230297550A1 (en) Dynamic data views
Nicacio et al. An approach to build consistent software architecture diagrams using devops system descriptors
Elakaş et al. A systematic mapping on software testing for blockchains
CN118537111A (en) Transaction reconciliation method, apparatus, device, medium and program product
CN118885405A (en) Database testing method and device
CN118897675A (en) Component library construction and calling method, device, equipment and storage medium
CN119002925A (en) Link relation identification method, device, equipment, medium and program product
US8504506B2 (en) Systems and methods for modeling and analyzing solution requirements and assets
CN118445209A (en) Software detection method, device, equipment, medium and program product
CN117170659A (en) Packaging method and device for test script code
Goossens et al. From OCEL to DOCEL–datasets and automated transformation
CN118296023B (en) Data comparison method, device, equipment, medium and program product
CN120386802B (en) Task item creation method, task item query method, device and equipment
US20250258654A1 (en) Retrieval augmented generation based on process artifacts
CA3090986C (en) Method and system for overseeing execution of graph-based contracts using hash chains
CN112395850B (en) A method, device and electronic device for checking data definition consistency
US20250053737A1 (en) Specialized Work Product
CN117726470A (en) Financial data processing methods and devices, storage media and electronic equipment
Sharma et al. Three Layered Crud API Architecture
Machini et al. Web API Usability: A Systematic Mapping Study
CN118394655A (en) Information processing method, device, equipment, medium and program product

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination