Qt framework-based upper computer client software self-updating management method and equipment

Through the self-update management method based on the Qt framework, the automatic detection, download, installation and restart of the upper-level client software is realized, solving the problems of low efficiency and security risks of traditional update methods, and improving the efficiency and user experience of software maintenance.

CN119938104APending Publication Date: 2025-05-06XIAN THERMAL POWER RES INST CO LTD +2
View PDF 0 Cites 2 Cited by

Patent Information

Application Number
CN202510077555.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-01-17
Publication Date
2025-05-06

AI Technical Summary

Technical Problem

The traditional software update method of computer client requires users to manually download and install, which is inefficient and has security risks. Especially under Linux systems, it is difficult for the existing technology to achieve efficient and secure automatic updates.

Method used

The self-update management method based on the Qt framework is adopted, and the software version is automatically detected through the self-update detection thread, authenticate and authorize, download and verify the integrity and compatibility of the software update package, and automatically install and restart to achieve zero-contact update.

Benefits of technology

It improves the efficiency and convenience of software maintenance, ensures the security and compatibility of the software, reduces the steps for user participation, reduces the error rate during the update process, and improves the user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119938104A_ABST
    Figure CN119938104A_ABST
Patent Text Reader

Abstract

The invention provides an upper computer client software self-updating management method and device based on Qt framework development, and the method comprises the steps: obtaining a latest version information file of software through a self-updating detection thread when the software of an upper computer client needs to be updated; the upper computer client performs identity verification, update authorization source verification, integrity verification and version compatibility verification on the software update package, automatically executes an installation script after the verification is passed, and decompresses and installs the software update package; software updating process management is set, and an updating mechanism and a rollback mechanism are checked regularly; the system starts to load a credible operating system and an updating program from the starting stage, and after the software updating package is installed, the client side of the upper computer automatically restarts and loads the new version software, and the self-updating process is completed. According to the invention, the efficiency and convenience of software maintenance can be improved, and the security of security software can be ensured.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the field of software updating, and in particular relates to a method and device for self-updating management of upper computer client software based on a Qt framework. Background Art

[0002] With the rapid development of the industrial field, the stability and functional integrity of the host client as a bridge connecting users and industrial equipment are crucial, and the application of host client software in industrial control systems is becoming more and more extensive. With the continuous development of computer technology, software updates have become an important means to maintain software functionality and system security. Especially in the Linux system, the update management of the host client software developed based on the Qt framework is crucial to ensure software performance and user experience.

[0003] However, the traditional method of updating the client software of the host computer usually requires users to manually download the software update package and install it. This method is not only inefficient, but also prone to software damage or system crashes due to improper operation, and has problems such as low update efficiency and poor security. Therefore, how to achieve efficient and secure automatic update of the client software of the host computer has become an urgent problem to be solved.

[0004] In the existing technology, although there are some solutions for automatic software updates, most of these solutions are for applications under Windows systems, and are not applicable to the host client software developed based on the Qt framework in the industrial field of Linux systems. The industrial field has higher requirements for the environment, including software version compatibility, hardware and driver and maintenance cycle costs, higher security requirements, and many scenarios require zero crashes. Therefore, it is of great practical significance to develop a self-update management method for host client software developed based on the Qt framework in the industrial field of Linux systems. Summary of the invention

[0005] In order to solve the problems of the above-mentioned prior art, the present invention provides a host computer client software self-update management method and device developed based on the Qt framework, which can automatically detect, download and install the latest version of the software, thereby improving the efficiency and convenience of software maintenance and ensuring the security of security software.

[0006] The present invention is achieved through the following technical solutions: In a first aspect, the present invention provides a method for self-updating and managing client software of a host computer based on a Qt framework, comprising: S1, when the software of the upper computer client needs to be updated, the latest version information file of the software is obtained through the self-update detection thread, and the version information in the version information file is compared with the version information of the local old version software to determine whether the software needs to be updated; if the judgment result is that the software needs to be updated, S2 is executed, and after confirming that the operator's identity is safe, S3 is executed to update the new version, otherwise, the next update detection is waited according to the set update detection time; the version information file contains the version information of the new version of the software; S2, before executing the software update, ensure the operator's identity security and operation security through identity authentication and update authorization authentication; S3, the host computer client downloads the software update package and performs identity authentication, update authorization source verification, integrity verification and version compatibility verification on the software update package, and automatically executes the installation script after the verification passes, decompresses and installs the software update package; S4, set up software update process management, regular check update mechanism and rollback mechanism; S5, after the software update package is installed, the host computer client automatically restarts and loads the new version of the software to complete the self-update process; S6, set up breakpoint resume, grayscale release, and A / B testing.

