A method and system for secure access authentication of terminal devices
By normalizing and exponentially amplifying the context vector of the terminal device, a weighted summation is generated to produce a context instability score. Combined with temporal consensus dispersion, this solves the problem of the inability to quantify environmental changes in real time in existing technologies, and improves the security of terminal device access authentication and the accuracy of dynamic trust assessment.
Patent Information
- Application Number
- CN202611287782.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-08-24
- Publication Date
- 2026-11-17
AI Technical Summary
Existing access authentication technologies cannot quantify changes in the context environment during a session in real time, lack differentiated risk response capabilities, and lack a reliable initial trust anchor, thus failing to effectively address security risks of terminal devices in different environments.
By obtaining the context vector of the terminal device, including IP address, device ID and geographical location, the change magnitude is calculated after normalization, and an exponential nonlinear amplification weighted sum is used to generate a context instability score. At the same time, the temporal consensus dispersion is introduced as a quantitative indicator, and the signature timestamps of multiple independent timestamp issuing institutions are used to verify the temporal consensus and provide a reliable initial trust anchor point.
It enables real-time quantitative perception of changes in the context environment during a session, clearly distinguishing between normal network drift and malicious environment jumps, thereby improving the security of terminal device access authentication and the accuracy of dynamic trust assessment.
Smart Images

