Firmware processing method for IO card of trusted DCS and related equipment

The firmware processing method for IO cards in trusted DCS systems verifies and monitors firmware files to ensure stable and reliable operation, addressing security risks by ensuring firmware integrity and accuracy during download and operation.

CN119225776APending Publication Date: 2024-12-31XIAN THERMAL POWER RES INST CO LTD +1
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202411250429.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-06
Publication Date
2024-12-31

AI Technical Summary

Technical Problem

The stable and reliable operation of IO cards in a trusted DCS system is not effectively ensured during the working process, leading to security risks due to lack of monitoring in the firmware download, startup, and operation stages.

Method used

A firmware processing method involving download information verification, checksum calculations, and periodic monitoring of firmware files in the IO card's flash memory to ensure integrity and accuracy, including burning, reading, and verifying firmware files, and using a dual-area storage mechanism with CRC checks.

Benefits of technology

Ensures the safe and reliable operation of IO cards by verifying firmware files during download and monitoring firmware operation, reducing system risks from unstable factors like electromagnetic interference.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119225776A_ABST
    Figure CN119225776A_ABST
Patent Text Reader

Abstract

The invention belongs to the technical field of distributed control systems, and particularly relates to a firmware processing method and related equipment for an IO card of a trusted DCS, and the method comprises the steps: carrying out the downloading information verification of a downloading request message; if the verification is passed, programming the firmware file in the downloading request message to the IO card; verifying the attached information in the read firmware file; if the verification is passed, the firmware file is successfully downloaded; judging whether a written firmware file exists in a code execution partition of the flash memory or not; if yes, verifying the firmware file written in the code execution partition; periodically reading firmware files stored in the code execution partition and the backup code area, and obtaining a check value calculation result; comparing the verification value calculation result with a pre-stored verification value; if yes, the firmware file stored in the code execution partition is normally run; according to the invention, stable and reliable operation of the IO card can be ensured, and the security risk of the trusted DCS system is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of distributed control systems, and in particular relates to a firmware processing method for IO cards of a trusted DCS system and related equipment. Background Art

[0002] Distributed Control System (DCS) is a new type of control equipment that uses computer technology to centrally monitor, operate, manage and decentralized control industrial production processes. It is widely used in industrial production fields such as electricity. The trusted DCS system is based on the traditional DCS system and improves the security of the system by introducing a trusted computing system.

[0003] The IO cards in the trusted DCS system are used to directly interact with field equipment. They are directly involved in receiving sensor unit signals and controlling the actions of field actuators. When an IO card fails, it may cause field equipment to lose control, the production process to terminate, or even cause a safety accident. Therefore, the stable and reliable operation of the IO card is directly related to the safe operation of the control subject. Among them, the downloading, startup, and operation monitoring of the IO card firmware files have a vital impact on the stable and reliable operation of the IO card.

[0004] At present, during the working process of IO cards, the file name or file format is only verified during the firmware download stage, and there is a lack of monitoring of the startup and operation stages. It is impossible to effectively ensure the stable and reliable operation of IO cards, which in turn creates a greater security risk for the trusted DCS system. Summary of the invention

[0005] In view of the technical problems existing in the prior art, the present invention provides a firmware processing method and related equipment for an IO card of a trusted DCS system to solve the technical problem that the stable and reliable operation of the IO card cannot be effectively ensured during the working process of the IO card, thereby generating a greater security risk for the trusted DCS system.

[0006] In order to achieve the above object, the technical solution adopted by the present invention is:

[0007] The present invention provides a firmware processing method for a trusted DCS system IO card, comprising:

[0008] Receive a download request message, and perform download information verification on the download request message; wherein the download request message includes download information and a firmware file; if the download information verification passes, burn the firmware file in the download request message to the IO card; read the firmware file burned in the IO card, and verify the accompanying information in the read firmware file; if the verification passes, the firmware file is downloaded successfully;

[0009] Determine whether there is a firmware file written in the code execution partition of the flash memory in the IO card; if so, verify the firmware file written in the code execution partition of the flash memory in the IO card;

[0010] The firmware files stored in the code execution partition and the backup code area of ​​the flash memory in the IO card are periodically read, and the check value calculation is performed respectively to obtain the check value calculation result; the check value calculation result is compared with the pre-stored check value; if they are consistent, the firmware files stored in the code execution partition of the flash memory in the IO card are normally operated.

