Authentication service method, device, server and authentication service system

By using the first authentication server and the second authentication server in the authentication service system, generating and cacheing user permission information, the problem of high maintenance cost of user permission information in the enterprise network application system is solved, and efficient permission authentication and response speed are achieved. .

CN112613010BActive Publication Date: 2024-11-26BEIJING 21VIANET DATA CENT
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202011585266.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-12-28
Publication Date
2024-11-26
Estimated Expiration
2040-12-28

AI Technical Summary

Technical Problem

In the prior art, the information maintenance cost of user permissions in enterprise network application systems is relatively high, and each application system needs to perform permission authentication based on the correspondence between users and permissions stored in its own information database, resulting in high information maintenance cost.

Method used

By introducing the first authentication server and the second authentication server in the authentication service system, receiving the client's login request, obtaining the user permission information from the user permission information database after successful verification, and establishing the corresponding relationship between the ticket credentials and the permission information in the cache server , generate ticket credentials, reducing the permission authentication needs of the local information database of each application system.

Benefits of technology

It reduces information maintenance costs, improves the response speed of application systems, simplifies the efficiency of user resource access, and reduces the operational complexity of each application system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112613010B_ABST
    Figure CN112613010B_ABST
Patent Text Reader

Abstract

The embodiments of the present application provide an authentication service method, device, server and authentication service system. Receive a login request from a target user sent by a client, and verify the login request based on a user login information database; if the verification is successful, obtain the target user's permission information in each application system from a user permission information database, and store the target user's permission information in each application system in a cache server; send a login request verification success notification to a second authentication server, so that the second authentication server generates a ticket voucher for the target user, and establish a correspondence between the target user's ticket voucher and the target user's permission information in each application system in the cache server; return the ticket voucher to the client as the target user's access credential when accessing each application system. The permission authentication process in the embodiments of the present application is based on a single database, the user permission information database, and therefore, the cost of information maintenance is relatively low.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the field of communication technology, and in particular, to an authentication service method, device, server, and authentication service system. Background Art

[0002] As business content continues to expand, more and more network application systems are being built by enterprises. To facilitate user use, single sign-on is generally implemented between internal application systems, that is, in multiple application systems, users only need to log in once to access all mutually trusted application systems.

[0003] Due to differences in job titles and identities, different users may have different access rights in various application systems. The single sign-on authentication process mainly includes two aspects: login authentication and permission authentication. At present, after confirming that the user has successfully logged in based on the user login information database, each application system usually needs to authenticate the user's permissions based on the corresponding relationship between users and permissions stored in the local information database to determine the user's access rights in each application system.

[0004] The above authentication process requires each application system to implement the correspondence between users and permissions stored in its own information base. Each application system needs to maintain a set of information bases containing the correspondence between users and permissions, and the information maintenance cost is high. Summary of the invention

[0005] The purpose of this application is to propose an authentication service method, device, server and authentication service system to solve the problem of high information maintenance cost in the prior art.

[0006] According to a first aspect of an embodiment of the present application, an authentication service method is provided, which is applied to a first authentication server in an authentication service system, wherein the authentication service system further includes: a second authentication server, and the method includes:

[0007] Receive a login request from a target user sent by a client, and verify the login request based on a user login information database;

[0008] If the verification is successful, the target user's permission information in each application system is obtained from the user permission information database, and the permission information of the target user in each application system is stored in the cache server; the user permission information database includes: the permission information of each user in each application system;

[0009] Send a login request verification success notification to the second authentication server so that the second authentication server generates a ticket credential for the target user, and establishes a correspondence between the ticket credential of the target user and the permission information of the target user in each application system in the cache server; return the ticket credential to the client as the access credential for the target user to access each application system.

[0010] Optionally, the authentication service system further includes: an application programming interface API gateway device;

[0011] The receiving a login request of a target user sent by a client comprises:

[0012] Receive a login request of a target user sent by the API gateway device; the login request is received by the API gateway device from the client and forwarded to the first authentication server.

[0013] Optionally, the method further comprises:

[0014] Receiving a to-be-verified ticket credential sent by an application system; the to-be-verified ticket credential is obtained after the application system parses a resource access request received from a client;

[0015] Determine whether the ticket credential to be verified exists in the cache server; if so, determine the user permission information corresponding to the ticket credential to be verified, and return the user permission information corresponding to the ticket credential to be verified to the application system, so that the application system determines whether the user has the permission to access the resource based on the user permission information corresponding to the ticket credential to be verified. If so, allow access to the resource; if not, return an access failure notification to the client.

[0016] According to a second aspect of an embodiment of the present application, an authentication service method is provided, which is applied to a second authentication server in an authentication service system, wherein the authentication service system further includes: a first authentication server, and the method includes:

[0017] receiving a login request verification success notification sent by the first authentication server, wherein the login request verification success notification is sent by the first authentication server to the second authentication server when the first authentication server receives a login request of a target user sent by a client and verifies the login request successfully based on a user login information database;