[0007] Furthermore, when the software of the host computer client needs to be updated, the latest version information file of the software is obtained through the self-update detection thread, including: The software of the host computer client sends an update request to the server when it is started or periodically, and receives the latest version information file of the software sent by the server based on the update request. The update request is used to trigger the server to send the latest version information file of the software to the host computer client.

[0008] Furthermore, the host computer client downloads the software update package of the new version software through the HTTPS protocol.

[0009] Furthermore, in S2, the operator needs to be authenticated and authorized. The authentication is done by digitally signing the software update package, which is digitally signed by a trusted developer or software provider. When executing the update, the host client verifies the digital signature of the software update package to ensure that the software update package has not been tampered with. The public key infrastructure system is used to manage the signing key to ensure that only the service provider with a valid private key signs the software update package, and requires users to perform multi-factor authentication when performing software updates; In S3, the update authorization source verification is specifically as follows: verifying the digital signature of the software update package; the integrity verification is specifically as follows: after the operator's identity is confirmed and authorized, the software update package is transmitted using an encryption protocol, and HPKP technology is used to prevent man-in-the-middle attacks. The software update package uses hash verification to verify the integrity of the downloaded software update package. After downloading the software update package, the client compares the hash value of the software update package with the hash value provided by the server to ensure that the software update package has not been tampered with, and stores the hash value of the software update package on a trusted server and compares it during update. At the same time, the software update package is digitally signed. After receiving the software update package, the upper computer client first verifies the legitimacy of the signature.

[0010] Furthermore, S4 specifically: supports checking for updates. The host client periodically queries the server for new updated versions. It adopts version control and incremental updates, sets a regular update check mechanism, and supports manually triggered update checks. It provides an automatic update option. Users choose to let the host client automatically download and install updates to ensure that the user system always uses the latest version; provides a manual update option to allow users to update as needed. In sensitive production environments, administrators control the update time; update notification and rollback mechanism. Before updating, the host client notifies the user of the update content and update size; the user chooses whether to install the update immediately or delay the update; provides a rollback mechanism. If the new version has problems or is unstable, the host client automatically or manually rolls back to the previous stable version.

[0011] Furthermore, in S5, trusted boot in trusted hardware ensures that the system loads trusted operating systems and update programs from the start-up phase to prevent malware from loading and tampering with update files before the update, and ensures that the signatures of the operating system and update programs are verified and can only be loaded with trusted certificates. Provide code integrity protection; place the update process in a controlled sandbox environment to limit the impact of the update process on other parts of the system; provide code signing to ensure that all client codes, including the updater itself, are signed, and unauthorized code cannot run during the update process.

[0012] Furthermore, during the execution of S1, S2 and S3, trusted verification of the installation environment and trusted installation isolation are performed, and trusted audit logs and real-time alarms are generated.

[0013] In a second aspect, the present invention provides a host computer client software self-update management system based on the Qt framework, comprising: The update detection module is used to obtain the latest version information file of the software through the self-update detection thread when the software of the upper computer client needs to be updated, compare the version information in the version information file with the version information of the local old version software, and determine whether the software needs to be updated; if the judgment result is that the software needs to be updated, after confirming the operator's identity security, the new version is updated, otherwise, the next update detection is waited according to the set update detection time; the version information file contains the version information of the new version software; The authentication and authorization module is used to ensure the operator's identity security and operation security through identity authentication and update authorization authentication before executing the software update; The trusted installation module is used to download the software update package and perform identity authentication, update authorization source verification, integrity verification and version compatibility verification on the software update package, and automatically execute the installation script after the verification is passed to decompress and install the software update package; after the software update package is installed, the host computer client automatically restarts and loads the new version of the software to complete the self-update process.

