CN108881172A - The analysis method and device of message - Google Patents

The analysis method and device of message Download PDF

Info

Publication number
CN108881172A
CN108881172A CN201810497040.XA CN201810497040A CN108881172A CN 108881172 A CN108881172 A CN 108881172A CN 201810497040 A CN201810497040 A CN 201810497040A CN 108881172 A CN108881172 A CN 108881172A
Authority
CN
China
Prior art keywords
message
field
format
resolved
value
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201810497040.XA
Other languages
Chinese (zh)
Inventor
糜文杰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Alibaba Group Holding Ltd
Original Assignee
Alibaba Group Holding Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Alibaba Group Holding Ltd filed Critical Alibaba Group Holding Ltd
Priority to CN201810497040.XA priority Critical patent/CN108881172A/en
Publication of CN108881172A publication Critical patent/CN108881172A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/22Parsing or analysis of headers
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/0078Avoidance of errors by organising the transmitted data in a format specifically designed to deal with errors, e.g. location
    • H04L1/0084Formats for payload data

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer Security & Cryptography (AREA)
  • Document Processing Apparatus (AREA)

Abstract

This specification embodiment provides a kind of analysis method and device of message, in the analytic method of message, receives message to be resolved.Obtain message configuration information corresponding with message to be resolved.The message configuration information includes the message format of message, the position of each field and field in messages included in message.According to message format, call corresponding data acquisition interface, with according to each field of position acquisition in message to be resolved corresponding field value.Convert the field value of each field to the data of fixed format.Export the data of the fixed format.

Description

