Page access method, system and related device

By actively judging the remaining validity period of the token and refreshing or storing the request queue in time, the problem of long waiting time caused by token expiration is solved, seamless token updates are achieved, and user experience and system fluency are improved.

CN120342695APending Publication Date: 2025-07-18JIALIAN PAYMENTS CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510499785.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-21
Publication Date
2025-07-18

AI Technical Summary

Technical Problem

In the prior art, the update is performed only after the token expires, resulting in the user waiting time being too long, affecting the user experience and system fluency.

Method used

When receiving a user page access request, it is actively judged whether the remaining valid time of the token is less than the preset expiration threshold. If it is less than, the refresh status of the token is obtained, and the page access request is sent using a new token when the refresh status is being refreshed, or a refresh request is sent when the refresh status is not refreshed, and the unrefreshed request queue is stored and processed in sequence.

Benefits of technology

It avoids long waits after the token is completely expired, ensures seamless connection of token updates, and improves user operation experience and system fluency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120342695A_ABST
    Figure CN120342695A_ABST
Patent Text Reader

Abstract

The invention discloses a page access method, a page access system and a related device, which are used for improving the access experience of a user. The method comprises the steps that when a target page access request initiated by a user at a client is received, whether the remaining valid time of a locally-stored Token of the user is smaller than a preset on-time threshold value or not is judged, and the Token is the Token bound with the user and sent to the client last time by a server; if the remaining effective time of the Token is smaller than a preset on-time threshold value, the refresh state of the Token is obtained, and the refresh state comprises the refresh state and the non-refresh state; and if the refreshing state is refreshing, after a new Token is obtained, the target page access request is sent to the server through the new Token, and the new Token is a new Token which is sent by the server to the client and is bound with the user.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of network security, and in particular, to a page access method, system, and related devices. Background Art

[0002] With the rapid development of information technology and the popularization of mobile applications, user authentication and authorization mechanisms have become an important part of page access. As a lightweight and stateless credential, Token is widely used in authentication and session management. For example, Token is used to implement stateless authentication and cross-domain single sign-on. When Token is the mainstream of authentication, the design and implementation of the Token update mechanism have become the key to improving user experience and system security.

[0003] In the prior art, Token update is usually achieved by relying on a verification mechanism. The terminal carries the Token in each request, and the server verifies the validity of the Token carried in the request. When the server detects that the Token has expired, it will return a specific error status code. After receiving the error status code, the terminal applies to the server for a new Token. After the server generates a new Token and returns it to the terminal, the terminal uses the new Token to initiate the original request again.

[0004] However, updating the Token after it has expired will cause the user to wait for a long time for the update process to complete after the Token expires, resulting in too long an operation interruption time, which seriously affects the user experience and system fluency. Summary of the Invention

[0005] To solve the above technical problems, this application provides a page access method, system, and related devices.

[0006] The technical solutions provided in this application are described below:

[0007] In a first aspect of this application, a page access method is provided. The method includes:

[0008] When receiving a target page access request initiated by a user on a client, determine whether the remaining valid time of the Token of the user stored locally is less than a preset approaching expiration threshold, where the Token is the Token bound to the user sent by the server to the client most recently;

[0009] If the remaining valid time of the Token is less than the preset approaching expiration threshold, obtain the refresh status of the Token, where the refresh status includes being refreshed and not being refreshed;

[0010] If the refresh status is "refreshing", after obtaining a new Token, send the target page access request to the server through the new Token, where the new Token is a new Token bound to the user sent by the server to the client.

[0011] Optionally, after obtaining the refresh status of the Token, the method further includes:

[0012] If the refresh status is "not refreshing", send a Token refresh request to the server and update the refresh status to "refreshing";

[0013] Receive the new Token returned by the server to the client according to the refresh Token request, and update the refresh status to "not refreshing".

[0014] Optionally, after the refresh status is "refreshing" and before obtaining a new Token, the method further includes:

