A safety testing method and apparatus for a remote vehicle control system

By obtaining application element location information to generate test scripts, controlling the application to generate test request messages, and using a proxy server to process response messages, the problem of the inability to detect communication vulnerabilities in remote vehicle control systems in existing technologies is solved, and efficient security testing applicability is achieved.

CN114815780BActive Publication Date: 2025-10-28HUAZHONG UNIV OF SCI & TECH +1
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202210449574.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-26
Publication Date
2025-10-28
Estimated Expiration
2042-04-26

AI Technical Summary

Technical Problem

Existing security testing methods for remote vehicle control systems cannot effectively detect vulnerabilities in the communication and signal processing mechanisms between the mobile terminal, server, and vehicle, and reverse engineering encryption algorithms is cumbersome and difficult to implement.

Method used

By obtaining the application's element location information, generating test scripts, and controlling the application to generate test request messages, and using a proxy server to capture and modify response messages, security testing of the communication process between the mobile terminal and the server can be achieved, avoiding reverse engineering to obtain encryption algorithms.

Benefits of technology

It enables security threat detection during communication between mobile terminals and servers without reverse engineering the encryption algorithm, and is highly portable and applicable to different applications.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114815780B_ABST
    Figure CN114815780B_ABST
Patent Text Reader

Abstract

This invention discloses a security testing method and apparatus for a remote vehicle control system. The security testing method includes: acquiring element location information within an application used to control the vehicle on a mobile terminal, the element location information reflecting the position of each element in the application's display interface; generating a test script based on the element location information and a test strategy, the test strategy including several different verification messages generated according to preset rules; and controlling the application to generate corresponding test request messages according to different verification messages and sending them to a server via the test script. This invention can detect security threats during communication between the mobile terminal and the server without reverse engineering the application to obtain the encryption algorithm.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of vehicle network security technology, specifically to a security testing method and apparatus for a remote vehicle control system. Background Technology

[0002] Currently, with the development of vehicle networking technology, the traditional method of controlling vehicles through mechanical means has gradually become outdated, and has been replaced by electrical and network control. While electrical and network control bring convenience to users, they also introduce information security issues. Some criminals can exploit vulnerabilities in the vehicle control system to attack vehicles, posing a huge threat to users' lives and property.

[0003] The mainstream remote vehicle control system currently consists of a mobile terminal, a server, and a vehicle. The vehicle is controlled through information interaction between these three terminals. Existing testing methods mainly focus on the security testing of the application on the mobile terminal. This method only targets the security of the application and cannot detect vulnerabilities in the communication and signal processing mechanisms between the mobile terminal, server, and vehicle. Furthermore, current methods for testing vulnerabilities in the communication between the mobile terminal and the server require reverse engineering the application to obtain the encryption algorithm, which is a cumbersome and difficult step to implement.

[0004] Therefore, it is particularly important to design a safety testing method and device for remote vehicle control systems that can solve the above problems. Summary of the Invention

[0005] The purpose of this invention is to provide a security testing method and apparatus for a remote vehicle control system, which can detect security threats during communication between a mobile terminal and a server without reverse engineering the application to obtain the encryption algorithm.

[0006] To achieve the above objectives, the present invention provides a safety testing method for a remote vehicle control system, comprising:

[0007] Obtain element location information of an application used to control a vehicle in a mobile terminal, wherein the element location information reflects the position of each element in the display interface of the application.

[0008] A test script is generated based on the element location information and the test strategy. The test strategy includes several different verification messages, which are generated according to preset composition rules.

[0009] The test script controls the application to generate corresponding test request messages according to different verification information and send them to the server.

[0010] Optionally, the security testing method further includes:

[0011] When the server sends a first response message including verification error information to the mobile terminal, the first response message is intercepted.

[0012] The first response message, which contained verification error information, is modified to a second response message containing verification correct information.

[0013] The second response message is sent to the mobile terminal.

[0014] Optionally, the security testing method further includes:

[0015] Deploy a proxy server between the mobile terminal and the server.

[0016] The method for obtaining the verification correctness information includes:

[0017] Send a request message generated based on the correct verification information to the server.

[0018] The proxy server captures the correct response message returned by the server to the mobile terminal and obtains the verification correct information in the correct response message;

[0019] The method for obtaining verification error information includes:

[0020] Send a request message generated based on the error verification information to the server.

[0021] The proxy server captures the error response message returned by the server to the mobile terminal and obtains the verification error information in the error response message.

[0022] Optionally, a proxy server may be deployed between the mobile terminal and the server.