Figure CN123122908A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of access authentication technology, and in particular to a secure access authentication method and system for terminal devices. Background Technology
[0002] Access authentication technology is used to confirm and verify the legitimacy of entities (including users, devices, or processes) attempting to access protected resources, and to grant or deny access permissions according to preset policies. It is a crucial foundation for ensuring information security. In existing access authentication technologies, after initial authentication, a user or device is granted a trust state and access permission set that typically remains unchanged throughout the session's lifecycle. The underlying premise is that a single legitimate login equates to continuous legitimacy throughout the entire session. However, in real-world attack scenarios, this premise is difficult to uphold—a user's session credentials may be stolen due to malware infection of the terminal, allowing attackers to use these credentials to initiate operations from another location. The system, only recognizing credential validity, cannot detect changes in the user's identity. Similarly, an employee may log in to the company's internal network and then bring their device into an insecure public wireless network, drastically increasing the security risk, yet the system maintains the original high-privilege access. Clearly, existing technologies cannot detect environmental changes and changes in the user's identity during a session, creating significant security blind spots.
[0003] To address the aforementioned issues, existing solutions have attempted to introduce dynamic trust assessment mechanisms. Current technologies often calculate trust scores based on similarity matching of frequently used historical features, and then use this information for access control. However, these solutions still have the following shortcomings: First, their trust assessment is based on static historical benchmarks, meaning they only determine "whether the current behavior matches past usage," failing to perceive continuous changes in the context during a session, let alone quantify the magnitude of these changes. Second, existing technologies use a linear weighting method to calculate trust values, lacking differentiated risk response capabilities for minor environmental fluctuations and drastic environmental changes. Third, the trust assessment and login authentication processes in existing technologies are independent of each other, lacking a reliable initial trust anchor point, and the initial trust value lacks objective basis. Therefore, there is an urgent need for a secure access authentication solution for terminal devices that can quantify changes in the context during a session in real time and possess differentiated risk response capabilities. Summary of the Invention
[0004] The purpose of this invention is to obtain the context vectors of the terminal device at the current and previous moments, normalize the IP address, device ID, and geographical location, calculate the magnitude of change, and then perform exponential nonlinear amplification of the magnitude of change of each feature before weighted summation to generate a context instability score. The normalization process unifies the three different dimensions of features—IP address, device ID, and geographical location—into a single mathematical space for comparison. The exponential nonlinear amplification minimizes the score contribution from minor environmental fluctuations (such as changes in the last digit of the IP address due to WiFi switching within a network segment), while exponentially increasing the score contribution from drastic environmental changes (such as IP jumps across network segments or regions, or device replacement). This allows the system to clearly distinguish between normal network drift and malicious environmental jumps, solving the problem that existing technologies cannot detect continuous changes in the context environment during a session and cannot provide differentiated risk responses based on the magnitude of these changes. Another objective of this invention is to introduce temporal consensus dispersion as a quantitative indicator after receiving signature timestamps returned by multiple independent timestamp issuing authorities and verifying the signature validity of each timestamp. This temporal consensus dispersion includes a timestamp distribution width component and a distribution symmetry component. The width component reflects the overall dispersion of each timestamp, while the symmetry component reflects whether the timestamp distribution is skewed. This quantifies the consensus quality among multi-source timestamps into a calculable and comparable value. Since the preset threshold is dynamically adjusted based on the historical network round-trip latency of each timestamp issuing authority, the consensus determination can adapt to different network environment conditions.
[0005] To achieve the above objectives, the present invention adopts the following technical solution: a terminal device secure access authentication method, comprising: S1. During the login phase, time-series consensus verification is performed based on the signature timestamps returned by multiple independent timestamp issuing authorities. After the verification is successful and the access credential verification is successful, the trust score of the terminal device is initialized to the preset full score. S2. During the session, obtain the context vector of the terminal device at the current time and the previous time. The context vector includes the IP address, device ID and geographical location. S3. Determine the normalized rate of change of each feature in the current context vector, and then perform exponential nonlinear amplification and weighted summation on the normalized rate of change of each feature in the current context vector to generate the current context instability score. S4. Adjust the trust score of the previous moment by deducting from the current moment's context instability score to obtain the current moment's trust score. S5. Determine the access permissions of the terminal device at the current moment based on the trust score at the current moment, and return to S2 for the next round of monitoring.
[0006] Preferably, the method for determining the normalized rate of change of each feature in the context vector at the current time includes: For an IP address, convert the dotted decimal string of the IP address to a 32-bit unsigned integer, and then divide it by 2³²−1 to obtain the normalized value of the IP address; calculate the absolute value of the difference between the normalized value of the IP address at the current time and the previous time, and divide it by the normalization reference value of the IP address to obtain the normalization rate of change of the IP address. For the device ID, compare the device ID string at the current time with that at the previous time. If they match, the device ID change value is 0; otherwise, it is 1. The device ID change value is used as the normalized change rate of the device ID. For geographic locations, calculate the spherical distance between the current and previous geographic locations, divide it by the preset geographic location baseline distance, and crop the division result to the [0,1] interval to obtain the geographic location normalized value; calculate the absolute value of the difference between the current and previous geographic location normalized values, divide it by the geographic location normalized baseline value, and obtain the geographic location normalized rate of change.
[0007] Preferably, the normalized reference value of the IP address or the normalized reference value of the geographical location is determined in the following way: Obtain the statistical distribution of the normalized numerical change amplitude of IP address or geographical location between two consecutive sampling points during historical usage, and use the preset percentile value of the statistical distribution as the normalized reference value of the corresponding feature.
[0008] Preferably, the method for generating the context instability score at the current moment includes: By using the amplification factors corresponding to each preset feature, the normalized rate of change of each feature in the current context vector is exponentially and non-linearly amplified to obtain the initial risk contribution value of each feature in the current context vector. The initial risk contribution values of each feature in the current context vector are weighted and summed using the preset sensitivity coefficients corresponding to each feature to obtain the context instability score at the current moment.
[0009] Preferably, the method for determining the access permissions of the terminal device at the current moment includes: When the trust score at the current moment is higher than the first threshold, normal access is granted; When the trust score at the current moment is lower than or equal to the first threshold and higher than the second threshold, restricted access is granted; Access is denied when the current trust score is lower than or equal to the second threshold.
[0010] Preferably, step S1 includes: Send challenge data containing user identifiers to multiple independent timestamp issuing authorities; Receive signature timestamps returned by various timestamp issuing authorities; Verify the validity of each signature timestamp, remove the signature timestamps that failed to be verified, and obtain the set of verified timestamps; Calculate the temporal consensus dispersion of the verified timestamp set, wherein the temporal consensus dispersion is the sum of the timestamp distribution width component and the distribution symmetry component; When the dispersion of the time-series consensus is less than or equal to a preset threshold, the time-series consensus verification is deemed successful.
[0011] Preferably, the timestamp distribution width component is the difference between the maximum and minimum timestamps in the verified timestamp set; the distribution symmetry component is the product of the deviation between the mean of the verified timestamp set and the average of the maximum and minimum timestamps, multiplied by a penalty factor.
[0012] Preferably, the method for determining the preset threshold includes: Obtain the round-trip delay statistical distribution of each timestamp issuing agency within a preset historical time period, calculate the preset percentile value of the round-trip delay statistical distribution, and obtain the basic window value; Obtain the time-series consensus dispersion value recorded during multiple historical authentication processes, calculate the standard deviation of the obtained time-series consensus dispersion value, and use it as a dynamic adjustment factor; The sum of the base window value and the dynamic adjustment factor is used as the preset threshold.
[0013] Preferably, step S4 further includes exponential decay processing of the trust score at the previous moment according to a preset time period.
[0014] As a preferred embodiment, a secure access authentication system for terminal devices includes: The multi-source challenge distribution module is used to send challenge data containing user identifiers to multiple independent timestamp issuing authorities during the login phase; The access consensus verification module is used to receive the signature timestamps returned by each timestamp issuing authority, verify the signature validity of each signature timestamp, and perform time-series consensus verification and access credential verification. The dynamic trust assessment module is used to initialize the trust score to a preset full score after confirming the validity of the user's access credentials. During the session, it obtains the context vector of the terminal device at the current time and the previous time, determines the normalized rate of change of each feature in the context vector at the current time, and then performs exponential nonlinear amplification and weighted summation on the normalized rate of change of each feature in the context vector at the current time to generate the context instability score at the current time. Based on the context instability score at the current time, it deducts and adjusts the trust score at the previous time to obtain the trust score at the current time. The session credential update module is used to determine the access permissions of the terminal device at the current time based on the trust score at the current time.
[0015] This invention obtains the context vectors of the terminal device at the current and previous moments, normalizes the IP address, device ID, and geographical location, calculates the change amplitude of each feature between the two moments, and then generates a context instability score by weighted summation of each change amplitude after exponential nonlinear amplification. This achieves real-time quantitative perception of continuous changes in the context environment during a session. Because an exponential nonlinear function is used to amplify the environmental change amplitude, the score contribution from minor environmental fluctuations is minimal, while the score contribution from drastic environmental changes grows exponentially, enabling the system to clearly distinguish between normal network drift and malicious environmental jumps. Simultaneously, by mapping IP addresses to ordered values, performing consistency comparisons on device IDs, calculating spherical distances for geographical locations, and standardizing each using its corresponding normalized baseline value, a unified quantitative evaluation of multi-dimensional context change features is achieved.
[0016] This invention further enhances the login process by sending challenge data containing user identifiers to multiple independent timestamp issuing authorities. After receiving and verifying each signature timestamp, it calculates the temporal consensus dispersion, including a timestamp distribution width component and a distribution symmetry component. When the dispersion is less than or equal to a preset threshold, the trust score is initialized to a preset maximum score, providing a reliable initial trust anchor with objective cryptographic basis for subsequent dynamic trust assessment. The temporal consensus dispersion, as a quantitative indicator, quantifies the consensus quality to reflect the credibility of the initial authentication. The preset threshold can be dynamically adjusted based on the historical network round-trip latency of each timestamp issuing authority, enabling consensus determination to adapt to different network environment conditions. Furthermore, the multi-source temporal consensus authentication in the login phase is systematically coupled with the context instability scoring in the session phase. This allows the trust score to dynamically adjust from a reliable initial value with environmental changes, forming a complete trust chain from login authentication to session monitoring. This effectively solves the problem in existing technologies where login authentication and session monitoring are independent and cannot form a complete trust chain, significantly improving the security of terminal device access authentication. Attached Figure Description
[0017] Figure 1 This is a system flowchart of the present invention. Detailed Implementation
[0018] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention.
[0019] Example 1, as Figure 1 As shown, the present invention provides a technical solution: a terminal device secure access authentication system comprising: The multi-source challenge distribution module is used to receive login intent from terminal devices, generate a one-time random challenge code, concatenate the user identifier with the one-time random challenge code, construct a JSON request payload containing data encoding, API version and request identifier, and send the request payload to multiple independent timestamp issuing agencies to establish a distributed challenge instruction set. The access consensus verification module is used to receive multiple signature timestamps and user access credentials returned according to the distributed challenge instruction set, verify the signature of each signature timestamp one by one, obtain a set of verified timestamps, extract each timestamp from the set of verified timestamps for comparison, and generate time-series consensus authentication credentials. The dynamic trust assessment module is used to initialize the trust score to the preset full score after confirming the user's access credentials based on the time-series consensus authentication credentials. It also collects the IP address, device ID and geographical location of the current terminal device to form an initial context vector, obtains the initial context trust baseline, and combines the initial context trust baseline with the attenuation constant to establish a session trust attenuation parameter set. The session credential update module is used to generate a context instability score based on the session trust decay parameter set, adjust the decayed trust score according to the score, compare the adjusted score with the security threshold and warning threshold, and obtain immediate access decision permissions.
[0020] The steps to obtain the distributed challenge instruction set are as follows: Upon receiving a login intent from a terminal device, the system parses the user identifier field and the receiving time record of the message, extracts the encoded string of the user identifier and the byte sequence of the receiving time record, combines and truncates them with byte blocks from a random source, and generates a one-time random challenge code. Based on the one-time random challenge code, read the encoded string of the user identifier, insert delimiters and fixed-length padding in a fixed order, concatenate the one-time random challenge code and the user identifier, and append a length check bit to form the concatenated data; Based on the concatenated data, a request payload is constructed for multiple independent timestamp issuing agencies, with route numbers and sending times marked. Each request is sent and each receipt number and target agency identifier is recorded to form a distributed challenge instruction set.
[0021] Specifically, upon receiving a login intent from a terminal device, the system first performs structured parsing on the data packet containing the login intent. Based on a preset communication protocol format, it locates and extracts the user identifier field, sequence number field, and reception time record. For example, in a fixed-length packet, bytes 0 to 31 are defined as the user identifier field, bytes 32 to 47 as the sequence number field, and bytes 48 to 55 as the high-precision Unix timestamp format reception time record. Next, it extracts the UTF-8 encoded string from the user identifier field and obtains its 64-bit byte sequence from the reception time record. Simultaneously, it calls the system's underlying cryptographically secure pseudo-random number generator, such as one based on HMAC. The deterministic random bit generator (HMAC-DRBG) generates a 256-bit random source byte block. To ensure the quality of randomness, the generator's entropy pool is periodically updated by collecting entropy from hardware noise sources (such as CPU temperature jitter or disk seek time). Subsequently, the extracted user identifier encoded string, the byte sequence recorded by the receiving time, and the generated random source byte block are sequentially concatenated to form a temporary byte string. This temporary byte string is used as input, and the SHA-256 hash algorithm is applied to generate a 256-bit hash digest. Finally, the first 128 bits of this hash digest are extracted as the final one-time random challenge code.
[0022] Based on the one-time random challenge code generated in the previous step, the encoded string of the user identifier parsed from the original login intent message is reread. A fixed block size is set, for example, 128 bits (16 bytes), for aligning the user identifier. The PKCS#7 padding scheme is used to pad the encoded string of the user identifier. Specifically, the difference between the length of the encoded string of the user identifier and the block size is calculated. If the difference is N, N bytes are padded to the end, with each byte having the value N. If the length of the encoded string of the user identifier is exactly an integer multiple of the block size, an additional 16-byte block is padded, with each byte having the value 16. After padding, the user identifier is compared with the padded string. A fixed, non-text printable character, such as the ASCII unit separator (0x1F), is inserted at the end of the data block. Next, a 128-bit one-time random challenge code is appended after the separator, forming an intermediate concatenated data. This intermediate concatenated data is then subjected to integrity verification using the CRC32 algorithm to calculate its cyclic redundancy check code. This algorithm treats the entire intermediate concatenated data as a long binary number and performs modulo-2 division on it using a predefined generator polynomial. The resulting 32-bit remainder is the CRC32 check code. This 32-bit check code is used as the length check bit and appended to the end of the intermediate concatenated data, thus forming the concatenated data.
[0023] Based on the concatenated data generated in the previous step, an independent request payload is constructed for each pre-defined independent timestamp issuing authority (TSA). This process first selects the target authority from a pre-configured list of TSAs. This list is established during system initialization and contains the API endpoint addresses and corresponding public key information of at least 10 trusted, geographically dispersed TSAs. For this authentication, 5 TSAs are randomly selected from this list. For each selected TSA, the concatenated data is Base64 encoded to ensure data integrity during transmission. Then, a JSON-formatted request payload is constructed with the structure {"apiVersion":"1.0","dataToSign":"[Base64 encoded concatenated data]","requestId":"[UUID]"}, where... A UUID is a unique identifier generated for this request. After constructing the payload, each request is assigned a route number from 1 to 5, and the current system time is recorded as the sending time. Then, these request payloads are sent one by one to the corresponding TSA endpoint address via HTTPS using a POST request. At the same time as sending each request, a record entry is created in the local session. This entry contains the route number, the target organization identifier (such as its domain name), the sending time, and an empty field for storing the receipt number. When the TSA server receives the request and processes it successfully, it immediately returns a receipt containing its internal transaction ID, which is the receipt number. This receipt number is recorded in the empty field of the corresponding entry. Finally, the five record entries corresponding to these five requests together constitute a structured set, namely the distributed challenge instruction set.
[0024] The steps to obtain the verified timestamp set are as follows: Based on the distributed challenge instruction set, the system receives multiple returned signature timestamps and the user's access credentials. For each signature timestamp, the signature field, timestamp field, and issuance identifier are extracted. The signature validity is verified using the corresponding public key, and failed verification items are filtered out. The verified timestamps are sorted in ascending order by time to obtain the set of verified timestamps.
[0025] Specifically, based on the distributed challenge instruction set, a concurrent listening process is initiated, opening a dedicated asynchronous receiving channel for each target organization identifier in the instruction set. This continuously monitors the network ports of these independent timestamp issuing organizations to receive returned signature timestamp data packets. Simultaneously, user access credentials submitted by terminal devices through independent channels are received in parallel. For each received signature timestamp data packet, integrity verification is first performed, such as checking if it conforms to the TimeStampResp structure defined in RFC3161. Then, this data structure is parsed to extract the timestamp token. This token itself is a signature data structure conforming to the CMS standard. Further parsing of the token separates the signature field, the embedded timestamp information (TSTInfo), and the issuer's certificate chain. The unique identifier of the issuing organization, i.e., the issuing identifier, is extracted from the certificate at the end of the certificate chain. Using this issuing identifier, a lookup is performed in the system's pre-configured keystore, which stores the public keys of all trusted timestamp issuing organizations. The system retrieves the public key corresponding to the issued identifier. Using this public key and a specified signature algorithm (e.g., SHA256withRSA), it decrypts and verifies the signature field to check its validity. The verification process involves comparing the decrypted hash value with the hash value recalculated based on the received TSTInfo content. If they match perfectly, the signature verification passes. If they do not match, or if the certificate has expired or been revoked (confirmed by querying the pre-set Certificate Revocation List (CRL)), or if the hash value of the original data contained in the TSTInfo does not match the hash value recorded when the system distributed the challenge, the verification fails. The signature timestamp is then marked as invalid and removed from the processing queue. The timestamp fields (usually UTC time in seconds or milliseconds, Unix timestamps) are extracted from all verified signature timestamps and collected into a temporary list. Finally, an ascending sorting algorithm is applied to all timestamp values in the list to obtain the set of verified timestamps.
[0026] The steps to obtain time-series consensus authentication credentials are as follows: Based on the verified timestamp set, the time-series consensus dispersion is calculated using the following formula: ; in, For time-series consensus dispersion, The largest timestamp in the set of verified timestamps. The smallest timestamp in the set of verified timestamps. The average value of all timestamps in the verified timestamp set is calculated using the following formula: , This represents the total number of timestamps in the verified timestamp set. For the first A timestamp, This is a penalty factor used to measure the asymmetry of timestamp distribution; Based on the dispersion of the time consensus, the dispersion of the time consensus is compared with the preset time window threshold. When the dispersion of the time consensus is less than or equal to the time window threshold, the timestamp distribution is determined to meet the time consensus requirements. Otherwise, it is marked as failing the time consensus verification and a time consensus authentication credential is generated.
[0027] Specifically, in the formula for calculating the dispersion of time-series consensus, the first part... The range of the timestamp set was directly calculated, reflecting the total width of the timestamp distribution. This is a fundamental indicator for measuring dispersion. (Part Two) This introduces considerations for distribution symmetry. By calculating the deviation between the mean and the midpoint of the range of the timestamps, it penalizes asymmetrical distributions where data points are concentrated around the maximum or minimum values. Such distributions may indicate systemic network latency or malicious latency at certain timestamp issuing agencies. The penalty factor... The introduction of this method allows for adjustments to the sensitivity to distribution symmetry based on the stringency of the security strategy, compared to using only traditional statistics such as standard deviation or variance.
[0028] The parameter represents the maximum timestamp in the verified timestamp set. The steps to obtain it are as follows: Iterate through the verified timestamp set, which is a list of multiple Unix timestamps in milliseconds. During the iteration, maintain a variable representing the current maximum value, initially set to the first element of the list. Then, compare this variable with each subsequent element in the list. If an element larger than the current maximum value is encountered, update the value of the variable. Continue this process until all elements have been traversed. The final value of the variable is then obtained. For example, the set of verified timestamps obtained from the previous step is {1678886401005, 1678886401150, 1678886401080, 1678886401210}, all in milliseconds. By comparing these four values, we can determine... The value is 1678886401210.
[0029] The parameter represents the minimum timestamp in the set of verified timestamps, and its acquisition steps are the same as... The process of obtaining the current minimum value is similar, also requiring iteration through the set of verified timestamps. However, during the iteration, a variable representing the current minimum value is maintained. This variable is initially set to the first element of the list, and then compared with each subsequent element in the list. If an element smaller than the current minimum value is encountered, the value of the variable is updated. After completing the iteration through the entire list, the final value of the variable is [value to be filled in]. Taking the same set of verified timestamps {1678886401005, 1678886401150, 1678886401080, 1678886401210} as an example, by comparing them one by one, it can be determined that... The value is 1678886401005.
[0030] The parameter represents the average value of all timestamps in the verified timestamp set. The steps to obtain this value are as follows: First, count the total number of timestamps in the verified timestamp set, denoted as . Then, sum all the timestamp values in the set, and finally divide the sum by the total number of timestamps. The calculation formula is: ,in For the set of For the example set {1678886401005, 1678886401150, 1678886401080, 1678886401210}, the total number of timestamps is... The sum of all timestamps is 4, and the total sum of all timestamps is 6715545604445. Therefore, The value is calculated as .
[0031] The parameter represents the total number of timestamps in the verified timestamp set. The steps to obtain this set are as follows: after obtaining the verified timestamp set, call the built-in counting function of the data structure or directly count the number of elements in the set by iterating through it. This value reflects the number of independent timestamp issuing authorities that successfully responded and returned valid signed timestamps. For the example verified timestamp set {1678886401005, 1678886401150, 1678886401080, 1678886401210}, it contains 4 timestamps, therefore... The value is 4.
[0032] The parameter represents the first in the set of verified timestamps. One timestamp, among which It is from 1 to The integer index, which is not a single value, but rather represents each independent, verified timestamp data point in the set, used for calculations such as summation or traversal. It will iterate through all the values in the set in turn, for example, when calculating the average. During the process, The value is 1678886401005. The value is 1678886401150. The value is 1678886401080. The value is 1678886401210.
[0033] The parameter is a penalty factor used to measure the asymmetry of timestamp distribution. Its value is set based on the system's security level and tolerance for network jitter. The acquisition steps are as follows: First, within a calibration period after system deployment (e.g., one week), collect a set of verified timestamps recorded during at least 10,000 successful authentication processes. For each set, calculate its third-order standard moment, i.e., the sample skewness, to obtain a skewness value distribution. Then, define the relationship between skewness and penalty strength according to the security policy. For example, for a system requiring high synchronization, a moderate penalty can be applied when the absolute value of the skewness is greater than 0.5, and a high penalty can be applied when the absolute value of the skewness is greater than 1.0. The value can be determined by a piecewise function, for example, when the absolute value of the skewness is in the interval [0, 0.5]. When the value is in the interval (0.5, 1.0), In (1.0, When the interval is ) In this example, the system is set to a high security level, and a fixed penalty factor is selected. .
[0034] Calculations based on parameters: Based on the obtained parameter values, , , ,as well as Substitute the values into the formula to perform the calculation.
[0035] ; ; The result indicates that the calculated time-series consensus dispersion is 212.5. This value comprehensively reflects the dispersion and symmetry of all valid timestamps collected in this authentication on the timeline, in milliseconds. This value itself represents the degree of "inconsistency" in the timestamp distribution. The smaller the value, the more concentrated and synchronized the timestamps returned by each timestamp issuing agency are, and the higher the consensus. Conversely, the larger the value, the more dispersed or asymmetrical the timestamp distribution is, and the lower the consensus. Subsequent steps will compare this calculation result of 212.5 with a dynamically set time window threshold to make a final determination on whether the time-series consensus of this login intent has been achieved.
[0036] Based on the temporal consensus dispersion, the calculated value of 212.5 is compared with a dynamically calibrated time window threshold. The process for setting this time window threshold is as follows: In the background, continuous network probing is performed on all configured trusted timestamp issuing institutions. A lightweight network latency probe packet is sent to each institution every minute, and the round-trip time (RTT) is recorded. All RTT data obtained from the probes over the past 24 hours are collected to form an RTT distribution dataset. The 95th percentile value of this dataset is calculated. For example, after statistical analysis, the 95th percentile value of the RTT over the past 24 hours is 150 milliseconds. Considering the differences in network paths among multiple institutions and the inherent latency of data processing, the base value of the time window threshold is set to 1.5 times this 95th percentile value. In addition, to cope with abnormal situations such as sudden network congestion, a dynamic adjustment factor based on historical time-series consensus dispersion data is introduced. The system records the most recent 1000 successful authentications. The base value is calculated, and its standard deviation is calculated. For example, if the standard deviation is 35 milliseconds, the final time window threshold is set as the sum of the base value and this standard deviation. The millisecond threshold is recalculated every hour to dynamically adapt to changes in the network environment. In this authentication, the calculated time-series consensus dispersion of 212.5 is compared with the currently effective time window threshold of 260. Since 212.5 is less than 260, the timestamp distribution is determined to meet the time-series consensus requirements. The system will generate a structured data object containing the verification result, which is the time-series consensus authentication credential. This credential is a JSON object, which includes the user identifier, a boolean consensus state field (marked as true), the calculated time-series consensus dispersion value (212.5), the time window threshold used in this verification (260), the timestamp of the credential generation, and a list containing the identifiers of all issuing authorities that contributed valid timestamps. If the comparison result is that the time-series consensus dispersion is greater than the time window threshold, the consensus state field will be marked as false, indicating that the time-series consensus verification has not passed. Finally, the entire JSON object is signed using the system's internal asymmetric encryption private key to form the final time-series consensus authentication credential.
[0037] The steps for obtaining the initial context trust baseline are as follows: Based on the time-series consensus authentication credentials, read the user's access credential number and issuing authority identifier, verify that the validity period covers the current time and record the verification status. If the verification status is valid, set the trust score to the preset maximum score, collect the IP address, device ID and geographical location to obtain the initial context vector. Based on the initial context vector, extract the IP address, device ID, and geographic location, read the status flag with a preset maximum trust score, concatenate the parameters and trust score in a fixed field order, and generate a verification digest to obtain the initial context trust baseline.
[0038] Specifically, based on the time-series consensus authentication credential, it is first parsed and its internal signature integrity is verified, confirming that the consensus status field is "passed". Then, from the user access credential received in parallel (e.g., a digital certificate of the X.509v3 standard), its sequence number field is read as the access credential number, and the issuer information field is extracted as the issuing authority identifier. Next, the validity period field within the certificate is obtained, which contains a start time and an end time. The currently acquired system time synchronized via Network Time Protocol (NTP) is compared with this validity period interval. If the current system time is within this interval, the verification status is recorded as "valid"; otherwise, it is recorded as "invalid" and the subsequent process is terminated. After successful verification, a trust score variable associated with the current session is initialized to a preset maximum score value. This preset maximum score value is defined in the system configuration. The value 1000 represents the highest trust level assigned at the beginning of the session. Afterward, the system begins collecting parameters that constitute the initial context. The source IP address is extracted from the IP header of the network packet initiating the login request. The device ID, generated by the pre-installed client agent on the terminal device, is decrypted and extracted from the request payload. This device ID is a stable and unique identifier generated by calculating a SHA-256 hash value by concatenating the device's CPU serial number, motherboard UUID, and operating system installation ID. Using the extracted IP address, the system queries a locally deployed, weekly updated high-precision IP geolocation database to obtain the corresponding latitude and longitude coordinates as the geolocation. Finally, the collected IP address, device ID, geolocation, and the initial trust score of 1000 are combined into a structured data set to form the initial context vector.
[0039] Based on the initial context vector, the string representations of each parameter are first extracted from the data structure, including the IP address (e.g., "192.0.2.1"), device ID (e.g., "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855"), and geographic location (formatted as "latitude, longitude", e.g., "34.0522, -118.2437"). Simultaneously, the trust score is read and confirmed to be equal to the preset maximum score of 1000, thus obtaining a status flag with a value of "true". Next, these parameter string representations are concatenated according to a predefined fixed field order: device ID, IP address, geographic location, trust score. Using the pipe symbol "|" as the separator between fields, a single, normalized long string is formed, such as "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855|192.0.2.1|34.0522,-118.2437|1000". This concatenated long string is then converted into a UTF-8 encoded byte sequence. This byte sequence is used as input to calculate a 256-bit hash digest using the SHA-256 hash algorithm. This digest serves as a check digest for subsequent verification of the initial context integrity. Finally, the original initial context vector and the newly generated check digest are encapsulated in a new data structure to obtain the initial context trust baseline.
[0040] The steps to obtain the session trust decay parameter set are as follows: Based on the initial context trust baseline, load the configuration identifier and effectiveness policy of the decay constant, bind the session identifier of the initial context trust baseline and write the effectiveness time, and generate a session trust decay parameter set.
[0041] Specifically, based on the initial context trust baseline, the policy group associated with the user's identity is first parsed, such as "Ordinary User Group" or "Administrator Group," and this is used as the query key to look up information in a pre-configured "Trust Decay Policy Table." This table stores the decay parameters corresponding to different policy groups. The configuration identifier of the decay constant matching the policy group is loaded, such as "policy_default," along with the corresponding effective policy. The effective policy defines the specific value of the decay constant, which is set based on statistical analysis of the historical session behavior of a specific user group. For example, by analyzing the average session duration and risk event frequency of the "Ordinary User Group" over the past three months, the lowest risk is calculated when session trust decreases by 0.1% per minute. Therefore, the decay constant is set to 0.001, and the policy also defines the time unit for decay calculation as "minutes". Next, the unique session identifier (SessionID) generated for this session is obtained from the current login process, and this session identifier is bound to the initial context trust baseline. This means that the baseline will serve as the starting point for all trust assessments during the session lifecycle. Then, the current system timestamp is obtained and written into the session record as the effective time, marking the official activation of the trust decay mechanism from this moment. Finally, the loaded configuration identifier, decay constant value, time unit, bound session identifier, initial context trust baseline, and effective timestamp are integrated into a structured parameter set to generate the session trust decay parameter set.
[0042] The steps to obtain the context instability score are as follows: Based on the session trust decay parameter set, the record fields of time interval and decay constant are called to calculate the decay function value and update the trust score cache. The context vector of the current secure session is obtained, the context vector of the previous moment is retrieved, the order of feature fields and normalization interval are unified, and context vector pairs are generated. The context instability score is calculated based on the context vector pairs using the following formula: ; in, Score the context instability. The first of the current security session context vectors The normalized values of each feature. The context vector of the previous time step The normalized values of each feature. Indicates the first The absolute value of the change in each feature For the first The normalized baseline value of each feature, For the first The sensitivity coefficient of a feature indicates the importance of that feature in the overall security assessment. For the first The amplification factor for each characteristic is used to control the intensity of the nonlinear response to the characteristic change. This represents the total number of features in the context vector.
[0043] Specifically, based on the session trust decay parameter set, the decay constant value (e.g., 0.001) and the effective timestamp at the time of session establishment are first extracted. The current system time is obtained, and the time difference between the two is calculated. This difference is then converted into a time interval in minutes (e.g., 10 minutes). According to the exponential decay model, the initial trust score of 1000 is multiplied by the product of the negative decay constant e and the time interval raised to the power of 1000 to calculate a trust score that decays naturally over time. The calculated result is then updated in the trust score cache of the current session, marked as the decayed trust score. Next, the context vector constituting the current secure session is re-collected. This process includes obtaining the current IP address from the network connection, obtaining the device ID through the client proxy, and retrieving the current latitude and longitude coordinates from the geolocation database using the IP address. Subsequently, the context vector recorded at the previous moment is retrieved from the session storage. If this is the first dynamic evaluation since the session started, the context vector at the previous moment is the initial context vector. For quantitative comparison, the features in the two vectors need to be uniformly processed. First, a fixed order of feature fields is determined, such as IP address, device ID, and geolocation. Then, each feature is numericalized and normalized. For the IP address, its dotted decimal string is converted to a 32-bit unsigned integer, and then divided by... The data is normalized to the [0,1] interval using the following method: For the device ID, its string is compared with that of the previous time. If they are equal, a value of 0 is generated; otherwise, a value of 1 is generated. This is the normalization result. For the geographic location, the Haversian formula is used to calculate the spherical distance between the current coordinates and the coordinates of the previous time. Then, this distance value is divided by a preset geographic location change baseline distance, which is obtained based on historical statistics. For example, in this embodiment, it is set to 50 kilometers (corresponding to 95% of the location change range of the normal user group). The result is then cropped to the [0,1] interval and used as the normalized value. If the calculated distance is greater than 50 kilometers, the normalized value is 1. Finally, the feature values of the current time and the previous time after numericalization and normalization are arranged according to the preset field order to form two numerical vectors, forming a context vector pair.
[0044] The formula for calculating the context instability score uses an exponential function to amplify the impact of changes, especially large and anomalous ones. This better reflects the actual scenario of security risk assessment: minor, normal environmental fluctuations should not cause drastic changes in trust values, but once the magnitude of the change exceeds a certain inflection point, the risk it represents will increase exponentially. The summation structure in the formula allows for independent weighted assessment of changes in multiple contextual features (such as IP, device, geographical location, etc.) and uses a sensitivity coefficient to evaluate the results. To reflect the varying importance of different characteristics in security assessments, the change amplification factor is used. This provides each feature with independent nonlinear response intensity adjustment capability, and normalized benchmark value The introduction of this concept unifies the original characteristic changes of different dimensions onto a comparable scale of relative change.
[0045] and The parameters represent the current security session context vector and the context vector at the previous time step, respectively. The normalized values of each feature are used. The acquisition of these two parameters depends on the context vector pair generated in the previous step. In each dynamic trust assessment loop, real-time context information is collected to form the current context vector, and the context vector saved during the previous assessment is read from the session cache as the context vector for the previous moment. Each feature in the vector needs to undergo predefined quantization and normalization processing before it can be used as the context vector. and For example, for IP address characteristics ( Its normalized value is obtained by dividing the integer IP value by the largest possible value, for geographical location ( The normalized value is obtained by dividing the actual physical distance by a reference distance. In this example, we focus on the change of the IP address and its normalized value at the previous time step. The normalized value at the current moment is 0.5015. It is 0.5018.
[0046] The parameter is the first The normalized baseline value of the first feature is used to convert the absolute value of feature change into a measure of relative change. Its value is set based on statistical analysis of historical data for that feature. The acquisition steps are as follows: collect the recorded data of context changes per minute in all legitimate user sessions within the past month. For the first feature... Given a feature, calculate the distribution of the absolute value of the difference between all two consecutive sampling points, and use the 95th percentile of this distribution as the... This is a baseline value, meaning that 95% of changes in the normal user group fall within this range. Changes outside this range are considered low-probability events. For example, for the normalized numerical characteristics of IP addresses, analysis of historical data shows that the 95th percentile of the absolute value of the difference per minute is 0.0010. Therefore, a normalized baseline value for IP address characteristics is set. It is 0.0010.
[0047] The parameter is the first The sensitivity coefficient of each feature represents the weight of that feature's change in contribution to the overall instability score. Its value is determined using the Analytic Hierarchy Process (AHP). First, a group of security experts, based on experience, compare all contextual features pairwise to determine their relative importance in identifying risk scenarios such as account theft and session hijacking, and construct a judgment matrix. For example, experts unanimously agree that "device ID change" is much more important than "IP address change," assigning it a higher comparison value. Then, by calculating the largest eigenvalue of the judgment matrix and its corresponding eigenvector, and normalizing the eigenvector, the weight of each feature is obtained. The values of these weights are dimensionless. For example, after calculation, the weights of each feature are: Device ID ( =0.6), IP address ( =0.25), geographical location ( =0.15), and the sum of these coefficients is 1.
[0048] The parameter is the first The amplification factor for each feature is used to adjust the growth rate of the exponential function, thereby controlling the nonlinear sensitivity of the score to feature changes. Its value is related to the system's risk tolerance strategy; it is a dimensionless, pure number, and a larger value should be set for high-risk features. This value allows even small changes to produce a large score increment. The steps to obtain this value are as follows: features are divided into three levels—high, medium, and low—according to their security importance, and a value is assigned to each level. Value ranges are defined, such as high risk [4.0, 6.0], medium risk [2.0, 4.0], and low risk [1.0, 2.0]. Then, a value is selected within the corresponding range based on the specific business meaning of each feature. For example, IP address changes are defined as a medium-risk feature. Considering that IP address changes have certain normal fluctuations in the public network environment, a value is selected to avoid over-sensitivity. It is version 3.0.
[0049] The parameter represents the total number of features in the context vector. This value is determined by the number of monitoring dimensions specified in the system design. In the current configuration, the system monitors three core context features: IP address, device ID, and geographic location. Therefore, The value is fixed at 3.
[0050] Calculations based on parameters: This example only calculates IP address characteristics ( The instability score component resulting from the change will be added together with all feature components later.
[0051] Known parameters: , , , , .
[0052] ; ; For example, if other features (device ID and geographic location) remain unchanged in this assessment, their instability score component is 0, then the total context instability score is... .
[0053] The results show that the context instability score of 0.3649 reflects the overall degree of change and risk weight of all monitored context features from the previous evaluation time to the current time. The higher the score, the more drastic or critical the change in the environment in which the user device is located, and the higher the potential security risk. A score of 0 indicates that the context environment is completely stable and there is no change. In this example, a score of 0.3649 indicates that a moderate IP address change was detected. This score will be used as a negative adjustment basis for user trust, and will be used to directly reduce the trust score after time decay.
[0054] The steps to obtain immediate access decision-making permissions are as follows: Based on the context instability score, the decayed trust score is read, and a trust value adjustment calculation is performed to generate immediate access decision permissions. Specifically, based on a context instability score of 0.3649, the calculated decayed trust score (e.g., 990.05) is first read from the session trust score cache. Next, the trust value adjustment calculation is performed, which converts the context instability score into a specific deduction from the trust score. This is done by multiplying the context instability score by a dynamically adjusted penalty coefficient. This penalty coefficient is set based on the user's current security group. For example, the coefficient is 200 for the "High-Privilege Administrator Group," 100 for the "Regular User Group," and 50 for the "Visitor Group." This differentiated setting reflects differentiated risk management for accounts with different permissions. In this example, the user belongs to the "Regular User Group," so the trust deduction is... The adjusted final trust score is Subsequently, this adjusted score is compared with the system's preset security and warning thresholds. These thresholds are set based on statistical learning from historical data. The security threshold is set as the 10th percentile of the trust score among all historically confirmed fraudulent sessions, for example, 700 points. Any session below this score is considered high-risk. The warning threshold is set as the 5th percentile of the trust score among all historically normal sessions, for example, 850 points. Sessions below this score but above the security threshold are considered medium-risk, and a permission object containing a 'partial access' decision field is generated. In this comparison, the score of 953.56 is higher than the warning threshold of 850 points, therefore the current session's security status is determined to be normal. Finally, based on the comparison result, a structured instant access decision permission object is generated. This object contains an "allow" access decision field, a final trust score of 953.56, and a status code to authorize the terminal device to continue performing its requested operation.
[0055] Example 2 This embodiment, based on Embodiment 1, adjusts the penalty factor in the calculation of the dispersion of time-series consensus. The interval boundaries, specific values, and validity will be further explained.
[0056] This embodiment employs a simulated authentication environment consisting of five independent timestamp issuing authorities, each deployed on different network nodes. In normal scenarios, the base processing latency of each timestamp issuing authority is set to 20 to 80 milliseconds, and the network transmission latency is set to 30 to 150 milliseconds, with an added random jitter of 15 milliseconds standard deviation. In abnormal scenarios, an additional latency of 150 to 800 milliseconds is injected into one or two timestamp issuing authorities on top of the normal latency to simulate network path hijacking, malicious delayed response, or abnormal timestamp issuing authorities.
[0057] First, 12,000 normal time-series samples and 3,600 abnormal time-series samples are generated. Each sample includes 4 or 5 timestamps verified by signatures. For each sample, the sample skewness of the timestamp distribution is calculated. The calculation formula is as follows: ; in, The sample skewness of the timestamp set. The number of timestamps, For the first A timestamp, The average of timestamps. is the sample standard deviation of the timestamp set.
[0058] absolute value of skewness for normal time series samples Statistical analysis was performed to obtain the absolute values of skewness corresponding to different percentiles, as shown in Table 1.
[0059] Table 1. Statistical results of the absolute values of skewness in normal time series samples.
[0060] As shown in Table 1, under normal network conditions, the absolute skewness of 95% of the timestamp sets does not exceed 0.48, and the absolute skewness of 99% of the timestamp sets does not exceed 0.97. Therefore, to avoid over-reliance on single samples for interval boundaries, and to facilitate system configuration and engineering implementation, the 95th percentile of 0.48 is rounded up to 0.5 as the boundary between the low-skewness and medium-skewness intervals; and the 99th percentile of 0.97 is rounded up to 1.0 as the boundary between the medium-skewness and high-skewness intervals.
[0061] Therefore, the absolute value of the skewness of the timestamp set can be divided into the following three intervals: when At that time, the timestamp distribution was determined to be a low-skewness distribution; when At that time, the timestamp distribution was determined to be a moderately skewed distribution; when At that time, the timestamp distribution was determined to be a highly skewed distribution.
[0062] After determining the skewness intervals, a parameter search method is used to determine the penalty factor corresponding to each skewness interval. Specifically, within the range of 1.0 to 3.5, multiple candidate penalty factors are generated with a step size of 0.5. Each candidate penalty factor is then substituted into the formula for calculating the dispersion of the time-series consensus: ; And 260 milliseconds was used as the time window threshold for this round of calibration. If the time exceeds 260 milliseconds, the corresponding sample will be identified as an abnormal sample.
[0063] To ensure that parameter selection balances the ability to detect abnormal samples and the ability to pass normal samples, a parameter evaluation function is defined. : ; in, The false negative rate is the rate at which abnormal samples are incorrectly identified as normal samples. This represents the false alarm rate when a normal sample is incorrectly identified as an abnormal sample. A coefficient of 5 indicates that in a high-security system, the security loss corresponding to a missed abnormal session is set to 5 times the loss from a false positive for a normal session.
[0064] In this embodiment, a false alarm rate of no more than 5% is set as a parameter selection constraint. An evaluation function is selected from candidate penalty factors that satisfy the false alarm rate constraint. The smallest candidate value is used as the penalty factor for the corresponding skewness interval. The parameter search results for each skewness interval are shown in Table 2.
[0065] Table 2. Search results for penalty factors under different skewness intervals
[0066] As shown in Table 2, in the low skewness range, a penalty factor of 1.5 can achieve a low evaluation function value while keeping the false alarm rate below 5%. In the medium skewness range, a penalty factor of 2.0 yields the lowest evaluation function value that satisfies the constraints. In the high skewness range, a penalty factor of 3.0 can reduce the false negative rate to 4.1% while keeping the false alarm rate below 5%. Therefore, in this embodiment, the penalty factor is determined as follows: ; The values of the aforementioned penalty factors are not directly specified based on the subjective judgment of security personnel. Instead, the skewness interval is determined based on the statistical distribution of normal time-series samples, and the specific values are determined based on the false alarm rate, false negative rate, and evaluation function of normal and abnormal samples.
[0067] In another implementation, when the system uses a fixed penalty factor instead of a piecewise penalty factor, a uniform parameter search is performed on all calibration samples. At a high security level, the same procedure applies. The evaluation results for each candidate penalty factor are calculated, as shown in Table 3.
[0068] Table 3 Search results for parameters of fixed penalty factor
[0069] As can be seen from Table 3, when the fixed penalty factor is 2.0, the evaluation function... The minimum value of 46.9 was achieved. While further increasing the penalty factor can slightly reduce the false negative rate, it significantly increases the false positive rate for normal samples. Therefore, in a high-security implementation using a fixed penalty factor, [the following is omitted as the text is incomplete and requires further context]. Set to 2.0.
[0070] For the verified timestamp set in Example 1: ; The calculated sample skewness of this timestamp set is approximately -0.1158, with an absolute skewness value of 0.1158, falling within the low skewness range. If a segmented penalty method is used, the corresponding base penalty factor is 1.5; if the system is at a high security level and a fixed penalty method is used, a fixed penalty factor of 2.0 is selected based on the full sample search results in Table 3. Therefore, in Example 1, the selected... It is determined based on the evaluation result that the cost of missed detection is higher than the cost of false alarm under high security level, rather than being arbitrarily preset.
[0071] To verify the technical effectiveness of the penalty item, 4000 normal verification samples and 2000 abnormal verification samples were generated. The normal verification samples were not involved in the parameter determination process described above; the abnormal verification samples were generated by randomly delaying the return time of one or two timestamp issuing agencies. Tests were conducted using three methods: no skewness penalty item, a fixed penalty factor of 2.0, and a segmented penalty factor. The results are shown in Table 4.
[0072] Table 4. Results of Temporal Anomaly Identification under Different Penalty Methods
[0073] As shown in Table 4, without a skewness penalty, the average dispersion of abnormal samples is only 238.4 milliseconds, which is lower than the 260-millisecond time window threshold. Some abnormal samples with obvious unilateral delay characteristics cannot be identified, resulting in an abnormal sample detection rate of only 41.8%. After applying a fixed penalty factor of 2.0, the abnormal sample detection rate increases to 91.4%. With a segmented penalty factor, the abnormal sample detection rate further increases to 95.9%, while the false alarm rate for normal samples remains below 5%.
[0074] Therefore, by determining the interval boundaries based on the normal sample skewness distribution and determining the penalty factor value based on the false alarm rate and false negative rate, the subjectivity in the penalty factor selection process can be reduced. Compared to the method of only calculating the timestamp range, this embodiment can effectively identify abnormal situations where the overall timestamp range has not increased significantly, but one or more timestamps have shifted to one side, thereby improving the ability to identify malicious delayed responses and abnormal timestamp issuing agencies.
[0075] Example 3 This embodiment, based on Embodiment 1, focuses on the sensitivity coefficient in the context instability scoring. and change amplification factor The determination process will be further explained, and the technical effectiveness of the context instability scoring will be verified through normal context drift scenarios and malicious context jump scenarios.
[0076] In this embodiment, the context vector includes IP address features, device ID features, and geographic location, with corresponding feature numbers as follows: , and .
[0077] For sensitivity coefficient The analytic hierarchy process (AHP) was used for determination. First, five security personnel with experience in endpoint security authentication performed pairwise comparisons of the three characteristics: device ID, IP address, and geographical location. The importance of these characteristic changes in identifying session hijacking, credential theft, and unauthorized remote access was used as the criterion for judgment.
[0078] The judgment values given by the five security personnel were aggregated using a geometric mean, resulting in the aggregated judgment results shown in Table 5.
[0079] Table 5. Aggregation judgment results of pairwise comparisons of contextual features
[0080] As can be seen from Table 5, the device ID directly corresponds to the terminal hardware and operating system environment. When it changes, it usually means that the access terminal itself has been replaced. Therefore, its security importance is the highest. The IP address may change normally due to dynamic address allocation, mobile network switching, etc., and its security importance is lower than that of the device ID. The geographical location is affected by IP positioning errors, base station switching and proxy networks, and its certainty when it changes alone is relatively low.
[0081] Construct a judgment matrix in the order of device ID, IP address, and geographical location. : ; The geometric mean of each row in the judgment matrix is calculated using the geometric mean method. The geometric mean of the row corresponding to the device ID is shown below. for: ; The geometric mean of rows corresponding to IP addresses for: ; Geometric mean of rows corresponding to geographical location for: ; Normalizing the geometric mean of the above rows, we get: ; ; ; Therefore, according to the feature numbering in Example 1, we get: ; Further consistency checks are performed on the judgment matrix. The largest eigenvalue of the judgment matrix is calculated. Consistency indicators for: ; When determining the order of a matrix At that time, the average random consistency index Therefore, the consistency ratio for: ; because This indicates that the judgment matrix meets the consistency requirement, and the obtained sensitivity coefficient can be used for context instability score calculation.
[0082] For the change amplification factor In this embodiment, instead of directly specifying fixed values based on high, medium, and low security levels, a combination of normal sample statistics, abnormal sample injection, and candidate parameter search is used to determine the values.
[0083] First, 8000 normal session context change samples were collected. For IP address and geographic location, the normalized change amplitude between two adjacent samples was calculated, and the 95th percentile of the normal sample change amplitude was determined as the normalized baseline value. For the device ID feature, since the device ID uses a binary method where the same ID is 0 and different IDs are 1, its normalization baseline value is set to 1. The resulting normalization baseline values are shown in Table 6.
[0084] Table 6. Normalized baseline values for each context feature
[0085] As can be seen from Table 6, the normal variation range of IP address normalization values is small, so 0.0010 is used as the baseline value for IP address variation; device ID is represented in binary form, so 1 is used as the baseline value for variation; the variation range of the 95th percentile of the geographic location normalization value is 0.2000, which corresponds to a normal location variation of about 10 kilometers when the normalization distance is 50 kilometers.
[0086] Then, 3000 sets of abnormal session samples were constructed. Among them, 1000 sets of samples were injected with abnormal IP address jumps, 1000 sets of samples were injected with device ID replacements, and the other 1000 sets of samples were injected with cross-regional geographical location jumps.
[0087] For IP address characteristics, the search change amplification factor is set to 0.5 within the range of 2.0 to 3.5; for device ID characteristics, the search change amplification factor is set to 1.0 within the range of 4.0 to 6.0; and for geographic location characteristics, the search change amplification factor is set to 0.5 within the range of 1.0 to 2.0.
[0088] During the parameter search process, the optimization direction was to maximize the detection rate of abnormal samples, while requiring the false alarm rate of normal samples to not exceed 5%. The test results of each candidate change amplification factor are shown in Table 7.
[0089] Table 7 Search results for parameters of amplification factors for each feature change
[0090] As can be seen from Table 7, for IP address characteristics, when At that time, the abnormal sample detection rate reached 89.6%, and the false alarm rate for normal samples was 4.8%, meeting the constraint that the false alarm rate should not exceed 5%; for the device ID feature, when At that time, the abnormal sample detection rate reached 97.6%. Increasing the value to 6.0 only improved the detection rate by 0.5 percentage points, but would cause the index to increase rapidly; therefore, 5.0 was chosen. Regarding geographical location, when... When the false alarm rate was 4.4% for normal samples, while when The false alarm rate increased to 6.1%, so 1.5 was selected.
[0091] Therefore, the amplification factor of this embodiment is: ; Among them, IP address corresponds to medium nonlinear amplification intensity, device ID corresponds to high nonlinear amplification intensity, and geographical location corresponds to low nonlinear amplification intensity. The above-mentioned amplification factors are determined by the false alarm rate of normal samples and the detection rate of abnormal samples, rather than being subjectively specified solely based on high, medium, and low security levels.
[0092] The instability scores are calculated below for different contextual changes. For ease of representation, let: ; The context instability score can then be expressed as: ; Set the relative change for a stable scenario as , , The calculation yields: ; Set the relative change in the normal drift scenario as , , The calculation yields: ; Set the relative change amount of the suspicious jump scenario as , , The calculation yields: ; Set the relative change in the malicious session hijacking scenario as: , , This means that the IP address changes beyond the normal baseline, the device ID is replaced, and the geographical location changes across regions. The calculation is as follows: ; The calculation results for each scenario are shown in Table 8.
[0093] Table 8 Instability scores for different contextual change scenarios
[0094] As shown in Table 8, when the IP address and geographic location only drift within the normal range, the context instability score is less than 0.5, which does not cause a sharp drop in the trust score. When the IP address and geographic location are both close to or exceed the normal change baseline, the score increases to 2.9344. When the device ID changes, accompanied by abnormal jumps in IP address and geographic location, the score increases rapidly to 98.6206. Therefore, the exponential amplification method can significantly amplify scenarios where multiple key features change abnormally together, while maintaining the tolerance for normal fluctuations.
[0095] To further verify the effectiveness of this solution, 2000 normal migration sessions and 2000 malicious hopping sessions were generated. Normal migration sessions included dynamic IP address reassignment, location changes within the same city, and mobile network switching, but the device ID remained unchanged; malicious hopping sessions included device ID replacement, cross-provincial or cross-border geographical location changes, and sudden changes in IP address network segments.
[0096] In this simulation experiment, a context instability score of at least 5 was defined as the criterion for determining abnormal contexts. The linear weighted scoring method, the unified index scoring method without distinguishing feature amplification factors, and the scoring method described in this embodiment were tested respectively. Specifically, the linear weighted scoring method scores based on the weighted sum of the changes in each feature; the unified index scoring method sets the amplification factor for all features to 1; and the method described in this embodiment... , , , , , The test results are shown in Table 9.
[0097] Table 9. Anomaly detection performance of different context scoring methods
[0098] As shown in Table 9, the linear weighted scoring method lacks non-linear amplification capability for scenarios where multiple features change significantly simultaneously, resulting in a malicious jump detection rate of 84.7%. After uniformly setting the same change amplification factor for all features, the malicious jump detection rate increased to 89.5%, but this did not fully reflect the differences in security importance between device ID, IP address, and geographical location. This embodiment uses the AHP method to determine the sensitivity coefficient and determines the change amplification factor through parameter search of normal and abnormal samples, thereby increasing the malicious jump detection rate to 97.6% while reducing the false alarm rate of normal drift to 4.3%.
[0099] Furthermore, the context instability score of this embodiment is used for trust score adjustment. The initial trust score after time decay is set to 990 points, the penalty coefficient for the ordinary user group is 100, and the adjusted trust score is limited to the range of 0 to 1000. The trust assessment results for normal drift sessions and malicious jump sessions are shown in Table 10.
[0100] Table 10 Trust assessment results for normal drift scenarios and malicious jump scenarios
[0101] As shown in Table 10, in the normal drift scenario, the average context instability score is 0.61, and the average adjusted trust score is still 929.00, meaning that 95.7% of normal sessions can continue to access the site. In the malicious jump scenario, the average context instability score increases to 52.84, and the average adjusted trust score decreases to 71.35, meaning that 97.6% of malicious sessions are denied access or required to perform two-factor authentication.
[0102] Therefore, this embodiment quantifies the importance of different contextual features using the analytic hierarchy process (AHP) and determines the change amplification factor through parameter search based on normal and abnormal samples, thus reducing subjectivity in the selection of sensitivity coefficients and change amplification factors. Compared to linear scoring methods or unified parameter scoring methods, this embodiment reduces false alarms caused by normal network drift and enhances the ability to identify malicious behaviors such as device replacement, abnormal IP address jumps, and cross-regional location jumps, thereby improving the accuracy and security of terminal device secure access authentication.
Claims
1. A method for secure access authentication of terminal devices, characterized in that, include: S1. During the login phase, time-series consensus verification is performed based on the signature timestamps returned by multiple independent timestamp issuing authorities. After the verification is successful and the access credential verification is successful, the trust score of the terminal device is initialized to the preset full score. S2. During the session, obtain the context vector of the terminal device at the current time and the previous time. The context vector includes the IP address, device ID and geographical location. S3. Determine the normalized rate of change of each feature in the current context vector, and then perform exponential nonlinear amplification and weighted summation on the normalized rate of change of each feature in the current context vector to generate the current context instability score. S4. Adjust the trust score of the previous moment by deducting from the current moment's context instability score to obtain the current moment's trust score. S5. Determine the access permissions of the terminal device at the current moment based on the trust score at the current moment, and return to S2 for the next round of monitoring.
2. The method according to claim 1, characterized in that, The method for determining the normalized rate of change of each feature in the context vector at the current time includes: For an IP address, convert the dotted decimal string of the IP address to a 32-bit unsigned integer, and then divide it by 2³²−1 to obtain the normalized value of the IP address; calculate the absolute value of the difference between the normalized value of the IP address at the current time and the previous time, and divide it by the normalization reference value of the IP address to obtain the normalization rate of change of the IP address. For the device ID, compare the device ID string at the current time with that at the previous time. If they match, the device ID change value is 0; otherwise, it is 1. The device ID change value is used as the normalized change rate of the device ID. For geographic locations, calculate the spherical distance between the current and previous geographic locations, divide it by the preset geographic location baseline distance, and crop the division result to the [0,1] interval to obtain the geographic location normalized value; calculate the absolute value of the difference between the current and previous geographic location normalized values, divide it by the geographic location normalized baseline value, and obtain the geographic location normalized rate of change.
3. The method according to claim 2, characterized in that, The normalized baseline value of the IP address or the normalized baseline value of the geographical location is determined in the following way: Obtain the statistical distribution of the normalized numerical change amplitude of IP address or geographical location between two consecutive sampling points during historical usage, and use the preset percentile value of the statistical distribution as the normalized reference value of the corresponding feature.
4. The method according to claim 1, characterized in that, The method for generating the context instability score at the current moment includes: By using the amplification factors corresponding to each preset feature, the normalized rate of change of each feature in the current context vector is exponentially and non-linearly amplified to obtain the initial risk contribution value of each feature in the current context vector. The initial risk contribution values of each feature in the current context vector are weighted and summed using the preset sensitivity coefficients corresponding to each feature to obtain the context instability score at the current moment.
5. The method according to claim 1, characterized in that, The method for determining the access permissions of the terminal device at the current moment includes: When the trust score at the current moment is higher than the first threshold, normal access is granted; When the trust score at the current moment is lower than or equal to the first threshold and higher than the second threshold, restricted access is granted; Access is denied when the current trust score is lower than or equal to the second threshold.
6. The method according to claim 1, characterized in that, Step S1 includes: Send challenge data containing user identifiers to multiple independent timestamp issuing authorities; Receive signature timestamps returned by various timestamp issuing authorities; Verify the validity of each signature timestamp, remove the signature timestamps that failed to be verified, and obtain the set of verified timestamps; Calculate the temporal consensus dispersion of the verified timestamp set, wherein the temporal consensus dispersion is the sum of the timestamp distribution width component and the distribution symmetry component; When the dispersion of the time-series consensus is less than or equal to a preset threshold, the time-series consensus verification is deemed successful.
7. The method according to claim 6, characterized in that, The timestamp distribution width component is the difference between the maximum and minimum timestamps in the verified timestamp set; the distribution symmetry component is the product of the deviation between the mean of the verified timestamp set and the average of the maximum and minimum timestamps, multiplied by a penalty factor.
8. The method according to claim 6, characterized in that, The method for determining the preset threshold includes: Obtain the round-trip delay statistical distribution of each timestamp issuing agency within a preset historical time period, calculate the preset percentile value of the round-trip delay statistical distribution, and obtain the basic window value; Obtain the time-series consensus dispersion value recorded during multiple historical authentication processes, calculate the standard deviation of the obtained time-series consensus dispersion value, and use it as a dynamic adjustment factor; The sum of the base window value and the dynamic adjustment factor is used as the preset threshold.
9. The method according to claim 1, characterized in that, In step S4, the trust score of the previous moment is also subjected to exponential decay processing according to a preset time period.
10. A secure access authentication system for terminal devices, characterized in that, include: The multi-source challenge distribution module is used to send challenge data containing user identifiers to multiple independent timestamp issuing authorities during the login phase; The access consensus verification module is used to receive the signature timestamps returned by each timestamp issuing authority, verify the signature validity of each signature timestamp, and perform time-series consensus verification and access credential verification. The dynamic trust assessment module is used to initialize the trust score to a preset full score after confirming the validity of the user's access credentials. During the session, it obtains the context vector of the terminal device at the current time and the previous time, determines the normalized rate of change of each feature in the context vector at the current time, and then performs exponential nonlinear amplification and weighted summation on the normalized rate of change of each feature in the context vector at the current time to generate the context instability score at the current time. Based on the context instability score at the current time, it deducts and adjusts the trust score at the previous time to obtain the trust score at the current time. The session credential update module is used to determine the access permissions of the terminal device at the current time based on the trust score at the current time.