The analysis method and device of message
Technical field
This specification one or more embodiment is related to field of computer technology more particularly to a kind of analytic method of message And device.
Background technique
During network communication, communication gate usually requires the message of parsing different-format, the different format example It such as can be extensible markup language (Extensible Markup Language, xml) format, JS object numbered musical notation (JavaScript Object Notation, json) format, streaming etc..To the message of different-format, it usually needs pass through Different analysis modes are parsed.For example, developer can for every kind of different-format message write it is corresponding Groovy (a kind of agile development language based on Java Virtual Machine) script, to be parsed to the message of different-format.
Accordingly, it is desirable to provide a kind of more general packet parsing scheme.
Summary of the invention
This specification one or more embodiment describes a kind of analysis method and device of message, and message solution can be improved The versatility of analysis.
In a first aspect, a kind of analytic method of message is provided, including:
Receive message to be resolved;
Obtain message configuration information corresponding with the message to be resolved;The message configuration information be according to it is described to What the sample message that analytic message matches determined;The message configuration information includes the message format of message, is wrapped in message The position of each field and the field contained in messages;
According to the message format, corresponding data acquisition interface is called, with each word according to the position acquisition Section corresponding field value in the message to be resolved;It is defined in the data acquisition interface for according to position acquisition field Field value method;
Convert the field value of each field to the data of fixed format;
Export the data of the fixed format.
Second aspect provides a kind of resolver of message, including:
Receiving unit, for receiving message to be resolved;
Acquiring unit, for obtaining message corresponding with the received message to be resolved of the receiving unit with confidence Breath;The message configuration information is determined according to the sample message to match with the message to be resolved;The message configuration Information includes the message format of message, the position of each field and the field in messages included in message;
Call unit, the message format for being obtained according to the acquiring unit, calls corresponding data acquisition to connect Mouthful, with each field according to the position acquisition in the message to be resolved corresponding field value;The data acquisition It is defined in interface for the method according to the field value of position acquisition field;
Conversion unit, for converting the field value of each field to the data of fixed format;
Output unit, the data of the fixed format for exporting the conversion unit conversion.
The analysis method and device for the message that this specification one or more embodiment provides, receives message to be resolved.It obtains Take message configuration information corresponding with message to be resolved.The message configuration information includes the message format of message, is wrapped in message The position of each field and field contained in messages.According to message format, corresponding data acquisition interface is called, with basis The each field of position acquisition corresponding field value in message to be resolved.Fixed format is converted by the field value of each field Data.Export the data of the fixed format.It follows that this specification provide analytic method by call it is predetermined with The corresponding interface of message format, realization parse the message of different message formats.Therefore, the parsing that this specification provides Method has versatility.
Detailed description of the invention
In order to illustrate more clearly of the technical solution of this specification embodiment, will make below to required in embodiment description Attached drawing is briefly described, it should be apparent that, the accompanying drawings in the following description is only some embodiments of this specification, right For those of ordinary skill in the art, without creative efforts, it can also be obtained according to these attached drawings Its attached drawing.
Fig. 1 is the application scenarios schematic diagram of the analytic method for the message that this specification provides;
Fig. 2 is the relation schematic diagram between each interface that this specification provides;
Fig. 3 is the analytic method flow chart for the message that this specification one embodiment provides;
Fig. 4 is the resolver schematic diagram for the message that this specification one embodiment provides.
Specific embodiment
With reference to the accompanying drawing, the scheme provided this specification is described.
The analytic method for the message that this specification provides can be applied in scene as shown in Figure 1, in Fig. 1, communication network Pass can receive the message from different business systems.These messages can have different message formats, e.g., xml format, Json format and streaming etc..Wherein, xml format, Json format message also may be collectively referred to as structuring message, and streaming Message can be referred to as streaming message.To these messages, in order to obtain corresponding data or content of text, communication gate can To be parsed to it.
Before the analytic method for executing the message that this illustrates that embodiment provides, category relevant to message can be pre-defined Property, which can include but is not limited to one or more of:For describing the attribute of message format, for describing The attribute of field information and attribute etc. for describing safety check information.
In one example, the attribute predetermined for describing message format can be as shown in table 1.
Table 1
Attribute Explanation
msgId Unique major key of message configuration
msgFormat Xml format, Json format and streaming etc.
Attribute predetermined for description field information can be as shown in table 2.Field information herein may include Position, field type and the father node etc. of field id, field path, field in data object.Position herein can be Marking path, or fixed position, it is subsequent to be described in detail.
Table 2
Attribute predetermined for describing safety check information can be as shown in table 3.Safety check information herein It may include digital signature content and being signed content.In addition, the safety check information can also be including signature algorithm etc..
Table 3
It, can be with people for the attribute value of the multiple pre defined attribute of determination after predefining attribute relevant to message To collect a variety of different types of sample messages in advance.For by taking structuring message as an example, different types of sample message can be with Refer to that node (concept of node is subsequent to be illustrated) in each sample message and/or node location be not identical.Later, according to every Kind sample message configures the attribute value of above-mentioned pre defined attribute.It should be noted that for the pre defined attribute in Tables 1 and 2, Configuration can be automatically completed.For the pre defined attribute in table 3, can be configured with artificial assistance.
For for configuring the attribute value of fieldId and srcPath, each word can be first identified from sample message Section.Assuming that current sample message is xml format, and the sample message of the xml format is as follows:
It, can be by a label to (including start-tag and end-tag) in the sample message of xml format as above A referred to as node.Then the node in the sample message of above-mentioned xml format for example can be:<request></request>,< head></head>And<funcion></function>Deng.It should be noted that if label pair corresponding with some node Middle nested other labels pair, then the node is known as non-leaf nodes.The section is known as to corresponding node with nested label The child node of point.Correspondingly, the node is the upper layer node of the child node.And if label centering corresponding with some node does not have Nested others label pair, then the node is known as leaf node.It in one implementation, can will be in the message of xml format Leaf node be identified as field.It is understood that containing four fields in the sample message of the xml format, respectively: <funcion></function>,<appId></appId>,<name></name>And<certNo></certNo>.
It is understood that after identifying each field in the sample message from xml format, so that it may determine The attribute value of fieldId and srcPath.It, can be according to leaf node corresponding with field for the attribute value of srcPath Multiple upper layer nodes determine.Such as previous example, to field:<funcion></function>, the attribute value of srcPath can be with For:request.head.function.It should be noted that for the sample message of xml format, the attribute value of srcPath It is properly termed as the marking path of field.
For the message of Json format, since it is usually by the array (being marked by square brackets) with nest relation It constitutes.Therefore, each array can be known as a node (or array node).And the array of not nested other arrays is claimed For leaf node, and the leaf node is identified as field.Identified in the sample message from Json format each field it Afterwards, so that it may determine the attribute value of fieldId and srcPath.For the attribute value of srcPath, equally can according to word Multiple upper layer nodes (upper layer node is also array) of the corresponding leaf node of section determine.It should be noted that for Json The message of format, the attribute value of srcPath are referred to as the marking path of field.
For the message of streaming, field can refer to the data of the regular length in the sample message of streaming.For The attribute value of srcPath may include initial position (start) and the end position (end) of above-mentioned regular length.
It is understood that being directed to every kind of sample message, the attribute value of the pre defined attribute in above-mentioned table 1- table 3 is completed After configuration, message configuration information corresponding with this kind of sample message is assured that.The message configuration information may include Each field (i.e. the attribute value of fieldId) included in the message format (i.e. the attribute value of msgFormat) of message, message And the position (i.e. the attribute value of srcPath) of each field in messages.In addition, being carried out to be able to achieve to certain pairs of messages Security verification, above-mentioned message configuration information can also include the digital signature content position in messages of message (i.e. The attribute value of signNode) and it is signed the position (i.e. the attribute value of unsignNode) of content in messages.
It should be noted that due to including attribute in table 1- table 3:MsgId, namely it is directed to every kind of sample message, it can To configure corresponding msgId, so that the msgId can be used for uniquely identifying a kind of sample message.Further, since for Different sample messages, corresponding message configuration information are generally also different.Therefore, report corresponding with every kind of sample message Literary configuration information can also be identified by the msgId of this kind of sample message.
Message is operated to realize, this specification is directed to the message of different message formats, also defines corresponding Data acquisition interface and text obtain interface.Wherein, it is defined again for according to position acquisition field in data acquisition interface The method of field value.Text is obtained in interface and is defined again for the method according to position acquisition content of text.
It should be noted that by calling above-mentioned data (text) to obtain interface, the report of available difference message format The data (text) of text, it is possible thereby to improve the versatility of the analytic method of message.
In one example, this specification defines data acquisition interface, text obtain interface and it is between the two after The relationship of holding can be as shown in Figure 2.In Fig. 2, StructMessageParser is that text corresponding with structuring message acquisition connects Mouthful, StreamMessageParser is that text (or data) corresponding with streaming message obtains interface.Two interfaces after The method in MessageParser is held.StructMessage is data acquisition interface corresponding with structuring message, Inherit the method in StructMessageParser.
It should be noted that the MessageParser in Fig. 2 specifically can be as shown in table 4.
Table 4
StructMessageParser in Fig. 2 specifically can be as shown in table 5.
Table 5
StructMessage in Fig. 2 specifically can be as shown in table 6.
Table 6
Method Explanation
getValue(path) Pass through position acquisition nodal value
getValue() Obtain the nodal value of this node
iterator Traverse all nodes under this array node
isArray Judge whether this node is array node
It should be noted that since StructMessage inherits the method in StructMessageParser, namely It is with all methods in table 5 and table 6.Wherein, getNode and getValue () are referred to as according to position acquisition word The method of the field value of section.
StreamMessageParser in Fig. 2 specifically can be as shown in table 7.
Table 7
It is understood that passing through the calling for obtaining interface to data acquisition interface or text, so that it may realize to not Message with message format is parsed.
Fig. 3 is the analytic method flow chart for the message that this specification one embodiment provides.The executing subject of the method It can be the communication gate in Fig. 1.As shown in figure 3, the method can specifically include:
Step 310, message to be resolved is received.
Message to be resolved herein can be received from operation system by communication gate.The message lattice of the message to be resolved Formula can include but is not limited to xml format, Json format and streaming etc..
Assuming that the message to be resolved is xml format, and the message to be resolved of the xml format is as follows:
Step 320, message configuration information corresponding with message to be resolved is obtained.
In one implementation, message identification can be identified from message to be resolved first.It later can be by the message The msgId for identifying message configuration information corresponding with different types of sample message is compared.If with any sample message The msgId of corresponding message configuration information compare it is consistent, then using the corresponding message configuration information of any sample message as The corresponding message configuration information of message to be resolved.And any sample message is the sample report to match with message to be resolved Text.
In the present specification, message to be resolved and the sample message to match belong to the message of same type.With structuring For for message, the position of node and node that the message of same type is included is identical.
Step 330, according to message format, corresponding data acquisition interface is called, to exist according to each field of position acquisition Corresponding field value in message to be resolved.
It should be noted that data corresponding with leaf node can be known as field value and (also referred to as be saved by structuring message Point value).For by taking the message of xml format as an example, which may be embodied in start-tag corresponding with leaf node and end Between label.It should be noted that above-mentioned field value is usually to pass through after analytical tool parses structuring message to obtain 's.The analytical tool is traditional common tool, is used to parse message according to the syntax rule of structuring message.
Optionally, in order to improve safety, before executing step 330, following step can be first carried out:
Step a calls corresponding text to obtain interface according to message format, according to digital signature content and to be signed The position of name content, obtains the digital signature content of message to be resolved and is signed content.
For by taking message format is xml format or Json format as an example, StructMessageParser can be called. Specifically, it can be by calling the getContentByNode method in StructMessageParser, to obtain digital label Name and is signed content at content.Assuming that above-mentioned message to be resolved further includes following content:
<xml>
<request>…</request>
<signature>##signaturecontent</signature>
</xml>
Assuming that the position of the digital signature content in the message configuration information of the message to be resolved is:Signature is signed The position of name content is:request.The digital signature content of the message to be resolved then got can be:## signaturecontent.And being signed content can be:<request>With</request>Between all content of text. Such as previous example, this, which is signed content, to be:<head><funcion>interface1.test</function><appId >shbank1</appId></head><body><name>Jack1</name><certNo>243252453453451</ certNo></body>。
For streaming message, StreamMessageParser can be called.Specifically, it can be and pass through calling GetValue method in StreamMessageParser, to obtain the digital signature content of message to be resolved and be signed Content.
Step b according to digital signature content and is signed content and predefined signature algorithm treats analytic message Carry out security verification.
Herein, according to digital signature content, be signed content and predefined signature algorithm is treated analytic message and carried out Security verification is traditional routine techniques, is not repeated again herein.
It is understood that can then pass through in security verification when also treating analytic message progress security verification When, execute step 330.
In step 330, by message format be xml format for for, StructMessage can be called.Specifically, may be used To be by calling getNode and getValue () method in StructMessage, to obtain each of message to be resolved The field value of field.
In one implementation, which is specifically as follows:To each field, the field is obtained in messages Top layer's node that position is included.Judge whether top layer's node is leaf node.If it is, calling getValue () method obtains corresponding nodal value from message to be resolved.If it is not, then calling getNode method, top layer's section is obtained The child node (type of the child node is StructMessage) of point, and the operation of above-mentioned judgement is executed to the child node;With this Analogize, until getting corresponding nodal value from message to be resolved.Field value of the nodal value that will acquire as the field.
It is with field:<funcion></function>, the position of field in messages is: For for request.head.function, top layer's node which includes is:request.Since request is Non-leaf nodes can call getNode method, obtain corresponding child node:head.And head is also non-leaf nodes, it can To continue to call getNode method, corresponding child node is obtained:function.Since function is leaf node, can adjust With getValue () method, corresponding nodal value is obtained:Interface1.test, thus the field value acquisition process of the field Terminate.It is similarly available to arrive, other fields:<appId></appId>,<name></name>And<certNo></ certNo>The corresponding field value in message to be resolved.
It should be noted that the operation of above-mentioned judgement can be executed by corresponding analytical tool.
For by taking message format is streaming as an example, StreamMessageParser can be called.Specifically, it can be logical GetValue (start, the end) method called in StreamMessageParser is crossed, it is each to be obtained from message to be resolved The field value of field.
Step 340, the field value of each field is converted to the data of fixed format.
Such as, the field value of each field can be converted to the data of map format.The data of map format herein can be with It is indicated by way of key-value pair (key-value).Wherein, key value can be according to the attribute in table 3:DestPath is determining, and Value is field value.
Above-mentioned conversion process is referred to as field mapping.
Step 350, the data of fixed format are exported.
To sum up, this specification is abstracted the resolving of message, and message is described as set of fields, extracts A kind of general resolving, can message (including structuring message and streaming message) to different-format carry out safety check And parsing, and it is converted into the data of fixed format.Further, since this specification is abstracted the resolving of message, from And decoupling is realized between the mapping of safety check, field and message format.Compared to traditional scheme for writing groovy script, drop The low code maintenance cost of the resolving of message, improves scalability and code stability.
Accordingly with the analytic method of above-mentioned message, a kind of parsing for message that this specification one embodiment also provides fills It sets, as shown in figure 4, the device includes:
Receiving unit 401, for receiving message to be resolved.
Acquiring unit 402, for obtaining message configuration information corresponding with the received message to be resolved of receiving unit 401. The message configuration information is determined according to the sample message to match with message to be resolved.The message configuration information includes message Message format, the position of each field and each field in messages included in message.
The message configuration information can be to be determined according to the attribute value of multiple pre defined attributes, which can be with Including one or more of:For describing the attribute of message format, for the attribute of description field information and for describing The attribute of safety check information.
Above-mentioned message format may include:Extensible markup language xml format, JS object numbered musical notation Json format and stream Formula.
When message format is xml format perhaps Json format, field can refer to the report of xml format or Json format Leaf node in text.The position of field can refer to the marking path being made of multiple upper layer nodes of leaf node.
When message format is streaming, field can refer to the data of the regular length in the message of streaming.The position of field The fixation position being made of the initial position of regular length and end position can be referred to by setting.
Call unit 403, the message format for being obtained according to acquiring unit 402, calls corresponding data acquisition interface, With according to each field of position acquisition in message to be resolved corresponding field value.It defines in data acquisition interface for basis The method of the field value of position acquisition field.
Conversion unit 404, for converting the field value of each field to the data of fixed format.
Output unit 405, the data of the fixed format for exporting the conversion of conversion unit 404.
Optionally, above-mentioned message configuration information can also include the digital signature content of message and be signed content and report Position in text.The device can also include:Verification unit 406.
Call unit 403 is also used to call corresponding text to obtain interface, to obtain report to be resolved according to message format Text digital signature content and be signed content.Text, which obtains, to be defined in interface for according to position acquisition content of text Method.
Verification unit 406, for according to the digital signature content of message to be resolved, be signed content and predefined label Name algorithm treats analytic message and carries out security verification.
Optionally, it when message format is extensible markup language xml format or JS object numbered musical notation Json format, is used for Method according to the field value of position acquisition field may include first method and second method.Wherein, first method is for leading to Position acquisition child node is crossed, second method is used to obtain the nodal value of this node.
Call unit 403 specifically can be used for:
To each field, top layer's node that the position of the field in messages is included is obtained.
Judge whether top layer's node is leaf node.
If it is, calling second method, corresponding nodal value is obtained from message to be resolved.
If it is not, then calling first method, the child node of top layer's node is obtained, and above-mentioned judgement is executed to the child node Operation;And so on, until getting corresponding nodal value from message to be resolved.
Field value of the nodal value that will acquire as field.
The function of each functional module of this specification above-described embodiment device can pass through each step of above method embodiment Rapid to realize, therefore, the specific work process for the device that this specification one embodiment provides does not repeat again herein.
The resolver for the message that this specification one embodiment provides, receiving unit 401 receive message to be resolved.It obtains Unit 402 obtains message configuration information corresponding with message to be resolved.Call unit 403 calls corresponding according to message format Data acquisition interface, with according to each field of position acquisition in message to be resolved corresponding field value.Conversion unit 404 will be each The field value of a field is converted into the data of fixed format.The data of the output fixed format of output unit 405.Thus, it is possible to mention The versatility of high packet parsing.
It should be noted that the resolver for the message that this specification embodiment provides can be communication gate in Fig. 1 One module or unit.
Those skilled in the art are it will be appreciated that in said one or multiple examples, described in this specification Function can be realized with hardware, software, firmware or their any combination.It when implemented in software, can be by these function Can storage in computer-readable medium or as on computer-readable medium one or more instructions or code passed It is defeated.
Above-described specific embodiment has carried out into one the purpose of this specification, technical scheme and beneficial effects Step is described in detail, it should be understood that being not used to limit this foregoing is merely the specific embodiment of this specification The protection scope of specification, all any modifications on the basis of the technical solution of this specification, made, change equivalent replacement Into etc., it should all include within the protection scope of this specification.