[0018] Generate a ticket credential of the target user, and establish a correspondence between the ticket credential of the target user and the permission information of the target user in each application system in the cache server; wherein the permission information of the target user in each application system is obtained by the first authentication server from a user permission information database, and the permission information of the target user in each application system is stored in the cache server; the user permission information database includes: the permission information of each user in each application system;

[0019] The ticket certificate is returned to the client as an access certificate for the target user to access various application systems.

[0020] According to a third aspect of an embodiment of the present application, an authentication service device is provided, which is applied to a first authentication server in an authentication service system, the authentication service system further comprising: a second authentication server, the device comprising:

[0021] A login request receiving module, used to receive a login request from a target user sent by a client, and verify the login request;

[0022] The permission information cache module is used to obtain the permission information of the target user in each application system from the user permission information database if the verification is successful, and store the permission information of the target user in each application system in the cache server; the user permission information database includes: the permission information of each user in each application system;

[0023] A notification sending module is used to send a login request verification success notification to the second authentication server, so that the second authentication server generates a ticket credential for the target user, and establishes a correspondence between the ticket credential of the target user and the permission information of the target user in each application system in the cache server; and returns the ticket credential to the client as the access credential for the target user to access each application system.

[0024] According to a fourth aspect of an embodiment of the present application, an authentication service device is provided, which is applied to a second authentication server in an authentication service system, wherein the authentication service system further includes: a first authentication server, and the device includes:

[0025] a notification receiving module, configured to receive a login request verification success notification sent by the first authentication server, wherein the login request verification success notification is sent by the first authentication server to the second authentication server when the first authentication server receives a login request of a target user sent by a client and verifies the login request successfully;

[0026] a ticket voucher generation module, used to generate the ticket voucher of the target user, and establish a correspondence between the ticket voucher of the target user and the permission information of the target user in each application system in the cache server; wherein the permission information of the target user in each application system is obtained by the first authentication server from the user permission information database, and the permission information of the target user in each application system is stored in the cache server; the user permission information database includes: the permission information of each user in each application system;

[0027] The ticket certificate returning module is used to return the ticket certificate to the client as the access certificate for the target user to access each application system.

[0028] According to the fifth aspect of an embodiment of the present application, a server is provided, comprising: one or more processors; a computer-readable medium configured to store one or more programs, and when the one or more programs are executed by one or more processors, the one or more processors implement the authentication service method of the first aspect of the above embodiment.

[0029] According to the sixth aspect of an embodiment of the present application, another server is provided, comprising: one or more processors; a computer-readable medium configured to store one or more programs, and when the one or more programs are executed by one or more processors, the one or more processors implement the authentication service method of the second aspect of the above embodiment.

[0030] According to a seventh aspect of an embodiment of the present application, a computer-readable storage medium is provided, on which a computer program is stored. When the program is executed by a processor, the authentication service method of the first aspect or the second aspect of the above-mentioned embodiment is implemented.

[0031] According to the authentication service method, device, server and authentication service system provided by the embodiments of the present application, the first authentication server in the authentication service system receives a login request of a target user sent by a client, and verifies the login request based on a user login information database; if the verification is successful, the permission information of the target user in each application system is obtained from a user permission information database, and the permission information of the target user in each application system is stored in a cache server; the user permission information database includes: the permission information of each user in each application system; a login request verification success notification is sent to the second authentication server, so that the second authentication server generates a ticket credential for the target user, and establishes a correspondence between the ticket credential of the target user and the permission information of the target user in each application system in the cache server; the ticket credential is returned to the client as an access credential for the target user to access each application system.

[0032] In the embodiment of the present application, after the target user's login request is successfully verified, that is, after it is determined that the target user has successfully logged in, the first authentication server uniformly authenticates the target user's permissions in each application system based on the user permission information database that includes the permission information of each user in each application system: the permission information of the target user in each application system is determined and stored in the cache server, and the second authentication server generates the access credentials for the target user to access each application system: the ticket credential, and establishes the ticket credential and permission information of the target user in the cache server. The above process does not require each application system to perform permission authentication based on the correspondence between users and permissions stored in its own local information base. Compared with the existing method that needs to be based on multiple information bases for authentication, the permission authentication process in the embodiment of the present application is based on a single database, the user permission information database, so the cost of information maintenance is low. BRIEF DESCRIPTION OF THE DRAWINGS

[0033] Other features, objects and advantages of the present application will become more apparent by reading the detailed description of non-limiting embodiments made with reference to the following drawings:

[0034] Figure 1 A schematic diagram of the structure of the authentication service system provided in the embodiment of the present application;

[0035] Figure 2 The authentication service method provided in Example 1 of this application is applied to Figure 1 A flowchart of the steps of the first authentication server in the authentication service system shown;

[0036] Figure 3 The authentication service method provided in Example 2 of this application is applied to Figure 1 A flowchart of steps of a second authentication server in the authentication service system shown;

[0037] Figure 4 Another structural diagram of the authentication service system provided in the embodiment of the present application;

[0038] Figure 5 Based on Figure 4 The illustrated authentication service system is an interactive flow chart of a specific instance of performing authentication services;

[0039] Figure 6 A schematic diagram of the structure of the authentication service device provided in Example 3 of the present application;

