Isomeric message transmission method, device, equipment and storage medium

By parsing heterogeneous messages into structured data and performing field verification and encryption during transmission, the problem of low transmission efficiency caused by multi-network element parsing and verification is solved, and efficient and secure message transmission is achieved.

CN115396228BActive Publication Date: 2025-10-24CCB FINTECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202211065799.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-01
Publication Date
2025-10-24
Estimated Expiration
2042-09-01

AI Technical Summary

Technical Problem

When transmitting heterogeneous messages across multiple networks, existing technologies require each network element to independently parse and verify security, resulting in long transmission time and low efficiency.

Method used

By acquiring heterogeneous messages and message configuration information, parsing them into structured data, and performing field verification and encryption in the first network element before transmission, subsequent network elements decrypt and encrypt according to the configuration information, reducing redundant verification and improving security by using point-to-point encryption.

Benefits of technology

It effectively reduces the transmission time of heterogeneous messages across multiple networks, improves transmission efficiency, and enhances the integrity and security of the transmission process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115396228B_ABST
    Figure CN115396228B_ABST
Patent Text Reader

Abstract

The application belongs to the technical field of data transmission, and particularly relates to a heterogeneous message transmission method, device and equipment and a storage medium. The heterogeneous message transmission method comprises the following steps: obtaining a first heterogeneous message and message configuration information, wherein the message configuration information comprises source message information, a field check rule and a field encryption rule; analyzing the first heterogeneous message according to the source message information to obtain structured data; performing security check on the structured data according to the field check rule; if the check is passed, encrypting the structured data according to the field encryption rule to obtain first ciphertext, and sending the first ciphertext to a second network element. The transmission efficiency of the heterogeneous message is improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application belongs to the technical field of data transmission, and particularly relates to a heterogeneous message transmission method and device, equipment and a storage medium. BACKGROUND

[0002] A message is a data unit exchanged and transmitted in a network, and contains complete data information to be sent. In order to ensure the security and integrity of the message, security check needs to be performed on the message in the process of message transmission.

[0003] In related technologies, if a transaction message passes through multiple different networks, a network element needs to be deployed in each network to parse and perform security check on the transaction message, so as to ensure the security and integrity of the message. Since each network element exists independently, each network element needs to parse and perform security check on the transaction message, which leads to a long transmission time and low transmission efficiency of the transaction message in multiple networks. SUMMARY

[0004] The present application provides a heterogeneous message transmission method, device, equipment and storage medium, which improves the transmission efficiency of the message.

[0005] In a first aspect, the present application provides a heterogeneous message transmission method, applied to a first network element, and the method comprises the following steps:

[0006] Obtaining a first heterogeneous message and message configuration information, wherein the message configuration information comprises source message information, field check rules and field encryption rules, and the source message information comprises a message format;

[0007] According to the source message information, the first heterogeneous message is parsed to obtain structured data;

[0008] Judging whether the message format of the structured data is consistent with the message format in the source message information;

[0009] If yes, the fields in the structured data are sequentially subjected to security check according to the field check rules;

[0010] If the check is passed, the structured data is encrypted according to the field encryption rules to obtain a first ciphertext;

[0011] The first ciphertext is sent to a second network element.

[0012] In a possible implementation, the number of the field check rules is N, and the N is an integer greater than 1; the security check on the structured data according to the field check rules comprises:

[0013] According to the first field check rule, the fields in the structured data are checked one by one for the first time;

[0014] If the (i-1)th security check is passed, the fields in the structured data are checked one by one for the ith time according to the ith field check rule;

[0015] Wherein, the i is taken as 2, 3, …, N in turn.

[0016] In a possible implementation, the structured data further comprises a parsing identifier; and sending the first ciphertext to the second network element comprises:

[0017] Sending the first ciphertext and the parsing identifier to the second network element, the parsing identifier being used to indicate that the second network element determines that the plaintext corresponding to the first ciphertext is structured data.

[0018] In a second aspect, the embodiments of the present application provide a heterogeneous message transmission method, applied to a second network element, the method comprising:

[0019] Receiving a first ciphertext sent by a first network element;

[0020] Obtaining message configuration information, the message configuration information comprising field decryption rules and field encryption rules;

[0021] Decrypting the first ciphertext according to the field decryption rules to obtain structured data;

[0022] Encrypting the structured data according to the field encryption rules to obtain a second ciphertext;

[0023] Sending the second ciphertext to a third network element.

[0024] In a possible implementation, the message configuration information further comprises target message information; and encrypting the structured data according to the field encryption rules to obtain a second ciphertext comprises:

[0025] Converting the structured data into a target message according to the target message information;

[0026] Encrypting the target message according to the field encryption rules to obtain a second ciphertext.

[0027] In a possible implementation, the message configuration information comprises association information; and sending the second ciphertext to a third network element comprises:

[0028] According to the association information, determining whether the target message is associated with other transactions;

[0029] If yes, sending the second ciphertext and the associated transactions to the third network element.

[0030] In a possible implementation, the message configuration information includes a field encryption rule; the structured data is encrypted according to the field encryption rule to obtain second ciphertext; and the method comprises:

[0031] According to the field verification rule, the fields in the structured data are verified one by one;

[0032] If the verification is passed, the structured data is encrypted according to the field encryption rule to obtain the second ciphertext.

[0033] In a possible implementation, the first ciphertext is decrypted according to the field decryption rule to obtain structured data; and the method comprises:

[0034] Receiving an analysis identifier sent by a first network element;

[0035] Decrypting the first ciphertext according to the field decryption rule to obtain plaintext;

[0036] According to the analysis identifier, it is determined that the plaintext is the structured data.

[0037] In a third aspect, an embodiment of the present application provides a heterogeneous message transmission device, comprising an obtaining module, an analysis module, a verification module, an encryption module and a sending module, wherein,

[0038] The obtaining module is configured to obtain a first heterogeneous message and message configuration information, wherein the message configuration information comprises source message information, a field verification rule and a field encryption rule, and the source message information comprises a message format;

[0039] The analysis module is configured to analyze the first heterogeneous message according to the source message information to obtain structured data;