[0011] Furthermore, the generation process of the download request message is as follows:

[0012] Obtain a firmware file by compiling the code; wherein the end of the firmware file carries generation compile time version information and a checksum CRC value;

[0013] The download request message is parsed and generated according to the firmware file and in combination with the firmware download request initiated in advance.

[0014] Furthermore, the process of verifying the download information of the download request message is specifically as follows: respectively performing consistency judgment on the firmware file name, file type and file content.

[0015] Furthermore, the process of burning the firmware file into the IO card is specifically as follows: burning the firmware file into the flash memory in the IO card in a binary form.

[0016] Furthermore, the process of reading the firmware file burned in the IO card and verifying the accompanying information in the read firmware file is as follows:

[0017] Read the burned firmware file from the flash memory in the IO card, and calculate the checksum of the read firmware file to obtain the checksum calculation value;

[0018] The calculated checksum value is compared with the checksum CRC value in the accompanying information of the firmware file.

[0019] Furthermore, before determining whether there is a written firmware file in the code execution partition of the flash memory in the IO card, a firmware download flag area determination step is also included;

[0020] The firmware download mark area determination step is as follows:

[0021] The bootloader program is used to read the contents of the firmware download flag area of ​​the flash in the IO card MCU; if a download flag exists, the bootloader is stopped to perform the firmware download or update process; if no download flag exists, it is determined whether there is a written firmware file in the code execution partition of the flash memory in the IO card.

[0022] Furthermore, the process of verifying the firmware file written in the code execution partition of the flash memory is specifically as follows: calculating a code segment check value and comparing it with the check value written in the flash.

[0023] The present invention also provides a firmware processing system for a trusted DCS system IO card, comprising:

[0024] The download module is used to receive a download request message and perform download information verification on the download request message; wherein the download request message includes download information and a firmware file; if the download information verification passes, the firmware file in the download request message is burned into the IO card; the firmware file burned in the IO card is read, and the accompanying information in the read firmware file is verified; if the verification passes, the firmware file is downloaded successfully;

[0025] The startup module is used to determine whether there is a firmware file written in the code execution partition of the flash memory in the IO card; if so, verify the firmware file written in the code execution partition of the flash memory;

[0026] The monitoring module is used to periodically read the firmware files stored in the code execution partition and the backup code area of ​​the flash memory in the IO card component, and respectively perform check value calculations to obtain check value calculation results; compare the check value calculation results with the pre-stored check values; if they are consistent, the firmware files stored in the code execution partition of the flash memory in the IO card component are normally operated.

[0027] The present invention also provides a firmware processing device for a trusted DCS system IO card, comprising:

[0028] Memory for storing computer programs;

[0029] The processor is used to implement the steps of the firmware processing method of the trusted DCS system IO card when executing the computer program.

[0030] The present invention also provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the firmware processing method of the trusted DCS system IO card are implemented.

[0031] Compared with the prior art, the present invention has the following beneficial effects:

[0032] The firmware processing method of the IO card of the trusted DCS system provided by the present invention realizes the verification of the firmware file during the download process by verifying the download information and the firmware file, thereby ensuring the integrity and accuracy of the firmware file during the download process; by verifying the firmware file written in the code execution partition of the flash memory, the safe and reliable startup of the firmware program can be ensured; secondly, by periodically reading the firmware files stored in the code execution partition and the backup code area of ​​the flash memory and performing verification value comparison, the real-time monitoring of the firmware code during the firmware operation process is realized, and possible data damage can be detected and processed in time, thereby avoiding the system risk caused by unstable factors such as electromagnetic interference; the method of the present invention has a simple process, can effectively ensure the stable and reliable operation of the IO card, and greatly reduces the safety risk of the trusted DCS system. BRIEF DESCRIPTION OF THE DRAWINGS

[0033] Figure 1 A flowchart of the firmware processing method of the trusted DCS system IO card provided in Example 1;

[0034] Figure 2 This is a flow chart of the IO card firmware download method in Example 1;

[0035] Figure 3 The schematic diagram of the flash storage partition structure and function of the MCU in the IO card in Example 1;

[0036] Figure 4 This is a flow chart of the IO card firmware startup method in Example 1;

[0037] Figure 5 Schematic diagram of the flow of the IO card firmware monitoring method in Example 1;