[0015] Store the target page access request in a local request queue, where the request queue is used to temporarily store all page access requests of the user when a new Token has not been obtained.

[0016] Optionally, the step of sending the target page access request to the server through the new Token includes:

[0017] Retrieve all the page access requests from the request queue;

[0018] Send the corresponding page access request to the server through the new Token in the queue order of each page access request in all the page access requests in the request queue.

[0019] Optionally, after obtaining the new Token and before sending the target page access request to the server through the new Token, the method further includes:

[0020] Judge whether the refresh status is updated to "not refreshing";

[0021] If so, execute the step of sending the target page access request to the server through the new Token.

[0022] Optionally, after judging whether the remaining valid time of the Token stored locally for the user is less than a preset expiration threshold, the method further includes:

[0023] If the remaining valid time of the Token is greater than or equal to the preset approaching expiration threshold, send the target page access request to the server and obtain the status code returned by the server to the client after receiving the target page access request.

[0024] Optionally, the method further includes: when the status code indicates unauthorized request, execute the step of obtaining the refresh status of the Token.

[0025] A second aspect of the present application provides a page access system, the system includes:

[0026] A first determination unit, configured to, when receiving a target page access request initiated by a user on a client, determine whether the remaining valid time of the Token of the user stored locally is less than a preset approaching expiration threshold, where the Token is the Token bound to the user sent by the server to the client most recently;

[0027] A first acquisition unit, configured to, if the remaining valid time of the Token is less than the preset approaching expiration threshold, acquire the refresh status of the Token, where the refresh status includes being in the process of refreshing and not being in the process of refreshing;

[0028] A sending unit, configured to, if the refresh status is being in the process of refreshing, after obtaining a new Token, send the target page access request to the server through the new Token, where the new Token is the new Token bound to the user sent by the server to the client.

[0029] Optionally, it further includes an update unit, specifically configured to:

[0030] If the refresh status is not being in the process of refreshing, send a Token refresh request to the server and update the refresh status to being in the process of refreshing;

[0031] Receive the new Token returned by the server to the client according to the Token refresh request and update the refresh status to not being in the process of refreshing.

[0032] Optionally, it further includes a storage unit, specifically configured to:

[0033] Store the target page access request in a local request queue, where the request queue is used to temporarily store all page access requests of the user when a new Token has not been obtained.

[0034] Optionally, the storage unit is specifically configured to:

[0035] Retrieve all the page access requests from the request queue;

[0036] According to the queue order of each page access request in all the page access requests in the request queue, sequentially send the corresponding page access request to the server through the new Token.

[0037] Optionally, it further includes a second determination unit, specifically used for:

[0038] Determine whether the refresh status is updated to not being in the process of refreshing;

[0039] If so, execute the step of sending the target page access request to the server through the new Token.

[0040] Optionally, it further includes a second acquisition unit, specifically used for:

[0041] If the remaining valid time of the Token is greater than or equal to the preset approaching expiration threshold, send the target page access request to the server, and acquire the status code returned by the server to the client after receiving the target page access request.

[0042] Optionally, it further includes an execution unit, specifically used for:

[0043] When the status code indicates that the request is unauthorized, execute the step of acquiring the refresh status of the Token.

[0044] The third aspect of the present application provides a page access device, and the device includes:

[0045] A processor, a memory, an input / output unit, and a bus;

[0046] The processor is connected to the memory, the input / output unit, and the bus;

[0047] The memory stores a program, and the processor calls the program to execute any one of the methods.

[0048] The fourth aspect of the present application provides a computer-readable storage medium, and a program is stored on the computer-readable storage medium, and when the program is executed on a computer, it executes the method in the first aspect and any optional method in the first aspect.

[0049] From the above technical solutions, it can be seen that the present application has the following advantages:

[0050] This application actively determines the remaining validity period of the Token, solving the problem of excessive user waiting time caused by updating the Token only after it expires. When receiving a page access request initiated by the user on the client side, it actively determines whether the remaining valid time of the Token is less than a preset approaching expiration threshold, avoiding the situation where the user is forced to wait for a long time for the update process to complete after the Token has completely expired. If the remaining valid time of the Token is less than the approaching expiration threshold, it immediately obtains the refresh status of the Token. Since the refresh status indicates whether a request to update the Token has been sent to the server, when the refresh status is "updating", after waiting for the new Token to be obtained, it uses the new Token to send a page access request to the server. During the entire page access process, by actively obtaining a new Token when the remaining validity period of the Token is lower than the approaching expiration threshold, it avoids operation interruptions caused by excessive user waiting time, ensuring seamless Token update, thereby significantly improving the user operation experience and system fluency. BRIEF DESCRIPTION OF THE DRAWINGS

[0051] To more clearly illustrate the technical solutions in this application, the following will briefly introduce the drawings required for the description of the embodiments. Obviously, the drawings in the following description are only some embodiments of this application. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.

[0052] Figure 1 Schematic flowchart of an embodiment of the page access method provided by this application;

[0053] Figure 2 Schematic flowchart of an embodiment of the process of sending a refresh Token request in page access provided by this application;

[0054] Figure 3 Schematic flowchart of another embodiment of the page access method provided by this application;

[0055] Figure 4 Schematic structural diagram of an embodiment of the page access system provided by this application;

[0056] Figure 5 Schematic structural diagram of an embodiment of the page access device provided by this application. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0057] This application provides a page access method that can improve the user access experience. It should be noted that the page access method of this application is applied to the terminal.

[0058] It should be noted that a page access method, device, and related devices provided in this application can be applied to a terminal, a system, or a server. For example, the terminal can be a smart phone, a computer, a tablet computer, a smart TV, a smart watch, a portable computer terminal, or a fixed terminal such as a desktop computer. For the convenience of description, this application takes the terminal as the execution subject for illustration.

[0059] A Token (Security Token) is a security token used for authentication and authorization. It is usually generated and issued by the server to the client for verifying the user's identity and permissions in stateless network communication. In practical applications, the Token is signed using encryption technology and contains user identification, validity period, and other metadata. The client carries the Token in subsequent requests for the server to verify, thus avoiding frequent repeated authentication.

[0060] Please refer to Figure 1 , this application first provides an embodiment of a page access method, and this embodiment includes:

[0061] S101. When receiving a target page access request initiated by a user on the client, determine whether the remaining valid time of the user's Token stored locally is less than a preset expiration threshold, where the Token is the Token bound to the user sent by the server to the client most recently;

[0062] In this embodiment, when receiving a page access request initiated by a user on the client, first read the current user's Token from local storage, where the current user's Token is the Token bound to the user sent by the server to the client most recently. After reading the current user's Token, parse and extract the remaining valid time of the current user's Token. Finally, determine whether the remaining valid time is less than the preset expiration threshold, and the preset expiration threshold can be dynamically adjusted according to business requirements. For example, in a low-frequency and high-security scenario, set the preset expiration threshold to 10 minutes, or in a high-frequency interaction scenario, set the preset expiration threshold to 2 minutes.

[0063] In practical applications, assume that the remaining valid time of the current user's Token is 5 minutes and the preset expiration threshold is 10 minutes, then it is determined that the remaining valid time of the current user's Token is less than the preset expiration threshold; assume that the remaining valid time of the current user's Token is 5 minutes and the preset expiration threshold is 2 minutes, then it is determined that the remaining valid time of the current user's Token is greater than the preset expiration threshold.

[0064] When it is determined that the remaining valid time of the user's Token is less than the preset approaching expiration threshold, step S102 is executed; when it is determined that the remaining valid time of the user's Token is greater than or equal to the preset approaching expiration threshold, the target page access request is directly sent to the server.

[0065] S102. If the remaining valid time of the Token is less than the preset approaching expiration threshold, obtain the refresh status of the Token. The refresh status includes being refreshed and not being refreshed.