[0040] The verification module is configured to determine whether the message format of the structured data is consistent with the message format in the source message information; if yes, the fields in the structured data are verified one by one according to the field verification rule;

[0041] The encryption module is configured to, if the verification is passed, encrypt the structured data according to the field encryption rule to obtain first ciphertext;

[0042] The sending module is configured to send the first ciphertext to a second network element.

[0043] In a fourth aspect, an embodiment of the present application provides a heterogeneous message transmission device, comprising a receiving module, an obtaining module, a decryption module, an encryption module and a sending module, wherein,

[0044] The receiving module is configured to receive the first ciphertext sent by the first network element.

[0045] The obtaining module is configured to obtain message configuration information, wherein the message configuration information comprises a field decryption rule and a field encryption rule.

[0046] The decryption module is configured to decrypt the first ciphertext according to the field decryption rule to obtain structured data.

[0047] The encryption module is configured to encrypt the structured data according to the field encryption rule to obtain a second ciphertext.

[0048] The sending module is configured to send the second ciphertext to a third network element.

[0049] In a fifth aspect, an electronic device is provided, comprising a processor and a memory.

[0050] The memory stores computer-executed instructions.

[0051] The processor executes the computer-executed instructions stored in the memory, so that the processor executes the heterogeneous message transmission method according to any one of the first aspect or the heterogeneous message transmission method according to any one of the second aspect.

[0052] In a sixth aspect, a computer-readable storage medium is provided, and the computer-readable storage medium stores computer-executed instructions. When the computer-executed instructions are executed by a processor, the computer-executed instructions are used to implement the heterogeneous message transmission method according to any one of the first aspect or the heterogeneous message transmission method according to any one of the second aspect.

[0053] In a seventh aspect, a computer program product is provided, and the computer program product comprises a computer program. When the computer program is executed by a processor, the computer program can implement the heterogeneous message transmission method according to any one of the first aspect or the heterogeneous message transmission method according to any one of the second aspect.

[0054] The present application provides a method, apparatus, device and storage medium for transmitting heterogeneous messages. A first network element obtains a first heterogeneous message and message configuration information, wherein the message configuration information includes source message information, field verification rules and field encryption rules. According to the source message information, the first heterogeneous message is parsed to obtain structured data. The source message information includes a message format, and it is determined whether the message format of the structured data is consistent with the message format in the source message information. If so, the fields in the structured data are security-verified one by one according to the field verification rules. If the verification passes, the structured data is encrypted according to the field encryption rules to obtain a first ciphertext, and the first ciphertext is sent to the second network element. Heterogeneous messages are transmitted in each network element through structured data, which effectively reduces repeated verification, reduces the transmission time of heterogeneous messages in multiple networks, and improves the transmission efficiency of heterogeneous messages. BRIEF DESCRIPTION OF THE DRAWINGS

[0055] Figure 1 A schematic diagram of an application scenario provided in an embodiment of the present application;

[0056] Figure 2 A schematic diagram of a heterogeneous message transmission method provided in an embodiment of the present application Figure 1 ;

[0057] Figure 3 A schematic diagram of a heterogeneous message transmission method provided in an embodiment of the present application Figure 2 ;

[0058] Figure 4 A schematic diagram of a heterogeneous message transmission method provided in an embodiment of the present application Figure 3 ;

[0059] Figure 4 Schematic diagram of the process of heterogeneous message transmission method provided in the embodiment of the present application Figure 5 ;

[0060] Figure 6 A schematic diagram of the structure of a heterogeneous message transmission device provided in an embodiment of the present application;

[0061] Figure 7 A schematic structural diagram of another heterogeneous message transmission device provided in an embodiment of the present application;

[0062] Figure 8 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0063] In order to make the purposes, technical solutions and advantages of the present application clearer, the technical solutions in the embodiments of the present application will be described clearly and completely below in conjunction with the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by a person of ordinary skill in the art without creative work fall within the scope of protection of the present application.

[0064] The collection, storage, use, processing, transmission, provision and disclosure of information such as financial data or user data involved in the embodiments of the present application all comply with the provisions of relevant laws and regulations and do not violate public order and good customs.

[0065] For the convenience of understanding, the concepts involved in the embodiments of the present application are described below.

[0066] 1, Heterogeneous message

[0067] The transaction message data composed of non-uniform fixed formats, such as JSON, XML and TXT format data.

[0068] 2, Structured data

[0069] Also known as row data, it is data logically expressed and implemented by two-dimensional table structure, strictly following the data format and length specification, mainly stored and managed by a relational database.

[0070] 3, Non-secure network

[0071] It refers to a network environment not completely controlled by the user, such as the Internet.

[0072] 4, Secure network

[0073] It refers to a network environment completely controlled by the user, such as an intranet.

[0074] It should be noted that the terms "first", "second" and the like involved in the embodiments of the present application are only used for the purpose of distinguishing description, and cannot be understood as indicating or implying relative importance, nor can it be understood as indicating or implying order.

[0075] The application scenarios to which the embodiments of the present application are applicable will be described below in conjunction with Figure 1

[0076] Figure 1 An application scenario schematic diagram provided by the embodiments of the present application. Please refer to Figure 1 ​, including a first network element and a second network element. The first network element is located in a non-secure network environment, and the second network element is located in a secure network environment. The first network element can transmit a heterogeneous message to the second network element. After receiving the heterogeneous message, the second network element can process the heterogeneous message and then forward the processed heterogeneous message to other network elements to complete service processing. A firewall can be deployed between the non-secure network environment and the secure network environment.

[0077] A plurality of first network elements can be deployed in the non-secure network environment, and a plurality of second network elements can be deployed in the secure network environment. The plurality of network elements are cascaded, and a firewall can be deployed between adjacent network elements. The number of network elements deployed in the embodiments of the present application is not limited.

[0078] In the related art, each network element is deployed independently, and each network element needs to analyze and perform security verification on the heterogeneous message, which results in a long transmission time and low transmission efficiency of the heterogeneous message in multiple networks.