Claims (10)

1. a kind of analytic method of message, which is characterized in that including:
Receive message to be resolved;
Obtain message configuration information corresponding with the message to be resolved;The message configuration information be according to it is described to be resolved What the sample message that message matches determined;The message configuration information includes the message format of message, included in message The position of each field and the field in messages;
According to the message format, corresponding data acquisition interface is called, is existed with each field according to the position acquisition Corresponding field value in the message to be resolved;It is defined in the data acquisition interface for the word according to position acquisition field The method of segment value;
Convert the field value of each field to the data of fixed format;
Export the data of the fixed format.
2. the method according to claim 1, wherein the message configuration information further includes the digital signature of message Content and it is signed the position of content in messages;Further include:
According to the message format, corresponding text is called to obtain interface, in the digital signature to obtain the message to be resolved Hold and be signed content;The text, which obtains, to be defined in interface for the method according to position acquisition content of text;
According to the digital signature content of the message to be resolved, content and predefined signature algorithm are signed to described wait solve It analyses message and carries out security verification.
3. method according to claim 1 or 2, which is characterized in that the message configuration information is according to multiple predefined What the attribute value of attribute determined, the pre defined attribute includes one or more of:For describing the attribute of message format, using In the attribute of description field information and attribute for describing safety check information.
4. the method according to claim 1, wherein the message format includes:Extensible markup language xml lattice Formula, JS object numbered musical notation Json format and streaming;
When the message format is the xml format perhaps Json format field refer to the xml format or Leaf node in the message of the Json format;The position of the field refers to multiple upper layer nodes by the leaf node The marking path of composition;
When the message format is streaming, the field refers to the data of the regular length in the message of streaming;The field Position refer to the fixation position being made of the initial position of the regular length and end position.
5. the method according to claim 1, wherein the message format is extensible markup language xml format Or JS object numbered musical notation Json format;The method for according to the field value of position acquisition field includes first method and the Two methods, wherein the first method is used for through position acquisition child node, and the second method is used to obtain the section of this node Point value;
The field each according to the position acquisition corresponding field value in the message to be resolved, including:
To each field, top layer's node that the position of the field in messages is included is obtained;
Judge whether top layer's node is leaf node;
If it is, calling the second method, corresponding nodal value is obtained from the message to be resolved;
If it is not, then calling the first method, the child node of top layer's node is obtained, and the child node is executed above-mentioned The operation of judgement;And so on, until getting corresponding nodal value from the message to be resolved;
Field value of the nodal value that will acquire as the field.
6. a kind of resolver of message, which is characterized in that including:
Receiving unit, for receiving message to be resolved;
Acquiring unit, for obtaining message configuration information corresponding with the received message to be resolved of the receiving unit;Institute Stating message configuration information is determined according to the sample message to match with the message to be resolved;The message configuration information packet Include the position of each field and the field in messages included in the message format of message, message;
Call unit, the message format for being obtained according to the acquiring unit, calls corresponding data acquisition interface, with The corresponding field value in the message to be resolved of each field according to the position acquisition;In the data acquisition interface It defines for the method according to the field value of position acquisition field;
Conversion unit, for converting the field value of each field to the data of fixed format;
Output unit, the data of the fixed format for exporting the conversion unit conversion.
7. device according to claim 6, which is characterized in that the message configuration information further includes the digital signature of message Content and it is signed the position of content in messages;
The call unit is also used to call corresponding text to obtain interface according to the message format, described wait solve to obtain It analyses the digital signature content of message and is signed content;The text, which obtains, to be defined in interface for according to position acquisition text The method of this content;
Verification unit, for according to the digital signature content of the message to be resolved, be signed content and predefined signature Algorithm carries out security verification to the message to be resolved.
8. device according to claim 6 or 7, which is characterized in that the message configuration information is according to multiple predefined What the attribute value of attribute determined, the pre defined attribute includes one or more of:For describing the attribute of message format, using In the attribute of description field information and attribute for describing safety check information.
9. device according to claim 6, which is characterized in that the message format includes:Extensible markup language xml lattice Formula, JS object numbered musical notation Json format and streaming;
When the message format is the xml format perhaps Json format field refer to the xml format or Leaf node in the message of the Json format;The position of the field refers to multiple upper layer nodes by the leaf node The marking path of composition;
When the message format is streaming, the field refers to the data of the regular length in the message of streaming;The field Position refer to the fixation position being made of the initial position of the regular length and end position.
10. device according to claim 6, which is characterized in that the message format is extensible markup language xml format Or JS object numbered musical notation Json format;The method for according to the field value of position acquisition field includes first method and the Two methods, wherein the first method is used for through position acquisition child node, and the second method is used to obtain the section of this node Point value;
The call unit is specifically used for:
To each field, top layer's node that the position of the field in messages is included is obtained;
Judge whether top layer's node is leaf node;
If it is, calling the second method, corresponding nodal value is obtained from the message to be resolved;
If it is not, then calling the first method, the child node of top layer's node is obtained, and the child node is executed above-mentioned The operation of judgement;And so on, until getting corresponding nodal value from the message to be resolved;
Field value of the nodal value that will acquire as the field.
CN201810497040.XA 2018-05-22 2018-05-22 The analysis method and device of message Pending CN108881172A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810497040.XA CN108881172A (en) 2018-05-22 2018-05-22 The analysis method and device of message

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810497040.XA CN108881172A (en) 2018-05-22 2018-05-22 The analysis method and device of message