[0023] The application in the mobile terminal is controlled to generate request messages based on at least two identical authentication information and send the generated request messages to the server.

[0024] The proxy server captures the request messages sent by the mobile terminal to the server and compares the request messages with each other.

[0025] Optionally, a proxy server may be deployed between the mobile terminal and the server.

[0026] The testing strategy also includes:

[0027] All generated test request messages are stored on the proxy server;

[0028] The proxy server sends the test request messages to the server one by one;

[0029] or

[0030] Each test request message generated is sent to the server via the proxy server.

[0031] Optionally, the element location information includes the location information of content input on the keyboard in the application;

[0032] The verification information is converted into keyboard click commands based on the element location information;

[0033] The application generates the test request message corresponding to the verification information according to the keyboard click command.

[0034] Optionally, the preset configuration rules include:

[0035] The character composition type and number of characters in the verification information.

[0036] To achieve the above objectives, the present invention also provides a safety testing device for a remote vehicle control system, comprising:

[0037] The acquisition module is used to acquire element location information of the application used to control the vehicle in the mobile terminal, wherein the element location information reflects the position of each element in the display interface of the application.

[0038] The generation module is used to generate a test script based on the element location information and the test strategy. The test strategy includes several different verification messages, which are generated according to preset composition rules.

[0039] The testing module is used to control the application to generate corresponding test request messages according to different verification information and send them to the server through the test script.

[0040] To achieve the above objectives, the present invention also provides an electronic device, comprising:

[0041] processor;

[0042] A memory in which executable instructions of the processor are stored;

[0043] The processor is configured to perform the safety testing method for a remote vehicle control system as described above by executing the executable instructions.

[0044] To achieve the above objectives, the present invention also provides a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the safety testing method for a remote vehicle control system as described above.

[0045] The present invention also provides a computer program product or computer program comprising computer instructions stored in a computer-readable storage medium. A processor of an electronic device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the electronic device to perform the aforementioned safety testing method for a remote vehicle control system.

[0046] This invention, after obtaining the element location information within an application used to control a vehicle, can generate a test script based on the element location information and a test strategy. The test strategy includes several different verification messages, generated according to preset rules. By executing the test script, the application can be controlled to generate corresponding test request messages according to different verification messages and send them to the server, thereby achieving security testing of information transmission between the mobile terminal and the server. Because this invention directly controls the application to generate test request messages through the test script, it eliminates the need to reverse engineer the application to obtain the encryption algorithm for message generation. Furthermore, it can be applied to different applications simply by changing the relevant parameters of the test script, exhibiting high portability. Attached Figure Description

[0047] Figure 1 This is a flowchart of a safety testing method for a remote vehicle control system according to an embodiment of the present invention.

[0048] Figure 2 This is a flowchart of a method for generating test messages using the keyboard within an application, according to an embodiment of the present invention.

[0049] Figure 3 This is a flowchart of a method for modifying a first response message into a second response message and performing a test according to an embodiment of the present invention.

[0050] Figure 4 This is a flowchart of a method for comparing request messages generated with the same verification information according to an embodiment of the present invention.

[0051] Figure 5 This is an information transmission diagram of the remote vehicle control system of the present invention.

[0052] Figure 6 This is an interface diagram of the WEditor of this invention for locating elements in an application.

[0053] Figure 7 This is a screenshot of the response message with verification error information displayed in the Mitmproxy interface.

[0054] Figure 8 This is a screenshot of the response message with verified correctness displayed in the Mitmproxy interface.

[0055] Figure 9 This is a screenshot of the login request message displayed in Mitmproxy.

[0056] Figure 10 This is a schematic block diagram of a safety testing device for a remote vehicle control system according to an embodiment of the present invention.

[0057] Figure 11 This is a schematic block diagram of an electronic device according to an embodiment of the present invention. Detailed Implementation

[0058] To explain the technical content, objectives, and effects of the present invention in detail, the following description is provided in conjunction with the embodiments and accompanying drawings.

[0059] In the communication process of a remote vehicle control system, the communication between the vehicle-mounted terminal and the server, between the server and the operator, and between the operator and the mobile terminal are relatively secure. Attackers find it difficult to obtain information during these communication processes. Therefore, the security threat to a remote vehicle control system mainly exists in the communication process between the server and the mobile terminal. To address this, this invention discloses a security testing method for a remote vehicle control system, capable of performing security tests on the information transmission process between the mobile terminal and the server.

[0060] Specifically, please refer to Figure 1 The security testing method includes:

[0061] S101. Obtain element location information of the application used to control the vehicle in the mobile terminal. The element location information reflects the position of each element in the display interface of the application.