[0079] Therefore, the embodiments of the present application propose a heterogeneous message transmission method. The network elements are cascaded, and each network element does not need to analyze and perform security verification on the heterogeneous message. The heterogeneous message is transmitted through structured data in each network element, which effectively reduces repeated verification, reduces the transmission time of the heterogeneous message in multiple networks, and improves the transmission efficiency of the heterogeneous message.

[0080] In the following, the technical solutions shown in the present application are described in detail through specific embodiments. It should be noted that the following embodiments can exist independently or in combination. For the same or similar concepts or processes, some embodiments can not be described again.

[0081] Figure 2 Flowchart of a heterogeneous message transmission method provided by the embodiments of the present application Figure 1 Please refer to Figure 2 The method can include the following steps.

[0082] S201, a first heterogeneous message and message configuration information are obtained. The message configuration information includes source message information, field verification rules, and field encryption rules.

[0083] The execution subject of the present application can be a network element. The network element can be a hardware device or a heterogeneous message transmission device arranged in the hardware device. The heterogeneous message transmission device can be implemented by software or by a combination of software and hardware. Optionally, the network element can be implemented by one hardware device or by multiple hardware devices.

[0084] The first heterogeneous message can be generated by the first network element or by another device and sent to the network element.

[0085] The message configuration information can be configured by the first network element, or configured by another network element in the cascaded deployment, for example, configured by the second network element, or configured by a third party outside the cascaded deployment.

[0086] When any network element in the cascaded deployment wants to use the message configuration information, the message configuration information can be loaded from the local, another network element or a third party. All network elements in the cascaded deployment can use the loaded message configuration information, that is, all network elements in the cascaded deployment correspond to the same message configuration information provider. One configuration is implemented everywhere, and all network elements in the cascaded deployment use unified configuration, which greatly reduces the configuration maintenance and change cost.

[0087] The message configuration information can include configuration information of multiple messages. For example, the message configuration information can include configuration information of three messages, and each message configuration information has a specific identifier.

[0088] When the first network element obtains the first heterogeneous message, the corresponding message configuration information can be loaded through the identifier of the first heterogeneous message. If the message configuration information does not exist, it is identified that the transaction corresponding to the current first heterogeneous message is illegal, and the transaction is directly rejected.

[0089] The source message information can include source message structure, field information and message format.

[0090] The field encryption rule can include a length verification rule, a data type verification rule and a pattern verification rule.

[0091] The field encryption rule can be a national encryption rule or an advanced encryption standard (AES) rule, which is not limited in the embodiments of the present application.

[0092] S202, according to the source message information, the first heterogeneous message is parsed to obtain structured data.

[0093] According to the source message information, the first heterogeneous message including multiple formats can be converted into structured data in a unified format.

[0094] For example, the first heterogeneous message can include data in JSON, XML and TXT formats. According to the source message information, the first heterogeneous message in the three formats can be converted into structured data in XML format.

[0095] The structured data can carry a parsing identifier, and the parsing identifier is used to indicate that the second network element determines that the plaintext corresponding to the first ciphertext is the structured data.

[0096] S203, according to the field verification rule, the structured data is subjected to security verification.

[0097] In a possible implementation, it can be judged whether the message format of the structured data is consistent with the message format in the source message information, and if so, the fields in the structured data are checked one by one according to the field checking rule.

[0098] If the verification passes, S204 is performed.

[0099] If the verification fails, the transaction corresponding to the first heterogeneous message is rejected.

[0100] S204, the structured data is encrypted according to the field encryption rule to obtain the first ciphertext.

[0101] For example, the structured data can be encrypted according to the national secret to obtain the first ciphertext.

[0102] S205, the first ciphertext is sent to the second network element.

[0103] The first network element can call a specific interface to send the first ciphertext to the second network element, or can send the first ciphertext to the second network element according to the link connection mode.

[0104] In order to ensure the security of data transmission, the first network element can also sign the first ciphertext before sending the first ciphertext.

[0105] The second network element and the first network element can be located in the same network environment, or can be located in different network environments.

[0106] S206, message configuration information is obtained, and the message configuration information includes the field decryption rule and the field encryption rule.

[0107] After the second network element receives the first ciphertext, the corresponding message configuration information can be loaded according to the unique identifier of the first ciphertext. If the message configuration information does not exist, it is identified that the transaction corresponding to the first ciphertext is illegal, and the transaction is directly rejected. The unique identifier of the first ciphertext can be the same as the identifier of the first heterogeneous message.

[0108] S207, the first ciphertext is decrypted according to the field decryption rule to obtain the structured data.

[0109] The field decryption rule used by the second network element can correspond to the field encryption rule used by the first network element. For example, if the AES encryption rule used by the first network element is used to encrypt the structured data to obtain the first ciphertext, the second network element needs to use the corresponding AES decryption rule to decrypt the first ciphertext to obtain the structured data.

[0110] S208, the structured data is encrypted according to the field encryption rule to obtain the second ciphertext.

[0111] The field encryption rule used by the second network element can be different from the field encryption rule used by the first network element. For example, if the first network element uses national secret encryption, the second network element can use AES encryption.

[0112] S209, sending the second ciphertext to the third network element.

[0113] The third network element can be a network element in cascaded deployment or a transaction network element.

[0114] If the third network element is a network element in cascaded deployment, it functions to transmit heterogeneous messages in the form of structured data, and the processing manner in the third network element can refer to the processing manner in the second network element. If the third network element is a transaction network element, it functions to complete the transaction content corresponding to the heterogeneous message.

[0115] In Figure 2 In the embodiment shown in the figure, the first network element obtains a first heterogeneous message and message configuration information, the message configuration information including source message information, a field verification rule, and a field encryption rule; according to the source message information, the first heterogeneous message is parsed to obtain structured data; according to the field verification rule, the structured data is subjected to security verification; if the verification is passed, the structured data is encrypted according to the field encryption rule to obtain a first ciphertext, and the first ciphertext is sent to the second network element. The second network element receives the first ciphertext sent by the first network element, and obtains the message configuration information, the message configuration information including a field decryption rule and a field encryption rule; according to the field decryption rule, the first ciphertext is decrypted to obtain structured data; according to the field encryption rule, the structured data is encrypted to obtain a second ciphertext; and the second ciphertext is sent to the third network element. The heterogeneous message is transmitted through structured data in each network element, effectively reducing repeated verification, reducing the transmission time of the heterogeneous message in multiple networks, and improving the transmission efficiency of the heterogeneous message. At the same time, point-to-point encryption is used between network elements, improving the integrity and security of the heterogeneous message in the transmission process.