[0040] Figure 7 A schematic diagram of the structure of the authentication service device provided in Example 4 of the present application;

[0041] Figure 8 A schematic diagram of the structure of a server provided in Embodiment 5 of the present application;

[0042] Fig. 9 This is the hardware structure of the server in Example 5 of the present application. DETAILED DESCRIPTION

[0043] The present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It is to be understood that the specific embodiments described herein are only configured to explain the relevant invention, rather than to limit the invention. It is also necessary to explain that, for ease of description, only the parts related to the relevant invention are shown in the accompanying drawings.

[0044] It should be noted that, in the absence of conflict, the embodiments and features in the embodiments of the present application can be combined with each other. The present application will be described in detail below with reference to the accompanying drawings and in combination with the embodiments.

[0045] See also Figure 1 , Figure 1 A structural diagram of an authentication service system provided in an embodiment of the present application, the authentication service system includes: a first authentication server 100 and a second authentication server 200. Among them, the first authentication server is mainly used to verify the login request of the target user, and when the verification is successful, the target user's permission information in each application system is stored in the cache server; the second authentication server 200 is mainly used to generate the access credentials for the target user to access each application system after confirming that the target user has successfully logged in: a ticket credential, and establish a corresponding relationship between the above-mentioned ticket credential and the target user's permission information in each application system.

[0046] In the embodiment of the present application, the number of first authentication servers may be one or more, and similarly, the number of second authentication servers may be one or more. When the number of first authentication servers is more than one, Figure 1 The first authentication server 100 in the authentication service system shown is a first authentication server cluster composed of multiple first authentication servers with a load balancing mechanism; when there are multiple second authentication servers, Figure 1 The second authentication server 200 in the authentication service system is a second authentication server cluster composed of multiple second authentication servers with a load balancing mechanism. In the embodiment of the present application, the first authentication server 100 and the second authentication server 200 can be different servers or the same server.

[0047] See also Figure 2 , Figure 2 The authentication service method provided in Example 1 of this application is applied to Figure 1 The step flow chart of the first authentication server in the authentication service system shown in the figure specifically includes the following steps:

[0048] Step 201: receiving a login request of a target user sent by a client, and verifying the login request based on a user login information database.

[0049] Specifically, the above login request may include: target user information and a login password to be verified. Correspondingly, the user login information database may include: a correspondence between user information and login passwords. The user information may be user name, account number and other information of the user, and the specific content of the user information is not limited here.

[0050] The verification process of this step may include: determining the target login password corresponding to the target user information based on the correspondence between the user information and the login password; judging whether the target login password is consistent with the login password to be verified, if so, determining that the verification is successful; if not, confirming that the verification has failed.

[0051] Step 202: If the verification is successful, the target user's authority information in each application system is obtained from the user authority information database, and the target user's authority information in each application system is stored in the cache server.

[0052] The user authority information database includes: authority information of each user in each application system.

[0053] Usually, the database used to store user permission information is a relational database. A relational database is a database that uses a relational model to organize data. It stores data in the form of rows and columns to facilitate user understanding. This series of rows and columns in a relational database is called a table, and a group of tables constitutes a database. The relational model can be simply understood as a two-dimensional table model, and a relational database is a data organization composed of two-dimensional tables and the relationships between them.

[0054] In this step, after obtaining the target user's authority information in each application system, the first authentication server stores (writes) the authority information into the cache server for the following purposes:

[0055] Compared with relational databases, cache servers have faster data query speeds and can be used to store frequently accessed data. The target user's permission information in each application system is stored in the cache server. In this way, after the authentication service for the target user is completed, when the target user accesses resources in a certain application system, the application system can quickly query the target user's permission information in the above cache server through the authentication service system, and then determine whether the target user has the permission to access the above resources based on the above permission information. If yes, access is allowed; if not, access fails. This can improve the response speed of the application system.

[0056] Step 203, sending a login request verification success notification to the second authentication server, so that the second authentication server generates a ticket credential for the target user, and establishes a correspondence between the ticket credential of the target user and the permission information of the target user in each application system in the cache server; and returns the ticket credential to the client as the access credential for the target user to access each application system.

[0057] After the client receives the ticket certificate of the target user returned by the second authentication server, it can be used as the access certificate for the target user to access various application systems. Specifically: when the target user wants to access a certain application system, the access certificate can be carried in the access request sent to the application system. After the application system receives the access request, it can parse the access certificate and verify its validity in the authentication service system. If the verification is successful, the user permission information corresponding to the ticket certificate is read from the cache database at the same time and returned to the application system, so that the application system can determine whether to return the requested resource to the client based on the user permission information.

[0058] In the embodiment of the present application, after the target user's login request is successfully verified, that is, after it is determined that the target user has successfully logged in, the first authentication server uniformly authenticates the target user's permissions in each application system based on the user permission information database that includes the permission information of each user in each application system: the permission information of the target user in each application system is determined and stored in the cache server, and the second authentication server generates the access credentials for the target user to access each application system: the ticket credential, and establishes the ticket credential and permission information of the target user in the cache server. The above process does not require each application system to perform permission authentication based on the correspondence between users and permissions stored in its own local information base. Compared with the existing method that needs to be based on multiple information bases for authentication, the permission authentication process in the embodiment of the present application is based on a single database, the user permission information database, so the cost of information maintenance is low.