Publications (1)

Publication Number Publication Date
CN108881172A true CN108881172A (en) 2018-11-23

Family

ID=64334362

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810497040.XA Pending CN108881172A (en) 2018-05-22 2018-05-22 The analysis method and device of message

Country Status (1)

Country Link
CN (1) CN108881172A (en)

Cited By (22)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109451045A (en) * 2018-12-12 2019-03-08 成都九洲电子信息系统股份有限公司 A kind of high-speed message acquisition network card control method can configure customized Ethernet header
CN109558124A (en) * 2018-12-11 2019-04-02 浪潮通用软件有限公司 A kind of engine and method carrying out message interaction with third party system interface
CN109889375A (en) * 2019-01-23 2019-06-14 中国银行股份有限公司 Service message method of calibration, device and computer storage medium
CN110119423A (en) * 2019-05-17 2019-08-13 厦门商集网络科技有限责任公司 A kind of data analysis method and computer readable storage medium of configurableization
CN110290119A (en) * 2019-06-10 2019-09-27 北京信安世纪科技股份有限公司 A kind of JSON message encryption method, decryption method and device
CN110311784A (en) * 2019-06-10 2019-10-08 北京信安世纪科技股份有限公司 A kind of JSON message endorsement method, sign test method and device
CN110855623A (en) * 2019-10-17 2020-02-28 北京全路通信信号研究设计院集团有限公司 Method and device for encoding and decoding messages of train operation control system
CN111641662A (en) * 2020-07-01 2020-09-08 中国银行股份有限公司 Message format inspection method and device
CN111756755A (en) * 2020-06-28 2020-10-09 中国银行股份有限公司 Message signature adding and signature checking method and device
CN112055018A (en) * 2020-09-03 2020-12-08 中国银行股份有限公司 Message analysis method and device
CN112383533A (en) * 2020-11-10 2021-02-19 中国农业银行股份有限公司 Message format conversion method and device
CN112417085A (en) * 2020-11-27 2021-02-26 平安普惠企业管理有限公司 Message comparison method and device, computer equipment and storage medium
CN112905182A (en) * 2019-12-04 2021-06-04 北京沃东天骏信息技术有限公司 Data analysis method and device
CN114422592A (en) * 2022-01-21 2022-04-29 深圳壹账通智能科技有限公司 Message conversion method and device, computer equipment and computer readable storage medium
CN114500691A (en) * 2022-02-16 2022-05-13 支付宝实验室(新加坡)有限公司 Information configuration method and device
CN114567557A (en) * 2022-03-07 2022-05-31 上海数禾信息科技有限公司 Message processing method and device, computer equipment and storage medium
CN114925386A (en) * 2022-07-15 2022-08-19 飞腾信息技术有限公司 Data processing method, computer device, data processing system and storage medium
CN115314573A (en) * 2022-08-05 2022-11-08 中国银行股份有限公司 Dynamic loading method and device for message body, electronic equipment and storage medium
CN115412619A (en) * 2022-07-21 2022-11-29 浙江众合科技股份有限公司 Log message real-time monitoring and analyzing method with user configurable message format
CN115643320A (en) * 2022-09-08 2023-01-24 中科云谷科技有限公司 Data processing method, system, storage medium and processor
CN115665284A (en) * 2022-10-28 2023-01-31 上海浦东发展银行股份有限公司 Message processing method and device based on distributed configuration center and computer equipment
CN115866087A (en) * 2022-11-29 2023-03-28 广发银行股份有限公司 Message mapping and HTTP request message conversion method and device

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101188561A (en) * 2007-12-20 2008-05-28 北京大学 Communication method and system for universal service data based on self-defined template
CN105049281A (en) * 2015-06-25 2015-11-11 浪潮(北京)电子信息产业有限公司 Message parsing method and equipment
CN106685982A (en) * 2017-01-13 2017-05-17 中国工商银行股份有限公司 External message processing method and system
US20180063292A1 (en) * 2011-09-23 2018-03-01 Guest Tek Interactive Entertainment Ltd. Central interface gateway and method of interfacing a property management system with a guest service device via the internet
CN108040040A (en) * 2017-11-30 2018-05-15 北京锐安科技有限公司 A kind of automation analysis method and device of application protocol message

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101188561A (en) * 2007-12-20 2008-05-28 北京大学 Communication method and system for universal service data based on self-defined template
US20180063292A1 (en) * 2011-09-23 2018-03-01 Guest Tek Interactive Entertainment Ltd. Central interface gateway and method of interfacing a property management system with a guest service device via the internet
CN105049281A (en) * 2015-06-25 2015-11-11 浪潮(北京)电子信息产业有限公司 Message parsing method and equipment
CN106685982A (en) * 2017-01-13 2017-05-17 中国工商银行股份有限公司 External message processing method and system
CN108040040A (en) * 2017-11-30 2018-05-15 北京锐安科技有限公司 A kind of automation analysis method and device of application protocol message

