-
Notifications
You must be signed in to change notification settings - Fork 2.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #37257 from sberyozkin/oidc_request_filter_type
Allow restricting OidcRequestFilters to specific OIDC endpoints
- Loading branch information
Showing
16 changed files
with
286 additions
and
56 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
52 changes: 52 additions & 0 deletions
52
extensions/oidc-common/runtime/src/main/java/io/quarkus/oidc/common/OidcEndpoint.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
package io.quarkus.oidc.common; | ||
|
||
import static java.lang.annotation.ElementType.TYPE; | ||
import static java.lang.annotation.RetentionPolicy.RUNTIME; | ||
|
||
import java.lang.annotation.Retention; | ||
import java.lang.annotation.Target; | ||
|
||
/** | ||
* Annotation that can be used to restrict {@link OidcRequestFilter} to specific OIDC endpoints | ||
*/ | ||
@Target({ TYPE }) | ||
@Retention(RUNTIME) | ||
public @interface OidcEndpoint { | ||
|
||
enum Type { | ||
ALL, | ||
|
||
/** | ||
* Applies to OIDC discovery requests | ||
*/ | ||
DISCOVERY, | ||
|
||
/** | ||
* Applies to OIDC token endpoint requests | ||
*/ | ||
TOKEN, | ||
|
||
/** | ||
* Applies to OIDC token revocation endpoint requests | ||
*/ | ||
TOKEN_REVOCATION, | ||
|
||
/** | ||
* Applies to OIDC token introspection requests | ||
*/ | ||
INTROSPECTION, | ||
/** | ||
* Applies to OIDC JSON Web Key Set endpoint requests | ||
*/ | ||
JWKS, | ||
/** | ||
* Applies to OIDC UserInfo endpoint requests | ||
*/ | ||
USERINFO | ||
} | ||
|
||
/** | ||
* Identifies an OIDC tenant to which a given feature applies. | ||
*/ | ||
Type value() default Type.ALL; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.