[0038] Figure 6 A flowchart of the firmware processing system of the trusted DCS system IO card provided in Example 2;

[0039] Figure 7 This is a flowchart of the firmware processing device of the trusted DCS system IO card provided in Example 3. DETAILED DESCRIPTION

[0040] In order to make the technical problems, technical solutions and beneficial effects solved by the present invention more clearly understood, the present invention is further described in detail in the following specific embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.

[0041] Example 1

[0042] As attached Figure 1 As shown, this embodiment 1 provides a firmware processing method for a trusted DCS system IO card, comprising the following steps:

[0043] Step 1, receiving a download request message, and verifying the download information of the download request message; wherein the download request message includes download information and a firmware file; if the download information verification passes, the firmware file in the download request message is burned to the IO card; the firmware file burned in the IO card is read, and the accompanying information in the read firmware file is verified. If the verification passes, the firmware file is downloaded successfully.

[0044] It should be noted that the generation process of the download request message is specifically as follows: obtaining a firmware file through code compilation; wherein the end of the firmware file carries generation compilation time version information and a checksum CRC value; based on the firmware file and in combination with a pre-initiated firmware download request, the download request message is parsed and generated.

[0045] As attached Figure 2 As shown in the figure, the download process of the firmware file is as follows:

[0046] Step 11: Generate a download request message; wherein the process of generating the download request message is specifically as follows:

[0047] The host computer initiates a firmware download request to download a predetermined file to a preset IO card.

[0048] The format, name and content of the predetermined file are checked to confirm that the format, name and content of the predetermined file are correct.

[0049] The predetermined file is compiled by a code compilation method to obtain a firmware file; wherein, during the code compilation process, compilation time version information and a checksum CRC value are generated at the end of the firmware file, that is, the end of the firmware file carries the generated compilation time version information and the checksum CRC value.

[0050] In conjunction with a pre-initiated firmware download request, the firmware file is parsed using a preset tool software to convert the binary content of the firmware file into a preset communication message format to obtain a download request message; wherein the download request message includes download information and a firmware file.

[0051] The download request message is sent to the IO card via a preset physical data link to avoid controller message interference and engineering misoperation.

[0052] Step 12: Receive the download request message on the IO card side and verify the download information in the download request message; wherein, the process of verifying the download information of the download request message is specifically as follows: respectively make consistency judgments on the firmware file name, file type and file to confirm that the name of the firmware file is consistent with the card type and the file type is the firmware type that needs to be updated.

[0053] Step 13, if the download information verification is passed, the firmware file in the download request message is burned to the IO card; specifically, after the download information verification is passed, jump to the bootloader program segment of the MCU in the IO card, and burn the firmware file in binary form to the flash memory in the IO card; preferably, the firmware file is burned in binary form to the flash code execution area 0x08020000-08090000 in the IO card, and the same binary content is burned in the flash code backup area 0x08090000-0x08100000 in the IO card for backup and monitoring.

[0054] Step 14, read the firmware file burned in the IO card, and check the accompanying information in the read firmware file; specifically, read the burned firmware file from the flash memory in the IO card, and calculate the checksum of the read firmware file to obtain a checksum calculation value; compare the checksum calculation value with the checksum CRC value in the accompanying information of the firmware file.

[0055] Step 15. If the checksum calculation value is consistent with the comparison result of the checksum CRC value in the accompanying information of the firmware file, the check is passed, and the firmware file is downloaded successfully. When the firmware file is downloaded successfully, the checksum calculation value is written to the flash address 0x08100000.

[0056] Step 16. If the comparison result of the checksum calculation value and the checksum CRC value in the accompanying information of the firmware file is inconsistent, the check fails and the firmware file download fails. When the firmware file download fails, the flash area is erased and the bootloader program continues to run.

[0057] Step 17: When the firmware file is downloaded successfully, reset the MCU and jump to the formal program segment to enter the startup phase.

