Data processing method and apparatus, electronic device, and program product
By encrypting and decrypting financial data and utilizing message queue transmission format and middleware, the problem of low data transmission efficiency in the domestic environment is solved, achieving secure and efficient data transmission.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- INDUSTRIAL AND COMMERCIAL BANK OF CHINA
- Filing Date
- 2026-02-14
- Publication Date
- 2026-06-02
Smart Images

Figure CN122137601A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of data communication and is applied to the field of financial technology. Specifically, it relates to a data processing method, apparatus, electronic device, and program product. Background Technology
[0002] In the current context of IT development in financial institutions, financial data, as a core asset, directly impacts the speed and quality of business operations through efficient processing and transmission. With the advancement of domestic technology, banks, insurance companies, securities firms, and other financial institutions are upgrading their IT infrastructure, adopting domestically produced software and hardware to respond to the national strategy of self-reliance and control over information technology. This shift has not only brought about innovation in the technological ecosystem but has also exacerbated the challenges of heterogeneous data sources. Particularly across the country, financial systems in different provinces or branches may be based on products and technical architectures from different vendors, such as database management systems, operating systems, and programming languages, increasing the difficulty of cross-system data transmission.
[0003] In a domestically developed environment, cross-regional financial data transmission presents a particularly prominent challenge. Traditional data exchange methods, such as file-sharing services, direct database connections, and custom interface solutions, while meeting data transmission needs to some extent, exhibit increasing limitations when faced with the specific characteristics of domestically developed systems. For example, file-sharing services may be limited by the degree of support for different file system formats, leading to file compatibility issues; direct database connections face challenges in connection adaptation and security due to the diversity of domestic database products; and custom interface solutions are constrained by differences in system interface standards, requiring extensive customization and increasing the burden on internal technical teams within financial institutions.
[0004] There is currently no effective solution to the problem of low efficiency in financial data processing when financial institutions transmit financial data due to heterogeneous data sources and the risk of data tampering, which requires developers to conduct additional development and testing. Summary of the Invention
[0005] The main objective of this application is to provide a data processing method, apparatus, electronic device, and program product to solve the problem in the related art where financial institutions transmit financial data, which is inefficient due to heterogeneous data sources and the risk of data tampering, requiring developers to conduct additional development and testing.
[0006] To achieve the above objectives, according to one aspect of this application, a data processing method is provided, comprising: determining financial data to be sent; encrypting the financial data to obtain an encrypted file; processing the encrypted file based on a message queue transmission format to generate a target message; sending the target message to a message queue of a message middleware, wherein the receiving end subscribes to the message queue of the message middleware, and after detecting that the message queue has received the target message, sends the target message to the receiving end through the message queue; verifying the target message, and decrypting the encrypted file based on a first verification result, so that the receiving end receives the financial data.
[0007] Furthermore, the financial data is encrypted to obtain an encrypted file, and the encrypted file is processed based on the message queue transmission format to generate a target message. This process includes: after the approval process for the financial data is detected to be completed, obtaining the approval flowchart file, approval content file, approval opinion file, and approval form file for the financial data to obtain an approval document; generating the first metadata information of the approval document and the second metadata information of the financial data, and writing the first metadata information and the second metadata information into a file to obtain a metadata file; encrypting the financial data, approval document, and metadata file to obtain an encrypted file, and generating a decryption key for the encrypted file using a national cryptographic algorithm; and processing the encrypted file and decryption key based on the message queue transmission format to generate a target message.
[0008] Furthermore, the encrypted file and decryption key are processed based on the message queue transmission format to generate the target message, including: processing the encrypted file based on a preset hash algorithm to obtain a first hash string; determining the message information of the message to be sent based on financial data, wherein the message information includes at least: message identification information, message type, message sending remarks description, message status, message sending retries number, and message creation time; generating a data transmission record based on the decryption key, the encrypted file, the first hash string, and the message information; determining the data transmission record as the message header, the encrypted file as the message body, and determining the target message based on the message header and message body.
[0009] Furthermore, sending the target message to the message queue of the message middleware includes: establishing a communication connection with the message queue based on the configuration information of the message middleware, wherein the configuration information includes at least: the IP information, port information, and message queue configuration information of the message middleware; creating a file message object based on the file path address of the target message, wherein the attribute information of the file message object is in string form; creating a session object based on the communication connection, and sending the target message to the message queue through the session object, so as to send the target message to the receiving end through the message middleware.
[0010] Further, the target message is verified, and the encrypted file is decrypted based on the first verification result so that the receiving end can receive the financial data. This includes: processing the encrypted file contained in the target message based on a preset hash algorithm to obtain a second hash string; verifying the first hash string in the data transmission record contained in the target message based on the second hash string to obtain a first verification result; if the first verification result indicates that the second hash string is different from the first hash string, resending the target message to the receiving end through a message queue based on a scheduled task; if the first verification result indicates that the second hash string is the same as the first hash string, the receiving end decrypts the encrypted file using the decryption key in the data transmission record contained in the target message so that the receiving end can receive the financial data.
[0011] Furthermore, the encrypted file is decrypted using the decryption key in the data transmission record contained in the target message, so that the receiving end receives the financial data. This includes: decrypting the encrypted file using the decryption key to obtain a metadata file and the financial data to be verified; performing an integrity check on the financial data to be verified based on the tag information in the metadata file to obtain a second verification result; if the second verification result indicates that the financial data to be verified is incomplete, re-acquiring the financial data to be sent and sending the re-acquiring financial data to the receiving end through the message queue of the message middleware; if the second verification result indicates that the financial data to be verified is complete, determining that the receiving end has received the financial data.
[0012] Furthermore, after generating a data transmission record based on the decryption key, the encrypted file, the first hash string, and the message information, the above method further includes: updating the message transmission record table in the preset storage space based on the data transmission record; after verifying the target message and decrypting the encrypted file based on the first verification result so that the receiving end receives the financial data, the above method further includes: receiving a response message sent by the receiving end, wherein the response message indicates that the receiving end has received the financial data; and updating each field of the data record corresponding to the financial data in the message transmission record table based on the response message.
[0013] To achieve the above objectives, according to another aspect of this application, a data processing apparatus is provided, comprising: an encryption unit for determining financial data to be sent, encrypting the financial data to obtain an encrypted file, and processing the encrypted file based on a message queue transmission format to generate a target message; a sending unit for sending the target message to a message queue of a message middleware, wherein a receiving end subscribes to the message queue of the message middleware, and after detecting that the message queue has received the target message, sends the target message to the receiving end through the message queue; and a decryption unit for verifying the target message and decrypting the encrypted file based on a first verification result, so that the receiving end receives the financial data.
[0014] Furthermore, the encryption unit includes: an acquisition subunit, used to acquire the approval flowchart file, approval content file, approval opinion file, and approval form file of the financial data after the approval process of the financial data is detected to be completed, to obtain the approval document; a generation subunit, used to generate the first metadata information of the approval document and the second metadata information of the financial data, and write the first metadata information and the second metadata information into a file to obtain a metadata file; an encryption subunit, used to encrypt the financial data, the approval document, and the metadata file to obtain an encrypted file, and use the national cryptographic algorithm to generate a decryption key for the encrypted file; and a first processing subunit, used to process the encrypted file and the decryption key based on the message queue transmission format to generate a target message.
[0015] Further, the first processing subunit includes: a processing module, used to process the encrypted file based on a preset hash algorithm to obtain a first hash string; a first determining module, used to determine the message information of the message to be sent based on financial data, wherein the message information includes at least: message identification information, message type, message sending remarks description, message status, message sending retries number, and message creation time; a generating module, used to generate a data transmission record based on the decryption key, the encrypted file, the first hash string, and the message information; and a second determining module, used to determine the data transmission record as the message header, the encrypted file as the message body, and the target message based on the message header and the message body.
[0016] Furthermore, the sending unit includes: an establishment subunit, used to establish a communication connection with the message queue based on the configuration information of the message middleware, wherein the configuration information includes at least: the IP information and port information of the message middleware, and the message queue configuration information; a creation subunit, used to create a file message object based on the file path address of the target message, wherein the attribute information of the file message object is in string form; and a first sending subunit, used to create a session object based on the communication connection, and send the target message to the message queue through the session object, so as to send the target message to the receiving end through the message middleware.
[0017] Further, the decryption unit includes: a second processing subunit, used to process the encrypted file contained in the target message based on a preset hash algorithm to obtain a second hash string; a verification subunit, used to verify the first hash string in the data transmission record contained in the target message based on the second hash string to obtain a first verification result; a second sending subunit, used to resend the target message to the receiving end through a message queue based on a timed task when the first verification result indicates that the second hash string is different from the first hash string; and a decryption subunit, used to decrypt the encrypted file by the receiving end using the decryption key in the data transmission record contained in the target message when the first verification result indicates that the second hash string is the same as the first hash string, so that the receiving end can receive the financial data.
[0018] Furthermore, the decryption subunit includes: a decryption module, used to decrypt the encrypted file using a decryption key to obtain a metadata file and financial data to be verified; a verification module, used to perform integrity verification on the financial data to be verified based on the tag information in the metadata file to obtain a second verification result; an acquisition module, used to reacquire the financial data to be sent if the second verification result indicates that the financial data to be verified is incomplete, and send the reacquired financial data to the receiving end through the message queue of the message middleware; and a third determination module, used to determine that the receiving end has received the financial data if the second verification result indicates that the financial data to be verified is complete.
[0019] Furthermore, the first processing subunit also includes: an update module, used to update the message transmission record table in the preset storage space according to the data transmission record after generating the data transmission record based on the decryption key, the encrypted file, the first hash string, and the message information; the above-mentioned device also includes: a receiving unit, used to receive a response message sent by the receiving end after verifying the target message and decrypting the encrypted file according to the first verification result so that the receiving end receives the financial data, wherein the response message indicates that the receiving end has received the financial data; and an update unit, used to update each field of the data record corresponding to the financial data in the message transmission record table according to the response message.
[0020] To achieve the above objectives, according to one aspect of this application, a computer program product is provided, including a computer program that, when executed by a processor, implements any of the above-described data processing methods, and when executed by a processor, implements the steps of the data processing methods in various embodiments of this application.
[0021] To achieve the above objectives, according to one aspect of this application, a computer-readable storage medium is provided, the computer-readable storage medium including stored computer instructions, wherein any of the above data processing methods are implemented when the computer instructions are executed by a processor.
[0022] To achieve the above objectives, according to one aspect of this application, an electronic device is provided, including one or more processors and a memory, the memory being used to store one or more programs, wherein when the one or more programs are executed by one or more processors, the one or more processors cause the one or more processors to implement any of the above data processing methods.
[0023] In this embodiment, by determining the financial data to be sent, encrypting the financial data to obtain an encrypted file, and processing the encrypted file based on the message queue transmission format to generate a target message, the target message is sent to the message queue of the message middleware. The receiving end subscribes to the message queue of the message middleware, and after detecting that the message queue has received the target message, it sends the target message to the receiving end through the message queue. The target message is verified, and the encrypted file is decrypted based on the first verification result, so that the receiving end receives the financial data. This solves the technical problem of low efficiency in financial data processing when financial institutions transmit financial data due to heterogeneous data sources and the risk of data tampering, requiring developers to perform additional development and testing work.
[0024] Encrypting financial data effectively prevents the risk of data leakage and tampering during transmission, ensuring data security. Message queue-based transmission improves the stability and efficiency of data transmission. Simultaneously, transmitting encrypted data via message queues and decrypting it at the receiving end automates data push and reception confirmation, achieving automated verification and decryption during financial data transmission. This reduces the additional development and testing work required for developers to verify data transmission security and integrity, achieving the technical effect of enabling financial institutions to transmit financial data securely and efficiently in a domestically developed environment. Attached Figure Description
[0025] The accompanying drawings, which form part of this application, are used to provide a further understanding of this application. The illustrative embodiments and descriptions of this application are used to explain this application and do not constitute an undue limitation of this application. In the drawings:
[0026] Figure 1 This is a hardware structure block diagram of a computer terminal (or mobile device) for implementing a data processing method according to Embodiment 1 of this application;
[0027] Figure 2 This is a flowchart of an optional data processing method provided according to Embodiment 1 of this application;
[0028] Figure 3 This is a schematic diagram of optional cross-provincial transmission of financial data according to Embodiment 1 of this application;
[0029] Figure 4This is a schematic diagram of an optional inter-provincial financial data transmission process provided in Embodiment 1 of this application;
[0030] Figure 5 This is a schematic diagram of a data processing apparatus provided according to Embodiment 2 of this application;
[0031] Figure 6 This is a schematic diagram of a data processing electronic device provided according to Embodiment 3 of this application. Detailed Implementation
[0032] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. This application will now be described in detail with reference to the accompanying drawings and embodiments.
[0033] It should be noted that the processing methods, apparatus, storage media, and electronic devices specified in this application can be used in the financial technology field to improve the efficiency of financial data processing during the transmission of financial data, and can also be used in any field other than the financial technology field. The application fields of the processing methods, apparatus, storage media, and electronic devices specified in this application are not limited.
[0034] It should be noted that the information collected in this application (including but not limited to user device information, user personal information, collected data, used data, generated data, processed data, etc.) and the data (including but not limited to data used for analysis, stored data, displayed data, collected information, used information, generated information, processed information, etc.) are all information and data authorized by the user or fully authorized by all parties. Furthermore, the collection, storage, use, processing, transmission, provision, disclosure, and application of the relevant data all comply with the relevant laws, regulations, and standards of the relevant countries and regions, have taken necessary confidentiality measures, do not violate public order and good morals, and provide corresponding operation entry points for users to choose to authorize or refuse. For example, this system has interfaces with relevant users or organizations, providing users with corresponding operation entry points for users to choose to agree to or refuse automated decision results; if the user chooses to refuse, the process proceeds to the expert decision-making stage.
[0035] Example 1
[0036] According to an embodiment of this application, a method embodiment for data processing is also provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.
[0037] The method embodiment provided in Embodiment 1 of this application can be executed in a mobile terminal, computer terminal or similar computing device. Figure 1 This is a hardware structure block diagram of a computer terminal (or mobile device) for implementing a data processing method, according to Embodiment 1 of this application. Figure 1 As shown, the computer terminal 10 (or mobile device) may include one or more processors 102 (shown as 102a, 102b, ..., 102n in the figure) 102 (processor 102 may include, but is not limited to, a microprocessor MCU or a programmable logic device FPGA, etc.), a memory 104 for storing data, and a transmission device 106 for communication functions. In addition, it may also include: a display, an input / output interface (I / O interface), a universal serial bus (USB) port (which may be included as one of the ports of a BUS bus), a network interface, a power supply, and / or a camera. Those skilled in the art will understand that... Figure 1 The structure shown is for illustrative purposes only and does not limit the structure of the aforementioned electronic device. For example, computer terminal 10 may also include... Figure 1 The more or fewer components shown, or having the same Figure 1 The different configurations shown.
[0038] It should be noted that the aforementioned one or more processors 102 and / or other data processing circuits are generally referred to herein as "data processing circuits". These data processing circuits may be embodied, in whole or in part, in software, hardware, firmware, or any other combination thereof. Furthermore, the data processing circuits may be a single, independent processing module, or may be integrated, in whole or in part, into any other element within the computer terminal 10 (or mobile device). As involved in the embodiments of this application, the data processing circuits serve as a processor control mechanism (e.g., selection of a variable resistor termination path connected to an interface).
[0039] The memory 104 can be used to store software programs and modules of application software, such as program instructions / data storage devices corresponding to the data processing method in this embodiment. The processor 102 executes various functional applications and data processing by running the software programs and modules stored in the memory 104, thereby implementing the aforementioned data processing method. The memory 104 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 104 may further include memory remotely located relative to the processor 102, and these remote memories can be connected to the computer terminal 10 via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.
[0040] The transmission device 106 is used to receive or send data via a network. Specific examples of the network described above may include a wireless network provided by the communication provider of the computer terminal 10. In one example, the transmission device 106 includes a Network Interface Controller (NIC), which can connect to other network devices via a base station to communicate with the Internet. In another example, the transmission device 106 may be a Radio Frequency (RF) module, used for wireless communication with the Internet.
[0041] The display may be, for example, a touchscreen liquid crystal display (LCD) that allows the user to interact with the user interface of the computer terminal 10 (or mobile device).
[0042] Under the aforementioned operating environment, this application provides the following: Figure 2 The data processing method shown. Figure 2 This is a flowchart of an optional data processing method provided according to Embodiment 1 of this application.
[0043] Step S201: Determine the financial data to be sent, encrypt the financial data to obtain an encrypted file, and process the encrypted file based on the message queue transmission format to generate the target message.
[0044] The executing entity in this embodiment 1 can be a data processing system. This system aims to achieve secure cross-system and cross-regional transmission of financial data under a domestically developed environment. Specifically, the data processing system performs the following functions: collecting financial data to be transmitted, including approval process records, opinion lists, and financial documents; encrypting the data using the State Cryptography Administration's Proposed Algorithm 4 (SM4) to ensure transmission security; recording data metadata through XML (eXtensible Markup Language) description files to ensure data integrity; encapsulating and sending the encrypted financial data using the file format of a message middleware; decrypting and verifying the data at the receiving end to ensure accurate data reception; and providing a feedback mechanism for data transmission status and transmission record management functions to monitor the transmission process. In summary, this data processing system effectively improves the efficiency and security of financial data reporting.
[0045] In this embodiment 1, after determining the financial data to be sent, an encryption algorithm is used to encrypt the data and generate an encrypted file. Subsequently, according to the message queue transmission standard, the encrypted file and its related attributes are encapsulated to generate the target message used for data transmission, thereby enabling the target message to be transmitted to the receiving end through the message queue format.
[0046] Step S202: Send the target message to the message queue of the message middleware. The receiving end subscribes to the message queue of the message middleware, and after detecting that the message queue has received the target message, it sends the target message to the receiving end through the message queue.
[0047] In this embodiment 1, the encrypted and encapsulated financial data is considered the target message. This target message establishes a session through a message middleware and is sent to a pre-defined remote message queue. The receiving end needs to subscribe to the corresponding message queue of the message middleware. When the message queue detects that the target message has been received, the receiving end's subscription mechanism is triggered. The system retrieves the target message from the queue through the application programming interface (API) provided by the message middleware. This process ensures secure data transmission and accurate reception, and through the message queue mechanism, asynchronous communication and orderly message processing are achieved.
[0048] Step S203: Verify the target message and decrypt the encrypted file based on the first verification result so that the receiving end can receive the financial data.
[0049] In this embodiment 1, the receiving end first verifies the target message. If the two match, it indicates that the file has not been tampered with during transmission, and the verification passes. Subsequently, based on the successful verification result, the receiving end uses the decryption key attached to the target message to decrypt the encrypted file, restoring the original financial data and ensuring the accurate receipt and use of the data. This process strictly follows information security protocols and, through a dual verification mechanism—verification and decryption—ensures the integrity and confidentiality of data during cross-system transmission.
[0050] Optionally, in the data processing method provided in Embodiment 1 of this application, the financial data is encrypted to obtain an encrypted file, and the encrypted file is processed based on the message queue transmission format to generate a target message. This includes: after detecting the completion of the approval process for the financial data, obtaining the approval flowchart file, approval content file, approval opinion file, and approval form file for the financial data to obtain an approval document; generating first metadata information of the approval document and second metadata information of the financial data, and writing the first metadata information and second metadata information into a file to obtain a metadata file; encrypting the financial data, approval document, and metadata file to obtain an encrypted file, and generating a decryption key for the encrypted file using a national cryptographic algorithm; and processing the encrypted file and decryption key based on the message queue transmission format to generate a target message.
[0051] In this embodiment 1, to ensure the security and compliance of financial data during cross-system transmission, approval documents are automatically retrieved at the end of the approval process. These approval documents include, but are not limited to, all approval documents such as approval flowcharts, approval content, approval comments, and approval forms. Approval documents may exist in PDF, Word, or image formats. Then, detailed metadata about the approval documents is generated, such as the filename (corresponding tags). <filename>), file type (corresponding label) <doctype>Size (corresponding label) <size>Creation date (corresponding tag) <createtime>), Update Date (corresponding tag) <updatetime>), and detailed metadata for generating financial data, such as data source (corresponding tags). <source> ), file identifier (corresponding label) <id>), data items (corresponding labels) <fields>Each data item includes: data title, data type, specific business data item, and data version, etc., and this metadata information is integrated and written into a new file, namely the metadata file. Secondly, the high-standard national cryptographic algorithm SM4 is used to uniformly encrypt the financial data, approval documents, and metadata file, forming an encrypted file, and simultaneously generating a decryption key. Finally, following the transmission rules of message queues, the encrypted file and decryption key are encapsulated into a message entity, namely the target message, ready for secure transmission through a message middleware. Through the above steps, comprehensive protection of financial data and approval documents is achieved in a domestic environment, ensuring the security and integrity of data transmission, and providing technical evidence for subsequent decryption verification.
[0052] Optionally, in the data processing method provided in Embodiment 1 of this application, the encrypted file and decryption key are processed based on the message queue transmission format to generate a target message, including: processing the encrypted file based on a preset hash algorithm to obtain a first hash string; determining the message information of the message to be sent based on financial data, wherein the message information includes at least: message identification information, message type, message sending remarks description, message status, message sending retries number, and message creation time; generating a data transmission record based on the decryption key, the encrypted file, the first hash string, and the message information; determining the data transmission record as the message header, determining the encrypted file as the message body, and determining the target message based on the message header and message body.
[0053] In this embodiment 1, to ensure the integrity and consistency of the encrypted file before and after transmission, the encrypted financial data file is first processed based on a preset hash algorithm, such as SHA-256, to obtain a first hash string. Then, based on the characteristics of the financial data and transmission requirements, the basic information contained in the message to be sent is determined. For example, the message identifier can be set to a UUID, the message type is "financial data transmission," the message sending remarks are described as "quarterly financial report," the initial message status is "not sent," the default message retry count is 0, and the message creation time is the actual date and time of message generation. Next, the decryption key, the encrypted file, the first hash string, and the aforementioned basic message information are combined to form a complete data transmission record, which serves as the basis for auditing and recovering the message transmission. Finally, this data transmission record is used as the message header, and the encrypted file is used as the message body. This encapsulation constitutes the target message to be transmitted to the message middleware, facilitating efficient and orderly transmission across systems.
[0054] Through the above steps, the technical effect of fine control and traceability of financial data transmission process is achieved in a domestic environment, ensuring the accuracy and security of data transmission even between heterogeneous systems, while providing an effective data retransmission mechanism to reduce the possibility of data loss.
[0055] Optionally, in the data processing method provided in Embodiment 1 of this application, sending the target message to the message queue of the message middleware includes: establishing a communication connection with the message queue based on the configuration information of the message middleware, wherein the configuration information includes at least: the IP information, port information, and message queue configuration information of the message middleware; creating a file message object based on the file path address of the target message, wherein the attribute information of the file message object is in string form; creating a session object based on the communication connection, and sending the target message to the message queue through the session object, so as to send the target message to the receiving end through the message middleware.
[0056] In this embodiment 1, to build a stable message transmission channel and achieve reliable transmission of financial data between heterogeneous systems, the configuration details of the message middleware are first parsed and obtained. This includes, but is not limited to, the server IP of the message middleware, such as 192.168.1.100, the communication port, such as 61616, and the specified message queue name, such as FinanceDataQueue. Then, based on the location information of the encrypted data to be sent, a file message object encapsulating the financial data file path (e.g., gwPath ="C:\temp\financeData.zip") is created. The attribute information of this object is stored in the form of a character sequence. Next, using the established communication connection, a session object is generated. This is the basis for message interaction. Through this session object, a data push command is executed, delivering the target message containing encrypted financial data to the designated message queue, ensuring the continuity and accuracy of data transmission. Finally, using the message middleware's publish-subscribe mechanism, the receiving end listens to the corresponding queue. Once a new message is detected, the receiving logic is triggered, thereby achieving real-time transmission and processing of cross-system data.
[0057] By configuring the message middleware in detail, a robust communication link was established, providing the necessary network environment support for data transmission. Financial data was converted into file message objects and attribute information was stored as strings, simplifying the data encapsulation process and enabling unified processing of different data types. The creation of session objects and message pushing ensured the atomicity and consistency of data transmission, guaranteeing no data loss even under network fluctuations through the persistence of message queues. The use of the message middleware not only enabled asynchronous data transmission, reducing the immediate load on the sending system, but also ensured that the receiving end could obtain data promptly and accurately through its built-in publish-subscribe model, thereby quickly responding to business needs. Through these steps, a highly efficient and secure cross-system transmission mechanism for financial data was built in a domestically developed environment. This significantly improved the efficiency of cross-system transmission of financial data in a domestically developed environment, reduced data processing latency, and strengthened security protection during data transmission, avoiding potential risks to financial institutions due to data leakage or tampering.
[0058] Optionally, in the data processing method provided in Embodiment 1 of this application, verifying the target message and decrypting the encrypted file according to the first verification result to enable the receiving end to receive financial data includes: processing the encrypted file contained in the target message based on a preset hash algorithm to obtain a second hash string; verifying the first hash string in the data transmission record contained in the target message according to the second hash string to obtain a first verification result; if the first verification result indicates that the second hash string is different from the first hash string, resending the target message to the receiving end through a message queue based on a timed task; if the first verification result indicates that the second hash string is the same as the first hash string, decrypting the encrypted file by the receiving end using the decryption key in the data transmission record contained in the target message to enable the receiving end to receive financial data.
[0059] In this embodiment 1, to verify the integrity and tamper-free status of financial data during transmission, a preset hash algorithm, such as SHA-256, is first used to process the encrypted file contained in the target message received from the message queue, obtaining a second hash string. Then, the calculated second hash string is compared with the first hash string in the data transmission record to obtain the verification result. Next, if a mismatch is found between the two hash strings, it indicates a possible anomaly or tampering during data transmission. At this point, the system automatically triggers a timed task to resend the target message through the message queue, implementing a data retransmission mechanism until the receiving end verifies the data. Finally, if the hash strings match, the receiving end reads the decryption key contained in the target message to decrypt the encrypted file, thereby ensuring that the recipient can accurately obtain the original financial data.
[0060] The application of hash algorithms provides an irreversible fingerprint for data transmission, effectively preventing passive or active data tampering during transmission. By rigorously comparing the first hash string in the transmission record with the second hash string in the received file, data corruption during transmission can be quickly identified, and a retransmission mechanism can be initiated promptly to ensure the reliability of data transmission. Through these steps, not only is the efficiency and security of cross-system transmission of financial data enhanced, but the automated verification and retransmission strategy also reduces the need for human intervention, further improving the automation level of data processing and the quality control of the overall transmission process. This provides financial institutions with a practical and efficient solution for data transmission in a domestically produced environment.
[0061] Optionally, in the data processing method provided in Embodiment 1 of this application, the encrypted file is decrypted using the decryption key in the data transmission record contained in the target message so that the receiving end receives the financial data. This includes: decrypting the encrypted file using the decryption key to obtain a metadata file and financial data to be verified; performing an integrity check on the financial data to be verified based on the tag information in the metadata file to obtain a second verification result; if the second verification result indicates that the financial data to be verified is incomplete, re-acquiring the financial data to be sent and sending the re-acquiring financial data to the receiving end through the message queue of the message middleware; and if the second verification result indicates that the financial data to be verified is complete, determining that the receiving end has received the financial data.
[0062] In this embodiment 1, to ensure that the received financial data remains intact after decryption, the encrypted file is first decrypted using the decryption key carried in the target message. This process restores the metadata file and the financial data to be verified. Then, the metadata file is analyzed to extract tag information, such as file size, file type, and file creation date. This information will serve as the standard for subsequent integrity verification. Next, the financial data to be verified is compared one by one with the tag information in the metadata file to determine if the data has undergone unexpected changes or loss. If incompleteness is found, the system automatically triggers a re-acquisition process for the financial data, sending the updated data to the receiving end again through the message queue of the message middleware. Finally, only when the verification result shows that the financial data is complete is it confirmed that the receiving end has successfully received the correct financial data.
[0063] The use of decryption keys ensures that only authorized holders can access financial data, while the introduction of metadata files provides quantifiable metrics for verifying the integrity of financial data. Rigorous verification of the decrypted data effectively prevents loss of financial data due to transmission errors or third-party interference, ensuring the authenticity and availability of the data. Upon detecting incomplete data, a retransmission mechanism is immediately initiated, avoiding delays and errors caused by manual intervention and improving the efficiency and accuracy of data transmission. Through these steps, not only is the security of data transmission strengthened, but the automated verification and retransmission process also reduces the data transmission failure rate, ensuring high availability and accuracy of financial data during cross-system transmission.
[0064] Optionally, in the data processing method provided in Embodiment 1 of this application, after generating a data transmission record based on the decryption key, the encrypted file, the first hash string, and the message information, the method further includes: updating the message transmission record table in the preset storage space based on the data transmission record; after verifying the target message and decrypting the encrypted file based on the first verification result so that the receiving end receives the financial data, the method further includes: receiving a response message sent by the receiving end, wherein the response message indicates that the receiving end has received the financial data; and updating each field of the data record corresponding to the financial data in the message transmission record table based on the response message.
[0065] In this embodiment 1, to manage the transmission status of each financial data transmission in a refined manner, firstly, after successful data transmission, the message transmission record table in the preset storage space, such as the Transmission Record Table, is updated in real time based on the data transmission record containing information such as the decryption key and the hash value of the encrypted file. This table records the details of each message transmission, including the message ID, status, number of retries, etc. Then, after the receiving end completes the verification and decryption of the target message and confirms that the financial data has been received correctly, a response message is generated. This message clearly indicates the reception status, for example, {"status": "received", "messageId": "123e4567-e89b-12d3-a456-426655440000"}. Secondly, the sending end receives this response message, confirming that the receiving end has indeed obtained the financial data. Finally, based on the content of the response message, the status of the corresponding financial data records in the message transmission record table is updated, such as changing the messageStatus field from "sending" to "received", and possibly updating additional information such as the timestamp, thus completing the closed-loop management of the entire transmission process.
[0066] The updating of the data transmission log ensures that every data transmission activity is accurately recorded. Whether it's any problem encountered during transmission or the final confirmation of receipt, a corresponding record can be found in the log, providing detailed evidence for subsequent auditing, troubleshooting, and performance optimization. The introduction of the response message mechanism enhances two-way confirmation of data transmission, ensuring information symmetry between the receiving and sending ends regarding the transmission status and avoiding transmission uncertainties caused by network latency or message loss. Through these steps, not only is the success rate and reliability of financial data transmission improved, but real-time status updates also provide financial institutions with real-time monitoring capabilities of the data transmission process. This facilitates the timely detection and handling of potential problems, ensuring smooth data transmission, and also helps optimize data transmission strategies and improve overall data processing efficiency.
[0067] Optionally, in this embodiment 1, Figure 3 This is a schematic diagram illustrating the optional inter-provincial transmission of financial data according to Embodiment 1 of this application. For example... Figure 3 As shown, firstly, the information systems of provinces A, B, and C each digitize their processed financial data and send it to their local message queues via message middleware deployed within their respective provinces. This process achieves initial data encapsulation and localized storage. Then, the message middleware in each province continuously monitors its respective message queue to ensure message integrity and timeliness, preparing for data transmission to the next stage. Secondly, the message middleware at headquarters subscribes to the message queues of provinces A, B, and C, efficiently retrieving messages through established communication connections. This step leverages the distributed nature of message middleware, enabling data to transcend geographical boundaries and converge centrally at headquarters. Finally, headquarters retrieves the target message from the message queues of the message middleware in each province, decrypts and verifies it, completing the final data reception. This achieves efficient cross-system and cross-province transmission of financial data nationwide, meeting the security, accuracy, and timeliness requirements of data exchange in a domestically developed environment.
[0068] Optionally, in this embodiment 1, Figure 4 This is a schematic diagram of an optional inter-provincial financial data transmission process provided in Embodiment 1 of this application. For example... Figure 4 As shown, firstly, the sending end encrypts financial data and related documents using the SM4 national cryptographic algorithm, forming an encrypted zip file. The data transmission record is then stored in a database. Subsequently, the encapsulated message is sent to the receiving end's message queue via a message middleware. Next, upon receiving the message, the receiving end immediately verifies the MD5 value of the zip file to confirm the data integrity during transmission. Secondly, if the MD5 verification fails, the receiving end reports an error status to the sending end, which then initiates a scheduled task mechanism to automatically attempt to resend the message. If the resend attempts reach a preset limit without success, the system will trigger manual intervention to promptly troubleshoot the problem. Finally, if the MD5 verification is successful, the receiving end uses the decryption key from the transmission record to decompress the zip file and recheck the integrity of the financial data. If the data is incomplete, the receiving end notifies the sending end, which then prepares and resends the data. Conversely, if the data is complete, the receiving end follows the XML file guidelines to formally access and process the financial data, simultaneously sending a confirmation message and triggering the sending end to update the message transmission record table, marking the end of a complete financial data transmission process.
[0069] It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although a logical order is shown in the flowchart, in some cases the steps shown or described may be executed in a different order than that shown here.
[0070] In summary, the data processing method provided in this application, by determining the financial data to be sent, encrypting the financial data to obtain an encrypted file, and processing the encrypted file based on the message queue transmission format to generate a target message, sends the target message to the message queue of the message middleware. Specifically, the receiving end subscribes to the message queue of the message middleware, and after detecting that the message queue has received the target message, it sends the target message to the receiving end through the message queue. The target message is verified, and the encrypted file is decrypted based on the first verification result, so that the receiving end receives the financial data. This solves the problem in related technologies where financial institutions transmitting financial data face low processing efficiency due to heterogeneous data sources and the risk of data tampering, requiring developers to perform additional development and testing.
[0071] Encrypting financial data effectively prevents the risk of data leakage and tampering during transmission, ensuring data security. Message queue-based transmission improves the stability and efficiency of data transmission. Simultaneously, transmitting encrypted data via message queues and decrypting it at the receiving end automates data push and reception confirmation, achieving automated verification and decryption during financial data transmission. This reduces the additional development and testing work required for developers to verify data transmission security and integrity, achieving the technical effect of enabling financial institutions to transmit financial data securely and efficiently in a domestically developed environment.
[0072] Example 2
[0073] This application also provides a data processing apparatus. It should be noted that the data processing apparatus of this application can be used to execute the data processing method provided in this application. The data processing apparatus provided in this application will be described below.
[0074] According to an embodiment of this application, an apparatus for implementing the above-described data processing method is also provided. Figure 5 This is a schematic diagram of a data processing apparatus provided according to Embodiment 2 of this application. Figure 5 As shown, the device includes: an encryption unit 501, a sending unit 502, and a decryption unit 503.
[0075] Specifically, the encryption unit 501 is used to determine the financial data to be sent, encrypt the financial data to obtain an encrypted file, and process the encrypted file based on the message queue transmission format to generate the target message.
[0076] The sending unit 502 is used to send the target message to the message queue of the message middleware. The receiving end subscribes to the message queue of the message middleware, and after detecting that the message queue has received the target message, it sends the target message to the receiving end through the message queue.
[0077] The decryption unit 503 is used to verify the target message and decrypt the encrypted file according to the first verification result so that the receiving end can receive the financial data.
[0078] The data processing apparatus provided in this application embodiment determines the financial data to be sent through an encryption unit 501, encrypts the financial data to obtain an encrypted file, and processes the encrypted file based on a message queue transmission format to generate a target message. A sending unit 502 sends the target message to a message queue of a message middleware. The receiving end subscribes to the message queue of the message middleware, and after detecting that the message queue has received the target message, it sends the target message to the receiving end through the message queue. A decryption unit 503 verifies the target message and decrypts the encrypted file based on the first verification result, enabling the receiving end to receive the financial data. This solves the problem in related technologies where financial institutions transmitting financial data face low processing efficiency due to heterogeneous data sources and the risk of data tampering, requiring developers to perform additional development and testing.
[0079] Encrypting financial data effectively prevents the risk of data leakage and tampering during transmission, ensuring data security. Message queue-based transmission improves the stability and efficiency of data transmission. Simultaneously, transmitting encrypted data via message queues and decrypting it at the receiving end automates data push and reception confirmation, achieving automated verification and decryption during financial data transmission. This reduces the additional development and testing work required for developers to verify data transmission security and integrity, achieving the technical effect of enabling financial institutions to transmit financial data securely and efficiently in a domestically developed environment.
[0080] Optionally, in the data processing apparatus provided in Embodiment 2 of this application, the encryption unit 501 includes: an acquisition subunit, used to acquire the approval flowchart file, approval content file, approval opinion file, and approval form file of the financial data after the approval process of the financial data is detected to be completed, to obtain an approval document; a generation subunit, used to generate first metadata information of the approval document and second metadata information of the financial data, and write the first metadata information and second metadata information into a file to obtain a metadata file; an encryption subunit, used to encrypt the financial data, approval document, and metadata file to obtain an encrypted file, and generate a decryption key for the encrypted file using a national cryptographic algorithm; and a first processing subunit, used to process the encrypted file and decryption key based on a message queue transmission format to generate a target message.
[0081] Optionally, in the data processing apparatus provided in Embodiment 2 of this application, the first processing subunit includes: a processing module, used to process the encrypted file based on a preset hash algorithm to obtain a first hash string; a first determining module, used to determine the message information of the message to be sent based on financial data, wherein the message information includes at least: message identification information, message type, message sending remarks description, message status, message sending retries number, and message creation time; a generating module, used to generate a data transmission record based on the decryption key, the encrypted file, the first hash string, and the message information; and a second determining module, used to determine the data transmission record as the message header, the encrypted file as the message body, and the target message based on the message header and the message body.
[0082] Optionally, in the data processing apparatus provided in Embodiment 2 of this application, the aforementioned sending unit 502 includes: an establishment subunit, used to establish a communication connection with the message queue based on the configuration information of the message middleware, wherein the configuration information includes at least: IP information, port information, and message queue configuration information of the message middleware; a creation subunit, used to create a file message object based on the file path address of the target message, wherein the attribute information of the file message object is in string form; and a first sending subunit, used to create a session object based on the communication connection, and send the target message to the message queue through the session object, so as to send the target message to the receiving end through the message middleware.
[0083] Optionally, in the data processing apparatus provided in Embodiment 2 of this application, the decryption unit 503 includes: a second processing subunit, used to process the encrypted file contained in the target message based on a preset hash algorithm to obtain a second hash string; a verification subunit, used to verify the first hash string in the data transmission record contained in the target message based on the second hash string to obtain a first verification result; a second sending subunit, used to resend the target message to the receiving end through a message queue based on a timed task when the first verification result indicates that the second hash string is different from the first hash string; and a decryption subunit, used to decrypt the encrypted file by the receiving end using the decryption key in the data transmission record contained in the target message when the first verification result indicates that the second hash string is the same as the first hash string, so that the receiving end can receive financial data.
[0084] Optionally, in the data processing apparatus provided in Embodiment 2 of this application, the above-mentioned decryption subunit includes: a decryption module, used to decrypt the encrypted file using a decryption key to obtain a metadata file and financial data to be verified; a verification module, used to perform integrity verification on the financial data to be verified based on the tag information in the metadata file to obtain a second verification result; an acquisition module, used to reacquire the financial data to be sent when the second verification result indicates that the financial data to be verified is incomplete, and send the reacquired financial data to the receiving end through the message queue of the message middleware; and a third determination module, used to determine that the receiving end has received the financial data when the second verification result indicates that the financial data to be verified is complete.
[0085] Optionally, in the data processing apparatus provided in Embodiment 2 of this application, the first processing subunit further includes: an update module, configured to update the message transmission record table in the preset storage space according to the data transmission record after generating the data transmission record based on the decryption key, the encrypted file, the first hash string, and the message information; the apparatus further includes: a receiving unit, configured to receive a response message sent by the receiving end after verifying the target message and decrypting the encrypted file according to the first verification result so that the receiving end receives the financial data, wherein the response message indicates that the receiving end has received the financial data; and an update unit, configured to update each field of the data record corresponding to the financial data in the message transmission record table according to the response message.
[0086] It should be noted that the encryption unit 501, sending unit 502, and decryption unit 503 mentioned above correspond to steps S201 to S203 in Embodiment 1. The two modules and the corresponding steps implement the same instances and application scenarios, but are not limited to the content disclosed in Embodiment 1. It should be noted that the above modules or units can be hardware or software components stored in memory (e.g., memory 104) and processed by one or more processors (e.g., processors 102a, 102b, ..., 102n). The above modules can also be part of a device and run in the computer terminal 10 provided in Embodiment 1.
[0087] Example 3
[0088] Embodiments of this application may provide an electronic device. Figure 6 This is a schematic diagram of a data processing electronic device according to Embodiment 3 of this application. Figure 6 As shown, the electronic device may include: one or more ( Figure 6 (Only one is shown) Processor 602, memory 604, memory controller, and peripheral interface, wherein the peripheral interface is connected to the radio frequency module, audio module and display.
[0089] The memory can be used to store software programs and modules, such as the program instructions / modules corresponding to the methods and apparatus in the embodiments of this application. The processor executes various functional applications and data processing by running the software programs and modules stored in the memory, thereby implementing the above-described methods. The memory may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory may further include memory remotely located relative to the processor, and these remote memories can be connected to the terminal via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.
[0090] The processor can access information and applications stored in memory via a transmission device to perform the following steps: determine the financial data to be sent, encrypt the financial data to obtain an encrypted file, process the encrypted file based on a message queue transmission format to generate a target message; send the target message to the message queue of a message middleware, wherein the receiving end subscribes to the message queue of the message middleware, and after detecting that the message queue has received the target message, sends the target message to the receiving end through the message queue; verify the target message, and decrypt the encrypted file based on the first verification result, so that the receiving end receives the financial data.
[0091] The processor can access information and applications stored in memory via a transmission device to perform the following steps: encrypting financial data to obtain an encrypted file, and processing the encrypted file based on a message queue transmission format to generate a target message, including: after detecting the completion of the approval process for the financial data, acquiring the approval flowchart file, approval content file, approval opinion file, and approval form file for the financial data to obtain an approval document; generating first metadata information for the approval document and second metadata information for the financial data, and writing the first metadata information and second metadata information into a file to obtain a metadata file; encrypting the financial data, approval document, and metadata file to obtain an encrypted file, and generating a decryption key for the encrypted file using a national cryptographic algorithm; and processing the encrypted file and decryption key based on a message queue transmission format to generate a target message.
[0092] The processor can invoke information and applications stored in the memory through the transmission device to perform the following steps: processing the encrypted file and decryption key based on the message queue transmission format to generate a target message, including: processing the encrypted file based on a preset hash algorithm to obtain a first hash string; determining the message information of the message to be sent based on financial data, wherein the message information includes at least: message identification information, message type, message sending remarks description, message status, message sending retries number, and message creation time; generating a data transmission record based on the decryption key, the encrypted file, the first hash string, and the message information; determining the data transmission record as the message header, the encrypted file as the message body, and determining the target message based on the message header and message body.
[0093] The processor can invoke information and applications stored in memory through the transmission device to perform the following steps: establish a communication connection with the message queue based on the configuration information of the message middleware, wherein the configuration information includes at least: the IP information, port information, and message queue configuration information of the message middleware; create a file message object based on the file path address of the target message, wherein the attribute information of the file message object is in string form; create a session object based on the communication connection, and send the target message to the message queue through the session object, so as to send the target message to the receiving end through the message middleware.
[0094] The processor can invoke information and applications stored in the memory through the transmission device to perform the following steps: verifying the target message and decrypting the encrypted file according to the first verification result, so that the receiving end receives financial data, including: processing the encrypted file contained in the target message based on a preset hash algorithm to obtain a second hash string; verifying the first hash string in the data transmission record contained in the target message according to the second hash string to obtain a first verification result; if the first verification result indicates that the second hash string is different from the first hash string, resending the target message to the receiving end through a message queue based on a timed task; if the first verification result indicates that the second hash string is the same as the first hash string, decrypting the encrypted file by the receiving end using the decryption key in the data transmission record contained in the target message, so that the receiving end receives financial data.
[0095] The processor can invoke information and applications stored in memory through the transmission device to perform the following steps: decrypting the encrypted file using the decryption key in the data transmission record contained in the target message so that the receiving end receives the financial data, including: decrypting the encrypted file using the decryption key to obtain a metadata file and financial data to be verified; performing an integrity check on the financial data to be verified based on the tag information in the metadata file to obtain a second verification result; if the second verification result indicates that the financial data to be verified is incomplete, re-acquiring the financial data to be sent and sending the re-acquiring financial data to the receiving end through the message queue of the message middleware; if the second verification result indicates that the financial data to be verified is complete, determining that the receiving end has received the financial data.
[0096] The processor can invoke information and applications stored in the memory via the transmission device to execute the following steps: After generating a data transmission record based on the decryption key, the encrypted file, the first hash string, and the message information, the method further includes: updating the message transmission record table in the preset storage space based on the data transmission record; after verifying the target message and decrypting the encrypted file based on the first verification result so that the receiving end receives the financial data, the method further includes: receiving a response message sent by the receiving end, wherein the response message indicates that the receiving end has received the financial data; and updating each field of the data record corresponding to the financial data in the message transmission record table based on the response message.
[0097] This application provides a data processing method. By determining the financial data to be sent, the financial data is encrypted to obtain an encrypted file. The encrypted file is then processed based on a message queue transmission format to generate a target message. The target message is sent to the message queue of a message middleware. The receiving end subscribes to the message queue of the message middleware, and upon detecting that the message queue has received the target message, it sends the target message to the receiving end through the message queue. The target message is verified, and the encrypted file is decrypted based on the first verification result, enabling the receiving end to receive the financial data. This solves the technical problem of low efficiency in financial data processing when financial institutions transmit financial data, due to heterogeneous data sources and the risk of data tampering, requiring developers to perform additional development and testing work.
[0098] Encrypting financial data effectively prevents the risk of data leakage and tampering during transmission, ensuring data security. Message queue-based transmission improves the stability and efficiency of data transmission. Simultaneously, transmitting encrypted data via message queues and decrypting it at the receiving end automates data push and reception confirmation, achieving automated verification and decryption during financial data transmission. This reduces the additional development and testing work required for developers to verify data transmission security and integrity, achieving the technical effect of enabling financial institutions to transmit financial data securely and efficiently in a domestically developed environment.
[0099] Those skilled in the art will understand that Figure 6 The structure shown is for illustrative purposes only. Electronic devices can also be smartphones, tablets, handheld computers, mobile internet devices (MIDs), PADs, and other terminal devices. Figure 6 This does not limit the structure of the aforementioned electronic device. For example, electronic devices may also include components that are more... Figure 6 The more or fewer components shown (such as network interfaces, display devices, etc.), or having the same Figure 6 The different configurations shown.
[0100] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be implemented by a program instructing the hardware related to the terminal device. The program can be stored in a computer-readable storage medium, which may include: flash drive, read-only memory (ROM), random access memory (RAM), disk or optical disk, etc.
[0101] Example 4
[0102] Embodiments of this application also provide a storage medium. Optionally, in this embodiment, the storage medium can be used to store the program code executed by the data processing method provided in Embodiment 1.
[0103] Optionally, in this embodiment, the storage medium may be located in any computer terminal in a group of computer terminals in a computer network, or in any mobile terminal in a group of mobile terminals.
[0104] This application also provides a computer program product, which, when executed on a data processing device, is a program adapted to perform data processing method steps.
[0105] The sequence numbers of the embodiments in this application are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.
[0106] In the above embodiments of this application, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0107] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. The device embodiments described above are merely illustrative; for example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the displayed or discussed mutual coupling, direct coupling, or communication connection may be through some interfaces; the indirect coupling or communication connection between units or modules may be electrical or other forms.
[0108] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0109] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0110] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as a USB flash drive, read-only memory (ROM), random access memory (RAM), portable hard drive, magnetic disk, or optical disk.
[0111] The above description is only a preferred embodiment of this application. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of this application, and these improvements and modifications should also be considered within the scope of protection of this application.< / fields> < / id> < / updatetime> < / createtime> < / size> < / doctype> < / filename>
Claims
1. A data processing method, characterized in that, include: The financial data to be sent is determined, the financial data is encrypted to obtain an encrypted file, and the encrypted file is processed based on the message queue transmission format to generate the target message; The target message is sent to the message queue of the message middleware, wherein the receiving end subscribes to the message queue of the message middleware, and after detecting that the message queue has received the target message, the target message is sent to the receiving end through the message queue; The target message is verified, and the encrypted file is decrypted based on the first verification result, so that the receiving end can receive the financial data.
2. The method according to claim 1, characterized in that, The financial data is encrypted to obtain an encrypted file, and the encrypted file is processed based on a message queue transmission format to generate a target message, including: After the approval process for the financial data is completed, the approval process flowchart, approval content, approval opinion, and approval form for the financial data are obtained to obtain the approval documents. Generate first metadata information of the approval document and second metadata information of the financial data, and write the first metadata information and the second metadata information into a file to obtain a metadata file; The financial data, the approval documents, and the metadata file are encrypted to obtain the encrypted file, and a decryption key for the encrypted file is generated using the national cryptographic algorithm. The encrypted file and the decryption key are processed based on the message queue transmission format to generate the target message.
3. The method according to claim 2, characterized in that, The encrypted file and the decryption key are processed based on the message queue transmission format to generate the target message, including: The encrypted file is processed based on a preset hash algorithm to obtain a first hash string; The message information to be sent is determined based on the financial data, wherein the message information includes at least: message identification information, message type, message sending remarks description, message status, message sending retries number, and message creation time; A data transmission record is generated based on the decryption key, the encrypted file, the first hash string, and the message information; The data transmission record is determined as the message header, the encrypted file is determined as the message body, and the target message is determined based on the message header and the message body.
4. The method according to claim 1, characterized in that, Sending the target message to the message queue of the message middleware includes: A communication connection with the message queue is established based on the configuration information of the message middleware, wherein the configuration information includes at least: the IP information, port information, and message queue configuration information of the message middleware; A file message object is created based on the file path address of the target message, wherein the attribute information of the file message object is in string form; A session object is created based on the communication connection, and the target message is sent to the message queue through the session object so that the target message can be sent to the receiving end through the message middleware.
5. The method according to claim 1, characterized in that, Verifying the target message and decrypting the encrypted file based on the first verification result, so that the receiving end receives the financial data, includes: The encrypted file contained in the target message is processed based on a preset hash algorithm to obtain a second hash string; The first hash string in the data transmission record contained in the target message is verified based on the second hash string to obtain the first verification result; If the first verification result indicates that the second hash string is different from the first hash string, the target message is resent to the receiving end through the message queue based on a scheduled task. If the first verification result indicates that the second hash string is the same as the first hash string, the receiving end decrypts the encrypted file using the decryption key in the data transmission record contained in the target message, so that the receiving end receives the financial data.
6. The method according to claim 5, characterized in that, The encrypted file is decrypted using the decryption key in the data transmission record contained in the target message, so that the receiving end can receive the financial data, including: The encrypted file is decrypted using the decryption key to obtain the metadata file and the financial data to be verified; The integrity of the financial data to be verified is checked based on the tag information in the metadata file to obtain a second verification result; If the second verification result indicates that the financial data to be verified is incomplete, the financial data to be sent is re-acquired and sent to the receiving end through the message queue of the message middleware. If the second verification result indicates that the financial data to be verified is complete, it is determined that the receiving end has received the financial data.
7. The method according to claim 3, characterized in that, After generating a data transmission record based on the decryption key, the encrypted file, the first hash string, and the message information, the method further includes: Update the message transmission record table in the preset storage space according to the data transmission records; After verifying the target message and decrypting the encrypted file based on the first verification result to enable the receiving end to receive the financial data, the method further includes: Receive a response message sent by the receiving end, wherein the response message indicates that the receiving end has received the financial data; The fields of the data records corresponding to the financial data in the message transmission record table are updated according to the response message.
8. A data processing apparatus, characterized in that, include: An encryption unit is used to determine the financial data to be sent, encrypt the financial data to obtain an encrypted file, and process the encrypted file based on a message queue transmission format to generate a target message. A sending unit is configured to send the target message to the message queue of a message middleware, wherein the receiving end subscribes to the message queue of the message middleware, and after detecting that the message queue has received the target message, the receiving end sends the target message to the receiving end through the message queue; The decryption unit is used to verify the target message and decrypt the encrypted file according to the first verification result, so that the receiving end can receive the financial data.
9. An electronic device, characterized in that, include: Memory, which stores executable programs; A processor for running the program, wherein the program, when running, performs the data processing method according to any one of claims 1 to 7.
10. A computer program product comprising computer instructions, characterized in that, When the computer instructions are executed by the processor, they implement the steps of the data processing method according to any one of claims 1 to 7.