[0059] See also Figure 3 , Figure 3 The authentication service method provided in Example 2 of this application is applied to Figure 1 The step flow chart of the second authentication server in the authentication service system shown in the figure specifically includes the following steps:

[0060] Step 301: Receive a login request verification success notification sent by a first authentication server.

[0061] Specifically, the login request verification success notification is sent by the first authentication server to the second authentication server when the first authentication server receives the login request of the target user sent by the client and verifies the login request successfully based on the user login information database.

[0062] Step 302: Generate a ticket certificate of the target user, and establish a correspondence between the ticket certificate of the target user and the permission information of the target user in each application system in the cache server.

[0063] Specifically, the target user's permission information in each application system is obtained by the first authentication server from the user permission information database, and the permission information of the target user in each application system is stored in the cache server; the user permission information database includes: the permission information of each user in each application system.

[0064] Step 303: Return the ticket certificate to the client as the access certificate for the target user to access various application systems.

[0065] Figure 3 In the illustrated embodiment, after the target user's login request is successfully verified, that is, after it is determined that the target user has successfully logged in, the first authentication server uniformly authenticates the target user's permissions in each application system based on the user permission information database that includes the permission information of each user in each application system: the permission information of the target user in each application system is determined and stored in the cache server, and the second authentication server generates the access credentials for the target user to access each application system: the ticket credential, and establishes the ticket credential and permission information of the target user in the cache server. The above process does not require each application system to perform permission authentication based on the correspondence between users and permissions stored in its own local information base. Compared with the existing method that requires authentication based on multiple information bases, the permission authentication process in the embodiment of the present application is based on a single database, the user permission information database, so the cost of information maintenance is low.

[0066] See also Figure 4 , Figure 4 Another structural diagram of the authentication service system provided in an embodiment of the present application. Figure 4 The authentication service system shown in Figure 1An API (Application Programming Interface) gateway device 300 is added to the authentication service system shown. The API gateway device 300 is a transit device for protocol transmission between the client and the authentication server (including the first server and the second server) in the authentication service system, which is used to integrate the first authentication server and the second authentication server into a whole, and provide a unified rest service to the outside (client), so that the interaction between the client and the authentication service system is simpler. Specifically: the interaction process directly uses http as the transmission protocol, and no other message protocol is required; data exchange is usually carried out in the format of xml and json, and the data description is relatively simple; when calling an interface (accessing and operating resources), the context and the current state do not need to be considered, which greatly reduces the complexity.

[0067] In the embodiment of the present application, the number of API gateway devices may be one or more. When the number of API gateway devices is more than one, Figure 4 The API gateway device 300 in the authentication service system shown is an API gateway device cluster composed of multiple API gateway devices and having a load balancing mechanism.

[0068] See also Figure 5 , Figure 5 Based on Figure 4 The interactive flow chart of a specific example of the authentication service system performing authentication service is shown, and the interactive process includes:

[0069] Step 501: The client sends a login request of a target user to an API gateway device.

[0070] Specifically, the login request may include: target user information and a login password to be verified. The target user information may be information such as a user name and account number of the target user, and the specific content of the target user information is not limited here.

[0071] Step 502: The API gateway device sends the above login request to the first authentication server.

[0072] Step 503: The first authentication server verifies the login request based on the user login information database.

[0073] The user login information database may include: the corresponding relationship between the user information and the login password of each user.

[0074] The verification process may include: determining the target login password corresponding to the target user information based on the correspondence between the user information and the login password; judging whether the target login password is consistent with the login password to be verified, if so, determining that the verification is successful; if not, confirming that the verification has failed.

[0075] Step 504: If the verification is successful, the first authentication server obtains the target user's authority information in each application system from the user authority information database.

[0076] The user authority information database includes: authority information of each user in each application system.

[0077] Step 505: The first authentication server stores the target user's authority information in each application system into a cache server.

[0078] Usually, the database used to store user permission information is a relational database. A relational database is a database that uses a relational model to organize data. It stores data in the form of rows and columns to facilitate user understanding. This series of rows and columns in a relational database is called a table, and a group of tables constitutes a database. The relational model can be simply understood as a two-dimensional table model, and a relational database is a data organization composed of two-dimensional tables and the relationships between them.

[0079] After obtaining the target user's authority information in each application system, the first authentication server stores (writes) the authority information into the cache server for the following purposes:

[0080] Compared with relational databases, cache servers have faster data query speeds and can be used to store frequently accessed data. The target user's permission information in each application system is stored in the cache server. In this way, after the authentication service for the target user is completed, when the target user accesses resources in a certain application system, the application system can quickly query the target user's permission information in the above cache server through the authentication service system, and then determine whether the target user has the permission to access the above resources based on the above permission information. If yes, access is allowed; if not, access fails. This can improve the response speed of the application system.

[0081] Step 506: The first authentication server sends a login request verification success notification to the second authentication server.