[0116] Figure 2 The embodiment shown in the figure illustrates a transmission method of heterogeneous messages before network elements in cascaded deployment. When the network elements are located in different positions, their processing manners of the heterogeneous messages are different. Next, the processing manner of the first network element in cascaded deployment is described with reference to Figure 3 The processing manner of the second network element in a non-secure network environment is described with reference to Figure 4 The processing manner of the last network element in cascaded deployment is described with reference to Figure 5 The processing manner of the last network element in cascaded deployment is described with reference to

[0117] Figure 3A heterogeneous message transmission method provided by an embodiment of the present application Figure 2 . Please refer to Figure 3 , the method can comprise:

[0118] S301, acquire a first heterogeneous message and message configuration information, the message configuration information comprises source message information, field verification rules and field encryption rules.

[0119] It should be noted that the execution process of S301 can refer to the execution process of S201, which will not be repeated here.

[0120] S302, according to the source message information, parse the first heterogeneous message to obtain structured data.

[0121] It should be noted that the execution process of S302 can refer to the execution process of S202, which will not be repeated here.

[0122] S303, the source message information includes message format, judge whether the message format of the structured data is consistent with the message format in the source message information.

[0123] If yes, execute S304.

[0124] If not, reject the transaction corresponding to the first heterogeneous message.

[0125] S304, according to the field verification rules, security check is performed on the structured data.

[0126] The number of field verification rules can be 1, or N, N is an integer greater than 1.

[0127] When the number of field verification rules is 1, the structured data can be security checked by the following way: according to the field verification rules, security check is performed on the fields in the structured data one by one.

[0128] When the number of field verification rules is N, the structured data can be security checked by the following way:

[0129] According to the first field verification rule, security check is performed on the fields in the structured data one by one; if the i-1th security check is passed, the i th security check is performed on the fields in the structured data one by one according to the i th field verification rule; wherein, the i is taken 2, 3, …, N in turn.

[0130] If the check is passed, execute S305.

[0131] If the check is not passed, reject the transaction corresponding to the first heterogeneous message.

[0132] For example, if the number of field check rules is 3, the first field check rule is used to perform the first security check on the fields in the structured data one by one, if the first security check fails, the transaction corresponding to the first heterogeneous message is rejected, if the first security check passes, the second field check rule is used to perform the second security check on the fields in the structured data one by one, if the second security check fails, the transaction corresponding to the first heterogeneous message is rejected, if the second security check passes, the third field check rule is used to perform the third security check on the fields in the structured data one by one, if the third security check fails, the transaction corresponding to the first heterogeneous message is rejected, if the third security check passes, S305 is executed.

[0133] S305, encrypt the structured data according to the field encryption rule to obtain the first ciphertext.

[0134] It should be noted that the execution process of S305 can refer to the execution process of S204, which will not be repeated here.

[0135] S306, send the first ciphertext to the second network element.

[0136] The transmission mode of the first ciphertext between the network elements in the cascaded deployment has the following two modes:

[0137] 1. The first ciphertext can be transmitted by calling a specific interface, and the interface only transmits the parsed data, that is, the interface only transmits the structured data.

[0138] 2. The first ciphertext can be transmitted according to the link connection mode.

[0139] Specifically, the first network element parses the first heterogeneous message to obtain structured data and a parsing identifier, and the structured data is sent to the second network element together with the parsing identifier after security check and encryption; the second network element determines whether the first ciphertext carries the parsing identifier to determine whether the plaintext corresponding to the first ciphertext needs to be parsed; if the first ciphertext carries the parsing identifier, it means that the plaintext corresponding to the first ciphertext is structured data and does not need to be parsed; if the first ciphertext does not carry the parsing identifier, it means that the plaintext corresponding to the first ciphertext is not structured data and needs to be parsed.

[0140] In Figure 3In the illustrated embodiment, the first network element acquires a first heterogeneous message and message configuration information, the message configuration information including source message information, field check rules and field encryption rules; according to the source message information, the first heterogeneous message is parsed to obtain structured data; the source message information includes message format, and it is judged whether the message format of the structured data is consistent with the message format in the source message information; if not, the transaction corresponding to the first heterogeneous message is rejected; if yes, the structured data is subjected to security check according to the field check rules; if the check passes, the structured data is encrypted according to the field encryption rules to obtain a first ciphertext; and the first ciphertext is sent to the second network element. Only the first network element in the cascaded deployment needs to parse and security check the heterogeneous message, and other network elements do not need to parse the message again, thereby improving the transmission efficiency of the heterogeneous message. Meanwhile, the point-to-point encryption mode is used between the network elements, thereby improving the integrity and security of the heterogeneous message in the transmission process.

[0141] Figure 4 Flowchart of a heterogeneous message transmission method provided by an embodiment of the application Figure 3 . Please refer to Figure 4 Taking the second network element being in a non-secure network environment as an example, the method can include:

[0142] S401, receiving a first ciphertext sent by a first network element.

[0143] The second network element can receive the first ciphertext through a specific interface or through a link connection mode.

[0144] Figure 4 The second network element in the illustrated embodiment is located in the middle position of the cascaded deployment.

[0145] S402, acquiring message configuration information, the message configuration information including field decryption rules and field encryption rules.

[0146] It should be noted that the execution process of S402 can refer to the execution process of S206, which will not be described here.

[0147] S403, decrypting the first ciphertext according to the field decryption rules to obtain structured data.

[0148] If the first ciphertext is received through a specific interface, the plaintext after decryption of the first ciphertext can be directly determined as the structured data.

[0149] If the first ciphertext is received through a link connection mode, it is necessary to determine whether the plaintext after decryption of the first ciphertext is the structured data through the following way:

[0150] receiving the parsing identifier sent by the first network element; decrypting the first ciphertext according to the field decryption rule to obtain plaintext; and determining that the plaintext is the structured data according to the parsing identifier.

[0151] For example, if the second network element receives the first ciphertext through link connection, the first ciphertext is decrypted according to the field decryption rule to obtain plaintext, and then it is determined whether the second network element receives the parsing identifier. If there is a parsing identifier, it is determined that the plaintext is structured data. If there is no parsing identifier, the plaintext needs to be parsed to be converted into structured data.

[0152] S404, the message configuration information includes a field check rule, and the structured data is subjected to security check according to the field check rule.

[0153] For the network element in the non-secure network environment, no matter where the network element is located in the cascade deployment, the network element needs to be subjected to security check. The specific process of security check can be referred to the execution process of S304, which will not be described herein.

[0154] For the second network element in the secure network environment, the network element does not need to be subjected to security check.

[0155] S405, the structured data is encrypted according to the field encryption rule to obtain second ciphertext.

[0156] It should be noted that the execution process of S405 can be referred to the execution process of S208, which will not be described herein.

[0157] S406, the second ciphertext is sent to the third network element.

[0158] The third network element, the first network element and the second network element are located in the same network environment, or can be located in different network environments, and the third network element can be a network element in the cascade deployment.

[0159] Figure 5 In the illustrated embodiment, when the second network element is in the non-secure network environment, the second network element receives the first ciphertext sent by the first network element; obtains message configuration information including a field decryption rule and a field encryption rule; decrypts the first ciphertext according to the field decryption rule to obtain structured data; the message configuration information includes a field check rule, and the structured data is subjected to security check according to the field check rule; the structured data is encrypted according to the field encryption rule to obtain second ciphertext; and the second ciphertext is sent to the third network element. The heterogeneous message is transmitted through structured data in each network element, effectively reducing repeated check, reducing transmission time of the heterogeneous message in multiple networks, and improving transmission efficiency of the heterogeneous message. At the same time, point-to-point encryption mode is used between network elements, improving the integrity and security of the heterogeneous message in the transmission process.

[0160] Figure 4 Flowchart of the heterogeneous message transmission method provided by the embodiment of the present application Figure 5 . Please refer to Figure 5 Taking the second network element as an example, the method can comprise the following steps:

[0161] S501, receiving the first ciphertext sent by the first network element.

[0162] It should be noted that the execution process of S501 can refer to the execution process of S401, which will not be repeated here.

[0163] S502, obtaining message configuration information, wherein the message configuration information comprises field decryption rules and field encryption rules.

[0164] It should be noted that the execution process of S502 can refer to the execution process of S402, which will not be repeated here.

[0165] S503, decrypting the first ciphertext according to the field decryption rules to obtain structured data.

[0166] It should be noted that the execution process of S503 can refer to the execution process of S403, which will not be repeated here.

[0167] S504, the message configuration information further comprises target message information, and the structured data is converted into a target message according to the target message information.

[0168] The target message information can comprise the type of the target message and the transmission address of the target message.

[0169] The structured data can be converted into the target message according to the type of the target message.

[0170] S505, encrypting the target message according to the field encryption rules to obtain second ciphertext.

[0171] The encryption process can refer to the execution process of S405, which will not be repeated here.

[0172] S506, the message configuration information comprises association information, and it is judged whether the target message is associated with other transactions according to the association information.

[0173] If yes, S507 is executed.

[0174] If no, S508 is executed.

[0175] S507, sending the associated transaction to a third network element.

[0176] The associated transaction can be sent to the third network element according to the transmission address of the target message.

[0177] S508. Send the second ciphertext to the third network element.

[0178] The second ciphertext may be sent to the third network element according to the transmission address of the target message.

[0179] The third network element may be a transaction network element, which may receive the second ciphertext, decrypt it, and execute a corresponding transaction.

[0180] If the target message has an associated transaction, the third network element needs to check whether the associated transaction has been completed before executing the transaction corresponding to the target message. If the associated transaction is completed, the transaction corresponding to the target message can be executed; if the associated transaction is not completed, the transaction corresponding to the target message will be refused to be executed.

[0181] exist Figure 6 In the illustrated embodiment, when the second network element is the last network element in a cascaded deployment, the second network element receives a first ciphertext sent by the first network element; obtains message configuration information, which includes field decryption rules and field encryption rules; decrypts the first ciphertext according to the field decryption rules to obtain structured data; the message configuration information also includes target message information; based on the target message information, the structured data is converted into a target message; the target message is encrypted according to the field encryption rules to obtain a second ciphertext; the message configuration information includes association information; based on the association information, it determines whether the target message is associated with other transactions; if so, the associated transaction is first sent to the third network element, followed by the second ciphertext; if not, the second ciphertext is sent to the third network element. Heterogeneous messages are transmitted within each network element using structured data, effectively reducing duplicate checks, shortening the transmission time of heterogeneous messages across multiple networks, and improving the transmission efficiency of heterogeneous messages. Furthermore, point-to-point encryption is used between network elements, improving the integrity and security of heterogeneous messages during transmission.

[0182] All network elements in the cascade deployment have the same structure, but the specific content they execute varies depending on the location of the network element.

[0183] Based on any of the above embodiments, the above heterogeneous message transmission method is described below with examples.

[0184] Example 1

[0185] Two network elements are deployed in cascade, with the first network element located in an insecure network environment and the second network element located in a secure network environment.

[0186] The first network element obtains a first heterogeneous message and message configuration information, the message configuration information including source message information, field check rules and field encryption rules; the first heterogeneous message is parsed according to the source message information to obtain structured data; the source message information includes a message format, and it is judged whether the message format of the structured data is consistent with the message format in the source message information; if not, the transaction corresponding to the first heterogeneous message is rejected; if yes, the structured data is subjected to security check according to the field check rules; if the check fails, the transaction corresponding to the first heterogeneous message is rejected; if the check passes, the structured data is encrypted according to the field encryption rules to obtain a first ciphertext; and the first ciphertext is sent to the second network element.