[0014] In a third aspect, the present invention provides a computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the steps of the upper computer client software self-update management method based on the Qt framework as described above are implemented.

[0015] In a fourth aspect, the present invention 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 host computer client software self-update management method based on the Qt framework as described above are implemented.

[0016] Compared with the prior art, the present invention has the following beneficial effects: Through the method of the present invention, the host computer client can automatically detect, download and install the latest version of the software, thereby improving the efficiency and convenience of software maintenance. Specific advantages include: high degree of automation: automatic detection, downloading, installation and restart of the host computer client software are realized without manual operation by the user, which greatly improves the efficiency of software updates. Accurate and reliable updates: by publishing the software update package through the server, the source of the software update package is ensured to be reliable, and security issues caused by unknown download sources are avoided. Integrity is guaranteed: before decompressing and installing the software update package, the system can use a digital signature or hash algorithm to verify the integrity of the software update package to ensure that it has not been tampered with. Good compatibility: the present invention is developed based on the Qt framework, suitable for host computer client software in the industrial field of Linux system, and has good compatibility and extensibility. Improve user experience: automatic update reduces the steps for users to participate in the update, reduces the error rate during the update process, and improves user experience. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0018] Figure 1 One of the flow charts of the Qt framework-based host computer client software trusted self-update management method provided by the present invention; Figure 2 The second flowchart of the Qt framework-based host computer client software trusted self-update management method provided by the present invention; Figure 3 A structural diagram of the host computer client software self-update management system based on the Qt framework provided by the present invention; Figure 4 A schematic diagram of an electronic device provided by the present invention. DETAILED DESCRIPTION

[0019] The following describes the embodiments of the present invention through specific examples, and those skilled in the art can easily understand other advantages and effects of the present invention from the contents disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present invention.

[0020] It should be noted that the process equipment or devices not specifically specified in the following embodiments are all conventional equipment or devices in the art.

[0021] It should be noted that the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusions. For example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices. Moreover, unless otherwise specified, the numbering of each method step is only a convenient tool for identifying each method step, and is not intended to limit the order of arrangement of each method step or to define the scope of the present invention. Changes or adjustments in their relative relationships should also be regarded as the scope of the present invention without substantially changing the technical content.

[0022] See also Figure 1 The present invention provides a method for self-updating the client software of a host computer based on the Qt framework, comprising: S1, when the software of the upper computer client needs to be updated, the latest version information file of the software is obtained through the self-update detection thread, and the version information in the version information file is compared with the version information of the local old version software to determine whether the software needs to be updated; if the judgment result is that the software needs to be updated, S2 is executed, and after confirming that the operator's identity is safe, S3 is executed to update the new version, otherwise, the next update detection is waited according to the set update detection time; the version information file contains the version information of the new version of the software; S2, before executing the software update, ensure the operator's identity security and operation security through identity authentication and update authorization authentication; S3, the host computer client downloads the software update package and performs identity authentication, update authorization source verification, integrity verification and version compatibility verification on the software update package, and automatically executes the installation script after the verification passes, decompresses and installs the software update package; S4, set up software update process management, regular check update mechanism and rollback mechanism; S5, after the software update package is installed, the host computer client automatically restarts and loads the new version of the software to complete the self-update process; S6, set up breakpoint resume, grayscale release, and A / B testing.

[0023] In this implementation, after the host computer client is turned on, it obtains the latest version information file through the self-update detection thread, compares the version information in the version information file with the version information of the local old version of the software, and determines whether the software needs to be updated; if the judgment result is that the software needs to be updated, S2 is executed to authenticate the identity and authorize the updater, and after authorization, S3 is performed to perform security detection on the software update package, otherwise, the next update detection is waited according to the set update detection time; the version information file contains the version information of the new version of the software; Authentication ensures that only legitimate users or services can perform software update operations, preventing unauthorized users from tampering with the system or installing malware. The update user provides credentials, such as username and password, hardware key, dynamic verification code, etc. Multi-factor authentication can also be used to increase the verification level to ensure the authenticity of the identity. For example, in addition to the password, a dynamic verification code or biometric authentication fingerprint, facial recognition, etc. is required. This multi-level verification method can effectively improve the security of authentication and prevent a single verification method from being attacked. Use Transport Layer Security (TLS) / Secure Sockets Layer (SSL) certificates through device / service authentication: Through the SSL / TLS handshake of the communicating parties (client and update server), the identities of each other are verified and data transmission is encrypted. Certificate verification: The client and server use X.509 certificates for authentication to ensure that both parties are trustworthy. Signed through public key infrastructure, the client verifies the signature of the software update package when downloading the update to ensure that the package comes from a trusted developer. Trusted Hardware Security Module Verification Use hardware security modules in sensitive operations (such as certificate generation, private key storage, etc.) to strengthen key management and verification to prevent private key leakage. Through role and permission management, different update permissions can be defined and customized according to different user roles such as administrators, ordinary users, and external suppliers.