[0082] Step 507: The second authentication server generates a ticket certificate for the target user.

[0083] Step 508: The second authentication server establishes a correspondence between the ticket credential of the target user and the permission information of the target user in each application system in the cache server.

[0084] Step 509: The second authentication server sends the ticket certificate to the API gateway device.

[0085] In step 510, the API gateway device returns the ticket certificate to the client as the access certificate for the target user to access various application systems.

[0086] After the client receives the target user's ticket certificate returned by the API gateway device, it can be used as the target user's access certificate to access various application systems. Specifically: when the target user wants to access an application system, the access certificate can be carried in the access request sent to the application system. After the application system receives the access request, it can parse the access certificate and verify its validity in the authentication service system. If the verification is successful, the user permission information corresponding to the ticket certificate is read from the cache database at the same time and returned to the application system, so that the application system can determine whether to return the requested resource to the client based on the user permission information.

[0087] Step 511: When the first authentication server receives the ticket credential to be verified sent by the application system, the first authentication server determines whether there is a ticket credential to be verified in the cache server.

[0088] The ticket voucher to be verified is obtained after the application system parses the resource access request received from the client. If yes, execute step 512.

[0089] In step 512, the first authentication server determines the user authority information corresponding to the ticket credential to be verified, and returns the user authority information corresponding to the ticket credential to be verified to the application system, so that the application system determines whether the user has the authority to access the resource based on the user authority information corresponding to the ticket credential to be verified. If so, access to the resource is allowed; if not, an access failure notification is returned to the client.

[0090] Figure 5 In the illustrated embodiment, after the target user's login request is successfully verified, that is, after it is determined that the target user has successfully logged in, the first authentication server uniformly authenticates the target user's permissions in each application system based on the user permission information database that includes the permission information of each user in each application system: the permission information of the target user in each application system is determined and stored in the cache server, and the second authentication server generates the access credentials for the target user to access each application system: the ticket credential, and establishes the ticket credential and permission information of the target user in the cache server. The above process does not require each application system to perform permission authentication based on the correspondence between users and permissions stored in its own local information base. Compared with the existing method that requires authentication based on multiple information bases, the permission authentication process in the embodiment of the present application is based on a single database, the user permission information database, so the cost of information maintenance is low.

[0091] In addition, when the application system receives a resource access request containing a ticket voucher from a client, it can directly send the ticket voucher to the authentication service system, which reads the user authority information corresponding to the ticket voucher from the cache server and returns it to the application system. The application system then determines whether the user has the right to access the resource based on the user authority information and performs the corresponding operation based on the judgment result. The application system does not need to perform user authority judgment based on its own stored information base, thus reducing the cost of maintaining the information base.

[0092] At the same time, the real-time user authority judgment of each application system is transferred to the authentication service system, which is pre-executed by the authentication service system, simplifying the operation of each application system and improving the efficiency of user resource access. In addition, since the authentication service system reads user authority information from the cache server, it is faster than each application system reading data from a relational database (information library) to judge user authority, which can further improve the efficiency of user resource access.

[0093] See also Figure 6 , Figure 6 This is a schematic diagram of the structure of the authentication service device provided in the third embodiment of the present application. The authentication service device is applied to the first authentication server in the authentication service system. The authentication service system also includes: a second authentication server. The authentication service device includes:

[0094] The login request receiving module 601 is used to receive the login request of the target user sent by the client and verify the login request;

[0095] The permission information cache module 602 is used to obtain the permission information of the target user in each application system from the user permission information database if the verification is successful, and store the permission information of the target user in each application system in the cache server; the user permission information database includes: the permission information of each user in each application system;

[0096] The notification sending module 603 is used to send a login request verification success notification to the second authentication server, so that the second authentication server generates a ticket certificate for the target user, and establishes a correspondence between the ticket certificate of the target user and the permission information of the target user in each application system in the cache server; and returns the ticket certificate to the client as the access credential for the target user to access each application system.

[0097] Optionally, the authentication service system further includes: an application program interface API gateway device;

[0098] The login request receiving module 601 is specifically used to receive a login request of a target user sent by the API gateway device; the login request is received by the API gateway device from the client and forwarded to the first authentication server.

[0099] Optionally, the device further comprises: a receipt module and a judgment module for receiving a ticket to be verified;

[0100] The to-be-verified ticket voucher receiving module is used to receive the to-be-verified ticket voucher sent by the application system; the to-be-verified ticket voucher is obtained after the application system parses the resource access request received from the client;

[0101] The judgment module is used to determine whether there is a ticket certificate to be verified in the cache server; if so, determine the user permission information corresponding to the ticket certificate to be verified, and return the user permission information corresponding to the ticket certificate to be verified to the application system, so that the application system can judge whether the user has the permission to access the resource based on the user permission information corresponding to the ticket certificate to be verified. If so, access to the resource is allowed; if not, an access failure notification is returned to the client.

[0102] This application Figure 6 The authentication service device of the illustrated embodiment is used to implement the corresponding authentication service method in the aforementioned method embodiment 1, and has the beneficial effects of the corresponding method embodiment, which will not be repeated here. In addition, the functional implementation of each module in the authentication service device of the embodiment of the present application can refer to the description of the corresponding part in the aforementioned method embodiment 1, which will not be repeated here.