[0058] It should be noted that when the trusted DCS system downloads and updates the firmware of the MCU and FPGA of the IO card, it is necessary to load the local firmware file through the host computer software, and after parsing, send the firmware content to the MCU of the IO card through the communication link between the controller and the IO card, and the MCU will verify and burn it according to the corresponding instructions; among them, the flash storage partition structure and function of the MCU in the IO card are as shown in the attached figure. Figure 3 As shown in the figure; after the download is completed, the IO card starts the firmware through its own program architecture, reads and verifies the firmware code segment from the bootloader, and runs the updated firmware program after the verification; when the MCU runs the user program, the flash code segment and the backup segment are periodically verified and compared to ensure the stable operation of the firmware program, and can respond and report to the controller in time when the firmware data is damaged due to external interference factors, thereby ensuring the safe download and stable operation of the IO card firmware in the trusted DCS system.

[0059] Step 2: Use the bootloader program to read the contents of the firmware download flag area of ​​the flash in the IO card MCU; if a download flag exists, stop the bootloader and perform the firmware download or update process; if no download flag exists, determine whether there is a firmware file written in the code execution partition of the flash memory in the IO card; if so, verify the firmware file written in the code execution partition of the flash memory.

[0060] As attached Figure 4 As shown, the specific steps include:

[0061] Step 21, use the bootloader program to read the contents of the firmware download flag area of ​​the flash in the IO card MCU to determine whether the IO card is in the user program running stage or the firmware download request jumps; wherein, if the IO card is in the user program running stage, it receives a download request and jumps to the bootloader, and writes a download flag in the firmware download flag area of ​​the flash in the IO card MCU; wherein, the download flag is an execution logic judgment in the bootloaer program; preferably, the next week flag is 0xAA55AA55.

[0062] Step 22: If the download flag is present, the bootloader is stopped to perform the firmware download or update process; if the download flag is not present, jump to step 23.

[0063] Step 23, using the bootloader program to determine whether there is a firmware file written in the code execution partition of the flash memory in the IO card; if so, verify the firmware file written in the code execution partition of the flash memory of the IO card; if not, continue to stay in the bootloader program; wherein, the process of verifying the firmware file written in the code execution partition of the flash memory of the IO card is specifically as follows: performing code segment check value calculation on the firmware file written in the code execution partition of the flash memory of the IO card to obtain a CRC check value calculation value.

[0064] Step 24: Compare the calculated CRC checksum value with the calculated checksum value in step 15.

[0065] Step 25. If the calculated CRC check value is compared with the checksum calculated value in step 15 and the result is consistent, jump the program execution start address to the formal program segment; if the calculated CRC check value is compared with the checksum calculated value in step 15 and the result is inconsistent, continue to run the bootloader program.

[0066] Step 3: periodically read the firmware files stored in the code execution partition and the backup code area of ​​the flash memory in the IO card, and perform check value calculations respectively to obtain check value calculation results; compare the check value calculation results with the pre-stored check values ​​to ensure that the MCU firmware data is not damaged by electromagnetic and environmental factors; if they are consistent, the firmware files stored in the code execution partition of the flash memory in the IO card are normally operated.

[0067] By periodically reading the firmware files stored in the code execution partition and backup code area of ​​the flash memory in the IO card and performing verification monitoring, it is ensured that the MCU firmware data is not damaged by electromagnetic and environmental factors. Figure 5 As shown, the specific steps include:

[0068] Step 31: periodically read the firmware files stored in the code execution partition and the backup code area of ​​the flash memory in the IO card, and perform CRC check value calculations respectively to obtain check value calculation results.

[0069] Step 32: Compare the checksum calculation result with the checksum calculation value in step 15.

[0070] Step 33, if they are consistent, the firmware file stored in the code execution partition of the flash memory in the IO card is run normally; if they are inconsistent, the card-level abnormal status is reported to the controller, and the execution action of the card is terminated to avoid causing equipment failure; it should be noted that when the data in the code execution partition and the backup code area of ​​the flash memory in the IO card are normal, the execution partition check value, the backup partition check value and the check value recorded in 0x08100000 should all be consistent.

[0071] The firmware processing method of the trusted DCS system IO card described in the first embodiment, during the firmware download process, the firmware file is verified, parsed and transmitted to ensure the integrity and accuracy of the firmware data; during the firmware startup process, a dual-area storage mechanism is adopted, and CRC check and firmware information verification are used to ensure the safe and reliable startup of the firmware program; specifically, the flash area data designated to store the formal program is read, the CRC check value of the firmware code data is calculated and compared with the check value generated during the download process, and the firmware name and version information are checked. After the verification is passed, the card MCU jumps from the bootloader to the formal program to complete the startup process of the firmware program; during the firmware operation process, the firmware files stored in the code execution partition and the backup code area of ​​the flash memory in the IO card are periodically read, and the check value calculation result is compared with the pre-stored check value, so as to realize real-time monitoring of the firmware code in the operation process, so as to avoid damage to the data in the MCU memory due to electromagnetic interference and other unstable factors in the electrical environment, and to terminate the card operation in time when the firmware code data is wrong, so as to avoid damage to other components of the system and field equipment, and further ensure the reliability of the card operation.