[0024] In order to ensure that the software update package has not been tampered with or damaged during the download, storage or transmission process, the upper computer client must verify the integrity of the software update package and generate a hash value through hash value verification. When releasing the software update package, calculate the hash value of the software update package (such as using the Secure Hash Algorithm (SHA)-256 or SHA-512), publish the calculated hash value together with the software update package, and put it in a safe location. Download the hash value verification through the trusted management platform: When downloading the software update package, the client calculates the hash value of the software update package, and compares the hash value provided by the client and the server. If the two are consistent, it means that the package has not been tampered with. If the hash values ​​do not match, the client stops updating and generates an alarm to generate a trusted audit log.

[0025] After the software update package is installed, the host client automatically restarts and loads the new version of the software to complete the self-update process. After verification, the transmission of the software update package will be encrypted. The transmission of the software update package must be protected by the encryption protocol HyperText Transfer Protocol Secure (HTTPS) (TLS / SSL) to prevent data from being tampered with or stolen during transmission. The encrypted connection between the client and the server should use a strong encryption algorithm and certificate to ensure communication security.

[0026] Furthermore, when the software of the host computer client needs to be updated, the latest version information file of the software is obtained through the self-update detection thread, including: The software of the host computer client sends an update request to the server when it is started or periodically, and receives the latest version information file of the software sent by the server based on the update request. The update request is used to trigger the server to send the latest version information file of the software to the host computer client.

[0027] Furthermore, the host computer client downloads the software update package of the new version software through the HTTPS protocol.

[0028] Furthermore, in S2, the operator needs to be authenticated and authorized. The authentication is done by digitally signing the software update package by a trusted developer or software provider. When the client executes the update, it verifies the digital signature of the software update package to ensure that the software update package has not been tampered with. The public key infrastructure system is used to manage the signing key to ensure that only the service provider with a valid private key signs the software update package, and requires the user to perform multi-factor authentication when performing software updates; In S3, the update authorization source verification is specifically as follows: verifying the digital signature of the software update package; the integrity verification is specifically as follows: after the operator's identity is confirmed and authorized, the software update package is transmitted using an encryption protocol, and HPKP technology is used to prevent man-in-the-middle attacks. The software update package uses hash verification to verify the integrity of the downloaded software update package. After downloading the software update package, the client compares the hash value of the software update package with the hash value provided by the server to ensure that the software update package has not been tampered with, and stores the hash value of the software update package on a trusted server and compares it during update. At the same time, the software update package is digitally signed. After receiving the software update package, the upper computer client first verifies the legitimacy of the signature.

[0029] Furthermore, S4 specifically: supports checking for updates, the client periodically queries the server for new updated versions, adopts version control and incremental updates, sets a regular checking mechanism, and supports manually triggered update checks, provides an automatic update option, and users choose to let the client automatically download and install updates to ensure that the user's system always uses the latest version; provides a manual update option to allow users to update as needed, and in sensitive production environments, administrators control the update time; update notification and rollback mechanism, before updating, the client notifies the user of the update content and update size; the user chooses whether to install the update immediately or delay the update; provides a rollback mechanism, if the new version has problems or is unstable, the client automatically or manually rolls back to the previous stable version.