[0103] See also Figure 7 , Figure 7 This is a structural diagram of an authentication service device provided in Embodiment 4 of the present application. The authentication service device is applied to a second authentication server in an authentication service system. The authentication service system further includes: a first authentication server. The authentication service device includes:

[0104] Notification receiving module 701, used to receive a login request verification success notification sent by the first authentication server, where the login request verification success notification is sent by the first authentication server to the second authentication server when the first authentication server receives the login request of the target user sent by the client and verifies the login request successfully;

[0105] The ticket voucher generation module 702 is used to generate a ticket voucher for the target user, and establish a correspondence between the ticket voucher for the target user and the target user's permission information in each application system in the cache server; wherein the target user's permission information in each application system is obtained by the first authentication server from the user permission information database, and the permission information of the target user in each application system is stored in the cache server; the user permission information database includes: the permission information of each user in each application system;

[0106] The ticket certificate returning module 703 is used to return the ticket certificate to the client as the access certificate for the target user to access various application systems.

[0107] This application Figure 7 The authentication service device of the illustrated embodiment is used to implement the corresponding authentication service method in the aforementioned method embodiment 2, and has the beneficial effects of the corresponding method embodiment, which will not be repeated here. In addition, the functional implementation of each module in the authentication service device of the embodiment of the present application can refer to the description of the corresponding part in the aforementioned method embodiment 2, which will not be repeated here.

[0108] See also Figure 8 , Figure 8 A schematic diagram of the structure of a server provided in Embodiment 5 of the present application: The server may include:

[0109] One or more processors 801;

[0110] The computer readable medium 802 may be configured to store one or more programs,

[0111] When one or more programs are executed by one or more processors, the one or more processors implement the authentication service method of the first or second embodiment described above.

[0112] Fig. 9 The hardware structure of the server in the fifth embodiment of the present application; Fig. 9 As shown, the hardware structure of the server may include: a processor 901, a communication interface 902, a computer readable medium 903 and a communication bus 904;

[0113] The processor 901, the communication interface 902, and the computer readable medium 903 communicate with each other via a communication bus 904;

[0114] Optionally, the communication interface 902 may be an interface of a communication module, such as an interface of a GSM module;

[0115] The processor 901 may be specifically configured to: receive a login request of a target user sent by a client, and verify the login request based on a user login information database; if the verification is successful, obtain the target user's permission information in each application system from a user permission information database, and store the target user's permission information in each application system in a cache server; the user permission information database includes: permission information of each user in each application system; send a login request verification success notification to a second authentication server, so that the second authentication server generates a ticket voucher for the target user, and establish a corresponding relationship between the ticket voucher of the target user and the permission information of the target user in each application system in the cache server; return the ticket voucher to the client as an access credential for the target user to access each application system; or, the processor 901 may be configured to: The body can also be configured as: a login request receiving module, which is used to receive the login request of the target user sent by the client and verify the login request; a permission information caching module, which is used to obtain the permission information of the target user in each application system from the user permission information database if the verification is successful, and store the permission information of the target user in each application system in the cache server; the user permission information database includes: the permission information of each user in each application system; a notification sending module, which is used to send a login request verification success notification to the second authentication server, so that the second authentication server generates a ticket certificate for the target user, and establishes a corresponding relationship between the ticket certificate of the target user and the permission information of the target user in each application system in the cache server; and returns the ticket certificate to the client as the access credential for the target user to access each application system.

[0116] The processor 901 may be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it may also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiments of the present application may be implemented or executed. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc.

[0117] The computer readable medium 903 can be, but is not limited to, a random access memory medium (Random Access Memory, RAM), a read-only memory medium (Read Only Memory, ROM), a programmable read-only memory medium (Programmable Read-Only Memory, PROM), an erasable read-only memory medium (Erasable Programmable Read-Only Memory, EPROM), an electrically erasable read-only memory medium (Electric Erasable Programmable Read-Only Memory, EEPROM), etc.

[0118] 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 program code configured to execute the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through a communication part, and / or installed from a removable medium. When the computer program is executed by a central processing unit (CPU), the above functions defined in the method of the present application are executed. It should be noted that the computer-readable medium 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 medium can be, for example, but not limited to, a system, device or device of electricity, magnetism, light, electromagnetic, infrared, or semiconductor, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to, an electrical connection with one or more conductors, a portable computer disk, a hard disk, a random access storage medium (RAM), a read-only storage medium (ROM), an erasable programmable read-only storage medium (EPROM or flash memory), an optical fiber, a portable compact disk read-only storage medium (CD-ROM), an optical storage medium, a magnetic storage medium, or any suitable combination of the above. In the present application, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, an apparatus or a device. 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, in which a computer-readable program code is carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, 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 configured to be used by or in combination with an instruction execution system, an apparatus or a device. The program code embodied on the computer readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.

