A message parsing method, device, equipment and medium
Through the message parsing method based on distributed version management tools, the code patch file analysis tool in the git code management tool is provided, which solves the problems of git tool operation complexity and analysis difficulty, and realizes simple and intuitive analysis and analysis of code patch files. Efficient analysis efficiency.
Patent Information
- Application Number
- CN202210601324.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-30
- Publication Date
- 2024-10-29
- Estimated Expiration
- 2042-05-30
AI Technical Summary
Existing git code management tools lack interface operation tools, causing junior users to encounter difficulties in handling complex operations. In particular, it is difficult to implement correlation and dependency analysis of code patch files.
Provides a message parsing method based on distributed version management tools, which performs verification and logical analysis by receiving the first message assembled from the user name and encrypted password, and the second message assembled from the patch file attribute information input by the user. , generate and parse the third message, and provide correlation and dependency analysis tools for code patch files.
It lowers the threshold for using git management tools, makes code patch files simpler and more intuitive, improves analysis efficiency, and supports the parsing of local and remote code patch files, as well as interface operations and display of commit specified files.
Smart Images

Figure CN115080106B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data processing technology, and in particular to a message parsing method, device, equipment and medium. Background Art
[0002] At present, Linux is a multi-user, multi-tasking, multi-threaded and multi-CPU operating system based on the Portable Operating System Interface of UNIX (POSIX). With the development of the Internet, Linux has received support from software enthusiasts, organizations, and companies all over the world. As a result, there are hundreds of different distributions of Linux, and code management also faces huge challenges. In order to facilitate code management, the community has derived the git code management tool (distributed version management tool). At present, the git code management tool has been applied to thousands of management systems, but the git code management tool is generally displayed in the form of Linux or Windows commands, especially some complex operations require a set of complex commands to combine to obtain the required relevant information, which is difficult for novice users because there are basically no related interface operation tools.
[0003] At present, the applications of git code management tools are partly some detection devices and complex system-level management devices formed by using git hooks, and partly simple patch file (patch) information display. There is no interface analysis tool for code patch file correlation information based on git code management tools. Summary of the invention
[0004] In order to overcome the above technical defects, the purpose of the present invention is to provide a message parsing method, device, equipment and medium. The method of the present invention is based on a distributed version management tool, and the method includes: receiving a first message assembled by a user name and an encrypted password string; receiving a second message assembled after parsing the attribute information of the patch file input by the user, wherein the attribute information includes a warehouse path; verifying and logically analyzing the first message and the second message, and generating a third message; parsing the third message. The present invention provides a code patch file analysis tool based on the git management tool, which lowers the threshold for using the git management tool, supports the correlation and dependency analysis of the code patch file, makes the code patch file simpler and more intuitive, and improves the analysis efficiency.
[0005] The specific technical solutions provided by the embodiments of the present invention are as follows:
[0006] In a first aspect, a message parsing method is provided, the method being based on a distributed version management tool, the method comprising:
[0007] Receiving a first message composed of a user name and an encrypted password string;
[0008] receiving a second message assembled after parsing attribute information of a patch file input by a user, wherein the attribute information includes a warehouse path;
[0009] Verifying and logically analyzing the first message and the second message, and generating a third message;
[0010] The third message is parsed.
[0011] Furthermore, before receiving the first message composed of the user name and the encrypted password string, the method further comprises:
[0012] Receive the IP address input by the user and determine whether the format of the IP address is correct;
[0013] If yes, then check the user name entered by the user; if no, then feedback the input error to the user;
[0014] The detecting of the user name input by the user comprises:
[0015] Determine whether the rule of the user name is correct;
[0016] If yes, the password entered by the user is checked; if no, an input error is fed back to the user;
[0017] The detecting of the password input by the user includes:
[0018] Determining whether the password rule is correct;
[0019] If yes, the password is encrypted using the md5sum command, and the user name and the encrypted password string are assembled to form a first message; if no, an input error is fed back to the user.
[0020] Furthermore, before receiving the second message formed by parsing the attribute information of the patch file input by the user and assembling it, the method further includes:
[0021] Receive attribute information of the patch file input by the user;
[0022] Detecting the attribute information of the patch file;
[0023] The detecting the attribute information of the patch file includes:
[0024] Determining whether the attribute information format of the patch file is qualified;
[0025] If so, the attribute information of the patch file is parsed, the parsed information is assembled into a second message, and it is determined whether the user name and password of the second message meet the rules at the same time; if not, an input error is fed back to the user.
[0026] Further, the verifying and logically analyzing the first message and the second message and generating a third message includes:
[0027] Determine whether the username and password of the first message satisfy the rules at the same time;
[0028] If yes, then compare and verify the username and password of the first message with the username and password maintained in the configuration file; if no, then determine the legitimacy of the user;
[0029] The comparing and verifying the user name and password of the first message with the user name and password maintained in the configuration file includes:
[0030] Determine whether the username and password of the first message are qualified by comparison and verification with the username and password maintained in the configuration file;
[0031] If yes, then continue to check the attribute information of the patch file input by the user; if no, then feedback an input error to the user.
[0032] Furthermore, the judging of the legitimacy of the user includes:
[0033] Determine whether the user is legitimate;
[0034] If yes, then determine whether the remote repository path corresponding to the user in the configuration file has been downloaded; if no, feedback an input error to the user;
[0035] The determining whether the remote repository path corresponding to the user in the configuration file has been downloaded includes:
[0036] Determine whether the remote repository path corresponding to the user in the configuration file has been downloaded;
[0037] If so, the first message and the second message are intersected according to the intersection rules, the corresponding git commands are assembled according to the intersection processing results to collect information, the collected information is analyzed for dependency and correlation, and the information after the dependency and correlation analysis is assembled into a third message; if not, the local warehouse path input by the user is first downloaded, and then the first message and the second message are intersected according to the intersection rules.
[0038] Further, parsing the third message includes:
[0039] Displaying the third message according to the parsing result of the third message;
[0040] The corresponding display of the third message according to the parsing result of the third message includes:
[0041] Determining whether to display the file content of the third message;
[0042] If yes, then the file content of the third message is displayed in a correlated manner; if no, then the file name list of the third message is displayed in a correlated manner;
[0043] Determining whether to display the specified file of the third message;
[0044] If so, the specified file of the third message is displayed; if not, all files of the third message are displayed.
[0045] Further, the parsing of the third message further includes:
[0046] Determine whether to exit the parsing process of the third message;
[0047] If yes, then exit the parsing process of the third message; if no, then re-check the attribute information of the patch file input by the user.
[0048] In a second aspect, a message parsing device is provided, the device comprising:
[0049] The receiving module is used to receive a first message formed by assembling a user name and an encrypted password string; and receive a second message formed by parsing attribute information of a patch file input by a user, wherein the attribute information includes a warehouse path;
[0050] A processing module, used to verify and logically analyze the first message and the second message, and generate a third message;
[0051] An output module is used to parse the third message.
[0052] According to a third aspect, a computer device is provided, the device comprising:
[0053] A memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of the message parsing method as described in any one of the first aspects.
[0054] In a fourth aspect, a computer storage medium is provided, the medium comprising:
[0055] A computer program is stored thereon, and when the computer program is executed by the memory, the steps of the message parsing method described in any one of the first aspects are implemented.
[0056] Compared with the prior art, the method of the technical solution provided by the embodiment of the present invention is based on a distributed version management tool, and the method includes: receiving a first message formed by assembling a user name and an encrypted password string; receiving a second message assembled after parsing the attribute information of the patch file input by the user, wherein the attribute information includes a warehouse path; verifying and logically analyzing the first message and the second message, and generating a third message; parsing the third message. The present invention provides a code patch file analysis tool based on the git management tool, lowers the threshold for using the git management tool, supports the correlation and dependency analysis of the code patch file, makes the code patch file simpler and more intuitive, and improves the analysis efficiency.
[0057] The technical solution provided by the embodiment of the present invention can be used not only for local code patch file parsing, but also for remote code patch file parsing; and it also supports interface operation and display of specified files in commit. BRIEF DESCRIPTION OF THE DRAWINGS
[0058] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0059] Figure 1 A first flow chart of a message parsing method provided in Embodiment 1 of the present invention;
[0060] Figure 2 A second flow chart of the message parsing method provided in Embodiment 2 of the present invention;
[0061] Figure 3 A specific flow chart of the message parsing method provided in Embodiment 2 of the present invention;
[0062] Figure 4 A first structural diagram of a message parsing device provided in Embodiment 3 of the present invention;
[0063] Figure 5 A second structural diagram of the message parsing device provided in Embodiment 3 of the present invention;
[0064] Figure 6 The exemplary system provided for the fifth embodiment of the present invention can be used to implement the various embodiments described in this application. DETAILED DESCRIPTION
[0065] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution in the embodiment of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiment of the present invention. Obviously, the described embodiment is only a part of the embodiment of the present invention, not all the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0066] It should be noted that, unless the context clearly requires otherwise, words such as “include”, “including” and similar words throughout the specification and claims should be interpreted as including rather than exclusive or exhaustive; that is, the meaning is “including but not limited to”.
[0067] Furthermore, in the description of the present invention, unless otherwise specified, “plurality” means two or more.
[0068] Embodiment 1
[0069] The embodiment of the present invention provides a message parsing method, such as Figure 1 As shown, the method is based on a distributed version management tool, and the method includes:
[0070] Receiving a first message composed of a user name and an encrypted password string;
[0071] receiving a second message assembled after parsing attribute information of a patch file input by a user, wherein the attribute information includes a warehouse path;
[0072] Verifying and logically analyzing the first message and the second message, and generating a third message;
[0073] The third message is parsed.
[0074] The technical solution provided by the embodiment of the present invention is based on the git management tool, provides a code patch file analysis tool, lowers the threshold for using the git management tool, supports the correlation and dependency analysis of code patch files, makes the code patch files simpler and more intuitive, and improves the analysis efficiency.
[0075] The technical solution provided by the embodiment of the present invention can be used not only for local code patch file parsing, but also for remote code patch file parsing; and it also supports interface operation and display of specified files in commit.
[0076] Embodiment 2
[0077] The embodiment of the present invention provides a message parsing method, such as Figure 2As shown, the method is based on a distributed version management tool, and the method includes:
[0078] Step S01, receiving an IP address input by a user, and determining whether the format of the IP address is correct;
[0079] If yes, then check the user name entered by the user; if no, then feedback the input error to the user;
[0080] The detecting of the user name input by the user comprises:
[0081] Determine whether the rule of the user name is correct;
[0082] If yes, the password entered by the user is checked; if no, an input error is fed back to the user;
[0083] The detecting of the password input by the user includes:
[0084] Determining whether the password rule is correct;
[0085] If yes, the password is encrypted using the md5sum command, and the user name and the encrypted password string are assembled to form a first message; if no, an input error is fed back to the user.
[0086] Receive attribute information of the patch file input by the user;
[0087] Detecting the attribute information of the patch file;
[0088] The detecting the attribute information of the patch file includes:
[0089] Determining whether the attribute information format of the patch file is qualified;
[0090] If so, the attribute information of the patch file is parsed, the parsed information is assembled into a second message, and it is determined whether the user name and password of the second message meet the rules at the same time; if not, an input error is fed back to the user.
[0091] That is, the user enters the repository path and / or other information of the patch file;
[0092] Detecting the repository path and / or other information of the patch file;
[0093] The detecting of the warehouse path and / or other information of the patch file includes:
[0094] Determine whether the repository path and / or other information format of the patch file is qualified;
[0095] If so, the warehouse path and / or other information of the patch file is parsed by the first parsing unit, the parsed information is assembled into a second message, and the second message is transmitted to the login verification unit through the transmission unit. The login verification unit determines whether the username and password of the second message meet the rules at the same time; if not, the input error is fed back to the user.
[0096] Specifically, the attribute information includes the warehouse path and / or other information. The login unit performs a reachability check on the IP address input by the user, and checks the legitimacy of the user name and password; when the user uses this method to perform patch file patch analysis, he will first be asked to enter the IP address, obtain the logged-in IP address, and determine whether the format of the IP address is incorrect. If the address is unreachable or has a format error, the user will be fed back an input error.
[0097] You will be asked to verify your username to see if it complies with the rules. The username must be at least 8 characters long and must contain both uppercase and lowercase letters, numbers, and special symbols. After parsing the user input to get the username, you will be asked to verify the rules. If it does not comply with the rules, you will be informed that the user has entered an error.
[0098] Further, parse the password entered by the user. Here, the password entered by the user must also be a combination of uppercase and lowercase letters, numbers, and special symbols and must not be less than 8 characters. If it does not meet the rules, feedback to the user that the input error has occurred; if the rules are met, continue to use the md5sum command to encrypt the password, assemble the encrypted password string with the user name to form the first message, and send it to the back-end login verification unit via the transmission unit for the next step of verification.
[0099] The user enters the repository path and / or other information of the patch file;
[0100] Detecting the repository path and / or other information of the patch file;
[0101] Determine whether the repository path and / or other information format of the patch file is qualified;
[0102] If so, the warehouse path and / or other information of the patch file is parsed by the first parsing unit, the parsed information is assembled into a second message, which is passed to the front-end transmission unit, and then transmitted to the back-end transmission unit via the front-end transmission unit, and the second message is transmitted to the login verification unit via the back-end transmission unit. The login verification unit determines whether the username and password of the second message meet the rules at the same time; if not, the input error is fed back to the user.
[0103] Here, the detection unit is used to detect the warehouse path and / or other information of the patch file to detect the legality and validity of the information input by the user. The warehouse path of the patch file is a required item, and the warehouse path must have a value, such as the path / home / project / ; other items such as the submitter, keyword, relative path of the patch file relative to the warehouse path, time point or time period, and commit number of the patch file input by the user are optional items. Not all optional items can be empty, and at least one optional item is required to have a value. Among them, the submitter, keyword, and relative path of the patch file relative to the warehouse path are strings. The time point is year-month-day-hour: minute: second (24-hour system), and there must be a space between the date and the hour, for example, 2022-03-0523:15:16. The time period uses the "~" symbol to connect the time points, for example, 2022-1-211:02:03 to 2022-1-211:03:05.
[0104] Here, the other information includes the submitter, keywords, the relative path of the patch file relative to the warehouse path, the time point or time period, and the commit number of the patch file entered by the user. Except for the warehouse path of the patch file, which is a required item, the rest of the user-entered information is optional. The more information the user fills in, the more accurate the correlation analysis of the code patch file patch will be.
[0105] Among them, the git management tool is a very powerful distributed version management tool, mainly used for Linux kernel development management; Linux kernel is an open source computer operating system kernel; Patch is a memory patch or file patch, etc.; Commit number is a unique numeric string that records the patch file.
[0106] Step S02, receiving a first message composed of a user name and an encrypted password string;
[0107] A second message is received which is assembled after parsing the attribute information of the patch file input by the user, wherein the attribute information includes a warehouse path.
[0108] Specifically, the second message includes code patch file information.
[0109] Step S03: verify and logically analyze the first message and the second message, and generate a third message.
[0110] Specifically, the received first message and the second message are verified, and after passing the verification, they are transmitted to the login verification unit.
[0111] Step S03 also includes:
[0112] Step S031, determining by a login verification unit whether the username and password of the first message satisfy the rules at the same time;
[0113] If yes, then compare and verify the username and password of the first message with the username and password maintained in the configuration file; if no, then determine the legitimacy of the user;
[0114] The comparing and verifying the user name and password of the first message with the user name and password maintained in the configuration file includes:
[0115] Determine whether the username and password of the first message are qualified by comparison and verification with the username and password maintained in the configuration file;
[0116] If yes, then continue to check the attribute information of the patch file input by the user; if no, then feedback an input error to the user.
[0117] Specifically, the login verification unit maintains a user table, where the user name is in plain text and the password is an md5 checksum. Both the user name and password must meet the rules of uppercase and lowercase letters, numbers, special symbols and the length must not be less than 8 characters. Each user operation must first be verified by the login verification unit.
[0118] If the username and password of the first message meet the rules at the same time, the username and password of the first message are compared and verified with the username and password maintained in the configuration file in the login verification unit, and it is determined whether the username and password of the first message are qualified after comparison and verification with the username and password maintained in the configuration file, and the comparison and verification result is sent to the front end via the transmission unit;
[0119] If the username and password of the first message fail to pass the verification after comparison with the username and password maintained in the configuration file, an input error is fed back to the user; if the username and password of the first message pass the verification after comparison with the username and password maintained in the configuration file, the warehouse path and / or other information of the patch file input by the user is continued to be checked to determine whether the warehouse path and / or other information format of the patch file is qualified; if so, the warehouse path and / or other information of the patch file is parsed by the first parsing unit, the parsed information is assembled into a second message, which is passed to the front-end transmission unit, and then transmitted to the back-end transmission unit via the front-end transmission unit, and the second message is transmitted to the login verification unit via the back-end transmission unit, and the login verification unit determines whether the username and password of the second message meet the rules at the same time; if not, an input error is fed back to the user.
[0120] Step S032, determining whether the user is legitimate;
[0121] If yes, then determine whether the remote repository path corresponding to the user in the configuration file has been downloaded; if no, feedback an input error to the user;
[0122] The determining whether the remote repository path corresponding to the user in the configuration file has been downloaded includes:
[0123] Determine whether the remote repository path corresponding to the user in the configuration file has been downloaded;
[0124] If so, the first message and the second message are intersected according to the intersection rule by the logic analysis unit, the corresponding git command is assembled according to the intersection processing result to collect information, the collected information is analyzed for dependency and correlation, and the information after the dependency and correlation analysis is assembled into a third message, and the third message is transmitted to the second parsing unit through the transmission unit; if not, the local warehouse path input by the user is first downloaded, and then the first message and the second message are intersected according to the intersection rule.
[0125] Specifically, determine whether the user is legitimate. If so, continue to transfer the first message and the second message to the logic analysis unit to determine whether the remote warehouse path corresponding to the user in the configuration file has been downloaded; if not, feedback an input error to the user;
[0126] If the remote warehouse path corresponding to the user in the configuration file has been downloaded, the first message and the second message are intersected according to the intersection rule by the logic analysis unit, the corresponding git command is assembled according to the intersection processing result to collect information, the collected information is subjected to dependency and correlation analysis, and the information after the dependency and correlation analysis is assembled into a third message, the third message is transmitted to the back-end transmission unit by the transmission unit, and the third message is transmitted to the front-end transmission unit by the back-end transmission unit, and then transmitted to the second parsing unit at the front end by the front-end transmission unit; if the remote warehouse path corresponding to the user in the configuration file has not been downloaded, the local warehouse path input by the user is first downloaded, and then the first message and the second message are intersected according to the intersection rule.
[0127] The parsing unit includes a first parsing unit and a second parsing unit, wherein the first parsing unit is used to parse user input information, and the second parsing unit is used to parse a third message fed back after a back-end logic analysis.
[0128] The download unit is used to download the remote warehouse path corresponding to the user in the configuration file, and the downloaded path is the local warehouse path input by the user.
[0129] The logic analysis unit is used to parse the received first message and the second message, then perform intersection processing on the first message and the second message according to the intersection rule, assemble the corresponding git command according to the intersection processing result to collect information, perform dependency and correlation analysis on the collected information, and assemble the information after the dependency and correlation analysis into a third message, and transmit the third message to the back-end transmission unit through the transmission unit.
[0130] Step S04: parse the third message.
[0131] Specifically, after the third message is parsed by the second parsing unit, it is simultaneously sent to the display unit for result display.
[0132] Step S04 also includes:
[0133] Step S041, displaying the third message according to the parsing result of the third message;
[0134] The corresponding display of the third message according to the analysis result of the third message includes: determining whether to display the file content of the third message by a second analysis unit;
[0135] If yes, then the file content of the third message is displayed in a correlated manner; if no, then the file name list of the third message is displayed in a correlated manner;
[0136] Determining whether to display the specified file of the third message;
[0137] If so, the specified file of the third message is displayed; if not, all files of the third message are displayed.
[0138] Specifically, the display unit displays analysis information of the code patch file patch, such as the commit number of the associated patch file or the patch file group, the patch file content, the patch file statistical content, and may also display the patch information of the specified file.
[0139] Step S042, determining whether to exit the parsing process of the third message;
[0140] If yes, then exit the parsing process of the third message; if no, then re-check the warehouse path and / or other information of the patch file input by the user.
[0141] Specifically, determining whether to exit the parsing process of the third message;
[0142] If so, exit the parsing process of the third message; if not, re-check the attribute information of the patch file input by the user to determine whether the attribute information format of the patch file is qualified; if so, parse the warehouse path and / or other information of the patch file through the first parsing unit, assemble the parsed information into a second message, and transmit the second message to the login verification unit through the transmission unit, and determine whether the user name and password of the second message meet the rules at the same time through the login verification unit; if not, feedback the input error to the user.
[0143] like Figure 3 The figure shows a specific flow chart of the message parsing method. The present invention receives a first message formed by assembling an encrypted password string and a user name; receives a second message formed by parsing the warehouse path and / or other information of a patch file input by a user; verifies and logically analyzes the first message and the second message; and parses and displays a third message assembled after the logical analysis according to the result of the logical analysis.
[0144] The message parsing method provided in the embodiment of the present invention may be improved and optimized without departing from the technical solution of the present invention, and these improvements and optimizations should also be regarded as within the protection scope of the present invention.
[0145] The embodiment of the present invention provides a method for parsing a message. The technical solution provided by the embodiment of the present invention is based on a distributed version management tool, and the method includes: receiving a first message formed by assembling a user name and an encrypted password string; receiving a second message formed by parsing the attribute information of a patch file input by a user, wherein the attribute information includes a warehouse path; verifying and logically analyzing the first message and the second message, and generating a third message; parsing the third message. The present invention provides a code patch file analysis tool based on the git management tool, which lowers the threshold for using the git management tool, supports the correlation and dependency analysis of code patch files, makes the code patch files simpler and more intuitive, and improves the analysis efficiency.
[0146] The technical solution provided by the embodiment of the present invention can be used not only for local code patch file parsing, but also for remote code patch file parsing; and it also supports interface operation and display of specified files in commit.
[0147] Embodiment 3
[0148] The present invention provides a message parsing device, such as Figure 4 As shown, the device includes a receiving module, a processing module, and an output module.
[0149] In this embodiment, the receiving module is used to receive a first message assembled by a user name and an encrypted password string; receive a second message assembled after parsing the attribute information of a patch file input by a user, wherein the attribute information includes a warehouse path; the processing module is used to verify and logically analyze the first message and the second message, and generate a third message; the output module is used to parse the third message.
[0150] Specifically, the receiving module includes a login unit; the processing module includes a detection unit, a parsing unit, a transmission unit, a download unit, a login verification unit, and a logic analysis unit; and the output module includes a display unit. Figure 5 As shown, the message parsing device includes two parts, the front end and the back end. The front end includes a login unit, a detection unit, a parsing unit, a transmission unit, and a display unit. The back end includes a download unit, a login verification unit, a logic analysis unit, and a transmission unit. The parsing unit includes a first parsing unit and a second parsing unit. The transmission unit includes a front-end transmission unit and a back-end transmission unit.
[0151] Furthermore, the login unit is used to receive attribute information of the patch file input by the user; receive an IP address input by the user, and determine whether the format of the IP address is correct;
[0152] If yes, then check the user name entered by the user; if no, then feedback the input error to the user;
[0153] The detecting of the user name input by the user comprises:
[0154] Determine whether the rule of the user name is correct;
[0155] If yes, the password entered by the user is checked; if no, an input error is fed back to the user;
[0156] The detecting of the password input by the user includes:
[0157] Determining whether the password rule is correct;
[0158] If yes, the password is encrypted using the md5sum command, and the user name and the encrypted password string are assembled to form a first message; if no, an input error is fed back to the user.
[0159] Furthermore, the detection unit is used to detect the attribute information of the patch file; and determine whether the attribute information format of the patch file is qualified.
[0160] Furthermore, the first parsing unit is used to parse the attribute information of the patch file and assemble the parsed information to form a second message; the second parsing unit is used to determine whether to display the file content of the third message; determine whether to display the specified file of the third message; determine whether to exit the parsing process of the third message; if so, exit the parsing process of the third message.
[0161] Furthermore, the transmission unit is used to transmit the second message to the login verification unit; and transmit the third message to the second parsing unit.
[0162] Further, the login verification unit is used to determine whether the username and password of the second message meet the rules at the same time; and is also used to determine whether the username and password of the first message meet the rules at the same time;
[0163] If yes, then compare and verify the username and password of the first message with the username and password maintained in the configuration file; if no, then determine the legitimacy of the user;
[0164] Determine whether the username and password of the first message are qualified by comparison and verification with the username and password maintained in the configuration file;
[0165] Determine whether the user is legitimate;
[0166] If so, it is determined whether the remote repository path corresponding to the user in the configuration file has been downloaded; if not, an input error is fed back to the user.
[0167] Furthermore, the logic analysis unit is used to perform intersection processing on the first message and the second message according to the intersection rule, assemble corresponding git commands according to the intersection processing results to collect information, perform dependency and correlation analysis on the collected information, and assemble the information after dependency and correlation analysis into a third message.
[0168] Furthermore, the downloading unit is used to download the local warehouse path input by the user.
[0169] Furthermore, the display unit is used to display the file content of the third message in a relational manner; display the file name list of the third message in a relational manner; display the specified files of the third message; and display all files of the third message.
[0170] Specifically, the display unit is used to display dependent and related patch file patch information; the download unit is used for online download of the code repository and also for updating the repository code; the detection unit is used to detect user input information; the first parsing unit is used to parse the front-end input information, and the second parsing unit is used to parse the third message information fed back by the back-end; the front-end transmission unit is used to push the front-end input information; the back-end transmission unit is used to push the third message information after logical analysis of the feedback; the login verification unit is used to verify the user name and password; the logic analysis unit is used to perform logical analysis on the submission information and patch files of the patch files and record related analysis information.
[0171] The technical solution provided by the embodiment of the present invention has the following beneficial effects:
[0172] The technical solution provided by the embodiment of the present invention is based on the git management tool, provides a code patch file analysis tool, lowers the threshold for using the git management tool, supports the correlation and dependency analysis of the code patch file, makes the code patch file simpler and more intuitive, and improves the analysis efficiency.
[0173] The technical solution provided by the embodiment of the present invention can be used not only for local code patch file parsing, but also for remote code patch file parsing; and it also supports interface operation and display of specified files in commit.
[0174] Embodiment 4
[0175] The present invention provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the following message parsing method can be executed:
[0176] Receiving a first message composed of a user name and an encrypted password string;
[0177] receiving a second message assembled after parsing attribute information of a patch file input by a user, wherein the attribute information includes a warehouse path;
[0178] Verifying and logically analyzing the first message and the second message, and generating a third message;
[0179] The third message is parsed.
[0180] The technical solution provided by the embodiment of the present invention has the following beneficial effects:
[0181] The technical solution provided by the embodiment of the present invention is based on the git management tool, provides a code patch file analysis tool, lowers the threshold for using the git management tool, supports the correlation and dependency analysis of the code patch file, makes the code patch file simpler and more intuitive, and improves the analysis efficiency.
[0182] The technical solution provided by the embodiment of the present invention can be used not only for local code patch file parsing, but also for remote code patch file parsing; and it also supports interface operation and display of specified files in commit.
[0183] Embodiment 5
[0184] The present invention provides a computer storage medium, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the following steps are implemented:
[0185] Receiving a first message composed of a user name and an encrypted password string;
[0186] receiving a second message assembled after parsing attribute information of a patch file input by a user, wherein the attribute information includes a warehouse path;
[0187] Verifying and logically analyzing the first message and the second message, and generating a third message;
[0188] The third message is parsed.
[0189] Furthermore, before receiving the first message composed of the user name and the encrypted password string, the method further comprises:
[0190] Receive the IP address input by the user and determine whether the format of the IP address is correct;
[0191] If yes, then check the user name entered by the user; if no, then feedback the input error to the user;
[0192] The detecting of the user name input by the user comprises:
[0193] Determine whether the rule of the user name is correct;
[0194] If yes, the password entered by the user is checked; if no, an input error is fed back to the user;
[0195] The detecting of the password input by the user includes:
[0196] Determining whether the password rule is correct;
[0197] If yes, the password is encrypted using the md5sum command, and the user name and the encrypted password string are assembled to form a first message; if no, an input error is fed back to the user.
[0198] Furthermore, before receiving the second message formed by parsing the attribute information of the patch file input by the user and assembling it, the method further includes:
[0199] Receive attribute information of the patch file input by the user;
[0200] Detecting the attribute information of the patch file;
[0201] The detecting the attribute information of the patch file includes:
[0202] Determining whether the attribute information format of the patch file is qualified;
[0203] If so, the attribute information of the patch file is parsed, the parsed information is assembled into a second message, and it is determined whether the user name and password of the second message meet the rules at the same time; if not, an input error is fed back to the user.
[0204] Further, the verifying and logically analyzing the first message and the second message and generating a third message includes:
[0205] Determine whether the username and password of the first message satisfy the rules at the same time;
[0206] If yes, then compare and verify the username and password of the first message with the username and password maintained in the configuration file; if no, then determine the legitimacy of the user;
[0207] The comparing and verifying the user name and password of the first message with the user name and password maintained in the configuration file includes:
[0208] Determine whether the username and password of the first message are qualified by comparison and verification with the username and password maintained in the configuration file;
[0209] If yes, then continue to check the attribute information of the patch file input by the user; if no, then feedback an input error to the user.
[0210] Furthermore, the judging of the legitimacy of the user includes:
[0211] Determine whether the user is legitimate;
[0212] If yes, then determine whether the remote repository path corresponding to the user in the configuration file has been downloaded; if no, feedback an input error to the user;
[0213] The determining whether the remote repository path corresponding to the user in the configuration file has been downloaded includes:
[0214] Determine whether the remote repository path corresponding to the user in the configuration file has been downloaded;
[0215] If so, the first message and the second message are intersected according to the intersection rules, the corresponding git commands are assembled according to the intersection processing results to collect information, the collected information is analyzed for dependency and correlation, and the information after the dependency and correlation analysis is assembled into a third message; if not, the local warehouse path input by the user is first downloaded, and then the first message and the second message are intersected according to the intersection rules.
[0216] Further, parsing the third message includes:
[0217] Displaying the third message according to the parsing result of the third message;
[0218] The corresponding display of the third message according to the parsing result of the third message includes:
[0219] Determining whether to display the file content of the third message;
[0220] If yes, then the file content of the third message is displayed in a correlated manner; if no, then the file name list of the third message is displayed in a correlated manner;
[0221] Determining whether to display the specified file of the third message;
[0222] If so, the specified file of the third message is displayed; if not, all files of the third message are displayed.
[0223] Further, the parsing of the third message further includes:
[0224] Determine whether to exit the parsing process of the third message;
[0225] If yes, then exit the parsing process of the third message; if no, then re-check the attribute information of the patch file input by the user.
[0226] Figure 6 An exemplary system provided for Embodiment 5 of the present invention that can be used to implement various embodiments described in this application;
[0227] like Figure 6As shown, in some embodiments, the system can be used as any of the above-mentioned devices for message parsing in each of the embodiments. In some embodiments, the system may include one or more computer-readable media (e.g., system memory or NVM / storage device) having a result and one or more processors (e.g., (one or more) processors) coupled to the one or more computer-readable media and configured to execute the result to implement the module to perform the actions described in the present application.
[0228] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by computer programs and related hardware. The above-mentioned computer programs can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided by the present invention can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0229] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0230] The above-mentioned embodiments only express several implementation methods of the present invention, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the patent of the present invention shall be subject to the attached claims.
Claims
1. A message parsing method, It is characterized in that The method is based on a distributed version management tool and includes: Receiving a first message composed of a user name and an encrypted password string; receiving a second message assembled after parsing attribute information of a patch file input by a user, wherein the attribute information includes a warehouse path; Verifying and logically analyzing the first message and the second message, and generating a third message; Parsing the third message; The verifying and logically analyzing the first message and the second message, and generating a third message, includes: Determine whether the username and password of the first message satisfy the rules at the same time; If yes, then compare and verify the username and password of the first message with the username and password maintained in the configuration file; if no, then determine the legitimacy of the user; The comparing and verifying the user name and password of the first message with the user name and password maintained in the configuration file includes: Determine whether the username and password of the first message are qualified by comparison and verification with the username and password maintained in the configuration file; If yes, continue to check the attribute information of the patch file input by the user; if no, feedback the input error to the user; The judging of the legitimacy of the user includes: Determine whether the user is legitimate; If yes, then determine whether the remote repository path corresponding to the user in the configuration file has been downloaded; if no, feedback an input error to the user; The determining whether the remote repository path corresponding to the user in the configuration file has been downloaded includes: Determine whether the remote repository path corresponding to the user in the configuration file has been downloaded; If so, the first message and the second message are intersected according to the intersection rules, the corresponding git commands are assembled according to the intersection processing results to collect information, the collected information is analyzed for dependency and correlation, and the information after the dependency and correlation analysis is assembled into a third message; if not, the local warehouse path input by the user is first downloaded, and then the first message and the second message are intersected according to the intersection rules.
2. The message parsing method according to claim 1, It is characterized in that Before receiving the first message composed of the user name and the encrypted password string, the method includes: Receive the IP address input by the user and determine whether the format of the IP address is correct; If yes, then check the user name entered by the user; if no, then feedback the input error to the user; The detecting of the user name input by the user comprises: Determine whether the rule of the user name is correct; If yes, the password entered by the user is checked; if no, an input error is fed back to the user; The detecting of the password input by the user includes: Determining whether the password rule is correct; If yes, the password is encrypted using the md5sum command, and the user name and the encrypted password string are assembled to form a first message; if no, an input error is fed back to the user.
3. The message parsing method according to claim 1, It is characterized in that Before receiving the second message formed by parsing the attribute information of the patch file input by the user, the method includes: Receive attribute information of the patch file input by the user; Detecting the attribute information of the patch file; The detecting the attribute information of the patch file includes: Determining whether the attribute information format of the patch file is qualified; If so, the attribute information of the patch file is parsed, the parsed information is assembled into a second message, and it is determined whether the user name and password of the second message meet the rules at the same time; if not, an input error is fed back to the user.
4. The message parsing method according to claim 1, It is characterized in that The parsing of the third message includes: Displaying the third message according to the parsing result of the third message; The corresponding display of the third message according to the parsing result of the third message includes: Determining whether to display the file content of the third message; If yes, then the file content of the third message is displayed in a correlated manner; if no, then the file name list of the third message is displayed in a correlated manner; Determining whether to display the specified file of the third message; If so, the specified file of the third message is displayed; if not, all files of the third message are displayed.
5. The message parsing method according to claim 4, It is characterized in that The parsing of the third message further includes: Determine whether to exit the parsing process of the third message; If yes, then exit the parsing process of the third message; if no, then re-check the attribute information of the patch file input by the user.
6. A message parsing device, It is characterized in that The device comprises: The receiving module is used to receive a first message formed by assembling a user name and an encrypted password string; and receive a second message formed by parsing attribute information of a patch file input by a user, wherein the attribute information includes a warehouse path; A processing module, used to verify and logically analyze the first message and the second message, and generate a third message; An output module, used for parsing the third message; The verifying and logically analyzing the first message and the second message, and generating a third message, includes: Determine whether the username and password of the first message satisfy the rules at the same time; If yes, then compare and verify the username and password of the first message with the username and password maintained in the configuration file; if no, then determine the legitimacy of the user; The comparing and verifying the user name and password of the first message with the user name and password maintained in the configuration file includes: Determine whether the username and password of the first message are qualified by comparison and verification with the username and password maintained in the configuration file; If yes, continue to check the attribute information of the patch file input by the user; if no, feedback the input error to the user; The judging of the legitimacy of the user includes: Determine whether the user is legitimate; If yes, then determine whether the remote repository path corresponding to the user in the configuration file has been downloaded; if no, feedback an input error to the user; The determining whether the remote repository path corresponding to the user in the configuration file has been downloaded includes: Determine whether the remote repository path corresponding to the user in the configuration file has been downloaded; If so, the first message and the second message are intersected according to the intersection rules, the corresponding git commands are assembled according to the intersection processing results to collect information, the collected information is analyzed for dependency and correlation, and the information after the dependency and correlation analysis is assembled into a third message; if not, the local warehouse path input by the user is first downloaded, and then the first message and the second message are intersected according to the intersection rules.
7. A computer device comprising a memory, a processor and a computer program stored in the memory, It is characterized in that The processor executes the computer program to implement the steps of the method according to any one of claims 1 to 5.
8. A computer storage medium having a computer program stored thereon, It is characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 5 are implemented.
Citation Information
Patent Citations
Message translation method and device based on net address translation (NAT) rule
CN105939269A
Code management method and device based on git, equipment and storage medium
CN109783076A