[0030] Furthermore, in S5, trusted boot in trusted hardware ensures that the system loads trusted operating systems and update programs from the start-up phase to prevent malware from loading and tampering with update files before the update, and ensures that the signatures of the operating system and update programs are verified and can only be loaded with trusted certificates. Provide code integrity protection; place the update process in a controlled sandbox environment to limit the impact of the update process on other parts of the system; provide code signing to ensure that all client codes, including the updater itself, are signed, and unauthorized code cannot run during the update process.

[0031] Furthermore, during the execution of S1, S2 and S3, trusted verification of the installation environment and trusted installation isolation are performed, and trusted audit logs and real-time alarms are generated.

[0032] After the host computer client of the present invention is turned on, it obtains the latest version information file through the self-update detection thread, specifically: The host computer client software sends an update request to the server when it is started or regularly. The update request triggers the server to send the latest version information file to the host computer client, and the host computer client software receives the latest version information file sent by the server.

[0033] In some specific implementations, the version information of the present invention includes version number, release time and update content.

[0034] In some specific implementations, the identity authentication and source authentication of the present invention verifies the legitimacy of the software update package through digital signature and Public Key Infrastructure (PKI).

[0035] In some specific implementations, the present invention downloads the software update package of the new version of the software through the HTTPS protocol to ensure the security of data transmission.

[0036] The integrity verification described in the present invention specifically includes: performing digital signature verification and hash value verification.

[0037] After the software update package is downloaded, the present invention verifies the digital signature of the software update package, and the installation operation can be performed only after the verification is successful. The digital signature is generated by the server and added to the software update package. The digital signature of the software update package is an important means to ensure that the software update package maintains integrity and authenticity during transmission and installation. The digital signature can verify the source of the software update package and ensure that it is released by a trusted developer or organization; through the digital signature, it can be ensured that the software update package has not been tampered with or damaged during transmission.

[0038] In some specific implementations, after the software update package is downloaded, a hash value of the software update package is obtained, and the hash value is compared with a checksum value of the software update package to determine the integrity of the software update package. If the software update package is complete, it is installed, otherwise it is not installed.

[0039] Before releasing the software update package, the server will use a specific hash algorithm (such as Message-Digest Algorithm 5 (MD5), SHA-1, SHA-256, etc.) to perform hash calculation on the content of the software update package to generate a checksum of fixed length. This checksum will be recorded in the release information for users to verify when downloading.

[0040] After the user downloads the software update package, the same hash algorithm is used to perform hash calculation on the downloaded software update package to obtain a new checksum. This newly generated checksum is compared with the checksum provided by the server. If the two are consistent, it means that the software update package is complete and has not been tampered with; if they are inconsistent, it means that there may be a problem and it is necessary to re-download or contact the server for confirmation.

[0041] Example 1 like Figure 2 As shown, the present invention is based on the Qt framework of the host computer client software self-update management method, the method comprises the following steps: (1) The server releases the software update package The server administrator packages the compiled new version of the software into a software update package and uploads it to the designated directory of the server; the server generates a version information file of the new version of the software, including the version number, release time, update content, and provides a download link.

[0042] (2) PC client software detection and update The upper computer client software sends an update request to the server when it is started or regularly. The update request triggers the server to send the latest version information file to the upper computer client, and the upper computer client software receives the latest version information file sent by the server.

[0043] The upper computer client compares the version number in the received version information file with the version number of the local old version software to determine whether an update is needed; if the two version numbers are the same, no update is required; if the two version numbers are different, an update is required.

[0044] (3) The host client downloads the software update package If the judgment result is that an update is required, the host client automatically downloads the software update package from the server to the local temporary directory according to the download link provided by the server. To ensure that the software update package is not tampered with during transmission, the software update package is downloaded through the HTTPS protocol to ensure the security of data transmission.

[0045] During the download process, the host client will display the download progress and status so that users can understand the download progress.

[0046] (4) Install the software update package on the host client It should be noted that the downloaded software update package needs to be verified for source, integrity, and version compatibility.

[0047] The specific process is: 1) Source verification: Verify the digital signature of the software update package. Subsequent operations can only be performed after successful verification to ensure that the software update package comes from a trusted source.

[0048] 2) Integrity verification of software update packages: Use hash functions to verify software update packages to ensure that the downloaded software update packages have not been tampered with. Trusted computing platforms (such as TPMs) can store public keys to verify the integrity of software update packages before installing them.

