An RBAC mechanism-based multi-factor authorization intelligent agent application packaging method
Patent Information
- Application Number
- CN202611347827.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-02
- Publication Date
- 2026-09-29
AI Technical Summary
[0005]为了弥补以上不足,本发明提供了一种基于RBAC机制多因素授权智能体应用封装方法,旨在改善现有RBAC多因素授权机制难以感知操作目标区域实时物理安全态势,导致合法授权的智能体仍可能在存在人员违规闯入等安全隐患的物理环境下执行高风险操作的问题
1、本发明中,将视觉识别技术与智能体访问控制机制相结合,将操作目标区域的实时物理安全态势作为授权决策的动态因子,能够使授权系统感知目标区域的人员分布、个人防护装备穿戴情况及危险区闯入状态,解决了现有RBAC多因素授权机制无法感知操作目标区域物理安全态势、导致合法授权下仍可能在危险现场执行高风险操作的技术问题。
Smart Images

Figure CN122845306A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of intelligent agent access control technology, and in particular to a method for encapsulating multi-factor authorized intelligent agent applications based on the RBAC mechanism. Background Technology
[0002] Currently, Role-Based Access Control (RBAC) and its extended multi-factor authorization mechanisms have been widely applied to the permission management of intelligent agents. However, existing authorization schemes generally make decisions based on static or semi-static policies, that is, they determine whether to allow the execution of a certain operation based on predetermined factors such as the agent's role, operation time, and network environment. The core logic of these schemes is "whether the identity and environment match the preset rules," and the input information for their authorization decisions is limited to the subject attributes and context within the digital space.
[0003] However, in industrial settings such as ports, construction sites, and power grids, intelligent agents are often authorized to perform operations involving physical space (such as starting cranes or remotely closing switches). The risks of such operations depend not only on "who is operating" and "when," but also on the physical security situation of the target area at that moment—for example, whether anyone has illegally entered the area or whether personnel are wearing personal protective equipment in compliance with regulations. Existing authorization mechanisms are completely "unaware" of the security situation in these physical spaces, meaning that an intelligent agent with a legitimate role and operating at a compliant time may still perform high-risk operations in critical situations where there is illegal intrusion into the target area, potentially causing serious safety incidents.
[0004] It is evident that how to enable intelligent agents to automatically perceive and respond to the real-time physical security situation of the target area and achieve dynamic matching between authorization granularity and on-site risks is a technical problem that needs to be solved in this field. Summary of the Invention
[0005] To overcome the above shortcomings, this invention provides a method for encapsulating intelligent agent applications based on the RBAC mechanism through multi-factor authorization. This method aims to improve the problem that the existing RBAC multi-factor authorization mechanism is unable to perceive the real-time physical security situation of the target area, which may cause legally authorized intelligent agents to perform high-risk operations in physical environments with security risks such as unauthorized personnel intrusion.
[0006] This invention provides the following technical solution: a method for encapsulating multi-factor authorization agent applications based on the RBAC mechanism, comprising: S1. Obtain the real-time visual recognition result of the target area, and calculate the visual security level based on the real-time visual recognition result; S2. Obtain the historical security context information of the target area, input the visual security level and the historical security context information into a preset risk assessment model, and output a dynamic risk coefficient. S3. Determine the current authorization granularity of the agent based on the preset value range into which the dynamic risk coefficient falls; S4. When the current authorization granularity allows execution, allow the operation request of the intelligent agent and establish a stateful secure session corresponding to the current operation; S5. During the execution of the current operation, the real-time visual safety level of the target area of the operation is periodically acquired, and when the real-time visual safety level is detected to reach a preset circuit breaker threshold, a stop command is sent to the execution end to interrupt the current operation. S6. Record the visual security level, the dynamic risk coefficient, and the current authorization granularity to form an authorization audit log.
[0007] The present invention has the following beneficial effects: 1. In this invention, visual recognition technology is combined with intelligent agent access control mechanism. The real-time physical security situation of the target area is used as a dynamic factor for authorization decision. This enables the authorization system to perceive the distribution of personnel, the wearing status of personal protective equipment and the intrusion status of dangerous areas in the target area. This solves the technical problem that the existing RBAC multi-factor authorization mechanism cannot perceive the physical security situation of the target area, which may lead to high-risk operations being performed in dangerous areas even under legal authorization.
[0008] 2. In this invention, an in-process circuit breaker mechanism is embedded in the authorization encapsulation layer, which can continuously monitor the real-time visual security level of the target area during operation execution, and send a stop command to the execution end to interrupt the current operation when the security level reaches the preset circuit breaker threshold. This forms a closed-loop security guarantee of dynamic evaluation before operation, continuous monitoring during operation, and immediate interruption when the security situation deteriorates. It solves the technical problem that the traditional authorization mechanism only focuses on the single permission verification before operation and cannot cope with the security situation deteriorating suddenly during operation execution, which poses a security risk.
[0009] 3. In this invention, by constructing a holographic authorization audit log, visual security level, dynamic risk coefficient, current authorization granularity, and user confirmation decision are associated and recorded. Simultaneously, circuit breaker events during operation execution and corresponding on-site visual security situation data are recorded. This can provide a complete chain of evidence including physical space evidence for compliance review and post-event traceability of security incidents. It solves the technical problem that traditional authorization audit logs only record subject identity, operation time, and permission verification results, and are difficult to restore the on-site security situation and circuit breaker events on which authorization decisions are based. Attached Figure Description
[0010] Figure 1 This is a flowchart illustrating a multi-factor authorization agent application encapsulation method based on the RBAC mechanism proposed in this invention. Figure 2This is a schematic diagram of the visual security level calculation and dynamic risk coefficient generation process of a multi-factor authorization intelligent agent application encapsulation method based on the RBAC mechanism proposed in this invention. Figure 3 This is a schematic diagram of the operation release and in-process circuit breaker process of a multi-factor authorization intelligent agent application encapsulation method based on the RBAC mechanism proposed in this invention; Figure 4 This is a schematic diagram of a multi-objective region joint authorization decision-making process for a multi-factor authorization agent application encapsulation method based on the RBAC mechanism proposed in this invention. Figure 5 This is a schematic diagram of the adaptive adjustment process of the circuit breaker threshold in a multi-factor authorized intelligent agent application encapsulation method based on the RBAC mechanism proposed in this invention. Detailed Implementation
[0011] The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0012] Example 1 In the first embodiment of the present invention, the present invention provides a method for encapsulating multi-factor authorization agent applications based on the RBAC mechanism, such as... Figures 1-5 As shown, it includes the following steps: S1. Obtain the real-time visual recognition results of the target area and calculate the visual security level based on the real-time visual recognition results.
[0013] Furthermore, in S1, the visual security level is calculated, including: The visual recognition platform analyzes the video stream of the target area in real time to identify the number of people in the target area, the status of their personal protective equipment, and their intrusion status relative to the danger zone. The personnel density index is calculated based on the ratio of the number of personnel to the preset maximum capacity of the target area; the personal protective equipment compliance index is calculated based on the ratio of the number of people wearing personal protective equipment in compliance with regulations to the total number of personnel; and the danger zone intrusion index is calculated based on the number of personnel entering the danger zone. Obtain the preset risk weight coefficient corresponding to the current job type; The visual safety level is obtained by weighting and summing the personnel density index, personal protective equipment compliance index, dangerous area intrusion index, and risk weight coefficient.
[0014] Specifically, the visual recognition platform receives video streams from cameras deployed in the target area in real time. The platform runs target detection, personal protective equipment (PPE) detection, and area intrusion detection algorithms frame-by-frame on this video stream to identify the number of people in the target area, the PPE status of each person, and the number of people entering the pre-defined danger zone within the target area. PPE includes at least a safety helmet and a reflective vest. The visual recognition platform provides a standardized application programming interface (API) query service, through which the authorized encapsulation layer obtains the real-time visual security level of the target area. The visual recognition platform sends the identification results to the authorized encapsulation layer. The authorized encapsulation layer calculates a personnel density index based on the ratio of the number of people to the pre-defined maximum capacity of the target area. The formula is: Personnel Density Index = Number of People in the Target Area / Pre-defined Maximum Capacity of the Target Area. The pre-defined maximum capacity is configured by the system administrator based on the physical dimensions of the target area and safety operating procedures.
[0015] The authorization layer calculates the PPE compliance index based on the ratio of the number of personnel wearing compliant PPE to the total number of personnel in the target area. The formula is: PPE Compliance Index = Number of Personnel Wearing Compliance PPE / Total Number of Personnel in the Target Area. The authorization layer determines the danger zone intrusion index based on the number of personnel entering the preset danger zone; this index is directly taken as the number of personnel entering the preset danger zone. The authorization layer obtains the preset risk weight coefficient corresponding to the current work type. The current work type includes any one of high-altitude work, ground inspection, and equipment operation, and each work type is pre-configured with a risk weight coefficient. The authorization layer performs a weighted sum of the personnel density index, PPE compliance index, danger zone intrusion index, and risk weight coefficient to obtain the visual safety level. The calculation formula is: ; in, For visual safety level, For population density index, For personal protective equipment compliance index, The danger zone intrusion index, The preset risk weight coefficient corresponding to the current job type. , , , These are preset weighting coefficients corresponding to the personnel density index, personal protective equipment compliance index, hazardous area intrusion index, and risk weighting coefficient. Each preset weighting coefficient ranges from 0 to 1, and the sum of the four is equal to 1. In one feasible implementation, , , , The danger zone intrusion index has the greatest impact on the visual safety level. This visual safety level is a continuous value, ranging from 0 to 100. The higher the visual safety level value, the higher the safety risk of the target area.
[0016] S2. Obtain historical security context information of the target area, input the visual security level and historical security context information into the preset risk assessment model, and output dynamic risk coefficient.
[0017] Furthermore, in S2, the dynamic risk coefficient is output, including: Obtain historical safety context information for the target area of the operation. The historical safety context information includes at least the historical accident rate, the basic risk level of the current operation type, and the movement trend information of personnel in the area. Based on visual security level, historical accident rate and basic risk level, a comprehensive risk base value that integrates visual risk and business risk is calculated; Based on the movement trend information of people within the region, determine the risk trend correction factor; The dynamic risk coefficient is generated by superimposing the comprehensive risk base value and the risk trend correction factor.
[0018] Specifically, the authorization encapsulation layer obtains historical safety context information of the target area. This historical safety context information includes at least the historical incident rate, the basic risk level of the current job type, and the movement trend information of personnel within the area. The historical incident rate, obtained from the authorization audit log, characterizes the frequency of safety events occurring in the area over a preset time period, measured in times per month. The basic risk level of the current job type is obtained from the system configuration table. Different job types correspond to different basic risk level values. Job types include high-altitude operations, ground inspections, and equipment operations. The basic risk level value is pre-configured, ranging from 0 to 10, with higher values indicating higher basic risk for that job type. In one exemplary implementation, the basic risk level for high-altitude operations is configured as 8, for ground inspections as 3, and for equipment operations as 5. The movement trend information of personnel within the area is obtained from the visual recognition platform. The visual recognition platform analyzes the movement trajectory of personnel within the area using a target tracking algorithm to determine whether personnel are approaching or moving away from the danger zone, and outputs the approaching or moving-away speed. The approach speed refers to the rate at which the distance from the current location of a person within the area to the boundary of the danger zone decreases over time, and the distance away speed refers to the rate at which the distance increases over time.
[0019] The authorized encapsulation layer calculates a comprehensive risk baseline value based on visual security level, historical accident rate, and basic risk level. The formula for calculating the comprehensive risk baseline value is: ; in, As a comprehensive risk baseline, The normalized visual safety level, The normalized historical accident rate, This is the normalized base risk level. , , These are preset weighting coefficients corresponding to the visual safety level, historical accident rate, and basic risk level, respectively. Each preset weighting coefficient ranges from 0 to 1, and the sum of the three equals 1. In one feasible implementation, , , Normalization maps each original value to a range of 0 to 1, specifically: visual safety level divided by 100, historical accident rate divided by a preset maximum accident rate threshold, and basic risk level divided by 10. The comprehensive risk base value ranges from 0 to 1; a higher value indicates a higher comprehensive risk after integrating current visual perception, historical safety records, and work type.
[0020] The authorized encapsulation layer determines the risk trend correction factor based on the movement trend information of people within the area. The formula for calculating the risk trend correction factor is: When the motion trend information indicates a nearing state: ; When the motion trend information indicates a state of distance: ; in, As a risk trend correction factor, This is the preset trend correction coefficient. The speed at which personnel approach the danger zone. The risk trend correction factor represents the speed at which personnel move away from the danger zone. When personnel move towards the danger zone, the risk trend correction factor is positive, indicating an upward trend in overall risk; when personnel move away from the danger zone, the risk trend correction factor is negative, indicating a downward trend in overall risk. In one feasible implementation, =0.1, and The unit is meters per second, and the value range is 0 to 5 meters per second.
[0021] The authorized encapsulation layer superimposes the comprehensive risk base value and the risk trend correction factor to generate a dynamic risk coefficient. The formula for calculating the dynamic risk coefficient is: ; in, For dynamic risk coefficient, As a comprehensive risk baseline, This is the risk trend correction factor. The dynamic risk coefficient ranges from -1 to 2. When the dynamic risk coefficient is less than 0, it is set to 0; when the dynamic risk coefficient is greater than 1, it is set to 1. This dynamic risk coefficient is used as input to the subsequent S3 step to determine the agent's current authorization granularity. The larger the value of this dynamic risk coefficient, the higher the dynamic risk after comprehensively considering static risk and trend changes.
[0022] S3. Determine the current authorization granularity of the agent based on the preset value range into which the dynamic risk coefficient falls.
[0023] Furthermore, in S3, the current authorization granularity of the agent is determined, including: Multiple mutually exclusive value ranges are preset, and each value range corresponds to an authorization granularity. The authorization granularity includes at least automatic execution, notification after execution, secondary confirmation required, and rejection. Determine the numerical range into which the dynamic risk coefficient falls; Based on the correspondence between numerical ranges and authorization granularities, the authorization granularity corresponding to the numerical range into which the dynamic risk coefficient falls is determined as the current authorization granularity of the agent.
[0024] Specifically, the authorization encapsulation layer pre-configures multiple mutually exclusive numerical ranges, each corresponding to an authorization granularity. The numerical ranges are divided by continuously covering the value range of the dynamic risk coefficient. The dynamic risk coefficient ranges from 0 to 1, and the authorization granularities include automatic execution, post-execution notification, secondary confirmation required, and rejection. In a feasible implementation, the correspondence between numerical ranges and authorization granularities is as follows: when the dynamic risk coefficient is greater than or equal to 0 and less than or equal to 0.3, the corresponding authorization granularity is automatic execution. Automatic execution means the agent executes the current operation request directly without user intervention; when the dynamic risk coefficient is greater than 0.3 and less than or equal to 0.6, the corresponding authorization granularity is post-execution notification. Post-execution notification means the agent pushes an operation completion notification to the user after executing the current operation request; when the dynamic risk coefficient is greater than 0.6 and less than or equal to 0.85, the corresponding authorization granularity is secondary confirmation required. Secondary confirmation required means the agent suspends the current operation request until it receives confirmation from the user; when the dynamic risk coefficient is greater than 0.85 and less than or equal to 1, the corresponding authorization granularity is rejection. A rejection indicates that the agent will not execute the current operation request and will directly return a rejection response.
[0025] After receiving the dynamic risk coefficient output from step S2, the authorization encapsulation layer compares the value of the dynamic risk coefficient with a preset value range to determine the value range into which the dynamic risk coefficient falls. Based on the correspondence between value ranges and authorization granularities, the authorization encapsulation layer determines the authorization granularity corresponding to the value range into which the dynamic risk coefficient falls as the agent's current authorization granularity. When the value of the dynamic risk coefficient is exactly equal to the boundary value of the value range, that boundary value belongs to the value range on the lower risk side. For example, when the dynamic risk coefficient is equal to 0.3, it belongs to the value range corresponding to automatic execution; when the dynamic risk coefficient is equal to 0.6, it belongs to the value range corresponding to post-execution notification. After the current authorization granularity is determined, the authorization encapsulation layer passes the current authorization granularity to step S4, which serves as the basis for determining whether to allow the agent's operation request and for establishing a stateful and secure session in step S4.
[0026] S4. When the current authorization granularity allows execution, allow the agent's operation request and establish a stateful and secure session corresponding to the current operation.
[0027] Furthermore, in S4, a stateful, secure session corresponding to the current operation is established, including: Determine if the current authorization granularity is denial; When the current authorization granularity is denial, a denial response is returned, and the current process ends; When the current authorization granularity is not "reject", perform the corresponding pre-release processing according to the type of the current authorization granularity; Allow the agent's operation request, create a session identifier corresponding to the current operation, and establish a stateful and secure session that includes the session identifier, the execution status of the current operation, and the target area identifier.
[0028] Furthermore, based on the type of the current authorization granularity, perform the corresponding pre-release processing, including: If the current authorization granularity is automatic execution or notification after execution, then proceed directly to the step of allowing the agent's operation request; If the current authorization granularity requires secondary confirmation, a confirmation request is sent to the authorized user terminal. Upon receiving the confirmation instruction, the process proceeds to allow the intelligent agent's operation request. Alternatively, if no confirmation instruction is received within the preset waiting time, a rejection response is returned and the current process ends.
[0029] Specifically, after obtaining the current authorization granularity determined in step S3, the authorization encapsulation layer determines whether the current authorization granularity is a rejection. When the current authorization granularity is a rejection, the authorization encapsulation layer returns a rejection response to the agent. The rejection response contains a rejection reason identifier, which indicates that the current operation request is rejected because the dynamic risk coefficient has reached the rejection threshold, thus ending the current process.
[0030] When the current authorization granularity is not rejection, the authorization encapsulation layer performs the corresponding pre-release processing according to the type of the current authorization granularity. The specific process of pre-release processing is as follows: when the current authorization granularity is automatic execution or post-execution notification, the authorization encapsulation layer does not perform any intervention operations and directly proceeds to the step of releasing the agent's operation request.
[0031] When the current authorization granularity requires secondary confirmation, the authorization encapsulation layer sends a confirmation request to the authorized user terminal. The confirmation request can be sent via push notification, SMS, or instant messaging. The confirmation request content includes at least the operation type, the operation target area identifier, and a dynamic risk coefficient. After sending the confirmation request, the authorization encapsulation layer starts a timer, waiting to receive a confirmation instruction from the authorized user terminal. If a confirmation instruction is received within a preset waiting time, the process proceeds to allow the agent's operation request. If no confirmation instruction is received within the preset waiting time, the authorization encapsulation layer returns a rejection response to the agent. The rejection response includes a timeout rejection flag, indicating that the operation request was rejected due to user confirmation timeout, thus ending the current process. In one feasible implementation, the preset waiting time is 60 seconds.
[0032] After allowing the agent's operation request, the authorization encapsulation layer creates a session identifier corresponding to the current operation. The session identifier is a globally unique identifier used to uniquely identify the current operation instance. The authorization encapsulation layer establishes a stateful secure session containing the session identifier, the execution state of the current operation, and the target region identifier. The stateful secure session is stored in the authorization encapsulation layer's local memory or a distributed cache. The initial value of the execution state is set to "Executing".
[0033] Once the stateful security session is established, the authorization encapsulation layer returns the session identifier to the agent and passes the stateful security session to step S5, which serves as the context for periodically querying the real-time visual security level of the target area in step S5.
[0034] S5. During the execution of the current operation, periodically obtain the real-time visual safety level of the target area of the operation, and when the real-time visual safety level is detected to reach the preset circuit breaker threshold, send a stop command to the execution end to interrupt the current operation.
[0035] Furthermore, in S5, a stop command is sent to the execution end to interrupt the current operation, including: Obtain the target area identification information of the target area from a stateful secure session; Based on the target area identification information, a visual security level query request is sent to the visual recognition platform according to a preset query cycle. Receive the real-time visual security level returned by the visual recognition platform in response to the query request; The real-time visual security level is compared with the preset circuit breaker threshold. When the real-time visual security level reaches or exceeds the preset circuit breaker threshold, the circuit breaker condition is triggered.
[0036] Specifically, after establishing a stateful secure session in step S4, the authorization encapsulation layer enters the execution phase of the current operation. The authorization encapsulation layer obtains the target area identification information from the stateful secure session. Based on the target area identification information, the authorization encapsulation layer sends a visual security level query request to the visual recognition platform according to a preset query period. The visual security level query request includes at least the target area identification information and a query timestamp. In one feasible implementation, the preset query period is 2 seconds.
[0037] The authorization encapsulation layer receives the real-time visual security level returned by the visual recognition platform in response to the query request. The calculation method for the real-time visual security level is the same as that for the visual security level in step S1, both based on the visual recognition platform performing real-time analysis and weighted summation of the video stream of the target area.
[0038] The authorization encapsulation layer compares the real-time visual security level with a preset circuit breaker threshold. The preset circuit breaker threshold is pre-configured based on the security level requirements of the target area. In one feasible implementation, when the visual security level ranges from 0 to 100, the preset circuit breaker threshold is 75. When the real-time visual security level is less than the preset circuit breaker threshold, the authorization encapsulation layer waits for the next query cycle and repeats the step of sending a visual security level query request. When the real-time visual security level reaches or exceeds the preset circuit breaker threshold, the authorization encapsulation layer determines that the circuit breaker condition has been triggered.
[0039] After determining that the circuit breaker condition has been triggered, the authorization encapsulation layer generates an abort instruction. The abort instruction includes at least the target area identifier and the session identifier of the current operation. The authorization encapsulation layer sends the abort instruction to the execution end. The execution end refers to the entity executing the current operation, including the agent itself or the operation execution module called by the agent. The execution end provides an operation abort interface in advance, and the authorization encapsulation layer sends the abort instruction to the execution end by calling this interface. Upon receiving the abort instruction, the execution end terminates the execution of the current operation.
[0040] The authorization encapsulation layer records the circuit breaker trigger time, the real-time visual security level at the time of triggering the circuit breaker, and the time of sending the abort command in the stateful security session, and updates the execution status in the stateful security session to "circuit breaker interrupted". After completing the circuit breaker interruption, the authorization encapsulation layer continues to execute step S6.
[0041] S6. Record the visual security level, dynamic risk coefficient, and current authorization granularity to form an authorization audit log.
[0042] Furthermore, in S6, an authorized audit log is generated, including: Obtain authorized audit data; If a user confirmation process exists, obtain the user confirmation decision result and confirmation time, and associate the user confirmation decision result and confirmation time with the authorized audit data; The authorized audit data is structured into an audit log entry according to a preset log format; Write audit log entries to persistent storage media.
[0043] Specifically, after determining the current authorization granularity in step S3, the authorization encapsulation layer retrieves authorization audit data from its local cache. The authorization audit data includes at least the visual security level, dynamic risk coefficient, current authorization granularity, the initiation time of the operation request, and the identification information of the operation target area. The visual security level is calculated in step S1, the dynamic risk coefficient is generated in step S2, and the current authorization granularity is determined in step S3.
[0044] The authorization encapsulation layer determines whether a user confirmation process exists in the current authorization flow. A user confirmation process refers to a process where the current authorization granularity requires secondary confirmation and a confirmation request has been sent to the authorized user terminal, awaiting a user response. If a user confirmation process exists, the authorization encapsulation layer obtains the user confirmation decision result and confirmation time. The user confirmation decision result includes confirmation approved or confirmation rejected. The authorization encapsulation layer associates the user confirmation decision result and confirmation time with the authorization audit data. If a user confirmation process does not exist, the authorization encapsulation layer does not supplement the authorization audit data with user confirmation information.
[0045] The authorization encapsulation layer structures the authorization audit data into an audit log entry according to a preset log format. The preset log format is a key-value pair structure. In a feasible implementation, the structure of the audit log entry is as follows: Audit Log Entry = {Operation Request Identifier, Operation Initiation Time, Target Area Identification Information, Operation Type, Visual Security Level, Dynamic Risk Coefficient, Current Authorization Granularity, User Confirmation Result, User Confirmation Time, Circuit Breaker Trigger Status, Circuit Breaker Trigger Time}.
[0046] Specifically, the user confirmation result and user confirmation time are filled with valid values only when a user confirmation process exists, while the circuit breaker trigger status and circuit breaker trigger time are filled with valid values only after the circuit breaker condition is triggered and the interrupt is executed in step S5. When the circuit breaker condition is not triggered, the circuit breaker trigger status is set to "not triggered".
[0047] The authorization encapsulation layer writes audit log entries to persistent storage media. Persistent storage media can be a local file system, a relational database, or a distributed storage system. After the audit log entries are written to persistent storage media, the authorization audit log for the current operation request is completed. This authorization audit log is used to support subsequent security incident tracing and compliance reviews.
[0048] Furthermore, when an operation request involves multiple target areas, it includes: Obtain the real-time visual recognition results for each target area and calculate the visual security level for each target area. Take the highest level among the visual safety levels as the joint visual safety level and execute steps S2 to S6. Alternatively, the visual safety levels can be weighted and summed according to the preset risk weights of each target area to obtain a joint visual safety level, and steps S2 to S6 can be executed.
[0049] Specifically, after receiving an operation request from the agent, the authorization encapsulation layer parses the target region information carried in the operation request. When the operation request carries multiple target region identifiers, it is determined that the operation request involves multiple target regions. The authorization encapsulation layer obtains the real-time visual recognition results for each target region. For each target region, the authorization encapsulation layer calculates its visual security level based on the real-time visual recognition results, following the calculation method in step S1. The real-time visual recognition results for each target region are provided by the visual recognition platform, and each target region corresponds to one or more video streams. After obtaining the visual security levels of all target regions, the authorization encapsulation layer calculates the joint visual security level using any of the following methods: Method 1: The authorization encapsulation layer uses the highest visual security level among all target regions as the joint visual security level. The mathematical expression for this method is: ; in, To achieve joint visual safety levels, to These represent the visual safety levels for target areas 1 through n, where n is the total number of target areas. This approach corresponds to a safety-first strategy, meaning that when the risk of any target area reaches the highest level, the overall risk assessment result takes the highest risk value.
[0050] Method Two: The authorization encapsulation layer weights and sums the visual security levels of each target area according to the preset risk weights of each target area to obtain a joint visual security level. The preset risk weights are pre-configured by the system administrator based on the impact of each target area on operational security, and the sum of the preset risk weights of all target areas is 1. The mathematical expression of this method is: ; in, To achieve joint visual safety levels, Let i be the visual security level of the i-th target area. Here, n represents the preset risk weight corresponding to the i-th target area, and n is the total number of target areas. Each preset risk weight ranges from 0 to 1, and the sum of the preset risk weights for all target areas equals 1. This method corresponds to a fine-grained weighting strategy, where different target areas are assigned different weights based on their safety importance. In a feasible implementation, when the operation request is to start the crane, the preset risk weight for the area below the boom is 0.6, the preset risk weight for the cab area is 0.3, and the preset risk weight for the lifting path area is 0.1.
[0051] After calculating the joint visual security level, the authorization encapsulation layer replaces the visual security level of a single target area with the joint visual security level and executes steps S2 to S6. Subsequent processes such as dynamic risk coefficient generation, authorization granularity determination, operation release and session establishment, in-process circuit breaking, and audit log generation are all based on the joint visual security level.
[0052] Furthermore, the preset circuit breaker threshold is adaptively adjusted in the following ways: Obtain the historical visual security level and historical dynamic risk coefficient corresponding to each circuit breaker trigger from the historical authorization audit log; Using historical visual security levels and historical dynamic risk coefficients as sample data, the frequency of circuit breaker triggering is statistically analyzed according to a preset time period. When the circuit breaker trigger frequency is lower than the preset low-frequency threshold, the preset circuit breaker threshold is lowered. When the circuit breaker trigger frequency is higher than the preset high-frequency threshold, the preset circuit breaker threshold is increased.
[0053] Specifically, the authorization encapsulation layer triggers an adaptive adjustment process for the circuit breaker threshold at a preset time period. In one feasible implementation, the preset time period is 24 hours, meaning the adjustment process is triggered once daily. The authorization encapsulation layer retrieves historical authorization audit logs from persistent storage media. These historical authorization audit logs are the accumulated historical data of the authorization audit logs recorded in step S6. The authorization encapsulation layer then filters from the historical authorization audit logs to identify the historical visual security level and corresponding historical dynamic risk coefficient for each triggering of the circuit breaker condition. The triggering circuit breaker condition refers to the event in step S5 where the real-time visual security level reaches or exceeds the preset circuit breaker threshold.
[0054] The authorized encapsulation layer uses historical visual security levels and corresponding historical dynamic risk coefficients as sample data to statistically analyze the circuit breaker trigger frequency according to a preset time period. The formula for calculating the circuit breaker trigger frequency is: ; in, The frequency at which the fuse is triggered. This represents the number of operation requests that trigger the circuit breaker condition within the current preset time period. This represents the total number of operation requests allowed to be executed within the authorization granularity determined by step S3 within the current preset time period.
[0055] The authorized encapsulation layer compares the fuse trigger frequency with preset low-frequency thresholds and preset high-frequency thresholds. The preset low-frequency threshold is the lower limit of the fuse trigger frequency, and the preset high-frequency threshold is the upper limit of the fuse trigger frequency. In one feasible implementation, the preset low-frequency threshold is 0.01, and the preset high-frequency threshold is 0.15, meaning that the trigger threshold is adjusted when the fuse trigger frequency is below 1% or above 15%. The preset low-frequency threshold and the preset high-frequency threshold are pre-configured by the system administrator according to the security level requirements of the target area.
[0056] When the frequency of circuit breaker triggering is lower than the preset low-frequency threshold, it indicates that the current preset circuit breaker threshold setting is too strict, resulting in too few circuit breaker events. The authorization encapsulation layer then lowers the preset circuit breaker threshold. The preset circuit breaker threshold is lowered by subtracting a preset adjustment step size from the current preset circuit breaker threshold. In one feasible implementation, the preset adjustment step size is 5. When the visual security level range is 0 to 100, the lowered preset circuit breaker threshold is the original value minus 5.
[0057] When the frequency of circuit breaker triggering exceeds a preset high-frequency threshold, it indicates that the current preset circuit breaker threshold setting is too lenient, resulting in too many circuit breaker events. The authorization encapsulation layer then increases the preset circuit breaker threshold. The method for increasing the preset circuit breaker threshold is to add a preset adjustment step size to the current preset circuit breaker threshold. In a feasible implementation, the preset adjustment step size is 5. When the visual security level range is 0 to 100, the increased preset circuit breaker threshold is the original value plus 5.
[0058] After adjusting the preset circuit breaker threshold, the authorized encapsulation layer stores the adjusted preset circuit breaker threshold in the system configuration for comparison and judgment between the real-time visual security level and the preset circuit breaker threshold in the subsequent S5 steps.
[0059] Example 2 This embodiment takes the remote control operation scenario of a quay crane at a port container terminal as an example to illustrate the specific implementation of the technical solution of the present invention.
[0060] Quay cranes at port container terminals are the core equipment for container loading and unloading operations. In remote control mode, operators control the quay cranes through a remote control system to complete container loading and unloading operations. The area beneath the quay cranes is the target work area, which presents safety risks such as spreader swaying and container falls. Unauthorized personnel entering this area face serious personal injury risks. To ensure operational safety, terminal management has deployed multiple high-definition cameras and configured a visual recognition platform in the area beneath the quay cranes to monitor in real time the distribution of personnel within the target area, the wearing of personal protective equipment, and whether personnel have entered the pre-defined danger zone.
[0061] When the agent receives an operation request to "start the quay crane and perform container loading and unloading operations", the authorization encapsulation layer initiates the authorization process of the technical solution of this invention.
[0062] In step S1, the authorization encapsulation layer sends a visual recognition request to the visual recognition platform, which receives video streams in real time from high-definition cameras deployed in the area beneath the quay crane. The visual recognition platform runs target detection, safety helmet and reflective vest detection, and area intrusion detection algorithms frame-by-frame on the video stream. In this embodiment, the target detection algorithm identifies three workers within the target area; the safety helmet and reflective vest detection algorithm identifies that two of the three workers are wearing safety helmets and reflective vests correctly, while one is not wearing a safety helmet; the area intrusion detection algorithm identifies that one person has entered a pre-defined hazard zone for crane swaying. The visual recognition platform then sends these identification results to the authorization encapsulation layer.
[0063] The authorization layer calculates the personnel density index based on the ratio of the number of people to the preset maximum capacity of the target area. Assuming the preset maximum capacity of the target area is 10 people, the personnel density index is: ; The authorized encapsulation layer calculates the personal protective equipment (PPE) compliance index based on the ratio of the number of personnel wearing PPE in compliance with regulations to the total number of personnel, i.e.: ; The authorization encapsulation layer determines the danger zone intrusion index based on the number of people entering the preset danger zone, i.e., the danger zone intrusion index is equal to 1.
[0064] The authorization encapsulation layer obtains the preset risk weight coefficient corresponding to the current operation type; the risk weight coefficient for quay crane operations is 0.8. The authorization encapsulation layer performs a weighted summation of the above four indices to obtain the visual safety level. In this embodiment, each weight coefficient is taken as... , , , ,but: ; That is, the visual safety level is 74.
[0065] In step S2, the authorization encapsulation layer obtains the historical safety context information of the target area. A query of the authorization audit log shows that the historical incident rate for this target area over the past 30 days is 2 incidents per month. The current operation type is high-altitude work, with a corresponding basic risk level of 7. The visual recognition platform analyzes the movement trajectory of personnel within the target area using a target tracking algorithm, identifying one person who has entered the danger zone and is currently slowly moving towards the lifting equipment at an approach speed of 0.3 meters per second.
[0066] The authorized encapsulation layer calculates a comprehensive risk baseline value based on the normalized visual security level, the normalized historical accident rate, and the normalized basic risk level. Specifically, the normalized value for the visual security level is 74 / 100 = 0.74, the normalized value for the historical accident rate is 2 / 5 = 0.4 (the preset maximum accident rate threshold is 5 times / month), and the normalized value for the basic risk level is 7 / 10 = 0.7. The weighting coefficients are respectively... , , ,but: ; The authorization encapsulation layer determines the risk trend correction factor based on the movement trend information of personnel within the area. Since the personnel entering the danger zone are currently approaching at a speed of 0.3 m / s, and the preset trend correction coefficient δ is set to 0.1, then: ; The authorized encapsulation layer superimposes the comprehensive risk base value and the risk trend correction factor to generate a dynamic risk coefficient: ; In step S3, the authorization encapsulation layer determines the agent's current authorization granularity based on the preset numerical range into which the dynamic risk coefficient 0.69 falls. In this embodiment, the correspondence between the preset numerical range and the authorization granularity is as follows: 0 to 0.3 corresponds to automatic execution; greater than 0.3 and less than or equal to 0.6 corresponds to notification after execution; greater than 0.6 and less than or equal to 0.85 corresponds to secondary confirmation required; and greater than 0.85 and less than or equal to 1 corresponds to rejection. The dynamic risk coefficient 0.69 falls within the range of greater than 0.6 and less than or equal to 0.85, therefore the current authorization granularity is secondary confirmation required.
[0067] In step S4, since the current authorization granularity requires secondary confirmation, the authorization encapsulation layer sends a confirmation request to the authorized user terminal. The confirmation request includes: operation type is "start quay crane," target area is the area below quay crane #3, dynamic risk coefficient is 0.69, and a message stating, "One person has entered the danger zone and is approaching the spreader; it is recommended to confirm site safety before execution." The authorization encapsulation layer starts a timer, waiting for a response from the authorized user terminal. Assuming the authorized user returns a confirmation command via the authorized user terminal within 45 seconds, the authorization encapsulation layer receives the confirmation command within a preset waiting time of 60 seconds. It then allows the agent's operation request, creates a session identifier corresponding to the current operation, and establishes a stateful secure session containing the session identifier, the execution status of the current operation, and the target area identifier. The agent then begins executing the quay crane start operation.
[0068] In step S5, during the execution of the current operation, the authorization encapsulation layer obtains the target area identification information from the stateful security session, sends a visual security level query request to the visual recognition platform every 2 seconds according to the preset query period, and continuously monitors the real-time visual security level of the target area.
[0069] The authorization encapsulation layer receives the real-time visual safety level returned by the visual recognition platform. Suppose that at the 30-second mark of operation, the visual recognition platform detects two more people entering the danger zone, and the real-time visual safety level rises to 82. At this point, the real-time visual safety level 82 reaches the preset circuit breaker threshold 75. The authorization encapsulation layer determines that the circuit breaker condition has been triggered, generates a stop command containing target area identification information and the current operation session identifier, and sends the stop command to the intelligent agent execution end. Upon receiving the stop command, the intelligent agent execution end immediately terminates the start operation of the quay crane to avoid potential safety accidents caused by continuing operation with multiple people in the danger zone. The authorization encapsulation layer updates the execution status in the stateful safety session to "circuit-breaker interrupted" and records the circuit breaker trigger time and the real-time visual safety level at the time of triggering the circuit breaker.
[0070] In step S6, the authorization encapsulation layer creates an authorization audit log from the data generated at each step of the authorization process. The authorization audit log records the visual security level (74), dynamic risk coefficient (0.69), the requirement for secondary confirmation at the current authorization granularity, the user's confirmation decision result (confirmation time: 45 seconds), the initiation time of the operation request, the target area identification information, the circuit breaker trigger status (triggered), the circuit breaker trigger time, and the real-time visual security level (82) at the time of triggering. The authorization encapsulation layer writes this audit log entry to persistent storage for subsequent security event tracing and compliance review.
[0071] This embodiment fully demonstrates the application process of the technical solution of the present invention in the remote control scenario of port quay cranes. By using the real-time visual safety situation of the target area as a dynamic factor for authorization decision-making and continuously monitoring the on-site safety situation during operation execution, this solution effectively solves the technical problem that the traditional RBAC multi-factor authorization mechanism cannot perceive the physical safety situation of the operation target area, realizes the dynamic matching of authorization granularity and on-site risk, and significantly improves the operational safety of intelligent agents in high-risk port operation scenarios.
[0072] Finally, it should be noted that the above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A method for encapsulating multi-factor authorization agent applications based on RBAC mechanism, characterized in that, include: S1. Obtain the real-time visual recognition result of the target area, and calculate the visual security level based on the real-time visual recognition result; S2. Obtain the historical security context information of the target area, input the visual security level and the historical security context information into a preset risk assessment model, and output a dynamic risk coefficient. S3. Determine the current authorization granularity of the agent based on the preset value range into which the dynamic risk coefficient falls; S4. When the current authorization granularity allows execution, allow the operation request of the intelligent agent and establish a stateful secure session corresponding to the current operation; S5. During the execution of the current operation, the real-time visual safety level of the target area is periodically acquired, and when the real-time visual safety level is detected to reach a preset circuit breaker threshold, a stop command is sent to the execution end to interrupt the current operation. S6. Record the visual security level, the dynamic risk coefficient, and the current authorization granularity to form an authorization audit log.
2. The method for encapsulating multi-factor authorization agent applications based on RBAC mechanism according to claim 1, characterized in that, In S1, the visual security level is calculated, including: The video stream of the target area is analyzed in real time through a visual recognition platform to identify the number of people in the target area, the status of their personal protective equipment, and their intrusion status relative to the danger zone. The personnel density index is calculated based on the ratio of the number of personnel to the preset maximum capacity of the target area; the personal protective equipment compliance index is calculated based on the ratio of the number of people wearing the personal protective equipment in compliance with regulations to the total number of personnel; and the danger zone intrusion index is calculated based on the number of personnel entering the danger zone. Obtain the preset risk weight coefficient corresponding to the current job type; The visual safety level is obtained by weighting and summing the personnel density index, the personal protective equipment compliance index, the danger zone intrusion index, and the risk weight coefficient.
3. The method for encapsulating multi-factor authorization agent applications based on RBAC mechanism according to claim 1, characterized in that, In S2, the dynamic risk coefficient is output, including: Obtain historical safety context information of the target area of the operation. The historical safety context information includes at least the historical accident rate, the basic risk level of the current operation type, and the movement trend information of people in the area. Based on the visual security level, the historical accident rate, and the basic risk level, a comprehensive risk base value that integrates visual risk and business risk is calculated. Based on the movement trend information of people within the area, a risk trend correction factor is determined; The dynamic risk coefficient is generated by superimposing the comprehensive risk base value with the risk trend correction factor.
4. The method for encapsulating multi-factor authorization agent applications based on RBAC mechanism according to claim 1, characterized in that, In step S3, determining the current authorization granularity of the agent includes: Multiple mutually exclusive value ranges are preset, and each value range corresponds to an authorization granularity. The authorization granularity includes at least automatic execution, execution notification, secondary confirmation required, and rejection. Determine the numerical range into which the dynamic risk coefficient falls; Based on the correspondence between the numerical range and the authorization granularity, the authorization granularity corresponding to the numerical range into which the dynamic risk coefficient falls is determined as the current authorization granularity of the agent.
5. The method for encapsulating multi-factor authorization agent applications based on RBAC mechanism according to claim 1, characterized in that, In step S4, establishing a stateful secure session corresponding to the current operation includes: Determine whether the current authorization granularity is a denial; When the current authorization granularity is "reject", a rejection response is returned, and the current process ends; When the current authorization granularity is not a rejection, perform the corresponding pre-release processing according to the type of the current authorization granularity; Allow the agent's operation request, create a session identifier corresponding to the current operation, and establish a stateful secure session containing the session identifier, the execution status of the current operation, and the target area identifier information.
6. The method for encapsulating multi-factor authorization agent applications based on RBAC mechanism according to claim 5, characterized in that, The step of performing the corresponding pre-release processing according to the type of the current authorization granularity includes: If the current authorization granularity is automatic execution or notification after execution, then proceed directly to the step of allowing the agent's operation request; If the current authorization granularity requires secondary confirmation, a confirmation request is sent to the authorized user terminal. Upon receiving the confirmation instruction, the process proceeds to allow the operation request of the intelligent agent. Alternatively, if the confirmation instruction is not received within a preset waiting period, a rejection response is returned and the current process ends.
7. The method for encapsulating multi-factor authorization agent applications based on RBAC mechanism according to claim 1, characterized in that, In step S5, sending a stop command to the execution end to interrupt the current operation includes: Obtain the target area identification information of the target area from the stateful security session; Based on the target area identification information, a visual security level query request is sent to the visual recognition platform according to a preset query cycle; Receive the real-time visual security level returned by the visual recognition platform in response to the query request; The real-time visual security level is compared with a preset circuit breaker threshold. When the real-time visual security level reaches or exceeds the preset circuit breaker threshold, the circuit breaker condition is determined to be triggered.
8. The method for encapsulating multi-factor authorization agent applications based on RBAC mechanism according to claim 1, characterized in that, In step S6, an authorized audit log is generated, including: Obtain authorized audit data; If a user confirmation process exists, obtain the user confirmation decision result and the confirmation time, and associate the user confirmation decision result and the confirmation time with the authorized audit data; The authorized audit data is structured into an audit log entry according to a preset log format; Write the audit log entries to persistent storage media.
9. The method for encapsulating multi-factor authorization agent applications based on RBAC mechanism according to claim 1, characterized in that, When the operation request involves multiple target areas, it includes: Obtain the real-time visual recognition results for each of the target regions, and calculate the visual security level for each of the target regions respectively; Take the highest level among the aforementioned visual safety levels as the joint visual safety level, and execute steps S2 to S6; Alternatively, the visual security levels can be weighted and summed according to the preset risk weights of the target areas to obtain a joint visual security level, and steps S2 to S6 can be executed.
10. The method for encapsulating multi-factor authorization agent applications based on RBAC mechanism according to claim 1, characterized in that, The preset circuit breaker threshold is adaptively adjusted in the following ways: Obtain the historical visual security level and historical dynamic risk coefficient corresponding to each circuit breaker trigger from the historical authorization audit log; Using the historical visual security level and the historical dynamic risk coefficient as sample data, the circuit breaker trigger frequency is statistically analyzed according to a preset time period; When the circuit breaker trigger frequency is lower than the preset low-frequency threshold, the preset circuit breaker threshold is lowered. When the circuit breaker trigger frequency is higher than the preset high-frequency threshold, the preset circuit breaker threshold is increased.