[0119] Computer program code configured to perform the operations of the present application may be written in one or more programming languages ​​or a combination thereof, including object-oriented programming languages ​​such as Java, Smalltalk, C++, and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0120] 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. In this regard, each box in the flowchart or block diagram can represent a module, a program segment, or a part of a code, and the module, program segment, or a part of the code contains one or more executable instructions configured to implement the specified logical function. There are specific sequential relationships in the above-mentioned specific embodiments, but these sequential relationships are only exemplary. When the specific implementation is implemented, these steps may be less, more, or the execution order may be adjusted. That is, in some implementations as replacements, 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 and / or flowchart, and the combination of boxes in the block diagram and / 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.

[0121] The modules involved in the embodiments of the present application may be implemented in software or hardware. The modules described may also be set in a processor. For example, they may be described as: a processor including a login request receiving module, a permission information caching module, and a notification sending module; or, a processor including a notification receiving module, a ticket voucher generating module, and a ticket voucher returning module. The names of these modules do not, in some cases, constitute limitations on the modules themselves. For example, the login request receiving module may also be described as a "module that receives a login request from a target user sent by a client and verifies the login request."

[0122] As another aspect, the present application further provides a computer-readable medium on which a computer program is stored. When the program is executed by a processor, the authentication service method described in the above-mentioned embodiment 1 or embodiment 2 is implemented.

[0123] As another aspect, the present application also provides a computer-readable medium, which may be included in the device described in the above embodiment; or it may exist independently without being assembled into the device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by the device, the device: receives a login request of the target user sent by the client, and verifies the login request based on the user login information database; if the verification is successful, obtains the target user's permission information in each application system from the user permission information database, and stores the target user's permission information in each application system in the cache server; the user permission information database includes: the permission information of each user in each application system; sends a login request verification success notification to the second authentication server, so that the second authentication server generates a ticket voucher for the target user, and establishes a corresponding relationship between the ticket voucher of the target user and the permission information of the target user in each application system in the cache server; returns the ticket voucher to the client as the access credential for the target user to access each application system. Alternatively, the device is configured to: receive a login request verification success notification sent by the first authentication server, where the first authentication server receives the login request of the target user sent by the client, and sends it to the second authentication server when the login request is successfully verified based on the user login information database; generate a ticket credential for the target user, and establish a correspondence between the ticket credential of the target user and the permission information of the target user in each application system in the cache server; wherein the permission information of the target user in each application system is obtained by the first authentication server from the user permission information database, and the permission information of the target user in each application system is stored in the cache server; the user permission information database includes: the permission information of each user in each application system; and return the ticket credential to the client as the access credential for the target user to access each application system.

[0124] The expressions "first", "second", "the first" or "the second" used in various embodiments of the present disclosure may modify various components regardless of order and / or importance, but these expressions do not limit the corresponding components. The above expressions are only configured for the purpose of distinguishing an element from other elements. For example, a first user device and a second user device represent different user devices, although both are user devices. For example, a first element may be referred to as a second element, and similarly, a second element may be referred to as a first element without departing from the scope of the present disclosure.

[0125] When one element (e.g., a first element) is referred to as being "(operably or communicatively) coupled" or "(operably or communicatively) coupled to" or "connected to" another element (e.g., a second element), it is understood that the one element is directly connected to the other element or the one element is indirectly connected to the other element via yet another element (e.g., a third element). Conversely, it is understood that when an element (e.g., a first element) is referred to as being "directly connected" or "directly coupled" to another element (the second element), no element (e.g., a third element) is interposed between the two.

[0126] The above description is only a preferred embodiment of the present application and an explanation of the technical principles used. Those skilled in the art should understand that the scope of the invention involved in the present application is not limited to the technical solution formed by a specific combination of the above technical features, but should also cover other technical solutions formed by any combination of the above technical features or their equivalent features without departing from the above invention concept. For example, the above features are replaced with the technical features with similar functions disclosed in this application (but not limited to) by each other to form a technical solution.

Claims

1. An authentication service method, It is characterized in that The method is applied to a first authentication server in an authentication service system, wherein the authentication service system further comprises: a second authentication server, and the method comprises: Receive a login request from a target user sent by a client, and verify the login request based on a user login information database; If the verification is successful, the target user's permission information in each application system is obtained from the user permission information database, and the permission information of the target user in each application system is stored in the cache server; the user permission information database includes: the permission information of each user in each application system; Sending a login request verification success notification to the second authentication server, so that the second authentication server generates a ticket credential of the target user, and establishes a correspondence between the ticket credential of the target user and the permission information of the target user in each application system in the cache server, and returns the ticket credential to the client as the access credential of the target user when accessing each application system; Receiving a to-be-verified ticket certificate sent by an application system; the to-be-verified ticket certificate is obtained after the application system parses a resource access request received from a client, and the resource access request includes the ticket certificate; Determine whether the ticket credential to be verified exists in the cache server; if so, determine the user permission information corresponding to the ticket credential to be verified, and return the user permission information corresponding to the ticket credential to be verified to the application system, so that the application system determines whether the user has the permission to access the resource based on the user permission information corresponding to the ticket credential to be verified. If so, allow access to the resource; if not, return an access failure notification to the client.