[0066] When it is determined that the remaining valid time of the user's Token is less than the preset approaching expiration threshold, the refresh status of the Token will be obtained, such as the isRefreshing variable. The refresh status includes being refreshed and not being refreshed, which is used to identify whether there is currently another page access request performing the Token refresh operation.

[0067] When the refresh status is being refreshed, step 103 is executed; when the refresh status is not being refreshed, it indicates that there is currently no other page access request triggering the refresh process, and a request to refresh the Token needs to be sent to the server.

[0068] S103. If the refresh status is being refreshed, after obtaining the new Token, send the target page access request to the server through the new Token. The new Token is the new Token bound to the user sent by the server to the client.

[0069] When it is detected that the refresh status of the obtained Token is being refreshed, it indicates that another page access request has triggered the refresh process, and the current page access request does not need to repeat the operation. After the refresh is completed and the new Token is obtained, the request headers of all page access requests will be automatically updated to the new Token and resent to the server. Specifically, the new Token is the new Token bound to the user sent by the server to the client. The user's new Token will be stored locally on the client to replace the original Token of this user stored locally on the client.

[0070] It should be noted that if the Token refresh fails, unified error handling will be triggered, such as redirecting to the login page or prompting the user to re-authenticate.

[0071] This embodiment actively judges the remaining validity period of the Token, solving the problem of excessive waiting time for users caused by updating the Token after it has expired. When receiving a page access request initiated by the user on the client side, it actively judges whether the remaining valid time of the Token is less than a preset approaching expiration threshold, avoiding the situation where users are forced to wait for a long time for the update process to complete after the Token has completely expired. If the remaining valid time of the Token is less than the approaching expiration threshold, the refresh status of the Token is immediately obtained. Since the refresh status indicates whether a request to update the Token has been sent to the server, when the refresh status is "updating", after waiting for the new Token to be obtained, the new Token is used to send a page access request to the server. During the entire page access process, since a new Token is actively obtained when the remaining validity period of the Token is lower than the approaching expiration threshold, it avoids operation interruptions caused by excessive user waiting time, ensuring seamless Token update, thus significantly improving the user operation experience and system fluency.

[0072] After obtaining the refresh status of the Token in step S102 above, if the refresh status is "not refreshing" and a refresh Token request needs to be sent, please refer to Figure 2 , Figure 2 This is an embodiment of sending a refresh Token request in the page access method provided by this application. This embodiment includes:

[0073] S201. If the refresh status is "not refreshing", send a refresh Token request to the server and update the refresh status to "refreshing";

[0074] In this embodiment, when it is determined that the refresh status of the Token is "not refreshing", a refresh request for the Token is immediately sent to the server, which can ensure that only one Token refresh request is initiated in a concurrent scenario, avoiding resource waste caused by repeated refreshing of multiple page access requests.

[0075] When sending the refresh request, the refresh status is updated from "not refreshing" to "refreshing". If the network is abnormal and the refresh fails, the refresh status is rolled back to "not refreshing".

[0076] S202. Receive the new Token returned by the server to the client according to the refresh Token request and update the refresh status to "not refreshing".

[0077] In this embodiment, when the client receives the new Token returned by the server according to the refresh Token request, the client will verify the validity of the new Token, such as checking the signature and timestamp. Subsequently, the verified new Token is stored locally on the client, and the refresh status is updated from "refreshing" to "not refreshing".

[0078] When it is detected that the Token is about to expire in this embodiment, the refresh status will be checked first. Only when it has not been refreshed will a request be initiated and the status be updated, effectively preventing the problem of multiple requests triggering refreshes simultaneously. Then, when a new Token is obtained, the refresh status will be immediately updated, enabling subsequent page access requests to use the new Token in a timely manner. In this way, not only is resource waste avoided, but also the timeliness of Token update is ensured.

[0079] Please refer to Figure 3 , another embodiment of a page access method provided by this application, which includes:

[0080] S301. When a target page access request initiated by a user on the client is received, determine whether the remaining valid time of the Token of the user stored locally is less than a preset expiration threshold, where the Token is the Token bound to the user sent by the server to the client for the last time;

[0081] In this embodiment, step S301 is similar to step S101 of the foregoing embodiment and will not be elaborated here.

[0082] S302. If the remaining valid time of the Token is greater than or equal to the preset expiration threshold, send the target page access request to the server and obtain the status code returned by the server to the client after receiving the target page access request;

[0083] In this embodiment, when it is determined that the remaining valid time of the current Token is greater than or equal to the preset expiration threshold, the target page access request will be directly sent to the server using the current Token. Specifically, when it is determined that the remaining valid time is greater than or equal to the preset expiration threshold, the request header of the target page access request is retained and the target page access request is sent to the server, where the current Token is carried in the request header of the target page access request.

[0084] After receiving the target page access request, the server will verify the Token in the request header of the target page access request. After the verification is completed, the client will receive the status code returned by the server.

[0085] Specifically, the returned status code includes a 200 status code, a 401 status code, or a 403 status code, where the 200 status code indicates that the request is successful, the 401 status code indicates that the request is unauthorized, and the 403 status code indicates that the request lacks permissions.

[0086] In some specific embodiments, when the status code indicates that the request is unauthorized, the step of obtaining the refresh status of the Token is performed, which is specifically described below:

[0087] Taking the example where the status code returned by the server is 401 (Unauthorized), when it is determined that the status code is 401, immediately obtain the refresh status of the current Token. If the refresh status of the current Token is being refreshed, then execute step S304; if the refresh status of the current Token is not being refreshed, then execute step S201 of the above embodiment.

[0088] S303. If the remaining valid time of the Token is less than the preset approaching expiration threshold, then obtain the refresh status of the Token. The refresh status includes being refreshed and not being refreshed.

[0089] In this embodiment, step S303 is similar to step S102 of the foregoing embodiment, and will not be elaborated here.

[0090] S304. If the refresh status is being refreshed, then store the target page access request in the local request queue. The request queue is used to temporarily store all page access requests of the user when a new Token has not been obtained.

[0091] In this embodiment, when it is determined that the refresh status is being refreshed, deposit the current target page access request into the local request queue. The request queue is used to temporarily store all page access requests of the user when a new Token has not been obtained. Specifically, the request queue can be managed according to the First In First Out (FIFO) principle.

[0092] The First In First Out (FIFO) principle arranges the target page access requests in the order of arrival at the request queue. When a new Token is successfully obtained, the target page access requests are processed sequentially from the head of the queue to ensure that the target page access requests that enter the request queue earliest can be preferentially sent in order when a new Token is obtained.

[0093] S305. After obtaining a new Token, determine whether the refresh status is updated to not being refreshed.

[0094] When the system obtains a new Token, it is necessary to determine whether the refresh status has been updated to not being refreshed. Specifically, when receiving the new Token, obtain the current refresh status. If the refresh status has not been updated to not being refreshed, then reset the refresh status; if the refresh status has been updated to not being refreshed, then execute step S306. In this way, the refresh status can be controlled in a timely manner to prevent multiple page access requests from concurrently triggering repeated refreshes.

[0095] It should be noted that if the refresh status is still being refreshed after resetting the refresh status, that is, the refresh status update fails, then it is necessary to perform targeted repair according to the update failure log. After the repair is completed, then execute step S306.

[0096] S306. Send a target page access request to the server via a new Token.

[0097] In this embodiment, step S306 is similar to step S103 in the foregoing embodiment, and will not be elaborated here.

[0098] In some specific embodiments, when sending a target page access request to the server, all page access requests (including the target page access request) are retrieved from the request queue, and after retrieval, according to the queue order of each page access request in the request queue among all page access requests, the corresponding page access requests are sequentially sent to the server via a new Token. The following is a specific description:

[0099] To ensure that the requests temporarily stored due to Token expiration can be resent in an orderly manner, after obtaining a new Token, the temporarily stored page access requests will be retrieved immediately from the head of the request queue in the order of first in first out, and each page access request carries the new Token.

[0100] After the retrieval is completed, the page access requests are sent to the server via the new Token while maintaining the order in the queue. During the sending process, the status of the page access requests will be monitored in real time. Those page access requests that fail to be sent are marked and an alarm is triggered, while those page access requests that are successfully sent are cleared from the request queue. In this way, not only can it be ensured that all page access requests (including the target page access request) can be accurately executed according to the original time sequence of the user's operation, but also the problem of untimely request sending caused by out-of-order page access requests can be avoided.

[0101] The following provides a detailed description of the page access system provided by this application. Please refer to Figure 4 , Figure 4 which is an embodiment of the page access system provided by this application. The system includes:

[0102] A first judgment unit 401, configured to judge whether the remaining valid time of the Token of the user stored locally is less than a preset approaching expiration threshold when receiving a target page access request initiated by the user on the client side. The Token is the Token bound to the user sent by the server to the client side for the last time;

[0103] A first acquisition unit 402, configured to acquire the refresh status of the Token if the remaining valid time of the Token is less than the preset approaching expiration threshold. The refresh status includes being in the process of refreshing and not being in the process of refreshing;

[0104] A sending unit 403, configured to send a target page access request to the server via the new Token after obtaining the new Token if the refresh status is being in the process of refreshing. The new Token is the new Token bound to the user sent by the server to the client side.

[0105] Optionally, it further includes an update unit 404, specifically used for:

[0106] If the refresh status is not in the process of refreshing, send a refresh Token request to the server and update the refresh status to being refreshed;

[0107] Receive the new Token returned by the server to the client according to the refresh Token request and update the refresh status to not in the process of refreshing.

[0108] Optionally, it further includes a storage unit 405, specifically used for:

[0109] Store the target page access request in the local request queue, and the request queue is used to temporarily store all page access requests of the user when a new Token has not been obtained.

[0110] Optionally, the storage unit 405 is specifically used for:

[0111] Retrieve all page access requests from the request queue;

[0112] Send the corresponding page access requests to the server one by one through the new Token according to the queue order of each page access request in all page access requests in the request queue.

[0113] Optionally, it further includes a second determination unit 406, specifically used for:

[0114] Determine whether the refresh status is updated to not in the process of refreshing;

[0115] If so, execute the step of sending the target page access request to the server through the new Token.

[0116] Optionally, it further includes a second acquisition unit 407, specifically used for:

[0117] If the remaining valid time of the Token is greater than or equal to the preset expiration threshold, send the target page access request to the server and obtain the status code returned by the server to the client after receiving the target page access request.

[0118] Optionally, it further includes an execution unit 408, specifically used for:

[0119] When the status code indicates that the request is unauthorized, execute the step of obtaining the refresh status of the Token.

[0120] For the specific implementation method, refer to Figures 1 to 3 the embodiments, which will not be elaborated here.

[0121] This application also provides a page access device. Please refer to Figure 5 ,Figure 5 An embodiment of the page access device provided by this application, the device includes:

[0122] A processor 501, a memory 502, an input / output unit 503, and a bus 504;

[0123] The processor 501 is connected to the memory 502, the input / output unit 503, and the bus 504;

[0124] The memory 502 stores a program, and the processor 501 calls the program to execute any of the above methods.

[0125] This application also relates to a computer-readable storage medium, on which a program is stored. The program, when running on a computer, causes the computer to execute any of the above methods.

[0126] Those skilled in the art can clearly understand that for the convenience and conciseness of description, the specific working processes of the above-described systems, devices, and units can refer to the corresponding processes in the foregoing method embodiments, and will not be elaborated herein.