[0072] Example 2

[0073] As attached Figure 6As shown, this embodiment 2 provides a firmware processing system for an IO card of a trusted DCS system, including: a download module, a startup module and a monitoring module; the download module is used to receive a download request message and perform download information verification on the download request message; wherein the download request message includes download information and a firmware file; if the download information verification passes, the firmware file in the download request message is burned to the IO card; the firmware file burned in the IO card is read, and the accompanying information in the read firmware file is verified, if the verification passes, the firmware file is downloaded successfully; the startup module is used to use the bootloader program to read the content of the firmware download flag area of ​​the flash in the MCU of the IO card; if the download flag bit exists, the bootloader is stopped. tloader, to perform firmware download or update process; if no download flag exists, determine whether there is a firmware file written in the code execution partition of the flash memory in the IO card; if so, verify the firmware file written in the code execution partition of the flash memory; run the module, which is used to periodically read the firmware files stored in the code execution partition and the backup code area of ​​the flash memory in the IO card, and calculate the check value respectively to obtain the check value calculation result; compare the check value calculation result with the pre-stored check value to ensure that the MCU firmware data is not damaged by electromagnetic and environmental factors; if they are consistent, run the firmware file stored in the code execution partition of the flash memory in the IO card normally.

[0074] Example 3

[0075] As attached Figure 7 As shown, this embodiment 3 provides a firmware processing device for a trusted DCS system IO card, including: a processor, a memory, and a computer program stored in the memory and executable on the processor, such as a firmware processing method program for a trusted DCS system IO card; wherein the attached Figure 7 The communication interface in is used to access external devices to obtain data.

[0076] When the processor executes the computer program, the steps of implementing the firmware processing method of the above-mentioned trusted DCS system IO card are, for example:

[0077] Receive a download request message and perform download information verification on the download request message; wherein the download request message includes download information and firmware files; if the download information verification passes, burn the firmware file in the download request message to the IO card; read the firmware file burned in the IO card, and verify the accompanying information in the read firmware file, if the verification passes, the firmware file is downloaded successfully; use the bootloader program to read the contents of the firmware download flag area of ​​the flash in the IO card MCU; if a download flag bit exists, stop the bootloader and perform the firmware download or update process; if no download flag bit exists , it is determined whether there is a firmware file written in the code execution partition of the flash memory in the IO card; if so, the firmware file written in the code execution partition of the flash memory is verified; the firmware files stored in the code execution partition and the backup code area of ​​the flash memory in the IO card are periodically read, and verification value calculations are performed respectively to obtain verification value calculation results; the verification value calculation results are compared with the pre-stored verification values ​​to ensure that the MCU firmware data is not damaged by electromagnetic and environmental factors; if they are consistent, the firmware file stored in the code execution partition of the flash memory in the IO card is normally operated.

[0078] Alternatively, when the processor executes the computer program, the functions of each module in the above system are realized, for example:

[0079] The download module is used to receive a download request message and perform download information verification on the download request message; wherein the download request message includes download information and a firmware file; if the download information verification passes, the firmware file in the download request message is burned to the IO card; the firmware file burned in the IO card is read, and the accompanying information in the read firmware file is verified. If the verification passes, the firmware file is downloaded successfully; the startup module is used to use the bootloader program to read the contents of the firmware download flag area of ​​the flash in the IO card MCU; if the download flag bit exists, the bootloader is stopped to perform the firmware download or update process; if the download flag bit does not exist .... If the flag bit exists, it is determined whether there is a firmware file written in the code execution partition of the flash memory in the IO card; if so, the firmware file written in the code execution partition of the flash memory is verified; an operation module is used to periodically read the firmware files stored in the code execution partition and the backup code area of ​​the flash memory in the IO card, and respectively calculate the verification value to obtain the verification value calculation result; the verification value calculation result is compared with the pre-stored verification value to ensure that the MCU firmware data is not damaged by electromagnetic and environmental factors; if they are consistent, the firmware file stored in the code execution partition of the flash memory in the IO card is normally operated.

