Mobile device, method of securely authenticating an agent in a mobile device, medium and product
By combining simulators to capture agent actions and state information in mobile devices, and using visual language models for contextual judgment and formal verification, the reliability of security verification of mobile device GUI agents is insufficient, achieving broader, deeper, and more efficient security detection.
Patent Information
- Application Number
- CN202511509025.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-22
- Publication Date
- 2026-01-23
- Estimated Expiration
- 2045-10-22
AI Technical Summary
Existing technologies for security verification of GUI agents in mobile devices suffer from problems such as limited detection dimensions and insufficient reliability, making it difficult to comprehensively and accurately identify potential risks.
By combining simulators or debugging tools to capture agent actions and state information, and using visual language models to perform contextual judgment and formal verification, a security verification report is generated, and the final decision is made based on the results of contextual judgment and formal verification.
It improves the breadth, depth, efficiency, and accuracy of security testing, enabling comprehensive identification of potential risks and the generation of interpretable security verification reports.
Smart Images

Figure CN120995453B_ABST
Abstract
Description
Technical Field
[0001] This invention generally relates to computer systems utilizing computational models, and more specifically to mobile devices, methods, media, and products for security verification of intelligent agents within mobile devices. Background Technology
[0002] In recent years, with the rapid development of Large Language Models (LLMs) and multimodal large models (e.g., Vision Language Models (VLMs)), intelligent agents capable of understanding human instructions and autonomously operating computer graphical user interfaces (GUIs) have become a reality. These intelligent agents, especially mobile GUI agents, can perceive the current interface state by analyzing screenshots and parsing the user interface (UI) layout (e.g., accessibility trees, or a11ytrees), and simulate human clicks, swipes, and input to complete a series of complex tasks such as booking tickets, shopping, file management, and information dissemination.
[0003] Mobile devices (such as smartphones, tablets, and laptops) serve as the core of modern personal computing, storing massive amounts of sensitive personal data, including contacts, photos, instant messages, financial accounts, and health information. Therefore, granting an intelligent agent the autonomy to operate a mobile device is tantamount to giving it access to the user's digital life. This high degree of autonomy and permission brings unprecedented convenience, but also introduces serious security and privacy risks. An uncontrolled or maliciously exploited intelligent agent could lead to the following consequences without the user's knowledge:
[0004] - Privacy breach: Sending users' private conversations, files containing sensitive information, or photos to third parties;
[0005] -Causing property damage: Executing unauthorized payment transactions or placing shopping orders;
[0006] - Compromise system integrity: Deleting critical files, tampering with important system settings (e.g., disabling lock screen passwords), installing malicious applications; and
[0007] - Generating or disseminating harmful content: Posting inappropriate remarks or illegal information on social media.
[0008] Therefore, establishing a robust, real-time, and comprehensive security monitoring and verification mechanism for mobile GUI agents has become a key technical bottleneck that must be overcome to move this technology from laboratory research to large-scale practical applications. This mechanism must be able to accurately perceive the complete "situation" of the agent's operations, understanding not only the direct consequences of its behavior but also its potential risks within a specific context.
[0009] In the field of agent security verification, existing technical solutions can be mainly divided into two categories: deterministic rule-based detection schemes and semantic judgment schemes based on large-scale models. These two schemes have different focuses in terms of technical approaches and capabilities, but both also have obvious limitations.
[0010] One existing technical solution for security verification of intelligent agents is a system state detector based on deterministic rules. This type of solution is a relatively traditional security monitoring method. Its core idea is to predefine a set of explicit security rules and trigger these rules by monitoring underlying system events to determine the security of behavior. This solution typically utilizes automated testing tools such as Android Debug Bridge (ADB) and Appium, or sets hooks at the operating system level to monitor low-level activities such as file system read / write, network connection establishment, system setting changes, and application installation / uninstallation in real time. When an event sequence matching a risky behavior pattern defined in a pre-defined rule base is detected, the system issues an alert. However, existing technical solutions of this type write an inspector for each application or scenario, hard-coding fixed security risks, rather than providing a holistic approach applicable to the entire mobile device environment. Furthermore, this solution is currently only in the academic research stage and has not yet been implemented in a practical product. For example, Lee et al.'s MobileSafetyBench (MobileSafetyBench: Evaluating Safety of Autonomous Agents in Mobile DeviceControl, https: / / arxiv.org / abs / 2410.17520) proposes a benchmark for evaluating the safety of mobile agents and implements a rule-based inspector. This inspector scores the safety of the agent's actions by monitoring a series of clearly defined risky behaviors, such as "user data is created / deleted," "password is disabled," or "agent is set."
[0011] However, such technical solutions lack semantic understanding capabilities, exhibiting a "semantic blindness" limitation. It can determine that "an image file has been shared," but cannot understand whether the image content is a landscape photo or a user's ID photo. It can detect that "a piece of text has been entered and sent," but cannot distinguish whether its content is a normal greeting or a password leak. Furthermore, the rule base used is difficult to maintain and has limited coverage. Security threats are constantly evolving, and application interfaces and functions are frequently updated. Relying on manually predefined rule bases makes it difficult to cover all potential risk scenarios, especially against new and covert attacks (such as phishing attacks exploiting UI visual vulnerabilities), which are almost powerless. At the same time, overly broad rules (such as detecting UI elements containing specific sensitive words) may lead to a large number of false positives, affecting normal use.
[0012] Another existing technical approach for security verification of intelligent agents is based on semantic discriminators using large visual language models (VLMs). With breakthroughs in image and language understanding using VLMs, some cutting-edge research has begun exploring the use of VLMs for end-to-end security assessment of the agent's behavioral trajectories. This approach takes a series of data during the agent's task execution, such as high-level instructions and action sequences, as input to a robust VLM (e.g., GPT-4o). Then, by designing specific prompts, the VLM is guided to "judge" or "score" the security and risk category of the entire behavior. The concept of using a Virtual Model (VLM) as a judge can be found in benchmarks and academic research evaluating the security of AI agents, such as Kuntz et al.'s OS-Harm (https: / / arxiv.org / abs / 2506.14866) and Liang et al.'s SafeMobile (https: / / arxiv.org / abs / 2507.00841). These works rely on the model's own knowledge and reasoning ability to identify risks, such as determining whether dialogue content involves privacy or identifying misleading click traps on the UI.
[0013] However, there is currently no representative work on such technical solutions in the mobile device field, and these solutions are only used for text-based agents. Furthermore, these solutions lack a "fact-grounded" understanding of the system state: the VLM's judgments are entirely based on the visual and text input it receives, and it cannot verify the actual state of the device at the underlying level. For example, a malicious application can deceive the VLM by drawing a fake UI, making it believe that a dangerous operation has been canceled, when in fact the operation has already been completed in the background. The VLM cannot verify whether system files have actually been modified or whether a network connection has actually been established. Additionally, these solutions lack reliability and real-time performance: the inference results of large models have a certain degree of randomness and uncertainty, which may lead to "illusions," and for rigorous security judgments, this uncertainty is fatal.
[0014] In summary, there is currently no dedicated and efficient security verification technology solution for mobile device GUI agents. The security verification of mobile device GUI agents remains hampered by a lack of technology that relies on a single detection dimension and insufficient reliability.
[0015] There is a need in the art to improve the technology for securely verifying agents in mobile devices in at least one of the above aspects. Summary of the Invention
[0016] This invention is provided to offer a technique for efficient and reliable security verification of GUI agents on mobile devices.
[0017] One aspect of the present invention provides a mobile device including computing resources, an agent, and a security detector. The agent is configured to: in response to receiving an input instruction from a user of the mobile device, invoke the computing resources to perform an operation, the operation including multiple actions. The security detector is configured to: capture the multiple actions of the agent using a simulator or debugging tool; capture a state associated with each action, the state including a system state and an interface state of the mobile device; and perform security verification on the operation performed by the agent based on the multiple actions and the associated states, wherein the result of the security verification is presented to the user, wherein the security detector is configured to: merge the multiple actions, the system state, and the interface state into a trajectory file; and perform contextual judgment using a visual language model based on the input instruction and the trajectory file, wherein the security verification is performed based on the result of the contextual judgment.
[0018] As described above, the system status of the mobile device includes statistical information of the system files of the mobile device and text information collected from the screen of the mobile device.
[0019] In any of the mobile devices described above, the security detector is configured to perform formal verification based on the statistical information and the textual information, wherein the security verification is performed based on the result of the formal verification.
[0020] The security detector, as described in any of the preceding mobile devices, is configured to: calculate a hash value of statistics associated with time points before and after the execution of one of the plurality of actions; and determine the result of the formal verification based on the consistency of the calculated hash value.
[0021] As described in any of the above mobile devices, the security detector is configured to: set an initial value for a risk quantification value; perform the following operations for all text in the text information: determine whether a sensitive word exists by comparing it with a list of sensitive words; in response to determining that a sensitive word exists, increment the risk quantification value by a first value; query whether a character sequence associated with the user's privacy information exists; in response to determining that a character sequence associated with the user's privacy information exists, increment the risk quantification value by a second value; and in response to determining that the risk quantification value exceeds a preset threshold, determine that the result of the formal verification indicates the presence of a risk.
[0022] For any of the mobile devices described above, the second value is greater than the first value.
[0023] In any of the mobile devices described above, the security detector is configured to determine the result of the security verification based on a logical OR of the result of the context judgment and the result of the formal verification.
[0024] For any of the mobile devices described above, the security detector is further configured to generate a security verification report based on the results of the security verification, wherein the security verification report includes a final security label, the source of risk discovery, a specific risk classification, and the reasoning for the ruling.
[0025] For any of the mobile devices described above, the interface state includes a screenshot of the mobile device's screen and interface layout information.
[0026] Another aspect of the present invention provides a method for security verification of an agent in a mobile device, comprising the following steps: S1: capturing multiple actions of the agent using a simulator or debugging tool, wherein the agent is configured to perform an operation in response to receiving an input instruction from a user of the mobile device, the operation including the multiple actions; S2: capturing a state associated with each action, the state including a system state and an interface state of the mobile device; and S3: performing security verification on the operation performed by the agent based on the multiple actions and the associated state, wherein the result of the security verification is presented to the user. S3 includes: S31: performing contextual judgment using a visual language model based on the input instruction, the multiple actions, the system state, and the interface state, wherein the security verification is performed based on the result of the contextual judgment; S31 includes: S311: merging the multiple actions, the system state, and the interface state into a trajectory file; and S312: performing contextual judgment using the visual language model based on the input instruction and the trajectory file.
[0027] As described in any of the above methods, the system status includes statistical information of the system files of the mobile device and text information collected from the screen of the mobile device.
[0028] As described in any of the above methods, S3 further includes: S32: performing formal verification based on the statistical information and the textual information, wherein the security verification is further performed based on the result of the formal verification.
[0029] As described in any of the preceding methods, S32 includes: S321: calculating a hash value of statistical information associated with the execution of one of the plurality of actions before and after the execution of the action; and S322: determining the result of the formal verification based on the consistency of the calculated hash value.
[0030] As described in any of the above methods, step S32 includes: S323: setting an initial value for the risk quantification value; S324: performing the following operations on all text in the text information: comparing with a list of sensitive words to determine if there are any sensitive words; in response to determining that there are sensitive words, incrementing the risk quantification value by a first value; querying whether there is a character sequence associated with the user's privacy information; in response to determining that there is a character sequence associated with the user's privacy information, incrementing the risk quantification value by a second value; and S325: in response to determining that the risk quantification value exceeds a preset threshold, determining that the result of the formal verification indicates the presence of risk.
[0031] As described in any of the above methods, the second value is greater than the first value.
[0032] As described in any of the above methods, S3 further includes: S33: determining the result of the security verification based on a logical OR of the result of the situation judgment and the result of the formal verification.
[0033] The method described in any of the above methods further includes: S4: generating a security verification report based on the results of the security verification, wherein the security verification report includes a final security label, the source of risk discovery, a specific risk classification, and the reasoning for the decision.
[0034] As described in any of the above methods, the interface state includes a screenshot of the mobile device's screen and interface layout information.
[0035] Another aspect of the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the method described in any of the preceding claims.
[0036] Another aspect of the present invention provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the method described in any of the above embodiments.
[0037] The method according to the present invention overcomes the problem of insufficient reliability of security verification for intelligent agents of graphical user interfaces of mobile devices, and improves the breadth, depth, efficiency and accuracy of security detection. Attached Figure Description
[0038] Figure 1 This is a block diagram of a mobile device according to some embodiments of the present invention.
[0039] Figure 2 A schematic diagram illustrating the execution environment and interaction process according to some embodiments of the present invention is shown.
[0040] Figure 3 A schematic diagram illustrating the process of performing security verification according to some embodiments of the present invention is shown.
[0041] Figure 4 Examples of trajectory files according to some embodiments of the present invention are shown.
[0042] Figure 5 Examples of regular expressions for sensitive word lists and user privacy information according to some embodiments of the present invention are shown.
[0043] Figure 6 This is a flowchart of a method for security verification of an intelligent agent in a mobile device according to some embodiments of the present invention.
[0044] Figure 7This is a flowchart of a first process associated with a method for security verification of an agent in a mobile device, according to some embodiments of the present invention.
[0045] Figure 8 This is a flowchart of a second process associated with a method for security verification of an agent in a mobile device, according to some embodiments of the present invention.
[0046] Figure 9 This is a flowchart of a third process associated with a method for security verification of an agent in a mobile device, according to some embodiments of the present invention.
[0047] Figure 10 This is a block diagram of a computer-readable storage medium according to some embodiments of the present invention.
[0048] Figure 11 This is a block diagram of a computer program product according to some embodiments of the present invention.
[0049] In the accompanying drawings, the same reference numerals refer to the same elements. Detailed Implementation
[0050] In this application, the term "instruction" refers to input to a model (e.g., a large language model) in performing a code generation task, and is generally in the form of natural language. An "instruction" may direct the model to perform a task by generating code, and in response, the model may generate code based on the instruction capable of performing the instructed task.
[0051] In this application, the term "agent" refers to an agent capable of perceiving its environment and taking actions to perform specific goals. An agent primarily refers to software code. Agents can be executed by the computing resources of a computing device. Agents can invoke corresponding models through API interfaces and call appropriate tools (e.g., PDF readers, Python interpreters, calculators, etc.) to interact with various forms of input or to implement corresponding functions.
[0052] In this application, ordinal numbers such as "first," "second," and "third" are used to distinguish different instances of objects with the same name. The ordinal numbers "first," "second," and "third" do not indicate a relative order of the indicated objects in time, space, sequence, or other aspects.
[0053] According to one aspect of the present invention, a mobile device is provided.
[0054] Figure 1 This is a block diagram of a mobile device 100 according to some embodiments of the present invention.
[0055] As an example, mobile device 100 may include any computing device suitable for mobility, such as smartphones, tablets, laptops, etc.
[0056] In some embodiments, the mobile device 100 may include computing resources 110, an agent 120, and a security detector 130.
[0057] In some embodiments, computing resources 110 may include a central processing unit (CPU), a graphics processing unit (GPU), and various other processing units or cores (e.g., arithmetic logic units, integer units, floating-point units, tensor units, etc.).
[0058] In some embodiments, agent 120 may invoke the corresponding model via an application programming interface (API). For example, the model may include a large language model, a multimodal model, a multimodal language model, etc. In some embodiments, the model invoked by agent 120 may be deployed locally on mobile device 100. In some embodiments, the model invoked by agent 120 may be deployed remotely to mobile device 100, for example, in the cloud. In some embodiments, some of the models invoked by agent 120 may be deployed locally on mobile device 100, while others may be deployed remotely to mobile device 100. In some embodiments, agent 120 may invoke various tools to interact with various forms of input or to implement corresponding functions.
[0059] In some embodiments, the security detector 130 may not invoke the model. In some embodiments, the security detector 130 may invoke the corresponding model via an API. For example, the model may include a large language model, a multimodal model, a multimodal language model, etc. In some embodiments, the model invoked by the security detector 130 may be deployed locally on the mobile device 100. In some embodiments, the model invoked by the security detector 130 may be deployed remotely on the mobile device 100, for example, in the cloud. In some embodiments, some of the models invoked by the security detector 130 may be deployed locally on the mobile device 100, while others may be deployed remotely on the mobile device 100. In some embodiments, the security detector 130 may invoke various tools to interact with various forms of input or to implement corresponding functions. The following will combine... Figure 2 and Figure 3 The functions and specific implementation of the security detector 130 are further described.
[0060] Figure 2A schematic diagram illustrating the execution environment and interaction process according to some embodiments of the present invention is shown.
[0061] Figure 2 The interaction process can be in Figure 1 It is executed in mobile device 100. For ease of explanation, in... Figure 2 The computing resources 110 of the mobile device 100 are omitted.
[0062] The agent 120 can be configured to invoke computing resources to perform an operation, which may include multiple actions 230. In some embodiments, the agent 120 can be configured to perform an operation in response to receiving a user input instruction 210.
[0063] The security detector 130 can be configured to capture multiple actions 230 of the agent 120 using a simulator or debugging tool.
[0064] The security detector 130 can be configured to capture the state associated with each action. In some embodiments, these states may include the system state and interface state of the mobile device 100. In some embodiments, the interface state may include screenshots of the screen of the mobile device 100 and interface layout information.
[0065] The security detector 130 can be configured to perform security verification on the operations performed by the agent 120 based on multiple actions 230 and associated states. The results of the security verification can be presented to the user of the mobile device 100.
[0066] Some implementations improve the breadth, depth, efficiency, and accuracy of security detection by performing security verification on the trajectory formed by multiple actions and associated states involved in the operations performed by the agent.
[0067] In some embodiments, the security detector 130 may be configured to perform contextual judgment using a visual language model based on input instructions 210, multiple actions 230, system state, and interface state. Security verification is then performed based on the results of the contextual judgment.
[0068] In some embodiments, the security detector 130 may be configured to merge multiple actions 230, system states, and interface states into a trajectory file. The security detector 130 may be configured to perform contextual judgment using a visual language model based on input instructions 210 and the trajectory file. The following will combine... Figure 4 This section provides a specific example of the merged trajectory file.
[0069] In some embodiments, system status may include statistical information of the system files of the mobile device 100 and text information collected from the screen of the mobile device 100.
[0070] In some embodiments, the security detector 130 may be configured to perform formal verification based on statistical and textual information. The security verification may be performed based on the results of the formal verification.
[0071] In some embodiments, the security detector 130 may be configured to calculate a hash value of statistics associated with moments before and after the execution of one of a plurality of actions 230. The security detector 130 may be configured to determine the result of a consistency verification based on the calculated hash value.
[0072] In some embodiments, the security detector 130 may be configured to set an initial value for the risk quantification value. The security detector 130 may be configured to perform the following operations on all text in the text information: determine whether a sensitive word exists by comparing it to a sensitive word list; in response to determining the existence of a sensitive word, increment the risk quantification value by a first value; query whether a character sequence associated with the user's privacy information exists; in response to determining the existence of a character sequence associated with the user's privacy information, increment the risk quantification value by a second value; and in response to determining that the risk quantification value exceeds a preset threshold, determine the result of formal verification as indicating the presence of a risk. In some embodiments, the second value may be greater than the first value. The following will combine... Figure 5 This section provides specific examples of regular expressions for creating sensitive word lists and querying privacy information.
[0073] In some embodiments, system state may include statistics on system files of the mobile device and textual information collected from the screen of the mobile device. Security detector 130 may be configured to perform formal verification based on the statistics and textual information. Security detector 130 may be configured to determine the result of security verification based on a logical OR of the result of contextual judgment and the result of formal verification. Some embodiments perform verification based on a hybrid result of formal verification and contextual judgment, enabling security verification to both "verify the facts" through rule-based detection to understand the real changes occurring in the underlying system, and "understand the context" through the result of contextual judgment to perceive the potential risks behind the visual and textual information on the screen, thereby gaining a comprehensive and three-dimensional situational awareness capability.
[0074] It should be understood that the purpose of the corresponding embodiments is to combine the contextual assessment and formal verification described above to perform hybrid security verification of the agent 120. In other embodiments described above, contextual assessment or formal verification can be performed on the agent 120 separately. The combination of contextual assessment and formal verification is not intended to limit the scope of the invention. The following will combine... Figure 3 This section provides a specific example of how to perform hybrid security verification on agent 120 by combining contextual judgment with formal verification.
[0075] Optionally, in some embodiments, the security detector 130 may also be configured to generate a security verification report based on the results of the security verification. The security verification report includes a final security label, the source of the risk discovery, the specific risk classification, and the reasoning behind the decision. Some embodiments, based on their security verification process, generate reports with attributable characteristics, clearly indicating which verification (e.g., formal verification, situational judgment, or both) discovered the security risk, thus making the report interpretable.
[0076] The execution environment and interaction process of mobile devices are further described in detail.
[0077] like Figure 2 As shown, the mobile device 100 can receive user input instructions 210. In response to receiving user input instructions 210, the intelligent agent 120 can interact with various applications in the execution environment 220 to perform operations.
[0078] Security detector 130 can capture multiple actions 230 included in the operations of agent 120 using an emulator or debugging tool. As an example, the environment for capturing actions 230 could be a tool used by developers to develop and test applications, such as the emulator provided by Google Android Studio. Additionally, Google provides a debugging tool called Android Debug Bridge (ADB), which has the ability to capture device actions (the device can be a mobile device or an emulator). When enabled, this feature allows users to listen to all operations performed on the phone.
[0079] The security detector 130 can simultaneously capture interface states (e.g., screenshots of the mobile device 100) and system states (e.g., SystemState Trace (SST) data at the underlying level of the current mobile device 100) associated with the actions performed by the agent 120. This state information can be combined into a complete trajectory T.
[0080] As an example, a trajectory T includes multiple actions 230 and a set of states associated with each action. For instance, for an operation with three actions 230, the trajectory T includes a first action and a first state associated with the first action, a second action and a second state associated with the second action, a third action and a third state associated with the third action, and so on. As an example, action 230 could be opening an application. It should be noted that the last action 230 is not the action actually performed by the agent, but rather a special marker indicating that the trajectory ends here.
[0081] As an example, a trajectory T may include multiple actions 230, SST data associated with each action, and screenshots and accessibility trees (abbreviated as a11ytree) associated with each action.
[0082] SST data is a structured snapshot or log of the underlying system state obtained through system tools such as ADB. Examples include file system directory structure, key system configuration file contents, network connection status, and permission settings lists. SST data can include various statistical information about system files and all text visible on the current mobile device screen. Accessibility trees, originally designed for the blind to facilitate the creation of programs for reading screen content, record the arrangement (size, location, etc.) of various elements on the current screen (such as application icons or text). The raw accessibility tree file can be in XML format, which can be processed into TXT and JSON formats.
[0083] The process of a security detector performing security verification is further described using a specific example.
[0084] Suppose the instruction used in the scenario is "Send this recent family photo to my mom." However, agent 120 mistakenly selects a screenshot that contains the user's credit card information.
[0085] The security detector 130 can collect the behavioral trajectory of the agent 120, which may include the text of the above-mentioned instructions, the screenshot of the selected credit card, the action of clicking the "share" button when sending a photo, and the SST data before and after the sharing operation.
[0086] For formal verification, security detector 130 can receive and analyze SST data. SST data shows that an image file was shared via an instant messaging application. Based on rules in the rule base, sharing the image is a normal operation and does not trigger any preset system-level violation rules (e.g., no system files were modified, no application was installed). Therefore, the result of formal verification could be: {Risk: False}.
[0087] For contextual judgment, the security detector 130 can receive instructions, credit card screenshots, and sharing actions. The security detector 130 can use Visual Learning Model (VLM) to analyze the credit card screenshot, identifying typical credit card features such as card layout, 16-digit numbers, and expiration date through its built-in visual knowledge. VLM can then combine this with the "sharing" action to determine that the behavior constitutes a high-risk "personal privacy breach." Therefore, the contextual judgment result could be: {Risk: True, Category "{Privacy Breach}", Reason: "Sensitive financial information (credit card number) contained in the shared image."}
[0088] Subsequently, a decision can be made based on the results of formal verification and situational judgment. If the result of formal verification is "true" and the result of situational judgment is "false", a logical "OR" operation is performed between the two, and the final decision is "unsafe".
[0089] The following final report can then be generated:
[0090] - Final safety label: Unsafe;
[0091] - Source of risk discovery: Contextual judgment;
[0092] - Specific risk category: Privacy breach;
[0093] - Reasoning for the ruling: VLM believed that the shared images contained sensitive financial information (credit card number), posing a risk of privacy breach.
[0094] In the example above, by combining the results of formal verification and contextual judgment, the "semantic blind spot" of using a rule detector alone was successfully overcome, and hidden security risks that are closely related to the context were accurately identified.
[0095] For ease of explanation, only an embodiment of hybrid security verification of agent 120 using both contextual judgment and formal verification is described. However, it should be understood that security verification of agent 120 can be performed using only contextual judgment, or only formal verification. Furthermore, some details described above can be omitted when using only contextual judgment or only formal verification. The following will combine... Figure 3 Explain the specific process of performing security verification.
[0096] Figure 3 A schematic diagram illustrating the process of performing security verification according to some embodiments of the present invention is shown. Figure 3 The security verification process in the system can be performed by Figure 1 , Figure 2 The security detector 130 shown is used to perform this.
[0097] Figure 3 The diagram illustrates the operation of an agent transferring a user's bank account information, which may include a trajectory T with three actions. It should be understood that this is merely an example, and the trajectory T may include more or fewer actions.
[0098] Based on the captured actions and associated states, the security detector can perform security verification on the operations performed by the agent.
[0099] As an example, a security detector can perform formal verification and / or contextual judgment on the operations performed by an agent.
[0100] Contextual judgment can be made by security detectors based on the above information. Figure 2 The trajectory file and input instructions are executed using a visual language model. As an example, before performing contextual judgment, the screenshot sequence can be preprocessed, such as by frame extraction for long trajectories (e.g., for a trajectory with n actions, only m actions are processed, where m is less than n) to improve efficiency. The VLM can receive this multimodal data and, based on preset prompts, assess the semantic and visual aspects of whether the behavior poses a risk, such as privacy breaches or harmful content. The VLM outputs a contextual judgment result (e.g., in JSON format) containing risk characterization, classification, and justification.
[0101] Formal verification can be performed by a security detector based on the above information. Figure 2 The system status (e.g., SST data) is used to execute the command.
[0102] As an example, the hash value (in digest format) of the system file statistics in the SST data before and after the action is executed can be calculated. It should be understood that since the same information will necessarily produce the same hash value, if the hash values calculated before and after are different, the SST information can be considered changed, the action can be directly considered risky, and all subsequent actions can be skipped.
[0103] As another example, the risk quantification value q can be initialized, and the following operations can be performed on all text on the screen in the SST data before / after the action is executed:
[0104] - Check the list of sensitive words to determine if any sensitive words are present;
[0105] - In response to the detection of sensitive words, the risk quantification value is incremented by a first value (e.g., q is incremented by 0.2 for each sensitive word found).
[0106] - Query whether a character sequence associated with a user's privacy information exists;
[0107] - In response to the determination of the existence of a character sequence associated with the user's privacy information, the risk quantification value is increased by a second value (for example, the user's privacy information may include email address, password, credit card number, mobile phone number, etc., and each time a character sequence suspected to be an email address, password, credit card number, or mobile phone number is found, q is increased by 0.5).
[0108] In response to a risk quantification value exceeding a preset threshold (e.g., q exceeds 0.3), the formal verification result is determined to indicate the presence of risk. As an example, if a risk is detected, the formal verification result containing risk details is output. The following section combines... Figure 5 This section provides specific examples of sensitive words and query character sequences.
[0109] In the example, the result of the security verification is determined by a logical "OR" between the situational assessment result and the formal verification result: Final Decision = Formal Verification Result ∨ Situational Assessment Result. Specifically, the security verification result indicates "unsafe" if either the situational assessment result or the formal verification result reports a risk (either is true). The security verification result indicates "safe" only if both the situational assessment result and the formal verification result indicate no risk. In the example, based on the security verification result, the system can generate a detailed structured report. This report not only includes the final "safe / unsafe" label but may also include the following information:
[0110] - Risk Source: Clearly indicate whether the risk was discovered through formal verification, situational judgment, or both;
[0111] - Risk Classification: If the final label is "unsafe", then the specific risk type will be given according to the source of the reported risk, such as "system integrity breach" or "personal privacy breach";
[0112] - Reasoning for the ruling: Please include a brief written explanation. If the formal verification report indicates a risk, specify which rule was violated; if the situational assessment report indicates a risk, please include the analysis and reasoning provided by VLM.
[0113] like Figure 3 As shown, the first action included in trajectory T is an upward swipe. Based on the state information corresponding to this first action, both the first situational judgment 310 and the first formal verification 315 indicate no risk, therefore the label associated with this action is "safe". The second action included in trajectory T is a click. Based on the state information corresponding to this second action, either the second situational judgment 320 or the second formal verification 325 indicates no risk, therefore the label associated with this action is "safe". The third action included in trajectory T is an operation related to information transmission. Based on the state information corresponding to this third action, either the third situational judgment 330 or the third formal verification 335 reports a risk, therefore the label associated with this action is "unsafe".
[0114] Figure 4 Examples of trajectory files according to some embodiments of the present invention are shown.
[0115] In the example, the accessibility tree file itself is not integrated into the track file, but the track file stores the relative path to the accessibility tree file, for example... Figure 4 The file shown is "objects": "objects / objects_001_start_1756453950069.json". Figure 4In the example shown, the path to the screenshot is saved after "observation", and the action performed by agent 120 is saved in square brackets after "action".
[0116] Figure 5 Examples of regular expressions for sensitive word lists and user privacy information according to some embodiments of the present invention are shown.
[0117] exist Figure 5 In the example shown, the sensitive word list is a text file containing a list of sensitive words, one per line, which can be expanded as needed. As an example, this sensitive word list could be derived from other open-source projects. The detection of sensitive information such as email addresses, passwords, credit card numbers, and phone numbers uses four regular expressions (strings that summarize a certain character arrangement format), which can also be expanded as needed. Figure 5 In the example shown, the four regular expressions used are enclosed in double quotes on the right.
[0118] Figure 6 This is a flowchart of a method for security verification of an intelligent agent in a mobile device according to some embodiments of the present invention. The method can be combined with the above... Figure 1 The mobile device 100 described is used for execution, but the scope of the invention is not limited thereto.
[0119] In some embodiments, the method may include step S1: capturing multiple actions of the agent using a simulator or debugging tool. In some embodiments, the agent may be configured to perform operations, which include multiple actions.
[0120] In some embodiments, the method may include step S2: capturing the state associated with each action, including the system state and interface state of the mobile device. In some examples, the interface state may include a screenshot of the screen and interface layout information.
[0121] In some embodiments, the method may include step S3: performing security verification on the operations performed by the agent based on multiple actions and associated states. In some embodiments, the result of the security verification may be presented to a user of a mobile device.
[0122] In some embodiments, the method may further include step S4: generating a security verification report based on the results of the security verification. In some embodiments, the security verification report may include a final security label, the source of risk discovery, specific risk classification, and the reasoning for the decision.
[0123] Steps S1-S4 can be found in the above reference. Figure 1 The security detector 130 described herein is performed, but the scope of the invention is not limited thereto.
[0124] Figure 7 This is a flowchart of a first process associated with a method for security verification of an agent in a mobile device according to some embodiments of the present invention. This first process can be referenced above. Figure 1 The described security detector 130 performs, and can be Figure 6 The specific implementation of step S3 in the method is described, but the scope of the present invention is not limited thereto.
[0125] In some embodiments, the agent may be configured to perform an operation in response to receiving input instructions from a user. In some embodiments, the first process may include step S31: performing a contextual judgment using a visual language model based on the input instructions, multiple actions, system state, and interface state. In some embodiments, security verification may be performed based on the result of the contextual judgment.
[0126] In some embodiments, step S31 may include step S311: merging multiple actions, system states, and interface states into a trajectory file.
[0127] In some embodiments, step S31 may include step S312: performing context judgment using a visual language model based on input instructions and trajectory files.
[0128] Figure 8 This is a flowchart of a second process associated with a method for security verification of an agent in a mobile device, according to some embodiments of the present invention. This second process can be referenced above. Figure 1 The described security detector 130 performs, and can be Figure 6 The specific implementation of step S3 in the method is described, but the scope of the present invention is not limited thereto.
[0129] In some embodiments, system status may include statistical information about the mobile device's system files and text information collected from the mobile device's screen.
[0130] In some examples, the second process may include step S32: performing formal verification based on statistical and textual information. In some examples, security verification may be performed based on the results of formal verification.
[0131] In some examples, step S32 may include step S321: calculating the hash value of statistics associated with the time before and after the execution of one of the multiple actions.
[0132] In some examples, step S32 may include step S322: determining the result of formal verification based on the consistency of the calculated hash value.
[0133] In some examples, step S32 may include step S323: setting an initial value for the risk quantification value.
[0134] In some examples, step S32 may include step S324: performing the following operations on all text in the text information: determining whether a sensitive word exists by comparing it with a list of sensitive words; in response to determining that a sensitive word exists, incrementing the risk quantification value by a first value; querying whether a character sequence associated with the user's privacy information exists; in response to determining that a character sequence associated with the user's privacy information exists, incrementing the risk quantification value by a second value. In some examples, the second value may be greater than the first value.
[0135] In some examples, step S32 may include step S325: in response to determining that the risk quantification value exceeds a preset threshold, the result of the formal verification is determined to indicate the presence of risk.
[0136] Figure 9 This is a flowchart of a third process associated with a method for security verification of an agent in a mobile device, according to some embodiments of the present invention. This third process can be referenced above. Figure 1 The described security detector 130 performs, and can be Figure 6 The specific implementation of step S3 in the method is described, but the scope of the present invention is not limited thereto.
[0137] In some examples, the agent can be configured to perform an action in response to receiving input instructions from the user.
[0138] In some examples, the third process may include step S31: performing contextual judgment using a visual language model based on input instructions, multiple actions, system state, and interface state. In some examples, security verification may be performed based on the result of the contextual judgment.
[0139] In some examples, system status may include statistics on the mobile device's system files and text information collected from the mobile device's screen.
[0140] In some examples, the third process may include step S32: performing formal validation based on statistical and textual information.
[0141] In some examples, the third process may include step S33: determining the result of security verification by a logical OR of the result of contextual judgment and the result of formal verification.
[0142] It should be understood that this third process can be a combination of the above. Figure 2 and Figure 3 This is a specific example of the process by which formal verification and contextual judgment are used to perform security verification on agent 120, but the scope of the present invention is not limited thereto.
[0143] According to another aspect of the present invention, a computer-readable storage medium is provided.
[0144] Figure 10 This is a block diagram of a computer-readable storage medium 1000 according to some embodiments of the present invention.
[0145] A computer-readable storage medium 1000 stores a computer program 1050. When executed by a processor, the computer program 1050 implements the above-mentioned... Figures 6-9 The steps of each method or process described.
[0146] According to another aspect of the present invention, a computer program product is provided.
[0147] Figure 11 This is a block diagram of a computer program product 1100 according to some embodiments of the present invention.
[0148] Computer program product 1100 may include computer program 1050. Computer program 1050, when executed by a processor, implements the above-mentioned... Figures 6-9 The steps of each method or process described.
[0149] Table 1 below shows the experimental results obtained using embodiments of the present invention.
[0150]
[0151] In Table 1, the left side shows the model used by the safety detector according to an embodiment of the present invention; precision is the percentage of correctly predicted samples; F1 is the harmonic mean of precision and recall, where precision is the percentage of actual positive samples predicted as positive (at risk), and recall is the percentage of actual positive samples correctly predicted as positive.
[0152] As shown in Table 1, the security verification method according to embodiments of the present invention achieves high accuracy in various models and has a high ability to identify "risky" samples. Furthermore, the hybrid verification method combining contextual judgment and formal verification achieves significantly higher reliability in security verification.
[0153] Various embodiments of the invention have been described with reference to the accompanying drawings, which are illustrative and not restrictive.
Claims
1. A mobile device, characterized in that, include: Computing resources; An intelligent agent is configured to: in response to receiving an input instruction from a user of the mobile device, invoke the computing resources to perform an operation, the operation including multiple actions; as well as The security detector is configured as follows: Capture the agent's multiple actions using a simulator or debugging tool; Capture the state associated with each action, including the system state and interface state of the mobile device, the system state including statistics of the system files of the mobile device and text information collected from the screen of the mobile device; as well as Security verification is performed on the operations executed by the agent based on the multiple actions and associated states, wherein the result of the security verification is presented to the user. The security detector is configured as follows: The multiple actions, the system state, and the interface state are merged into a trajectory file; and Based on the input instructions and the trajectory file, a visual language model is used to perform contextual judgment. The security detector is configured as follows: Perform formal verification based on the statistical information and the textual information. The security detector is configured to: Calculate the hash value of statistical information associated with the execution of one of the plurality of actions before and after the execution of the action; and The result of the formal verification is determined based on the consistency of the calculated hash values. The security verification is performed based on the results of the context judgment and the results of the formal verification.
2. The mobile device according to claim 1, characterized in that, The security detector is configured to: Set the initial value for the risk quantification value; Perform the following operations on all text in the text information: Check against the sensitive word list to determine if any sensitive words are present; In response to the determination of the presence of sensitive words, the risk quantification value is incremented by a first value; Check if a character sequence exists that is associated with the user's privacy information; In response to determining the existence of a character sequence associated with a user's privacy information, the risk quantification value is incremented by a second value; as well as In response to determining that the risk quantification value exceeds a preset threshold, the result of the formal verification is determined to indicate the existence of risk.
3. The mobile device according to claim 2, characterized in that, The second value is greater than the first value.
4. The mobile device according to claim 1, characterized in that, The security detector is configured to: The result of the security verification is determined by a logical OR between the result of the situational judgment and the result of the formal verification.
5. The mobile device according to claim 1, characterized in that, The security detector is also configured to: A security verification report is generated based on the results of the security verification. The security verification report includes the final security label, the source of risk discovery, the specific risk classification, and the reasoning for the decision.
6. The mobile device according to claim 1, characterized in that, The interface state includes a screenshot of the mobile device's screen and interface layout information.
7. A method for security verification of intelligent agents in mobile devices, characterized in that, Includes the following steps: S1: Capture multiple actions of the agent using a simulator or debugging tool, wherein the agent is configured to perform an operation in response to receiving input instructions from a user of the mobile device, the operation including the multiple actions; S2: Capture the state associated with each action, including the system state and interface state of the mobile device, the system state including statistics of the mobile device's system files and text information collected from the mobile device's screen; and S3: Perform security verification on the operation performed by the agent based on the multiple actions and associated states, wherein the result of the security verification is presented to the user. S3 includes: S31: Based on the input instructions, the multiple actions, the system state, and the interface state, perform context judgment using a visual language model; S31 includes: S311: Merge the multiple actions, the system state, and the interface state into a trajectory file; and S312: Based on the input instruction and the trajectory file, perform context judgment using the visual language model; and S32: Perform formal verification based on the statistical information and the textual information. S32 includes: S321: Calculate the hash value of statistical information associated with the time before and after the execution of one of the plurality of actions; and S322: Determine the result of the formal verification based on the consistency of the calculated hash values. The security verification is performed based on the results of the context judgment and the results of the formal judgment.
8. The method according to claim 7, characterized in that, S32 includes: S323: Set the initial value for the risk quantification value; S324: Perform the following operation on all text in the text information: Check against the sensitive word list to determine if any sensitive words are present; In response to the determination of the presence of sensitive words, the risk quantification value is incremented by a first value; Check if a character sequence exists that is associated with the user's privacy information; In response to determining the existence of a character sequence associated with a user's privacy information, the risk quantification value is incremented by a second value; and S325: In response to determining that the risk quantification value exceeds a preset threshold, the result of the formal verification is determined to indicate the existence of risk.
9. The method according to claim 8, characterized in that, The second value is greater than the first value.
10. The method according to claim 7, characterized in that, S3 further includes: S33: The result of the security verification is determined by a logical OR between the result of the situation judgment and the result of the formal verification.
11. The method according to claim 7, characterized in that, The method further includes: S4: Generate a security verification report based on the results of the security verification. The security verification report includes the final security label, the source of risk discovery, the specific risk classification, and the reasoning for the decision.
12. The method according to claim 7, characterized in that, The interface state includes a screenshot of the mobile device's screen and interface layout information.
13. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method as described in any one of claims 7-12.
14. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the steps of the method as described in any one of claims 7-12.
Citation Information
Patent Citations
Application creation method and device, equipment and storage medium
CN115826926A
Electric power large model agent operation evaluation method and system
CN120782134A