Cited By (28)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109558124A (en) * 2018-12-11 2019-04-02 浪潮通用软件有限公司 A kind of engine and method carrying out message interaction with third party system interface
CN109451045A (en) * 2018-12-12 2019-03-08 成都九洲电子信息系统股份有限公司 A kind of high-speed message acquisition network card control method can configure customized Ethernet header
CN109889375A (en) * 2019-01-23 2019-06-14 中国银行股份有限公司 Service message method of calibration, device and computer storage medium
CN110119423A (en) * 2019-05-17 2019-08-13 厦门商集网络科技有限责任公司 A kind of data analysis method and computer readable storage medium of configurableization
CN110290119A (en) * 2019-06-10 2019-09-27 北京信安世纪科技股份有限公司 A kind of JSON message encryption method, decryption method and device
CN110311784A (en) * 2019-06-10 2019-10-08 北京信安世纪科技股份有限公司 A kind of JSON message endorsement method, sign test method and device
CN110290119B (en) * 2019-06-10 2021-11-09 北京信安世纪科技股份有限公司 JSON message encryption method, decryption method and device
CN110855623A (en) * 2019-10-17 2020-02-28 北京全路通信信号研究设计院集团有限公司 Method and device for encoding and decoding messages of train operation control system
CN110855623B (en) * 2019-10-17 2022-04-08 北京全路通信信号研究设计院集团有限公司 Method and device for encoding and decoding messages of train operation control system
CN112905182A (en) * 2019-12-04 2021-06-04 北京沃东天骏信息技术有限公司 Data analysis method and device
CN111756755A (en) * 2020-06-28 2020-10-09 中国银行股份有限公司 Message signature adding and signature checking method and device
CN111641662A (en) * 2020-07-01 2020-09-08 中国银行股份有限公司 Message format inspection method and device
CN112055018B (en) * 2020-09-03 2023-05-23 中国银行股份有限公司 Message analysis method and device
CN112055018A (en) * 2020-09-03 2020-12-08 中国银行股份有限公司 Message analysis method and device
CN112383533A (en) * 2020-11-10 2021-02-19 中国农业银行股份有限公司 Message format conversion method and device
CN112417085A (en) * 2020-11-27 2021-02-26 平安普惠企业管理有限公司 Message comparison method and device, computer equipment and storage medium
CN114422592A (en) * 2022-01-21 2022-04-29 深圳壹账通智能科技有限公司 Message conversion method and device, computer equipment and computer readable storage medium
CN114500691A (en) * 2022-02-16 2022-05-13 支付宝实验室(新加坡)有限公司 Information configuration method and device
CN114567557A (en) * 2022-03-07 2022-05-31 上海数禾信息科技有限公司 Message processing method and device, computer equipment and storage medium
CN114925386A (en) * 2022-07-15 2022-08-19 飞腾信息技术有限公司 Data processing method, computer device, data processing system and storage medium
CN115412619A (en) * 2022-07-21 2022-11-29 浙江众合科技股份有限公司 Log message real-time monitoring and analyzing method with user configurable message format
CN115412619B (en) * 2022-07-21 2024-06-04 浙江众合科技股份有限公司 Method for real-time monitoring and analyzing log message with user configurable message format
CN115314573A (en) * 2022-08-05 2022-11-08 中国银行股份有限公司 Dynamic loading method and device for message body, electronic equipment and storage medium
CN115314573B (en) * 2022-08-05 2024-02-23 中国银行股份有限公司 Dynamic loading method and device for message body, electronic equipment and storage medium
CN115643320A (en) * 2022-09-08 2023-01-24 中科云谷科技有限公司 Data processing method, system, storage medium and processor
CN115665284A (en) * 2022-10-28 2023-01-31 上海浦东发展银行股份有限公司 Message processing method and device based on distributed configuration center and computer equipment
CN115866087A (en) * 2022-11-29 2023-03-28 广发银行股份有限公司 Message mapping and HTTP request message conversion method and device
CN115866087B (en) * 2022-11-29 2023-11-17 广发银行股份有限公司 Message mapping and message conversion method, device and transmission system

