A network token management method, device, equipment and medium
By detecting and updating the token validity on the token management server side and using cloud servers to obtain new tokens, the problems of inflexible token management and large resource utilization in the existing technology are solved, and resource conservation and pressure reduction are achieved .
Patent Information
- Application Number
- CN202211346571.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-10-31
- Publication Date
- 2024-11-15
- Estimated Expiration
- 2042-10-31
AI Technical Summary
The existing technology lacks flexibility in token management, resulting in a large amount of user-side and server resources, high server pressure, and inconvenient management of token effectiveness.
By receiving local token acquisition requests from the user side on the token management server, detecting the validity of the token, and updating the token when invalid, using the cloud server to obtain new tokens, reducing server pressure, and improving the flexibility of token management .
It effectively saves system resources of token management services, slows down server pressure, and ensures centralized management and effectiveness of tokens when used frequently.
Smart Images

Figure CN115694837B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of data communication technology, and in particular to a network token management method, device, equipment and medium. Background Art
[0002] When an application interacts with a backend server for data, security verification is required, such as user name, password, token, etc. If each application uses a new user name, password and other verification information for each data interaction, it will undoubtedly greatly increase the processing pressure on the server, and it is very unsafe and cumbersome to use. In order to reduce the pressure on the server, tokens are used for security verification. In order to achieve unified management of tokens and convenient application, the existing solutions are to maintain the validity of tokens for a long time when a single or multiple applications use tokens, which lacks the flexibility of users' needs for tokens, and occupies relatively more device resources and server resources for a longer time. Summary of the invention
[0003] In view of the above-mentioned shortcomings of the prior art, the present invention provides a network token management method, device, equipment and medium, which can save user token application time and system resources, reduce server pressure, and solve the above-mentioned technical problems.
[0004] A network token management method provided by the present invention is applied to a token management server, including receiving a local token acquisition request from a user terminal; acquiring a locally stored local token according to the local token acquisition request; sending the local token to the user terminal; receiving first data carrying a token sent by the user terminal, wherein the token in the first data is the local token received by the user terminal from the token management server; detecting the validity of the token in the first data, and sending a token invalidation message to the user terminal when the token in the first data is invalid; receiving a cloud token acquisition request sent by the user terminal after receiving the token invalidation message; acquiring a new token from a cloud server according to the cloud token acquisition request; updating the local token with the new token, and sending the updated local token to the user terminal.
[0005] In one embodiment of the present invention, the method further includes:
[0006] When the token management service is started, it actively obtains a token from the cloud server as the local token.
[0007] In one embodiment of the present invention, the local token acquisition request, obtaining the local token, specifically includes:
[0008] According to the local token acquisition request, check whether a local token is stored locally;
[0009] When the local token is stored locally, the local token is directly obtained;
[0010] When the local token does not exist, a token is obtained from the cloud server as the local token.
[0011] In one embodiment of the present invention, the network token management method further includes:
[0012] After the token management service is started, the network status is detected;
[0013] When the network status detection is passed, a connection service is established to wait for the user terminal to connect;
[0014] A connection request initiated by the user terminal is received, and a connection is established with the user terminal.
[0015] In one embodiment of the present invention, the network token management method further includes:
[0016] Detecting the validity period of the local token stored locally;
[0017] When the validity period of the local token expires, the locally stored local token is deleted.
[0018] In one embodiment of the present invention, detecting the validity of the token in the first data and sending token invalidation information to the user terminal when the token in the first data is invalid specifically includes:
[0019] Detecting whether there is a local token matching the token in the data locally;
[0020] When the local token matching the token in the data does not exist locally, token invalidation information is sent to the user terminal.
[0021] In one embodiment of the present invention, the network token management method further includes:
[0022] Receiving second data carrying a token sent by the user end after receiving the updated local token, wherein the token in the second data is the updated local token received by the user end from the token management server;
[0023] Detect the validity of the token in the second data, and send token invalidation information to the user end when the token in the second data is invalid, and return to the step of receiving the cloud token acquisition request sent by the user end after receiving the token invalidation information.
[0024] In one embodiment of the present invention, the local token acquisition request or the cloud token acquisition request of multiple applications of the user end is processed based on a message queue.
[0025] To achieve the above objectives and other related objectives, the present invention also provides a network token management device, comprising:
[0026] A first receiving module, used for receiving a local token acquisition request from a user terminal;
[0027] A local token acquisition module, used to acquire a locally stored local token according to the local token acquisition request;
[0028] A first sending module, used to send the local token to the user terminal;
[0029] A second receiving module, configured to receive first data carrying a token sent by the user terminal, wherein the token in the first data is the local token received by the user terminal from the token management server;
[0030] A second sending module, used for detecting the validity of the token in the first data, and sending token invalidation information to the user terminal when the token in the first data is invalid;
[0031] A third receiving module, used to receive a cloud token acquisition request sent by the user end after receiving the token invalidation information;
[0032] A cloud token acquisition module, used to acquire a new token from a cloud server according to the cloud token acquisition request;
[0033] The third sending module is used to update the local token with the new token and send the updated local token to the user terminal.
[0034] To achieve the above-mentioned object and other related objects, the present invention further provides an electronic device, the electronic device comprising:
[0035] one or more processors;
[0036] The storage device is used to store one or more programs, and when the one or more programs are executed by the one or more processors, the electronic device implements the network token management method.
[0037] To achieve the above objectives and other related objectives, the present invention also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor of a computer, the computer executes the network token management method.
[0038] Beneficial effects of the present invention: The present invention receives a local token acquisition request from a user terminal; acquires a locally stored local token according to the local token acquisition request; sends the local token to the user terminal; receives first data carrying a token sent by the user terminal, wherein the token in the first data is the local token received by the user terminal from the token management server; detects the validity of the token in the first data, and sends a token invalidation message to the user terminal when the token in the first data is invalid; receives a cloud token acquisition request sent by the user terminal after receiving the token invalidation message; acquires a new token from the cloud server according to the cloud token acquisition request; updates the local token with the new token, and sends the updated local token to the user terminal. The present invention effectively saves system resources of the token management service, relieves the pressure on the server, and ensures centralized management of tokens when tokens are frequently used.
[0039] It should be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present application. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] The drawings herein are incorporated into the specification and constitute a part of the specification, showing embodiments consistent with the present application, and together with the specification, are used to explain the principles of the present application. Obviously, the drawings described below are only some embodiments of the present application, and for those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative work. In the drawings:
[0041] Figure 1 It is a schematic diagram of an application scenario of the network token management method provided by an embodiment of the present invention;
[0042] Figure 2 is a specific flow chart of the network token management method provided by an embodiment of the present invention;
[0043] Figure 3 It is a token management service architecture diagram of the network token management method provided by an embodiment of the present invention;
[0044] Figure 4 is a program execution flow chart of the network token management method provided by an embodiment of the present invention;
[0045] Figure 5 It is a diagram of a token acquisition process at the user end of the network token management method provided by an embodiment of the present invention;
[0046] Figure 6 It is a functional module block diagram of the network token management method provided by an embodiment of the present invention;
[0047] Figure 7 It is a structural block diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0048] The following will describe the embodiments of the present invention with reference to the accompanying drawings and preferred embodiments. Those skilled in the art can easily understand other advantages and effects of the present invention from the contents disclosed in this specification. The present invention can also be implemented or applied through other different specific embodiments, and the details in this specification can also be modified or changed in various ways based on different viewpoints and applications without departing from the spirit of the present invention. It should be understood that the preferred embodiments are only for illustrating the present invention, not for limiting the scope of protection of the present invention.
[0049] It should be noted that the illustrations provided in the following embodiments are only schematic illustrations of the basic concept of the present invention, and thus the drawings only show components related to the present invention rather than being drawn according to the number, shape and size of components in actual implementation. In actual implementation, the type, quantity and proportion of each component may be changed arbitrarily, and the component layout may also be more complicated.
[0050] In the following description, numerous details are discussed to provide a more thorough explanation of the embodiments of the present invention. However, it is obvious to those skilled in the art that the embodiments of the present invention can be implemented without these specific details. In other embodiments, well-known structures and devices are shown in the form of block diagrams rather than in detail to avoid making the embodiments of the present invention difficult to understand.
[0051] First of all, it should be noted that a token is an encrypted string generated by the server, which serves as a temporary key for the client to make requests. When the user successfully logs in with the account and password for the first time, the server generates a token and the token expiration time and returns it to the client. If the login is successful, the client only needs to bring the token to request data within the valid time, without having to bring the username and password again. The token determines whether the request is allowed and determines which user the request belongs to. It allows you to access network and system resources without providing a password or other credentials. These tokens will persist in the system unless the system is restarted. Take the actual process as an example. When you successfully log in with the account and password for the first time after downloading QQ or WeChat, the token saves us the process of entering the account and password every time we open the application.
[0052] The biggest feature of tokens is randomness and unpredictability. Hackers or software cannot guess them. There are many kinds of tokens, such as access tokens, which represent system objects of the subject of access control operations; security tokens, also known as authentication tokens or hardware tokens, are physical devices for computer identity verification, such as USB shields; session tokens are unique identifiers in interactive sessions. Tokens are time-limited. After a period of time, when tokens become invalid, users need to re-verify and obtain new tokens; tokens are completely managed by applications, so they can avoid the same-origin policy; tokens stored on the user side are stateless and can be expanded and shared among multiple services.
[0053] Figure 1 This is a schematic diagram of the application scenario of the network token management method provided by an embodiment of the present invention. In this scenario, the user terminal 110 carries the user name and password to send an authentication request to the server terminal 120. If the server terminal 120 succeeds in the authentication, the server terminal 120 will apply for a token from the cloud 130, save it locally and then send the token to the user terminal 110. The user terminal 110 can bring the token to prove its legal status every time it makes a request.
[0054] Figure 2 is a specific flow chart of the network token management method provided by an embodiment of the present invention. The method can be applied to Figure 1 The implementation environment shown is a schematic diagram. It should be understood that the method may also be applicable to other exemplary implementation environments and may be specifically executed by devices in other implementation environments. This embodiment does not limit the implementation environment to which the method is applicable.
[0055] like Figure 2 As shown, in an exemplary embodiment, the network token management method includes at least steps S21 to S28, which are described in detail as follows:
[0056] Step S21: receiving a local token acquisition request from a user terminal.
[0057] In a specific embodiment, when the token management service is started, a network status detection is performed after the token management service is started; when the network status detection passes, a connection service is established to wait for the user terminal to connect; a connection request initiated by the user terminal is received, and a connection is established with the user terminal; during initialization, the server can actively obtain a token from the cloud server once as the local token.
[0058] Step S22: Acquire the locally stored local token according to the local token acquisition request.
[0059] In a specific embodiment, the server checks whether a local token is stored locally based on the local token acquisition request; when the local token is stored locally, the local token is directly acquired; when the local token does not exist, a token is acquired from the cloud server as the local token.
[0060] Step S23: Send the local token to the user terminal.
[0061] In a specific embodiment, after the server obtains the local token, it can send the local token to the client through the network, for example. After the client receives the local token, it can carry the token for authentication when sending data to the server.
[0062] Step S24: receiving first data carrying a token sent by the user terminal, where the token in the first data is the local token received by the user terminal from the token management server.
[0063] In a specific embodiment, after receiving the first data sent by the client, the server parses the first data to obtain a token carried therein for authentication.
[0064] Step S25: Detect the validity of the token in the first data, and send token invalidation information to the user terminal when the token in the first data is invalid.
[0065] In a specific embodiment, the server does not actively detect the validity period of the local token stored locally; the server receives data sent by the user, and can detect whether the local token corresponding to the token in the data is within the validity period. When it is not within the validity period, it sends a token invalidation message to the user. After receiving the token invalidation message, the user sends a cloud token acquisition request to the server. The token management service of the server does not actively check or update the validity of the local token, thereby avoiding waste of resources.
[0066] In another specific embodiment, the server detects the validity period of the local token stored locally; when the validity period of the local token expires, the local token stored locally is deleted. Therefore, when the server receives the data sent by the user, it can detect whether there is a local token matching the token in the data locally; when there is no local token matching the token in the data locally, a token invalidation message is sent to the user.
[0067] Step S26: receiving a cloud token acquisition request sent by the user terminal when the local token is invalid.
[0068] In a specific embodiment, after receiving the token invalidation information sent by the server, the client sends a cloud acquisition request to the server to request the server to re-acquire a new token from the cloud.
[0069] Step S27: Obtain a new token from the cloud server according to the cloud token acquisition request. After receiving the cloud token acquisition request sent by the client, the server will request the cloud server to generate a new token, that is, the server will passively obtain a new token from the cloud server after the local token is invalid.
[0070] Step S28: Update the local token with the new token, and send the new local token to the user terminal.
[0071] After receiving the new local token, the user terminal will send data (i.e., second data) to the server terminal, which carries the new token. The server terminal will receive the second data carrying the token sent by the user terminal after receiving the updated local token, and the token in the second data is the updated local token received by the user terminal from the token management server; detect the validity of the token in the second data, and send token invalidation information to the user terminal when the token in the second data is invalid, and return to the step of receiving the cloud token acquisition request sent by the user terminal after receiving the token invalidation information. After receiving the token invalidation information, the user terminal will send a cloud token acquisition request to the server again until the token is detected as valid by the server and the data is sent successfully.
[0072] It should be noted that the user end usually includes multiple applications, so the network token management method of this embodiment can process the local token acquisition request or the cloud token acquisition request of multiple applications on the user end based on the message queue, and multiple applications and multiple messages are processed and replied in sequence. When multiple applications obtain tokens from the token management service on the server end, the message queue format ensures the integrity of multiple messages and ensures that the messages are not lost.
[0073] Figure 3 It is a token management service architecture diagram of the network token management method provided in an embodiment of the present invention. Figure 3It shows that the token management server is started, the network is detected, and after the network status detection is passed, a token token is actively obtained from the cloud server. This acquisition is mainly to save the time for subsequent valid token acquisition and reduce the waiting time for the user to obtain the token from the server for the first time. Of course, it is not necessary to actively obtain it after startup. Here, the network establishment lag is avoided in the embedded device. A connection service is established, and the server waits for the user to connect. After the user is connected to the server, there are two ways to obtain the token from the server. As shown in 1, the server directly obtains the local token stored locally based on the request of the user's application app and returns it to the user's application app. In this way, the user's waiting time is short and the efficiency is high; as shown in 2, there is no token stored locally. After receiving the token acquisition request from the user, the server must obtain the newly generated token from the cloud server, and then update the local token and return it to the user's application app. The disadvantage of this operation is that the user's waiting time is relatively long.
[0074] Figure 4 1 is a flowchart of the program execution of the network token management method provided by the embodiment of the present invention. Figure 4 The specific implementation steps are as follows:
[0075] 1: The token management service waits for the client to connect after the process initialization is completed;
[0076] 2: The client and server establish a connection;
[0077] 3: The user initiates a request to obtain a local token;
[0078] 4: The server sends the local token to the client, and the client obtains the local token and then sends the data with the local token;
[0079] 5: If the token carried in the server feedback data is invalid, the user needs to send a cloud token acquisition request to the server again;
[0080] 6: The server sends the new local token to the client. After receiving the new local token, the client sends data with the local token to the server again until the data is sent successfully.
[0081] Figure 5This is a diagram of the process of obtaining tokens on the user side of the network token management method provided by an embodiment of the present invention. This figure illustrates the details of information interaction between the server side and the user side. When multiple applications obtain tokens from the token management service, the integrity of multiple messages is guaranteed in the form of a queue to ensure that messages are not lost, and multiple applications and multiple messages are processed and replied in sequence. From application 1 to application n, when multiple applications obtain tokens, it is guaranteed that the latest valid token is obtained from the cloud in a timely manner when the first token expires or becomes invalid. This ensures that all applications that need tokens in a short period of time will obtain updated valid tokens.
[0082] Figure 6 is a functional module block diagram of a network token management method provided by an embodiment of the present invention. The device can be applied to Figure 1 The device may also be applicable to other exemplary implementation environments and specifically configured in other devices, and this embodiment does not limit the implementation environment to which the device is applicable.
[0083] like Figure 6 As shown, the device includes a first receiving module 61, a local token acquisition module 62, a first sending module 63, a second receiving module 64, a second sending module 65, a third receiving module 66, a cloud token acquisition module 67, and a third sending module 68;
[0084] The first receiving module 61 is used to receive a local token acquisition request from a user terminal;
[0085] The local token acquisition module 62 is used to acquire the locally stored local token according to the local token acquisition request;
[0086] The first sending module 63 is used to send the local token to the user terminal;
[0087] The second receiving module 64 is used to receive first data carrying a token sent by the user terminal, where the token in the first data is the local token received by the user terminal from the token management server;
[0088] The second sending module 65 is used to detect the validity of the token in the first data, and send token invalidation information to the user terminal when the token in the first data is invalid;
[0089] The third receiving module 66 is used to receive a cloud token acquisition request sent by the user end after receiving the token invalidation information;
[0090] The cloud token acquisition module 67 is used to obtain a new token from the cloud server according to the cloud token acquisition request;
[0091] The third sending module 68 is used to update the local token with the new token and send the updated local token to the user terminal.
[0092] It should be noted that the network token management device provided in the above embodiment and the network token management method provided in the above embodiment belong to the same concept, wherein the specific manner in which each module and unit performs operations has been described in detail in the method embodiment, and will not be repeated here. In actual applications, the network token management device provided in the above embodiment can allocate the above functions to different functional modules as needed, that is, divide the internal structure of the device into different functional modules to complete all or part of the functions described above, and this is not limited here.
[0093] An embodiment of the present application also provides an electronic device, comprising: one or more processors; a storage device for storing one or more programs, when the one or more programs are executed by the one or more processors, the electronic device implements the network token management method provided in the above-mentioned embodiments.
[0094] Figure 7 The structure diagram of the computer system suitable for implementing the electronic device of the embodiment of the present application is shown. It should be noted that: Figure 7 The computer system 700 of the electronic device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0095] like Figure 7 As shown, the computer system 700 includes a central processing unit (CPU) 701, which can perform various appropriate actions and processes according to the program stored in the read-only memory (ROM) 702 or the program loaded from the storage part 708 to the random access memory (RAM) 703, such as executing the method described in the above embodiment. In the RAM 703, various programs and data required for system operation are also stored. The CPU 701, ROM 702 and RAM 703 are connected to each other through a bus 704. An input / output (I / O) interface 705 is also connected to the bus 704.
[0096] The following components are connected to the I / O interface 705: an input section 706 including a keyboard, a mouse, etc.; an output section 707 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 708 including a hard disk, etc.; and a communication section 709 including a network interface card such as a LAN (Local Area Network) card, a modem, etc. The communication section 709 performs communication processing via a network such as the Internet. A drive 710 is also connected to the I / O interface 705 as needed. A removable medium 711, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 710 as needed so that a computer program read therefrom is installed into the storage section 708 as needed.
[0097] In particular, according to an embodiment of the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, an embodiment of the present application includes a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a computer program for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication section 709, and / or installed from a removable medium 711. When the computer program is executed by a central processing unit (CPU) 701, various functions defined in the system of the present application are executed.
[0098] It should be noted that the computer-readable medium shown in the embodiment of the present application can be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium can be, for example, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media can include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM), a flash memory, an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present application, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, wherein a computer-readable computer program is carried. This propagated data signal can take a variety of forms, including but not limited to an electromagnetic signal, an optical signal, or any suitable combination of the above. A computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. A computer program contained on a computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wired, etc., or any suitable combination of the above.
[0099] The flowchart and block diagram in the accompanying drawings illustrate the possible architecture, functions and operations of the system, method and computer program product according to various embodiments of the present application. Wherein, each box in the flowchart or block diagram can represent a module, a program segment, or a part of the code, and the above-mentioned module, program segment, or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flowchart, and the combination of boxes in the block diagram or flowchart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0100] The units involved in the embodiments described in this application may be implemented by software or hardware, and the units described may also be set in a processor. The names of these units do not, in some cases, constitute limitations on the units themselves.
[0101] Another aspect of the present application provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor of a computer, the computer executes the network token management method as described above. The computer-readable storage medium may be included in the electronic device described in the above embodiment, or may exist independently without being assembled into the electronic device.
[0102] Another aspect of the present application also provides a computer program product or a computer program, which includes computer instructions stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the network token management method provided in each of the above embodiments.
[0103] The above embodiments are merely illustrative of the principles and effects of the present invention, and are not intended to limit the present invention. Anyone familiar with the technology may modify or change the above embodiments without violating the spirit and scope of the present invention. Therefore, all equivalent modifications or changes made by a person of ordinary skill in the art without departing from the spirit and technical ideas disclosed by the present invention shall still be covered by the claims of the present invention.
Claims
1. A network token management method, characterized in that: Applied to the token management server; The method comprises: Receive a local token acquisition request from the user; According to the local token acquisition request, obtain the locally stored local token; Sending the local token to the user terminal; Receiving first data carrying a token sent by the user terminal, where the token in the first data is the local token received by the user terminal from the token management server; Detecting the validity of the token in the first data, and sending token invalidation information to the user terminal when the token in the first data is invalid; Receiving a cloud token acquisition request sent by the user end after receiving token invalidation information; Obtain a new token from the cloud server according to the cloud token acquisition request; The local token is updated with the new token, and the updated local token is sent to the user terminal.
2. The network token management method according to claim 1, characterized in that: The method further comprises: When the token management service is started, a token is actively obtained from the cloud server as the local token.
3. The network token management method according to claim 1, characterized in that: According to the local token acquisition request, a local token is acquired, specifically including: According to the local token acquisition request, check whether a local token is stored locally; When the local token is stored locally, the local token is directly obtained; When the local token does not exist, a token is obtained from the cloud server as the local token.
4. The network token management method according to claim 1, characterized in that: The network token management method further includes: After the token management service is started, the network status is detected; When the network status detection is passed, a connection service is established to wait for the user terminal to connect; A connection request initiated by the user terminal is received, and a connection is established with the user terminal.
5. The network token management method according to claim 1, characterized in that: The network token management method further includes: Detecting the validity period of the local token stored locally; When the validity period of the local token expires, the locally stored local token is deleted.
6. The network token management method according to claim 1, characterized in that: Detecting the validity of the token in the first data, and sending token invalidation information to the user terminal when the token in the first data is invalid, specifically includes: Detecting whether there is a local token matching the token in the data locally; When the local token matching the token in the data does not exist locally, token invalidation information is sent to the user terminal.
7. The network token management method according to claim 1, characterized in that: The network token management method further includes: Receiving second data carrying a token sent by the user end after receiving the updated local token, wherein the token in the second data is the updated local token received by the user end from the token management server; Detect the validity of the token in the second data, and send token invalidation information to the user end when the token in the second data is invalid, and return to the step of receiving the cloud token acquisition request sent by the user end after receiving the token invalidation information.
8. The network token management method according to claim 1, characterized in that: The local token acquisition request or the cloud token acquisition request of multiple applications on the user side is processed based on a message queue.
9. A network token management device, characterized in that: Applied to a token management server, the device comprises: A first receiving module, used for receiving a local token acquisition request from a user terminal; A local token acquisition module, used to acquire a locally stored local token according to the local token acquisition request; A first sending module, used to send the local token to the user terminal; A second receiving module, configured to receive first data carrying a token sent by the user terminal, wherein the token in the first data is the local token received by the user terminal from the token management server; A second sending module, used for detecting the validity of the token in the first data, and sending token invalidation information to the user terminal when the token in the first data is invalid; A third receiving module, used to receive a cloud token acquisition request sent by the user end after receiving the token invalidation information; A cloud token acquisition module, used to acquire a new token from a cloud server according to the cloud token acquisition request; The third sending module is used to update the local token with the new token and send the updated local token to the user terminal.
10. An electronic device, characterized in that: The electronic device comprises: one or more processors; A storage device for storing one or more programs, when the one or more programs are executed by the one or more processors, enables the electronic device to implement the network token management method as described in any one of claims 1 to 8.
11. A computer-readable storage medium, characterized in that: A computer program is stored thereon, and when the computer program is executed by a processor of a computer, the computer is caused to execute the network token management method according to any one of claims 1 to 8.
Citation Information
Patent Citations
Equipment authentication method, device and system, terminal equipment and storage medium
CN112417425A
Login method and device, electronic equipment and storage medium
CN113190808A
Method and device for starting up and logging in cloud desktop based on one-time fingerprint touch
CN115033297A
Vehicle-mounted terminal Token uniqueness and cloud authentication system and vehicle-mounted terminal Token uniqueness and cloud authentication method
CN115242400A
Application login using token transmitted from mobile device
WO2022046165A1