[0062] It is understandable that element positioning information refers to the position information of various elements in the application's display interface, such as text input boxes and OK buttons.

[0063] S102. Generate a test script based on the element location information and the test strategy. The test strategy includes several different verification messages, which are generated according to preset composition rules.

[0064] Specifically, the verification information can be a login password, verification code, or PIN code; any information used to verify identity is acceptable, and no specific restrictions are imposed in this invention.

[0065] Understandably, the preset character composition rules include the character composition type and the number of characters in the verification information. The character composition type of the verification information can be Chinese characters, numbers, letters, or special symbols, etc. The verification information can be composed of a single character type or a combination of multiple character types; the number of characters refers to the number of digits in the characters. For example, a typical verification code is a four- or six-digit pure numeric verification code, and this preset composition rule can generate verification information such as 0000-9999 or 000000-999999.

[0066] S103. The test script controls the application to generate corresponding test request messages according to different verification information and send them to the server.

[0067] Specifically, the generated verification information can be iterated to generate corresponding test request messages, which are then sent to the server. Upon receiving the test request messages, the server returns corresponding response messages. These response messages can be intercepted and their presence can be determined. If they do, the attack is successful, indicating a security threat in the communication between the server and the mobile terminal. If, after all test request messages are sent to the server, no valid verification information is found in the server's response messages, the attack fails, again indicating no security threat in the communication between the server and the mobile terminal. If the returned response messages contain information indicating expired verification information or that other protective verification information has been compromised, the test can be terminated early, and no security threat is deemed to exist.

[0068] Please see Figure 2 In some embodiments, the security testing method further includes:

[0069] S201, Element positioning information includes the position information of content input on the keyboard in the application.

[0070] S202. Convert the verification information into keyboard click commands based on the element location information.

[0071] S203. The application generates a test request message corresponding to the verification information according to the keyboard click command.

[0072] When entering verification information that is a PIN code, due to the program's security protection mechanism, it is not possible to directly input the PIN code using the send_keys function. In this case, it is necessary to use the keyboard command to click on the application's keyboard to input the verification information into the input box.

[0073] Specifically, a proxy server is deployed between the mobile terminal and the server. Information between the mobile terminal and the server is transmitted through the proxy server. The proxy server is equipped with a packet capture tool that can capture and parse data packets from the mobile terminal and the server.

[0074] In some embodiments, the testing strategy further includes:

[0075] Store all generated test request messages on the proxy server;

[0076] The proxy server sends test request messages to the server one by one.

[0077] or

[0078] Each test request message is sent to the server via the proxy server.

[0079] The method of storing all generated test request messages on the proxy server first and then sending them to the server one by one avoids the process of generating messages while sending them, thus improving the testing speed. The method of sending each generated test request message to the server can save a lot of testing time when the response message contains information indicating that the verification information has expired or that other protection verification information has been brute-forced, as it does not require generating all test request messages.

[0080] Please see Figure 3 In some embodiments, the security testing method further includes:

[0081] S301. When the server sends a first response message including verification error information to the mobile terminal, the first response message is intercepted.

[0082] S302. Modify the first response message containing the verification error message into a second response message containing the verification correct message.

[0083] S303. Send a second response message to the mobile terminal.

[0084] If the mobile terminal performs the same action as the verified correct action after receiving the second response message, then a corresponding security threat is determined to exist.

[0085] Specifically, the methods for verifying the acquisition of correct information include:

[0086] Send a request message generated based on the correct verification information to the server;

[0087] The proxy server captures the correct response message returned by the server to the mobile terminal and obtains the verification information in the correct response message.

[0088] Specifically, the methods for obtaining verification error messages include:

[0089] Send a request message generated based on the error verification information to the server;

[0090] The proxy server captures the error response messages returned by the server to the mobile terminal and obtains the verification error information in the error response messages.

[0091] Please see Figure 4 In some embodiments, the security testing method further includes:

[0092] S401. Control the application in the mobile terminal to generate request messages based on at least two identical authentication information and send the generated request messages to the server.

[0093] S402. Capture the request messages sent by the mobile terminal to the server through the proxy server and compare the request messages with each other.

[0094] At least two identical verification messages are generated and compared. If the content of the request messages is consistent, it is considered that there is a corresponding security threat to the information processing mechanism between the mobile terminal and the server.

[0095] The following specific example illustrates the technical solution of the present invention:

[0096] Please see Figure 5 The diagram illustrates the information transmission process for a user to log in to the application and unlock the door lock through the application. Specifically, the login process involves the application on the mobile terminal sending a login verification code request, including the user's mobile phone number, to the server. Upon receiving the login verification code request, the server sends the verification code to the mobile terminal corresponding to the mobile phone number through the mobile operator. After receiving the verification code, the mobile terminal sends a login request to the server according to the verification code. The server verifies the login request, and if the verification is successful, it returns a login response to the mobile terminal, allowing the user to successfully log in to the application.

[0097] The specific process of unlocking the door is as follows: The mobile terminal application sends an unlock request to the server. After receiving the unlock request, the server sends an unlock response to the mobile terminal. After receiving the unlock response, the application on the mobile terminal asks the user to enter a PIN code. The user enters the PIN code, generates a corresponding PIN code verification request, and sends it to the server. The server receives the PIN code verification request and verifies it. If the verification is correct, it returns a verified PIN code verification response to the mobile terminal, enabling the application to generate an unlock request with authentication to the server. Upon receiving the unlock request, the server sends an unlock command to the vehicle.

[0098] To test the aforementioned remote vehicle control system, a personal computer can be used as a proxy server. The personal computer and a mobile terminal with the application to be tested installed are connected, either via USB or by placing the personal computer on the same local area network (LAN). When using a LAN connection, an ADB debugging tool (Android Debug Bridge) needs to be installed on the personal computer. The ADB debugging tool allows the personal computer to connect to the mobile terminal via its IP address. A packet capture tool, Mitmproxy, is also installed on the personal computer. After configuring the mobile terminal and personal computer, running Mitmproxy allows the capture of data packets transmitted between the server and the mobile terminal.

[0099] The personal computer also has UIAutomator and WEditor installed. WEditor is used to obtain element positioning information from the application, such as... Figure 6 As shown, Figure 6 The UIAutomator tool can retrieve the position information of the phone number input field, verification code input field, and login confirmation button. Based on this position information, test scripts can be written using UIAutomator, which can then control the application to perform corresponding tests.

[0100] The test script can control the application to generate a large number of login request messages. If the verification code consists of six digits, it can generate one million login request messages for security testing. Similarly, the test script can control the application to generate a large number of PIN code verification request messages. If the PIN code consists of six digits, it can generate one million PIN code verification request messages for security testing. Since the PIN code cannot be input through the send_keys function, the test script can simulate keyboard clicks based on the keyboard input position information obtained by WEditor.

[0101] A personal computer can be used to capture the login response message returned by the server after receiving the login request, and the captured login response message can be viewed, such as... Figure 7 and Figure 8 As shown, where, according to Figure 7 and Figure 8 It can obtain the content of the verification error message and the verification correct message. On a personal computer, the verification error message in the login response message returned by the server to the mobile terminal with the verification error message is modified to the verification correct message. The modified login response message is then returned to the mobile terminal. UIAutomator monitors whether the application's display page changes, thereby achieving security testing.

[0102] like Figure 9As shown, a personal computer can capture login request messages sent from a mobile terminal to a server and display the message content on the Mitmproxy interface. It can control the application to repeatedly enter the same verification code twice to generate the corresponding login request message and send it. The personal computer can compare the contents of the two login request messages to test whether there are any security threats in the information processing mechanism between the mobile terminal and the server.

[0103] This invention, after obtaining the element location information within an application used to control a vehicle, can generate a test script based on the element location information and a test strategy. The test strategy includes several different verification messages, generated according to preset rules. By executing the test script, the application can be controlled to generate corresponding test request messages according to different verification messages and send them to the server, thereby achieving security testing of information transmission between the mobile terminal and the server. Because this invention directly controls the application to generate test request messages through the test script, it eliminates the need to reverse engineer the application to obtain the encryption algorithm for message generation. Furthermore, it can be applied to different applications simply by changing the relevant parameters of the test script, exhibiting high portability.

[0104] Please see Figure 10 The present invention also discloses a safety testing device for a remote vehicle control system, comprising:

[0105] The acquisition module 100 is used to acquire element location information of the application used to control the vehicle in the mobile terminal. The element location information reflects the position of each element in the display interface of the application.

[0106] The generation module 200 is used to generate test scripts based on element location information and test strategy. The test strategy includes several different verification messages, which are generated according to preset composition rules.

[0107] The test module 300 is used to control the application to generate corresponding test request messages according to different verification information and send them to the server through test scripts.

[0108] This invention enables security testing of information transmission between mobile terminals and servers. Furthermore, since this invention directly controls the application to generate test request messages through test scripts, it does not require reverse engineering of the application to obtain encryption algorithms to generate messages. Moreover, it can be applied to different applications simply by changing the relevant parameters of the test script, thus exhibiting high portability.

