Authentication federation server, authentication federation method, authentication federation system, and program
The authentication cooperation server addresses the limitations of existing authentication services by managing authentication information and tokens, enabling efficient and secure user terminal authentication with resource servers.
Patent Information
- Application Number
- JP2021013917
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Filing Date
- 2021-01-29
- Publication Date
- 2024-09-02
- Estimated Expiration
- 2041-01-29
AI Technical Summary
Existing authentication services like OpenID Connect may not meet the specific requirements of resource servers, necessitating additional functions for user terminal authentication.
An authentication cooperation server that transmits authentication information to an authentication server, receives tokens, issues and stores codes, and associates them with tokens, enabling seamless authentication and token management between user terminals and resource servers.
Provides necessary functions for user terminal authentication, allowing resource servers to utilize authentication services efficiently while managing tokens and codes, ensuring secure and efficient access.
Smart Images

Figure 0007543154000006 
Figure 0007543154000001 
Figure 0007543154000005
Abstract
Description
[Technical field]
[0001] The present invention relates to an authentication collaboration server that cooperates with an authentication server to provide a function for authenticating a user terminal. [Background technology]
[0002] In recent years, services that allow users to use various functions provided by server devices via a network from their user terminals have been widely deployed. In many cases, a server device providing a service (hereinafter, a resource server) requires authentication of a user using account information such as a user ID and a password when a user terminal requests access to a resource held by the resource server.
[0003] However, to perform user authentication, the resource server needs to prepare a server for authenticating users (hereafter referred to as authentication server) in addition to the services it provides. As a result, services that enable federated authentication using a user ID issued by an ID provider of a cloud service as the resource server's own user ID, such as OpenID Connect (OIDC), have been proposed and are already known. By using these authentication services, the resource server does not need to prepare its own authentication service, and can focus on developing its own services.
[0004] In the technology disclosed in Patent Document 1, authentication information is sent to an external authentication system, and if the authentication is successful, the authentication information is stored in association with address information. Then, when a response is received to a request to end use of an external service sent in response to an operation to end use of the external service on a specific screen, the first authentication information associated with the address information of the external service is deleted. [Prior art documents] [Patent documents]
[0005] [Patent Document 1] JP 2017-154492 A Summary of the Invention [Problem to be solved by the invention]
[0006] If the authentication service to be used provides an authentication federation function such as OpenID Connect, and functions such as a login screen required for authentication satisfy the requirements of a resource server, the authentication server can be used using the technology disclosed in Patent Document 1. However, depending on the requirements of the resource server, the authentication federation function of the authentication service may not be sufficient. The present invention has been made in view of the above problems, and aims to provide functions required for authentication of a user terminal in cooperation with an authentication server. [Means for solving the problem]
[0007] The present invention provides an authentication collaboration server that provides a resource server that provides a service to a user terminal with a function for authenticating the user terminal in collaboration with an authentication server, the authentication collaboration server comprising: authentication information transmission means for transmitting authentication information of the user terminal to the authentication server; token receiving means for receiving a token used by the user terminal to access the resource server from the authentication server; code issuing means for issuing a code for identifying a response of successful authentication and transmitting the code to the resource server; storage means for storing the code and the token in association with each other; and token sending means for sending the token corresponding to the code to the resource server when the code is sent from the resource server. Effect of the Invention
[0008] According to the present invention, it is possible to provide the functions required for authenticating a user terminal in cooperation with an authentication server. [Brief description of the drawings]
[0009] [Figure 1] FIG. 2 is a diagram illustrating a functional configuration according to the first embodiment. [Diagram 2]FIG. 2 is a diagram illustrating a hardware configuration according to the first embodiment. [Diagram 3] FIG. 4 is a sequence diagram of an authentication federation server according to the first embodiment. [Figure 4] FIG. 13 is a diagram illustrating claims included in an ID token in the first embodiment. [Diagram 5] 4 is a diagram illustrating an example of data stored in a storage unit according to the first embodiment. FIG. [Figure 6] FIG. 11 is a sequence diagram of an authentication federation server according to the second embodiment. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0010] (Embodiment 1) FIG. 1 is a diagram showing a functional configuration of an authentication federation server in the first embodiment of the present invention. In the figure, 101 is an authentication federation server in this embodiment. 102 is an authentication server that manages IDs and performs authentication processing and token issuance processing. The authentication federation server 101 and the authentication server 102 work together to function as an authentication federation system. 103 is a user terminal used by a user. 104 is a resource server that provides a service that the user uses via the user terminal. The resource server 104 manages access to the user terminal 103 by using a token.
[0011] Reference numeral 105 denotes an authentication request receiving unit that causes the authentication federation server 101 to receive an authentication request from the resource server 104. Reference numeral 106 denotes an authentication screen processing unit that causes the authentication federation server 101 to provide an authentication screen to the user terminal 103 and process user authentication information input on the authentication screen. Reference numeral 107 denotes an authentication information transmitting unit that transmits the user authentication information passed from the authentication screen processing unit to the authentication server 102.
[0012] Reference numeral 108 denotes a token receiving unit that receives a token from the authentication server when authentication is successful. Reference numeral 109 denotes a code issuing unit that issues a code and transmits it to the resource server. Reference numeral 110 denotes a storage unit that associates the code and the token and stores them. Reference numeral 111 denotes a token request receiving unit that receives a token request. Reference numeral 112 denotes a token transmitting unit that transmits a token in response to the token request. Reference numeral 113 denotes a token updating unit that updates the token.
[0013] 2 is a diagram showing the hardware configuration of the authentication collaboration server in this embodiment. In the diagram, 201 is a CPU (Central Processing Unit) that executes a control program for the information processing device. 202 is a ROM that stores the control program and the like. 203 is a RAM that is used to provide a work area for the CPU 201. 204 is a network IF that communicates with applications outside the device. 205 is a storage device such as a hard disk that stores data.
[0014] FIG. 3 is a sequence diagram in which the authentication federation server in this embodiment receives a request from the resource server and performs authentication federation.
[0015] First, in step S301, the user accesses the resource server 104 from the user terminal 103. For example, when a specific URL is input from the browser of the user terminal, the resource server is accessed. At this time, the resource server 104 checks the login state of the user as the resource server. The login state is determined, for example, by whether or not there is a valid token in the cookie information of the browser corresponding to the domain of the resource server. If the resource server determines that the user is not in the login state, the resource server transitions to the authentication federation server 101 in step S302. The transition destination of the authentication federation server 101 corresponds to the authentication request receiving unit 105. In this embodiment, the authentication federation server 101 is described as providing an authentication federation function in accordance with OpenID Connect. In this case, the authentication request receiving unit 105 corresponds to an authorization endpoint included in the OpenID Connect specifications. At this time, as specifications for transitioning to the authorization endpoint, a client ID, a scope, a response type, a redirect URI, and the like are given to request parameters to the authorization endpoint. However, the present invention is not limited to this, and any specifications may be used as long as the transition destination of the authentication federation can be provided from the resource server.
[0016] Next, in step S303, the authentication screen processing unit 106 provides an authentication screen to the user terminal 103.
[0017] In step S304, the user inputs authentication information on the authentication screen. Typical authentication information is an ID and a password, but any information such as biometric authentication information may be used.
[0018] When the user inputs the authentication information, in step S305, the user terminal 103 transmits the authentication information to the authentication federation server 101. In the authentication federation server 101, the authentication information transmitting unit 107 transmits the authentication information to the authentication server 102 in step S306.
[0019] The authentication server 102 verifies the authentication information and performs authentication in step S307. If the authentication information does not match and authentication fails, a failure response is returned to the authentication federation server 101, and the authentication federation server 101 returns a failure response to the user terminal 103. The user terminal displays an error message indicating authentication failure on an authentication screen. On the other hand, if authentication is successful in the authentication server 102 in step S307, the authentication server issues a token in step S308 and returns the token to the authentication federation server 101 together with an authentication success response. The authentication federation server 101 receives the issued token at the token receiving unit 108. In this embodiment, the token issued here will be described as a pair of an ID token and a refresh token conforming to the OpenID Connect specification.
[0020] FIG. 4 is an example of a claim included in an ID token. iss is the issuer of the token and represents the authentication server 102. sub is a value that uniquely identifies the ID authenticated by the authentication server 102. aud represents the ID of the client to which the ID token is issued and corresponds to the resource server 104. iat represents the time when the ID token was issued. exp represents the validity period of the ID token. auth_time represents the time when the authentication server 102 performed authentication. preferred_username represents the username of the ID in the authentication information. email represents the email address linked to the authentication information. However, this is merely an example of a token, and the present invention is not limited to this.
[0021] Next, when the authentication federation server 101 receives the token and the authentication success response, in step S309, the code issuing unit 109 issues a code. The code may be any information such as a UUID as long as it is capable of identifying a response indicating successful authentication.
[0022] Next, in step S310, the storage unit 110 stores the code and the token in association with each other. FIG. 5 shows an example of a database in which the storage unit 110 stores the code and the token in association with each other. In the figure, 501 is a code. 502 is an ID token issued by the authentication server 102. 503 is a refresh token issued by the authentication server 102 together with the ID token. 504 is a client ID passed by the resource server 104 when transitioning to the authorization endpoint of the authentication federation server in step S302. 505 is a redirect URI passed by the resource server 104 when transitioning to the authorization endpoint of the authentication federation server in step S302, and is used for verifying request parameters at the token endpoint described later. 506 is the validity period of the code, and if a token request described later is received using a code that has exceeded this validity period, the request is invalidated.
[0023] However, the data stored in the storage unit 110 in the present invention is not limited to this, and the present invention can be applied as long as the code issued by the authentication collaboration server 101 and the token issued by the authentication server 102 are stored in association with each other.
[0024] One of the features of the present invention is that a token issued by an authentication server different from the authentication federation server 101 is received in step S309, and once associated with a code in step S310, the token is stored and used in steps described below.
[0025] Next, in step S311, the code issuing unit 109 transmits the issued code to the resource server 104. According to the authorization code flow of OpenID Connect, this code becomes the authorization code of the authorization endpoint. This corresponds to the transition to the authorization endpoint of the authentication collaboration server in step S302 by attaching the code to the redirect URI passed to the authorization endpoint.
[0026] Next, in step S312, the resource server 104 requests a token from the authentication federation server 101. The authentication federation server 101 receives this token request at the token request receiving unit 111. According to the authorization code flow of the OpenID Connect specification, this token request corresponds to requesting an ID token to the token endpoint using the authorization code issued at the authorization endpoint. In this case, authentication information for the client ID and a redirect URI specified when transitioning to the authorization endpoint are passed as request parameters. The token request receiving unit 111 verifies the request parameters of the token request. However, the present invention is not limited to the OpenID Connect specification.
[0027] If the token request receiving unit 111 determines that it is OK to return the token, in step S313, the token sending unit 112 obtains a token corresponding to the code included in the token request from the storage unit 110 and sends it to the resource server 104.
[0028] In step S314, the resource server 104 verifies whether the token received from the authentication federation server is an appropriate token issued by the authentication server 102. For example, if the token is an ID token, since it is a token in JWT (Json Web Token) format, the resource server 104 obtains a public key from the authentication server 102, verifies the signature of the token, and verifies whether the claim in Fig. 4 is appropriate.
[0029] If the token verification is successful, the resource server 104 manages the login state as a resource server and provides services to the user terminal 103 in step S315.
[0030] With the above configuration and sequence, the authentication federation server in this embodiment transmits authentication information from the authentication screen to the authentication server, and stores the token received when the authentication is successful in association with a code issued by the authentication federation server.
[0031] This makes it possible to provide an authentication federation function such as OpenID Connect and an authentication screen unique to the authentication federation server while utilizing the authentication function, token issuing function, and public key provision function required for token verification of the authentication server 102.
[0032] (Embodiment 2) In the first embodiment, the storage unit 110 stores the token issued by the authentication server in step S308 in association with the code, and when a token request is received from the resource server, the token transmission unit 112 transmits the stored token in step S313. Therefore, the token issuance time (iat claim) of the ID token shown in Fig. 4 is not strictly the time corresponding to step S313, but the time corresponding to step S308. In addition, the token expiration time (exp claim) is also determined from the time corresponding to step S308. Therefore, the difference in time between step S308 and step S313 may affect the processing on the resource server side and the strictness of the specifications.
[0033] The flow of this embodiment to solve this problem is shown in Fig. 6. Note that, while the type of token was arbitrary and the refresh token was not a mandatory component in the first embodiment, a refresh token is required in this embodiment.
[0034] In Fig. 6, steps S301 to S307 are the same as the flow in Fig. 3 of embodiment 1. When the authentication server 102 authenticates in step S307, it issues a token and a refresh token in step S601. In the authentication collaboration server 101, the code issuing unit 109 issues a code in step S309, as in the above embodiment.
[0035] Next, in step S602, the storage unit 110 stores the code and the refresh token in association with each other. At this time, the token issued by the authentication server 102 in step S601 may be stored, or in this embodiment, may be discarded without being stored. It is sufficient that the refresh token is stored together with the code.
[0036] Steps S311 and S312 are the same as those in the first embodiment. When the token request receiving unit 111 receives the token request, the token updating unit 113 obtains a refresh token corresponding to the code from the storage unit 110, and transmits the refresh token to the authentication server 102 in step S603 to request a token update. In step S604, the authentication server 102 issues an updated token in response to the token update request. Then, in step S605, the token transmitting unit 112 transmits the updated token to the resource server 104. At this time, the refresh token used for token update may be provided to the resource server 104 together with the token.
[0037] Through the above sequence, the authentication federation server in this embodiment uses the refresh token issued in step S308 to update the token when receiving the token request in step S312. As a result, the token issue time and expiration date included in the token are set based on the time updated in step S604, so that a more appropriate time can be set for the token returned by the authentication federation server.
[0038] (Embodiment 3) In the first and second embodiments, the description is based on the authorization code flow of OpenID Connect, and the token issued by the authentication server 102 is also described as an ID token, but the present invention is not limited to this. For example, the token may be in a format other than an ID token, such as a simple UUID. In addition, the endpoint to which the authentication request receiving unit 105 transitions in step S302 may not conform to the authorization endpoint of OpenID Connect. In addition, the endpoint to which the token request receiving unit 111 receives in step S312 may not conform to the token endpoint of OpenID Connect. The token issued by the authentication server 102 may be stored in association with the code issued by the authentication collaboration server 101, and when the resource server requests a token using that code, the token associated with the code may be returned.
[0039] (Embodiment 4) In the first to third embodiments, there are three types of servers, the authentication federation server 101, the authentication server 102, and the resource server 104, but these are not necessarily configured as separate devices. For example, the authentication federation server 101 and the resource server 104 may be configured as the same device, and steps S302, S311, S312, and S313 may be communications between functions operating in the same device.
[0040] On the other hand, if the functions of the authentication federation server 101 and the authentication server 102 are configured in the same device, the token issuance in step S308 should not be performed immediately after the authentication in step S307, but should be performed immediately after step S312, thereby eliminating the need for the storage unit 110. In that case, it is preferable to configure the software of the authentication federation server 101 and the authentication server 102 to run in the same device.
[0041] (Other embodiments) The present invention can also be realized by a process in which a program for implementing one or more of the functions of the above-described embodiments is supplied to a system or device via a network or a storage medium, and one or more processors in a computer of the system or device read and execute the program. The present invention can also be realized by a circuit (e.g., ASIC) that implements one or more of the functions. [Explanation of symbols]
[0042] 101 Authentication server 102 Authentication Server 103 User terminal 104 Resource Server 105 Authentication request receiver 106 Authentication screen processing unit 107 Authentication information transmission unit 108 Token receiver 109 Code Issuance Department 110 Preservation Department 111 Token request receiver 112 Token sending unit 113 Token Update Unit
Claims
1. An authentication collaboration server that provides a resource server that provides a service to a user terminal with a function for authenticating the user terminal in collaboration with an authentication server, an authentication information transmitting means for transmitting authentication information of the user terminal to the authentication server; a token receiving means for receiving, from the authentication server, a token used for the user terminal to access the resource server; a code issuing means for issuing a code for identifying a response of successful authentication and transmitting the code to the resource server; A storage means for storing the code and the token in association with each other; a token transmitting means for transmitting the token corresponding to the code to the resource server when the code is transmitted from the resource server; An authentication collaboration server comprising:
2. 2. The authentication collaboration server according to claim 1, further comprising a processing unit that provides the user terminal with an authentication screen for inputting the authentication information at the user terminal.
3. The method further includes: receiving an authentication request from the resource server; The processing means provides the authentication screen based on the authentication request; The authentication collaboration server according to claim 2 , wherein the code issuing unit transmits the code to the resource server as a response to the authentication request.
4. 2 . The authentication collaboration server according to claim 1 , wherein the code issuing unit transmits the code in accordance with OpenID Connect, and the token transmitting unit transmits the token in accordance with OpenID Connect.
5. The authentication collaboration server according to claim 1 , wherein the token includes an ID token or a refresh token.
6. a token updating unit that transmits a request to the authentication server to update the token corresponding to the code and receives the updated token from the authentication server; 2 . The authentication collaboration server according to claim 1 , wherein the token transmission unit transmits the token updated by the token update unit to the resource server.
7. An authentication collaboration method for providing a resource server that provides a service to a user terminal with a function for authenticating the user terminal in collaboration with an authentication server, comprising: an authentication information transmission step of transmitting authentication information of the user terminal to the authentication server; a token receiving step of receiving, from the authentication server, a token used by the user terminal to access the resource server; a code issuing step of issuing a code for identifying a response in which authentication has been successfully performed and transmitting the code to the resource server; a storing step of storing the code and the token in association with each other; a token transmitting step of, when the code is transmitted from the resource server, transmitting the token corresponding to the code to the resource server; 13. An authentication collaboration method comprising:
8. Computer, An authentication collaboration server that provides a resource server that provides a service to a user terminal with a function for authenticating the user terminal in collaboration with an authentication server, an authentication information transmitting means for transmitting authentication information of the user terminal to the authentication server; a token receiving means for receiving, from the authentication server, a token used for the user terminal to access the resource server; a code issuing means for issuing a code for identifying a response of successful authentication and transmitting the code to the resource server; A storage means for storing the code and the token in association with each other; a token transmitting means for transmitting the token corresponding to the code to the resource server when the code is transmitted from the resource server; A program for causing an authentication federation server to function, comprising:
9. An authentication server; an authentication collaboration server that provides a resource server that provides a service to a user terminal with a function for authenticating the user terminal in collaboration with the authentication server, an authentication information transmitting means for transmitting authentication information of the user terminal to the authentication server; a token receiving means for receiving, from the authentication server, a token used for the user terminal to access the resource server; a code issuing means for issuing a code for identifying a response of successful authentication and transmitting the code to the resource server; A storage means for storing the code and the token in association with each other; a token transmitting means for transmitting the token corresponding to the code to the resource server when the code is transmitted from the resource server; and an authentication federation server comprising:
Citation Information
Patent Citations
Authority delegation system, method of controlling the same, authorization server, and program
JP2017027459A
Apparatus, authentication system, server device, and authentication method
JP2017154492A
Information processing system, information processing method, information processing apparatus, and program
JP2018018143A
API providing device and API usufruct transfer approval method
JP2018133022A