[0049] During the specific operation, a hash algorithm (such as md5 or sha256) is used to calculate the hash value, and the calculated hash value is compared with the check value provided by the server. If the two are consistent, the software update package is complete and the next step is performed; otherwise, the software update package is incomplete and the next step is not performed. The integrity of the software update package is ensured by verifying the check value.

[0050] 3) Version control and verification: Before installing a software update package, the system can check the compatibility between the local old version of the software and the new version of the software to be installed through a trusted computing mechanism. This can prevent incompatible or potentially harmful updates from being applied.

[0051] After the software update package is verified, the host computer client automatically executes the installation script to decompress and install the software update package (decompress the software update package to obtain the files of the new version of the software and replace the original files of the old version of the software).

[0052] The atomicity of the software update package installation process must be guaranteed, either all of it is executed or not at all, with no intermediate state. A separate script or tool is used to ensure atomicity, and a detailed design of multi-layer protection is carried out.

[0053] During the installation of the software update package, the host computer client will back up the files of the old version of the software so that a rollback operation can be performed when the software update package fails to be installed, that is, it can be restored by restoring the backup. The present invention designs an effective rollback mechanism to deal with update failures or incompatibility. Trusted computing can ensure data integrity and system stability during the rollback process.

[0054] After the software update package is installed, the upper computer client software sends an update request again and receives the latest version information file sent by the server; the version number in the received version information file is compared with the version number of the local old version software. If the two version numbers are the same, the update is successful. If the two version numbers are different, the update is unsuccessful and needs to be updated again.

[0055] After the software update package is installed, if the new version of the software requires migrating user data, the installer will prompt the user to migrate the data.

[0056] (5) The host computer client is updated After the software update package is installed, the host client automatically restarts and loads the new version of the software to complete the self-update process.

[0057] After the host computer client is restarted, it will perform simple initialization operations to ensure that the new version of the software can run normally.

[0058] At each stage of the above-mentioned update process of the present invention, trusted verification of the installation environment and trusted installation isolation are performed, and a trusted audit log is generated. The specific operations include: 1) Secure Boot and Chain of Trust: At each stage of the update process, Secure Boot and Chain of Trust mechanisms are used to ensure that each step is performed in a trusted environment. This means that the decompression and installation of the software update package must be completed in a verified and trusted environment.

[0059] 2) Dynamic trust evaluation: During the update process, the trust status of the current operating environment can be dynamically evaluated to ensure that no update operations are performed in an unsafe environment; file trust static evaluation, the evaluation data source is reliable, which can be achieved by real-time monitoring of the system status and configuration.

[0060] 3) Audit and recording mechanism: Record and audit all operations during the update process to ensure that the source, version, and execution status of each update can be traced. This is very important for subsequent security analysis and troubleshooting.

[0061] Example 2 When performing software updates in a production environment, the specific process is as follows: (1) Backup Before updating, use a script or tool to back up the files of the old version of the software so that you can restore the original functionality of the program in case the update fails.

[0062] (2) Preparation Before updating, ensure the correctness of the environment, such as checking the system version, disk space, etc.

[0063] (3) Download the software update package The upper computer client software periodically sends an update request to the server, and the update request triggers the server to send the latest version information file to the upper computer client, and the upper computer client software receives the latest version information file sent by the server.

[0064] The upper computer client compares the version number in the received version information file with the version number of the local old version software to determine whether an update is needed; if the two version numbers are the same, no update is required; if the two version numbers are different, an update is required.

[0065] If the result of the judgment is that an update is required, the host computer client automatically downloads the software update package from the server to the local temporary directory according to the download link provided by the server.

[0066] (4) Check for software update packages The digital signature of the software update package is verified. The installation operation can be performed only after successful verification to ensure that the software update package comes from a trusted source. The downloaded software update package uses a hash algorithm (such as md5 or sha256) to calculate the hash value, and the calculated hash value is compared with the checksum provided by the server. If the two are consistent, the software update package is complete and the next step of installation is performed; otherwise, the software update package is incomplete and the next step of installation is not performed.

[0067] At the same time, version compatibility verification is also performed to check the compatibility between the local old version software and the new version software to be installed.