[0080] Exemplarily, the computer program may be divided into one or more modules / units, which are stored in the memory and executed by the processor to implement the present invention. The one or more modules / units may be a series of computer program instruction segments capable of implementing specific functions, which are used to describe the execution process of the computer program in the firmware processing device of the trusted DCS system IO card.

[0081] For example, the computer program may be divided into a download module, a startup module and a monitoring module, and the specific functions of each module are as follows:

[0082] The download module is used to receive a download request message and perform download information verification on the download request message; wherein the download request message includes download information and a firmware file; if the download information verification passes, the firmware file in the download request message is burned to the IO card; the firmware file burned in the IO card is read, and the accompanying information in the read firmware file is verified. If the verification passes, the firmware file is downloaded successfully; the startup module is used to use the bootloader program to read the contents of the firmware download flag area of ​​the flash in the IO card MCU; if the download flag bit exists, the bootloader is stopped to perform the firmware download or update process; if the download flag bit does not exist .... If the flag bit exists, it is determined whether there is a firmware file written in the code execution partition of the flash memory in the IO card; if so, the firmware file written in the code execution partition of the flash memory is verified; an operation module is used to periodically read the firmware files stored in the code execution partition and the backup code area of ​​the flash memory in the IO card, and respectively calculate the verification value to obtain the verification value calculation result; the verification value calculation result is compared with the pre-stored verification value to ensure that the MCU firmware data is not damaged by electromagnetic and environmental factors; if they are consistent, the firmware file stored in the code execution partition of the flash memory in the IO card is normally operated.

[0083] The firmware processing device of the trusted DCS system IO card can be a computing device such as a desktop computer, a notebook, a PDA, and a cloud server. The firmware processing device of the trusted DCS system IO card can include, but is not limited to, a processor and a memory. Those skilled in the art will understand that the attached Figure 7 The schematic diagram is only an example of the firmware processing device of the trusted DCS system IO card component, and does not constitute a limitation on the firmware processing device of the trusted DCS system IO card component. It may include more or fewer components than shown in the figure, or combine certain components, or different components. For example, the firmware processing device of the trusted DCS system IO card component may also include input and output devices, network access devices, buses, etc.

[0084] The processor may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor may be a microprocessor or any conventional processor, etc. The processor is the control center of the firmware processing device of the trusted DCS system IO card, and uses various interfaces and lines to connect various parts of the firmware processing device of the entire trusted DCS system IO card.

[0085] The memory may be used to store the computer program and / or module, and the processor implements various functions of the firmware processing device of the trusted DCS system IO card by running or executing the computer program and / or module stored in the memory and calling the data stored in the memory.

[0086] The memory may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area may store data created according to the use of the mobile phone (such as audio data, a phone book, etc.), etc. In addition, the memory may include a high-speed random access memory, and may also include a non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a smart memory card (SmartMediaCard, SMC), a secure digital (SecureDigital, SD) card, a flash card (FlashCard), at least one disk storage device, a flash memory device, or other volatile solid-state storage devices.

[0087] Example 4

[0088] This embodiment 4 also provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the steps of the firmware processing method of the trusted DCS system IO card are implemented.

[0089] The module / unit integrated by the firmware processing device of the trusted DCS system IO card may be stored in a computer-readable storage medium if it is implemented in the form of a software functional unit and sold or used as an independent product.

[0090] Based on such understanding, the present embodiment 4 implements all or part of the processes in the firmware processing method of the above-mentioned trusted DCS system IO card component, and can also be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium, and when the computer program is executed by the processor, the steps of the firmware processing method of the above-mentioned trusted DCS system IO card component can be implemented. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form, etc.

[0091] The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, USB flash drive, mobile hard disk, magnetic disk, optical disk, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal and software distribution medium, etc.

[0092] It should be noted that the content contained in the computer-readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, computer-readable media does not include electrical carrier signals and telecommunication signals.

[0093] The above embodiment is only one of the implementation methods that can realize the technical solution of the present invention. The scope of protection claimed by the present invention is not limited only to this embodiment, but also includes changes, replacements and other implementation methods that can be easily thought of by any technician familiar with the technical field within the technical scope disclosed by the present invention.