[0127] In several embodiments provided by this application, it should be understood that the disclosed systems, devices, and methods can be implemented in other ways. For example, the device embodiments described above are merely illustrative. For example, the division of the units is only a logical function division, and there may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed couplings or direct couplings or communication connections to each other can be through some interfaces, and the indirect couplings or communication connections of the devices or units can be in electrical, mechanical, or other forms.

[0128] The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they can be located in one place, or distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

[0129] In addition, in each embodiment of this application, the functional units can be integrated in one processing unit, or each unit can exist physically alone, or two or more units can be integrated in one unit. The above integrated units can be implemented in the form of hardware or in the form of software functional units.

[0130] When the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of this technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of this application. The foregoing storage medium includes: various media such as USB flash drives, mobile hard disks, read-only memories (ROM, read-only memory), random access memories (RAM, random access memory), magnetic disks, or optical discs that can store program codes.

Claims

1. A page access method, characterized in that, The method includes: When receiving a target page access request initiated by a user on the client side, determining whether the remaining valid time of the Token of the user stored locally is less than a preset approaching expiration threshold, where the Token is the Token bound to the user sent by the server to the client side for the last time; If the remaining valid time of the Token is less than the preset approaching expiration threshold, obtaining the refresh status of the Token, where the refresh status includes being in the process of refreshing and not being in the process of refreshing; If the refresh status is being in the process of refreshing, after obtaining a new Token, sending the target page access request to the server through the new Token, where the new Token is the new Token bound to the user sent by the server to the client side; 2. The method according to claim 1, wherein After obtaining the refresh status of the Token, the method further includes: If the refresh status is not being in the process of refreshing, sending a Token refresh request to the server and updating the refresh status to being in the process of refreshing; Receiving the new Token returned by the server to the client side according to the Token refresh request and updating the refresh status to not being in the process of refreshing.

3. The method according to claim 1, wherein After the refresh status is being in the process of refreshing and before obtaining a new Token, the method further includes: Storing the target page access request in a local request queue, where the request queue is used to temporarily store all page access requests of the user when a new Token has not been obtained.

4. The method according to claim 3, wherein The sending the target page access request to the server through the new Token includes: Retrieving all the page access requests from the request queue; Sequentially sending the corresponding page access requests to the server through the new Token according to the queue order of each page access request in the request queue among all the page access requests.

5. The method according to claim 1, wherein After obtaining the new Token and before sending the target page access request to the server through the new Token, the method further includes: Determining whether the refresh status is updated to not being in the process of refreshing; If so, performing the step of sending the target page access request to the server through the new Token.

6. The method according to any one of claims 1 to 5, characterized in that After determining whether the remaining valid time of the Token of the user stored locally is less than the preset approaching expiration threshold, the method further includes: If the remaining valid time of the Token is greater than or equal to the preset approaching expiration threshold, sending the target page access request to the server and obtaining the status code returned by the server to the client side after receiving the target page access request.

7. The method according to claim 6, wherein The method further includes: when the status code indicates unauthorized access, performing the step of obtaining the refresh status of the Token.

8. A page access system, characterized in that, The system includes: A first judgment unit, configured to, when receiving a target page access request initiated by a user at a client, judge whether the remaining valid time of the Token of the user stored locally is less than a preset approaching expiration threshold, where the Token is the Token bound to the user sent by the server to the client most recently; A first acquisition unit, configured to, if the remaining valid time of the Token is less than the preset approaching expiration threshold, acquire the refresh status of the Token, where the refresh status includes being refreshed and not being refreshed; A sending unit, configured to, if the refresh status is being refreshed, after acquiring a new Token, send the target page access request to the server through the new Token, where the new Token is a new Token bound to the user sent by the server to the client.

9. A page access device, characterized in that, The device includes: a processor, a memory, an input / output unit, and a bus; the processor is connected to the memory, the input / output unit, and the bus; the memory stores a program, and the processor calls the program to execute the method as described in any one of the above.

10. A computer-readable storage medium, on which a program is stored, and when the program is executed on a computer, it executes the method as described in any one of claims 1 to 7.