[0187] The second network element receives the first ciphertext sent by the first network element; obtains message configuration information, the message configuration information including field decryption rules, field encryption rules and target message information; the first ciphertext is decrypted according to the field decryption rules to obtain structured data; the structured data is converted into a target message according to the target message information; the target message is encrypted according to the field encryption rules to obtain a second ciphertext; the message configuration information includes association information, and it is judged according to the association information whether the target message is associated with other transactions; if yes, the associated transaction is sent to the transaction network element first, and then the second ciphertext is sent; if not, the second ciphertext is sent to the transaction network element.

[0188] The transaction network element needs to check whether the target message is associated with other transactions before executing the transaction corresponding to the target message, and determine whether the associated transaction has been completed, if the associated transaction is completed, the transaction corresponding to the target message can be executed; if the associated transaction is not completed, the transaction corresponding to the target message is rejected.

[0189] The heterogeneous message is transmitted through structured data in each network element, which effectively reduces repeated check, reduces transmission time of the heterogeneous message in multiple networks, and improves transmission efficiency of the heterogeneous message. At the same time, point-to-point encryption mode is used between network elements, which improves the integrity and security of the heterogeneous message in the transmission process.

[0190] Example 2

[0191] The three network elements are deployed in cascade, the first network element and the second network element are located in a non-secure network environment, and the third network element is located in a secure network environment.

[0192] The first network element obtains a first heterogeneous message and message configuration information, the message configuration information including source message information, field check rules and field encryption rules; according to the source message information, the first heterogeneous message is parsed to obtain structured data; the source message information includes a message format, and it is judged whether the message format of the structured data is consistent with the message format in the source message information; if not, the transaction corresponding to the first heterogeneous message is rejected; if yes, the structured data is subjected to security check according to the field check rules; if the check fails, the transaction corresponding to the first heterogeneous message is rejected; if the check passes, the structured data is encrypted according to the field encryption rules to obtain a first ciphertext; and the first ciphertext is sent to the second network element.

[0193] The second network element receives the first ciphertext sent by the first network element; obtains message configuration information, the message configuration information including field decryption rules, field encryption rules and field check rules; the first ciphertext is decrypted according to the field decryption rules to obtain structured data; the structured data is subjected to security check according to the field check rules; if the check fails, the transaction corresponding to the first heterogeneous message is rejected; if the check passes, the structured data is encrypted according to the field encryption rules to obtain a second ciphertext; and the second ciphertext is sent to the third network element.

[0194] The third network element receives the second ciphertext sent by the second network element; obtains message configuration information, the message configuration information including field decryption rules, field encryption rules and target message information; the second ciphertext is decrypted according to the field decryption rules to obtain structured data; the structured data is converted into a target message according to the target message information; the target message is encrypted according to the field encryption rules to obtain a third ciphertext; the message configuration information includes association information, and according to the association information, it is judged whether the target message is associated with other transactions; if yes, the associated transaction is sent to the transaction network element first, and then the third ciphertext is sent; if not, the third ciphertext is sent to the transaction network element.

[0195] Before executing the transaction corresponding to the target message, the transaction network element needs to check whether the target message is associated with other transactions and determine whether the associated transaction has been completed, and if the associated transaction is completed, the transaction corresponding to the target message can be executed; if the associated transaction is not completed, the transaction corresponding to the target message is rejected.

[0196] The heterogeneous message is transmitted through structured data in each network element, effectively reducing repeated check, reducing transmission time of the heterogeneous message in multiple networks, and improving transmission efficiency of the heterogeneous message. At the same time, point-to-point encryption mode is used between network elements, improving the integrity and security of the heterogeneous message in the transmission process.

[0197] Example 3

[0198] The three network elements are deployed in cascade, the first network element is located in a non-secure network environment, and the second network element and the third network element are located in a secure network environment.

[0199] The first network element obtains a first heterogeneous message and message configuration information, the message configuration information including source message information, field check rules and field encryption rules; according to the source message information, the first heterogeneous message is parsed to obtain structured data; the source message information includes a message format, and it is judged whether the message format of the structured data is consistent with the message format in the source message information; if not, the transaction corresponding to the first heterogeneous message is rejected; if yes, the structured data is subjected to security check according to the field check rules; if the check fails, the transaction corresponding to the first heterogeneous message is rejected; if the check passes, the structured data is encrypted according to the field encryption rules to obtain a first ciphertext; and the first ciphertext is sent to a second network element.

[0200] The second network element receives the first ciphertext sent by the first network element; obtains message configuration information, the message configuration information including field decryption rules and field encryption rules; the first ciphertext is decrypted according to the field decryption rules to obtain structured data; the structured data is encrypted according to the field encryption rules to obtain a second ciphertext; and the second ciphertext is sent to a third network element.

[0201] The third network element receives the second ciphertext sent by the second network element; obtains message configuration information, the message configuration information including field decryption rules, field encryption rules and target message information; the second ciphertext is decrypted according to the field decryption rules to obtain structured data; the structured data is converted into a target message according to the target message information; the target message is encrypted according to the field encryption rules to obtain a third ciphertext; the message configuration information includes association information, and it is judged according to the association information whether the target message is associated with other transactions; if yes, the associated transaction is sent to a transaction network element first, and then the third ciphertext is sent; if not, the third ciphertext is sent to the transaction network element.

[0202] Before executing the transaction corresponding to the target message, the transaction network element needs to check whether the target message is associated with other transactions and determine whether the associated transaction has been completed, and if the associated transaction is completed, the transaction corresponding to the target message can be executed; if the associated transaction is not completed, the transaction corresponding to the target message is rejected.

[0203] The heterogeneous message is transmitted through structured data in each network element, which effectively reduces repeated check, reduces the transmission time of the heterogeneous message in multiple networks, and improves the transmission efficiency of the heterogeneous message. At the same time, the point-to-point encryption mode is used between the network elements, which improves the integrity and security of the heterogeneous message in the transmission process.