Similar Documents

Publication Publication Date Title
CN108881172A (en) The analysis method and device of message
CN110287109B (en) Protocol interface testing method and device, computer equipment and storage medium thereof
US9483260B1 (en) Documentation generation for web APIs based on byte code analysis
CN106201643B (en) Data analysis method and device
US20140075242A1 (en) Testing rest api applications
CN100483419C (en) Data format verification method and device
KR20150042877A (en) Managing record format information
CN111078729B (en) Medical data tracing method, device, system, storage medium and electronic equipment
CN107220096A (en) A kind of json data analysis methods and device
JP7237457B2 (en) computing equipment
WO2015009542A1 (en) Semantics-oriented analysis of log message content
CN107301122A (en) interface test method, device, storage medium and computer equipment
CN103902269B (en) System and method for generating MIB files through XML files
CN109343836B (en) Data serialization and data deserialization method, device and equipment
US20220035661A1 (en) Task generation
US10572371B2 (en) Generating valid use cases from a parsed configuration file describing use case options
CN107273504A (en) Data query method and device based on Kudu
CN112882844B (en) Joint debugging method, device and storage medium based on network front end and network back end
CN109324958B (en) REST unified verification method, device, equipment and readable storage medium
WO2021259290A1 (en) Stored procedure conversion method and apparatus, and device and storage medium
CN108388606B (en) Method for checking base table field names in Sql sentences and computer equipment
CN104346407B (en) Form and the method and its device of XML file data interaction in data reporting system
CN110287429A (en) Data analysis method, device, equipment and storage medium
CN111061927B (en) Data processing method and device and electronic equipment
KR101482668B1 (en) System and method for generating database based on SCL

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20181123