Claims

1. A firmware processing method for a trusted DCS system IO card, characterized in that: include: Receive a download request message, and perform download information verification on the download request message; wherein the download request message includes download information and a firmware file; if the download information verification passes, burn the firmware file in the download request message to the IO card; read the firmware file burned in the IO card, and verify the accompanying information in the read firmware file; if the verification passes, the firmware file is downloaded successfully; Determine whether there is a firmware file written in the code execution partition of the flash memory in the IO card; if so, verify the firmware file written in the code execution partition of the flash memory in the IO card; The firmware files stored in the code execution partition and the backup code area of ​​the flash memory in the IO card are periodically read, and the check value calculation is performed respectively to obtain the check value calculation result; the check value calculation result is compared with the pre-stored check value; if they are consistent, the firmware files stored in the code execution partition of the flash memory in the IO card are normally operated.

2. The firmware processing method of a trusted DCS system IO card according to claim 1, characterized in that: The generation process of the download request message is as follows: Obtain a firmware file by compiling the code; wherein the end of the firmware file carries generation compile time version information and a checksum CRC value; The download request message is parsed and generated according to the firmware file and in combination with the firmware download request initiated in advance.

3. The firmware processing method of a trusted DCS system IO card according to claim 1, characterized in that: The process of verifying the download information of the download request message is specifically as follows: respectively determining the consistency of the firmware file name, file type and file content.

4. The firmware processing method of a trusted DCS system IO card according to claim 1, characterized in that: The process of burning the firmware file into the IO card is specifically as follows: burning the firmware file into the flash memory in the IO card in binary form.

5. The firmware processing method of a trusted DCS system IO card according to claim 1, characterized in that: The process of reading the firmware file burned in the IO card and verifying the accompanying information in the read firmware file is as follows: Read the burned firmware file from the flash memory in the IO card, and calculate the checksum of the read firmware file to obtain the checksum calculation value; The calculated checksum value is compared with the checksum CRC value in the accompanying information of the firmware file.

6. The firmware processing method of a trusted DCS system IO card according to claim 1, characterized in that: Before determining whether there is a written firmware file in the code execution partition of the flash memory in the IO card, it also includes a firmware download mark area determination step; The firmware download mark area determination step is as follows: The bootloader program is used to read the contents of the firmware download flag area of ​​the flash in the IO card MCU; if a download flag exists, the bootloader is stopped to perform the firmware download or update process; if no download flag exists, it is determined whether there is a written firmware file in the code execution partition of the flash memory in the IO card.

7. The firmware processing method of a trusted DCS system IO card according to claim 1, characterized in that: The process of verifying the firmware file written in the code execution partition of the flash memory in the IO card is specifically: calculating the verification value of the firmware file written in the code execution partition of the flash memory in the IO card, and comparing it with the verification value pre-written in the flash memory in the IO card.

8. A firmware processing system for a trusted DCS system IO card, characterized in that: include: The download module is used to receive a download request message and perform download information verification on the download request message; wherein the download request message includes download information and a firmware file; if the download information verification passes, the firmware file in the download request message is burned into the IO card; the firmware file burned in the IO card is read, and the accompanying information in the read firmware file is verified; if the verification passes, the firmware file is downloaded successfully; A startup module is used to determine whether there is a firmware file written in the code execution partition of the flash memory in the IO card; if so, verify the firmware file written in the code execution partition of the flash memory in the IO card; The monitoring module is used to periodically read the firmware files stored in the code execution partition and the backup code area of ​​the flash memory in the IO card component, and respectively perform check value calculations to obtain check value calculation results; compare the check value calculation results with the pre-stored check values; if they are consistent, the firmware files stored in the code execution partition of the flash memory in the IO card component are normally operated.

9. A firmware processing device for a trusted DCS system IO card, characterized in that: include: Memory for storing computer programs; A processor, configured to implement the steps of the firmware processing method for the trusted DCS system IO card as described in any one of claims 1 to 7 when executing the computer program.

10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the firmware processing method of the trusted DCS system IO card component as claimed in any one of claims 1 to 7 are implemented.

Citation Information

Cited By

  • Router firmware updating method and system based on communication protocol

    CN121239618A

  • A router firmware update method and system based on a communication protocol

    CN121239618B