[0068] (5) Stop the program Stop the program that is running the old version of the software to prepare for the update. That is, before updating the program, stop the program first to ensure that the update process will not be interrupted.

[0069] (6) Replace files Replace the original files of the old version of the software to install the software update package.

[0070] (7) Start the program Launch the new version of the software to verify that it works properly.

[0071] (8) Inspection procedures After the update, check the integrity and functionality of the program to ensure that the update was successful. Specifically, use a script or tool to check the correctness of the program of the new version of the software to ensure that it has been successfully updated.

[0072] (9) Restore backup If the update fails, restore the backed-up files of the original old version of the software to restore the original functions of the program, effectively solving the problem of restoring program functions after an update failure due to unexpected circumstances when updating the program in a production environment.

[0073] The self-update management method of the present invention has significant advantages in terms of user experience. First, users do not need to manually download and install software update packages, which reduces the user's operation steps and waiting time. Second, during the automatic update process, the client will display the update progress and status in real time, allowing users to clearly understand the update process (silent installation can also be selected). In addition, after the installation is completed, the new version of the software is automatically restarted and loaded, without the user having to perform additional operations, further improving the user experience.

[0074] Example 3 The following are device embodiments of the present invention, which can be used to perform method embodiments of the present invention. For details not disclosed in the device embodiments, please refer to the method embodiments of the present invention.

[0075] See also Figure 3 In an embodiment of the present invention, a host computer client software self-update management system 300 based on the Qt framework is provided, including: The update detection module 301 is used to obtain the latest version information file of the software through the self-update detection thread when the software of the upper computer client needs to be updated, compare the version information in the version information file with the version information of the local old version software, and determine whether the software needs to be updated; if the judgment result is that the software needs to be updated, after confirming the operator's identity security, the new version is updated, otherwise, the next update detection is waited according to the set update detection time; the version information file contains the version information of the new version software; The identity authentication and authorization module 302 is used to ensure the operator's identity security and operation security through identity authentication and update authorization authentication before executing the software update; The trusted installation module 303 is used to download the software update package and perform identity authentication, update authorization source verification, integrity verification and version compatibility verification on the software update package, and automatically execute the installation script after the verification is passed to decompress and install the software update package; after the software update package is installed, the host computer client automatically restarts and loads the new version of the software to complete the self-update process.

[0076] See also Figure 4 An electronic device provided in an embodiment of the present application includes a storage unit and a data processing unit. The storage unit stores a computer program. When the data processing unit executes the computer program, the steps of the upper computer client software self-update management method developed based on the Qt framework as described in any of the above embodiments are implemented.

[0077] In another embodiment of the present invention, a computer device is provided, the computer device includes a processor and a memory, the memory is used to store a computer program, the computer program includes program instructions, and the processor is used to execute the program instructions stored in the computer storage medium. The processor may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc. It is the computing core and control core of the terminal, which is suitable for implementing one or more instructions, and is specifically suitable for loading and executing one or more instructions in the computer storage medium to implement the corresponding method flow or corresponding function; the processor described in the embodiment of the present invention can be used for the controller to start the operation of the redundant data synchronization method for the first time.

[0078] In another embodiment of the present invention, the present invention further provides a storage medium, specifically a computer-readable storage medium (Memory), which is a memory device in a computer device for storing programs and data. It is understandable that the computer-readable storage medium here can include both a built-in storage medium in a computer device and an extended storage medium supported by the computer device. The computer-readable storage medium provides a storage space, which stores the operating system of the terminal. In addition, one or more instructions suitable for being loaded and executed by a processor are also stored in the storage space, and these instructions can be one or more computer programs (including program codes). It should be noted that the computer-readable storage medium here can be a high-speed random access memory (Random Access Memory, RAM) memory, or a non-volatile memory (non-volatile memory), such as at least one disk memory. The processor can load and execute one or more instructions stored in the computer-readable storage medium to implement the corresponding steps of the controller first starting redundant data synchronization method in the above embodiment.

[0079] It should be understood by those skilled in the art that the embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, compact disc read-only memory (CD-ROM), optical storage, etc.) containing computer-usable program code.