[0204] Figure 6 A structure diagram of a heterogeneous message transmission device provided by the embodiment of the application is shown. Please refer to Figure 7The heterogeneous message transmission device 10 comprises an acquisition module 11, an analysis module 12, a verification module 13, an encryption module 14 and a sending module 15, wherein

[0205] The acquisition module 11 is configured to acquire a first heterogeneous message and message configuration information, wherein the message configuration information comprises source message information, a field verification rule and a field encryption rule.

[0206] The analysis module 12 is configured to analyze the first heterogeneous message according to the source message information to obtain structured data.

[0207] The verification module 13 is configured to perform security verification on the structured data according to the field verification rule.

[0208] The encryption module 14 is configured to, if the verification passes, encrypt the structured data according to the field encryption rule to obtain first ciphertext.

[0209] The sending module 15 is configured to send the first ciphertext to a second network element.

[0210] In a possible implementation, the source message information comprises a message format; and the verification module 13 is specifically configured to:

[0211] determine whether the message format of the structured data is consistent with the message format in the source message information;

[0212] if yes, perform security verification on the structured data according to the field verification rule.

[0213] In a possible implementation, the number of the field verification rules is 1; and the verification module 13 is specifically configured to:

[0214] perform security verification on the fields in the structured data one by one according to the field verification rule.

[0215] In a possible implementation, the number of the field verification rules is N, wherein N is an integer greater than 1; and the verification module 13 is specifically configured to:

[0216] perform first security verification on the fields in the structured data one by one according to the first field verification rule;

[0217] if the i-1th security verification passes, perform i-th security verification on the fields in the structured data one by one according to the i-th field verification rule;

[0218] wherein the i is 2, 3, …, N in turn.

[0219] In a possible implementation, the structured data further comprises a parsing identifier; and the sending module 15 is specifically configured to:

[0220] send the first ciphertext and the parsing identifier to a second network element, where the parsing identifier is used to instruct the second network element to determine that the plaintext corresponding to the first ciphertext is structured data.

[0221] The heterogeneous message transmission device 10 provided by the embodiments of the present application can execute the technical solutions shown in the method embodiments, and the implementation principles and beneficial effects are similar, which will not be repeated here.

[0222] Figure 7 Another structure diagram of a heterogeneous message transmission device provided by the embodiments of the present application is provided. Please refer to Figure 8 The heterogeneous message transmission device 20 comprises a receiving module 21, an obtaining module 22, a decryption module 23, an encryption module 24 and a sending module 25, wherein,

[0223] The receiving module 21 is configured to receive a first ciphertext sent by a first network element.

[0224] The obtaining module 22 is configured to obtain message configuration information, where the message configuration information comprises field decryption rules and field encryption rules.

[0225] The decryption module 23 is configured to decrypt the first ciphertext according to the field decryption rules to obtain structured data.

[0226] The encryption module 24 is configured to encrypt the structured data according to the field encryption rules to obtain a second ciphertext.

[0227] The sending module 25 is configured to send the second ciphertext to a third network element.

[0228] In a possible implementation, the message configuration information further comprises target message information; and the encryption module 24 is specifically configured to:

[0229] convert the structured data into target messages according to the target message information.

[0230] encrypt the target messages according to the field encryption rules to obtain a second ciphertext.

[0231] In a possible implementation, the message configuration information comprises association information; and the sending module 25 is specifically configured to:

[0232] determine whether the target messages are associated with other transactions according to the association information.

[0233] If yes, send the associated transactions and the second ciphertext to the third network element.

[0234] In a possible implementation, the message configuration information includes a field verification rule; and the encryption module 24 is specifically configured to:

[0235] perform security verification on the structured data according to the field verification rule;

[0236] if the verification is passed, encrypt the structured data according to the field encryption rule to obtain the second ciphertext.

[0237] In a possible implementation, the decryption module 23 is specifically configured to:

[0238] receive an analysis identifier sent by a first network element;

[0239] decrypt the first ciphertext according to the field decryption rule to obtain plaintext;

[0240] determine, according to the analysis identifier, that the plaintext is the structured data.

[0241] The heterogeneous message transmission apparatus 20 provided by the embodiments of the present application can execute the technical solutions shown in the method embodiments, and the implementation principles and beneficial effects are similar, which will not be repeated here.

[0242] Figure 8 A structural schematic diagram of an electronic device provided by the embodiments of the present application is shown in FIG. 3. Figure 8 The electronic device 30 can include a transceiver 31, a memory 32, and a processor 33. The transceiver 31 can include a transmitter and / or a receiver. The transmitter can also be referred to as a sender, a transmitter, a sending port, a sending interface, or the like. The receiver can also be referred to as a receiver, a receiver, a receiving port, a receiving interface, or the like. The transceiver 31, the memory 32, and the processor 33 are connected to each other through a bus 34.

[0243] The memory 32 is configured to store program instructions.

[0244] The processor 33 is configured to execute the program instructions stored in the memory, so that the electronic device 30 executes any of the heterogeneous message transmission methods shown above.

[0245] The transceiver 31 is configured to perform the transceiving function of the electronic device 30.

[0246] ​ The electronic device shown in the embodiments can execute the technical solutions shown in the method embodiments, and the implementation principles and beneficial effects are similar, which will not be repeated here.

[0247] The embodiment of the present application provides a computer readable storage medium, the computer readable storage medium stores computer execution instructions, and the computer execution instructions are used for realizing the heterogeneous message transmission method of any one of the above when the computer execution instructions are executed by a processor.

[0248] The embodiment of the present application provides a computer program product, comprising a computer program, and the computer program can realize the heterogeneous message transmission method of any one of the above when the computer program is executed by a processor.

[0249] Other embodiments of the application will be apparent to those skilled in the art from consideration of the specification and practice of the application disclosed herein. It is intended that the specification and examples be considered as exemplary only, with the true scope and spirit of the application being indicated by the following claims.

[0250] It should be understood that the application is not limited to the precise construction that has been described above and shown in the accompanying drawings, and that various modifications and changes can be made by those skilled in the art without departing from the scope of the application. The scope of the application is limited only by the appended claims.

Claims