[0109] Please see Figure 11 The present invention also discloses an electronic device, comprising:

[0110] Processor 40;

[0111] Memory 50, which stores executable instructions of processor 40;

[0112] The processor 40 is configured to execute the safety testing method for the remote vehicle control system described above by executing executable instructions.

[0113] This invention also discloses a computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the safety testing method for a remote vehicle control system as described above.

[0114] This invention also discloses a computer program product or computer program, which includes computer instructions stored in a computer-readable storage medium. A processor of an electronic device reads the computer instructions from the computer-readable storage medium and executes the computer instructions, causing the electronic device to perform the safety testing method for a remote vehicle control system as described above.

[0115] It should be understood that, in the embodiments of the present invention, the processor may be a central processing unit (CPU), but it may also be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor.

[0116] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by hardware related to computer program instructions. The program can be stored in a computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. The storage medium can be a magnetic disk, optical disk, read-only memory (ROM), or random access memory (RAM), etc.

[0117] The above-disclosed examples are merely preferred embodiments of the present invention and should not be construed as limiting the scope of the present invention. Therefore, any equivalent variations made in accordance with the claims of the present invention are within the scope of the present invention.

Claims

1. A safety testing method for a remote vehicle control system, characterized in that, include: Obtain element location information of an application used to control a vehicle in a mobile terminal, wherein the element location information reflects the position of each element in the display interface of the application. A test script is generated based on the element location information and the test strategy. The test strategy includes several different verification messages, which are generated according to preset composition rules. The test script controls the application to generate corresponding test request messages according to different verification information and send them to the server. Specifically, when the server sends a first response message including verification error information to the mobile terminal, the first response message is intercepted. Modify the first response message, which contains verification error information, into a second response message, which contains verification correct information. The second response message is sent to the mobile terminal.

2. The safety testing method for a remote vehicle control system as described in claim 1, characterized in that, Also includes: Deploy a proxy server between the mobile terminal and the server. The method for obtaining the verification correctness information includes: Send a request message generated based on the correct verification information to the server. The proxy server captures the correct response message returned by the server to the mobile terminal and obtains the verification correct information in the correct response message; The method for obtaining verification error information includes: Send a request message generated based on the error verification information to the server. The proxy server captures the error response message returned by the server to the mobile terminal and obtains the verification error information in the error response message.

3. The safety testing method for a remote vehicle control system as described in claim 1, characterized in that, Deploy a proxy server between the mobile terminal and the server. The application in the mobile terminal is controlled to generate request messages based on at least two identical authentication information and send the generated request messages to the server. The proxy server captures the request messages sent by the mobile terminal to the server and compares the request messages with each other.

4. The safety testing method for a remote vehicle control system as described in claim 1, characterized in that, Deploy a proxy server between the mobile terminal and the server. The testing strategy also includes: All generated test request messages are stored on the proxy server; The proxy server sends the test request messages to the server one by one; or Each test request message generated is sent to the server via the proxy server.

5. The safety testing method for a remote vehicle control system as described in claim 1, characterized in that, The element location information includes the location information of content input on the keyboard in the application; The verification information is converted into keyboard click commands based on the element location information; The application generates the test request message corresponding to the verification information according to the keyboard click command.

6. The safety testing method for a remote vehicle control system as described in claim 1, characterized in that, The preset composition rules include: The character composition type and number of characters in the verification information.

7. A safety testing device for a remote vehicle control system, characterized in that, include: The acquisition module is used to acquire element location information of an application used to control a vehicle in a mobile terminal, wherein the element location information reflects the position of each element in the display interface of the application. The generation module is used to generate a test script based on the element location information and the test strategy. The test strategy includes several different verification messages, which are generated according to preset composition rules. The testing module is used to control the application to generate corresponding test request messages according to different verification information and send them to the server through the test script.

8. An electronic device, characterized in that, include: processor; A memory in which executable instructions of the processor are stored; The processor is configured to execute the safety testing method for the remote vehicle control system according to any one of claims 1-6 by executing the executable instructions.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the safety testing method for the remote vehicle control system as described in any one of claims 1-6.

Citation Information

Patent Citations

  • Method, device and system for testing running condition of application program in mobile terminal

    CN109582556A

  • Automatic test method and device, computer device and storage medium

    CN109828903A

  • Test script recording method, application program test method and related devices

    CN110716853A

  • Security test method and device, computer equipment and storage medium

    CN114039760A