2. The method according to claim 1, It is characterized in that The authentication service system also includes: an application program interface API gateway device; The receiving a login request of a target user sent by a client comprises: Receive a login request of a target user sent by the API gateway device; the login request is received by the API gateway device from the client and forwarded to the first authentication server.

3. An authentication service method, It is characterized in that A second authentication server applied to an authentication service system, the authentication service system further comprising: a first authentication server, the method comprising: receiving a login request verification success notification sent by the first authentication server, wherein the login request verification success notification is sent by the first authentication server to the second authentication server when the first authentication server receives a login request of a target user sent by a client and verifies the login request successfully based on a user login information database; Generate a ticket credential of the target user, and establish a correspondence between the ticket credential of the target user and the permission information of the target user in each application system in the cache server; wherein the permission information of the target user in each application system is obtained by the first authentication server from a user permission information database, and the permission information of the target user in each application system is stored in the cache server; the user permission information database includes: the permission information of each user in each application system; Returning the ticket certificate to the client as the access certificate for the target user to access various application systems; The first authentication server receives a to-be-verified ticket credential sent by the application system, wherein the to-be-verified ticket credential is obtained after the application system parses a resource access request received from the client, and the resource access request includes the ticket credential; The first authentication server determines whether there is a ticket credential to be verified in the cache server. If so, the first authentication server determines the user authority information corresponding to the ticket credential to be verified, and returns the user authority information corresponding to the ticket credential to be verified to the application system, so that the application system determines whether the user has the authority to access the resource based on the user authority information corresponding to the ticket credential to be verified. If so, access to the resource is allowed; if not, an access failure notification is returned to the client.

4. An authentication service device, It is characterized in that The first authentication server in the authentication service system is applied, and the authentication service system further includes: a second authentication server, and the device includes: A login request receiving module, used to receive a login request from a target user sent by a client, and verify the login request; The permission information cache module is used to obtain the target user's The target user's permission information in each application system is stored in the cache server; the user permission information database includes: the permission information of each user in each application system; a notification sending module, configured to send a login request verification success notification to the second authentication server, so that the second authentication server generates a ticket certificate of the target user, establishes a correspondence between the ticket certificate of the target user and the permission information of the target user in each application system in the cache server, and returns the ticket certificate to the client as an access credential for the target user to access each application system; The to-be-verified ticket voucher receiving module is used to receive the to-be-verified ticket voucher sent by the application system; the to-be-verified ticket voucher is obtained after the application system parses the resource access request received from the client, and the resource access request includes the ticket voucher; The judgment module is used to determine whether there is a ticket certificate to be verified in the cache server; if so, determine the user permission information corresponding to the ticket certificate to be verified, and return the user permission information corresponding to the ticket certificate to be verified to the application system, so that the application system can judge whether the user has the permission to access the resource based on the user permission information corresponding to the ticket certificate to be verified. If so, access to the resource is allowed; if not, an access failure notification is returned to the client.

5. An authentication service device, It is characterized in that A second authentication server applied to an authentication service system, the authentication service system further comprising: a first authentication server, the device comprising: a notification receiving module, configured to receive a login request verification success notification sent by the first authentication server, wherein the login request verification success notification is sent by the first authentication server to the second authentication server when the first authentication server receives a login request of a target user sent by a client and verifies the login request successfully; a ticket voucher generation module, used to generate the ticket voucher of the target user, and establish a correspondence between the ticket voucher of the target user and the permission information of the target user in each application system in the cache server; wherein the permission information of the target user in each application system is obtained by the first authentication server from the user permission information database, and the permission information of the target user in each application system is stored in the cache server; the user permission information database includes: the permission information of each user in each application system; A ticket certificate returning module, used to return the ticket certificate to the client as an access credential for the target user to access various application systems; The first authentication server includes a to-be-verified ticket credential receiving module, which is used to receive the to-be-verified ticket credential sent by the application system; the to-be-verified ticket credential is obtained after the application system parses the resource access request received from the client, and the resource access request includes the ticket credential; The first authentication server also includes a judgment module for determining whether there is a ticket credential to be verified in the cache server; if so, determining the user permission information corresponding to the ticket credential to be verified, and returning the user permission information corresponding to the ticket credential to be verified to the application system, so that the application system determines whether the user has the permission to access the resource based on the user permission information corresponding to the ticket credential to be verified. If so, access to the resource is allowed; if not, an access failure notification is returned to the client.

6. A server, characterized in that: include: A processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface communicate with each other via the communication bus; The memory is used to store at least one executable instruction, and the executable instruction enables the processor to perform an operation corresponding to the authentication service method according to any one of claims 1-2.

7. A server, characterized in that: include: A processor, a memory, a communication interface and a communication bus, wherein the processor, the memory and the communication interface communicate with each other via the communication bus; The memory is used to store at least one executable instruction, and the executable instruction enables the processor to perform operations corresponding to the authentication service method as described in claim 3.

8. An authentication service system, It is characterized in that include: The server according to claim 6 and the server according to claim 7.

9. The system according to claim 8, It is characterized in that Also includes: API gateway device.