Skip to content

Commit 8780b4c

Browse files
Add /.well-known/oauth-authorization-server
1 parent cc050b4 commit 8780b4c

File tree

2 files changed

+12
-8
lines changed

2 files changed

+12
-8
lines changed

src/main/java/com/authlete/jaxrs/server/api/ConfigurationEndpoint.java

Lines changed: 11 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (C) 2016-2022 Authlete, Inc.
2+
* Copyright (C) 2016-2024 Authlete, Inc.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -32,16 +32,16 @@
3232
*
3333
* <p>
3434
* An OpenID Provider that supports <a href=
35-
* "http://openid.net/specs/openid-connect-discovery-1_0.html">OpenID Connect
35+
* "https://openid.net/specs/openid-connect-discovery-1_0.html">OpenID Connect
3636
* Discovery 1.0</a> must provide an endpoint that returns its configuration
3737
* information in a JSON format. Details about the format are described in
38-
* "<a href="http://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata"
38+
* "<a href="https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata"
3939
* >3. OpenID Provider Metadata</a>" in OpenID Connect Discovery 1.0.
4040
* </p>
4141
*
4242
* <p>
4343
* Note that the URI of an OpenID Provider configuration endpoint is defined in
44-
* "<a href="http://openid.net/specs/openid-connect-discovery-1_0.html#ProviderConfigurationRequest"
44+
* "<a href="https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderConfigurationRequest"
4545
* >4.1. OpenID Provider Configuration Request</a>" in OpenID Connect Discovery
4646
* 1.0. In short, the URI must be:
4747
* </p>
@@ -53,9 +53,9 @@
5353
* <p>
5454
* <i>Issuer Identifier</i> is a URL to identify an OpenID Provider. For example,
5555
* {@code https://example.com}. For details about Issuer Identifier, See <b>{@code issuer}</b>
56-
* in "<a href="http://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata"
56+
* in "<a href="https://openid.net/specs/openid-connect-discovery-1_0.html#ProviderMetadata"
5757
* >3. OpenID Provider Metadata</a>" (OpenID Connect Discovery 1.0) and <b>{@code iss}</b> in
58-
* "<a href="http://openid.net/specs/openid-connect-core-1_0.html#IDToken">2. ID Token</a>"
58+
* "<a href="https://openid.net/specs/openid-connect-core-1_0.html#IDToken">2. ID Token</a>"
5959
* (OpenID Connect Core 1.0).
6060
* </p>
6161
*
@@ -66,12 +66,15 @@
6666
* use, so you should change it.
6767
* </p>
6868
*
69-
* @see <a href="http://openid.net/specs/openid-connect-discovery-1_0.html"
69+
* @see <a href="https://openid.net/specs/openid-connect-discovery-1_0.html"
7070
* >OpenID Connect Discovery 1.0</a>
7171
*
72+
* @see <a href="https://www.rfc-editor.org/rfc/rfc8414.html"
73+
* >RFC 8414 OAuth 2.0 Authorization Server Metadata</a>
74+
*
7275
* @author Takahiko Kawasaki
7376
*/
74-
@Path("/.well-known/openid-configuration")
77+
@Path("/.well-known/{path : openid-configuration|oauth-authorization-server}")
7578
public class ConfigurationEndpoint extends BaseConfigurationEndpoint
7679
{
7780
/**

src/main/webapp/WEB-INF/web.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@
8787
<filter-mapping>
8888
<filter-name>API</filter-name>
8989
<url-pattern>/api/*</url-pattern>
90+
<url-pattern>/.well-known/oauth-authorization-server</url-pattern>
9091
<url-pattern>/.well-known/openid-configuration</url-pattern>
9192
<url-pattern>/.well-known/openid-credential-issuer</url-pattern>
9293
<url-pattern>/.well-known/openid-federation</url-pattern>

0 commit comments

Comments
 (0)