[0080] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0081] These computer program instructions may also be stored in a computer readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0082] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process in the computer or other programmable device. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0083] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in the relevant field should understand that the specific implementation methods of the present invention can still be modified or replaced by equivalents. Any modification or equivalent replacement that does not depart from the spirit and scope of the present invention should be covered within the scope of protection of the claims of the present invention.

Claims

1. A self-update management method for host computer client software based on Qt framework, characterized in that: include: S1, when the software of the upper computer client needs to be updated, the latest version information file of the software is obtained through the self-update detection thread, and the version information in the version information file is compared with the version information of the local old version software to determine whether the software needs to be updated; if the judgment result is that the software needs to be updated, S2 is executed, and after confirming that the operator's identity is safe, S3 is executed to update the new version, otherwise, the next update detection is waited according to the set update detection time; the version information file contains the version information of the new version of the software; S2, before executing the software update, ensure the operator's identity security and operation security through identity authentication and update authorization authentication; S3, the host computer client downloads the software update package and performs identity authentication, update authorization source verification, integrity verification and version compatibility verification on the software update package, and automatically executes the installation script after the verification passes, decompresses and installs the software update package; S4, set up software update process management, regular check update mechanism and rollback mechanism; S5, after the software update package is installed, the host computer client automatically restarts and loads the new version of the software to complete the self-update process.

2. The Qt framework-based host computer client software self-update management method according to claim 1, characterized in that: When the software of the upper computer client needs to be updated, the latest version information file of the software is obtained through the self-update detection thread, including: The software of the host computer client sends an update request to the server when it is started or periodically, and receives the latest version information file of the software sent by the server based on the update request. The update request is used to trigger the server to send the latest version information file of the software to the host computer client.

3. The Qt framework-based host computer client software self-update management method according to claim 1, characterized in that: The host computer client downloads the software update package of the new version software through the HTTPS protocol.

4. The Qt framework-based host computer client software self-update management method according to claim 1, characterized in that: In S3, the update authorization source verification specifically includes: verifying the digital signature of the software update package; the integrity verification specifically includes: using hash verification to verify the integrity of the downloaded software update package.

5. The Qt framework-based host computer client software self-update management method according to claim 1, characterized in that: S4 is specifically as follows: the host computer client periodically queries the server for a new version of the software, adopts version control and incremental updates, sets up a regular update check mechanism, supports manual triggering of update checks, and provides an automatic update option; provides a rollback mechanism, if the new version of the software has problems or is unstable, the host computer client automatically or manually rolls back to the previous version of the software.

6. The Qt framework-based host computer client software self-update management method according to claim 1, characterized in that: Before S1, the host client loads a trusted operating system during the startup phase.

7. The Qt framework-based host computer client software self-update management method according to claim 1, characterized in that: During the execution of S1, S2, and S3, trusted verification of the installation environment and trusted installation isolation are performed, and trusted audit logs and real-time alarms are generated.

8. A host computer client software self-update management system based on Qt framework, characterized in that: include: The update detection module is used to obtain the latest version information file of the software through the self-update detection thread when the software of the upper computer client needs to be updated, compare the version information in the version information file with the version information of the local old version software, and determine whether the software needs to be updated; if the judgment result is that the software needs to be updated, after confirming the operator's identity security, the new version is updated, otherwise, the next update detection is waited according to the set update detection time; the version information file contains the version information of the new version software; The authentication and authorization module is used to ensure the operator's identity security and operation security through identity authentication and update authorization authentication before executing the software update; The trusted installation module is used to download the software update package and perform identity authentication, update authorization source verification, integrity verification and version compatibility verification on the software update package, and automatically execute the installation script after the verification is passed to decompress and install the software update package; after the software update package is installed, the host computer client automatically restarts and loads the new version of the software to complete the self-update process.

9. A computer device, characterized in that: It includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the upper computer client software self-update management method based on the Qt framework as described in any one of claims 1 to 7 are implemented.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the upper computer client software self-update management method based on the Qt framework as claimed in any one of claims 1 to 7 are implemented.

Citation Information

Cited By

  • Authorization method and system based on multi-factor binding equipment and upper computer software

    CN122451858A

  • Hierarchical on-premises ai governance system and method

    TWI941563B