1. A heterogeneous message transmission method, characterized by, The application is applied to a first network element, and the heterogeneous message is a transaction message data composed of transaction data in multiple different formats; the method comprises the following steps: Obtaining a first heterogeneous message and message configuration information, wherein the message configuration information comprises source message information, field check rules and field encryption rules; According to the source message information, the first heterogeneous message is parsed to obtain structured data in a unified format; The source message information comprises message formats, and it is judged whether the message formats of the structured data are consistent with the message formats in the source message information; If yes, the fields in the structured data are checked one by one according to the field check rules; If the check is passed, the structured data is encrypted according to the field encryption rules to obtain first ciphertext; The first ciphertext is sent to a second network element, and the second network element decrypts the first ciphertext to obtain the structured data; If the second network element is a network element in a non-secure network environment, the second network element checks the structured data; if the second network element is a network element in a secure network environment, the second network element does not need to check the structured data.

2. The method of claim 1, wherein, The number of the field check rules is N, and N is an integer greater than 1; the structured data is checked according to the field check rules; which comprises the following steps: The fields in the structured data are checked one by one according to the first field check rule to obtain the first check result; If the i-1th check is passed, the i-th field check rule is used to check the fields in the structured data one by one to obtain the i-th check result; Wherein, i is 2, 3, …, N in turn.

3. The method according to claim 1 or 2, characterized in that, The structured data further comprises a parsing identifier; the first ciphertext is sent to a second network element, which comprises the following steps: The first ciphertext and the parsing identifier are sent to the second network element, and the parsing identifier is used to indicate that the second network element determines that the plaintext corresponding to the first ciphertext is structured data.

4. A heterogeneous message transmission method, characterized by, The application is applied to a second network element, and the heterogeneous message is a transaction message data composed of transaction data in multiple different formats; the method comprises the following steps: Receiving first ciphertext sent by a first network element; the first ciphertext is obtained by encrypting structured data by the first network element, and the structured data is structured data in a unified format obtained by parsing a first heterogeneous message by the first network element; the message format of the structured data is consistent with the message format in the source message information; Obtaining message configuration information, wherein the message configuration information comprises field decryption rules and field encryption rules; According to the field decryption rules, the first ciphertext is decrypted to obtain structured data; if the second network element is a network element in a non-secure network environment, the second network element checks the structured data; if the second network element is a network element in a secure network environment, the second network element does not need to check the structured data; According to the field encryption rules, the structured data is encrypted to obtain second ciphertext; The second ciphertext is sent to a third network element.

5. The method of claim 4, wherein, The message configuration information further includes target message information; the structured data is encrypted according to the field encryption rule to obtain second ciphertext; including: The structured data is converted into target message according to the target message information; The target message is encrypted according to the field encryption rule to obtain second ciphertext.

6. The method of claim 5, wherein, The message configuration information includes association information; the second ciphertext is sent to a third network element; including: Whether the target message is associated with other transactions is judged according to the association information; If yes, the associated transactions and the second ciphertext are sent to the third network element.

7. The method of claim 4, wherein, The message configuration information includes field check rule; the structured data is encrypted according to the field encryption rule to obtain second ciphertext; including: The fields in the structured data are checked one by one according to the field check rule; If the check is passed, the structured data is encrypted according to the field encryption rule to obtain the second ciphertext.

8. The method according to any one of claims 5-7, characterized in that, The first ciphertext is decrypted according to the field decryption rule to obtain structured data; including: An analysis identifier is received, which is sent by a first network element; The first ciphertext is decrypted according to the field decryption rule to obtain plaintext; It is determined that the plaintext is the structured data according to the analysis identifier.

9. A heterogeneous message transmission apparatus, characterized by comprising: An acquisition module, an analysis module, a check module, an encryption module and a sending module are included, and the heterogeneous message is transaction message data composed of multiple different formats of transaction data; wherein, The acquisition module is used to acquire a first heterogeneous message and message configuration information, and the message configuration information includes source message information, field check rule and field encryption rule; The analysis module is used to analyze the first heterogeneous message to obtain structured data in a unified format according to the source message information; The check module is used to determine whether the message format of the structured data is consistent with the message format in the source message information according to the message format in the source message information; if yes, the fields in the structured data are checked one by one according to the field check rule; The encryption module is used to encrypt the structured data according to the field encryption rule if the check is passed to obtain first ciphertext; The sending module is used to send the first ciphertext to a second network element; the second network element decrypts the first ciphertext to obtain the structured data; If the second network element is a network element in a non-secure network environment, the second network element performs security check on the structured data; if the second network element is a network element in a secure network environment, the second network element does not need to perform security check on the structured data.

10. A heterogeneous message transmission apparatus, characterized by comprising: Applied to a second network element, including a receiving module, an acquisition module, a decryption module, an encryption module and a sending module, the heterogeneous message is transaction message data composed of multiple different formats of transaction data; wherein, The receiving module is configured to receive first ciphertext sent by the first network element; the first ciphertext is obtained by encrypting structured data by the first network element, and the structured data is uniform structured data obtained by parsing a first heterogeneous message by the first network element; a message format of the structured data is consistent with a message format in source message information; The obtaining module is configured to obtain message configuration information, and the message configuration information includes field decryption rules and field encryption rules; The decryption module is configured to decrypt the first ciphertext according to the field decryption rules to obtain structured data; The encryption module is configured to encrypt the structured data according to the field encryption rules to obtain second ciphertext; The sending module is configured to send the second ciphertext to a third network element; if the second network element is a network element in a non-secure network environment, the second network element performs security check on the structured data; if the second network element is a network element in a secure network environment, the second network element does not need to perform security check on the structured data.

11. An electronic device, comprising: The computer readable storage medium stores computer execution instructions. The computer readable storage medium stores computer execution instructions. The computer readable storage medium stores computer execution instructions.

12. A computer-readable storage medium, characterized in that, The computer readable storage medium stores computer execution instructions.

Citation Information

Patent Citations

  • Data standardization method, device and electronic device

    CN109086444A

  • Message encryption method, message decryption method, device and system

    CN114697133A

  • Secure message transmission apparatus and processing method thereof

    US20160241523A1