This repository has been archived by the owner on Oct 29, 2024. It is now read-only.
forked from brokenhandsio/vapor-oauth
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Refactor DiscoveryDocument and OAuthDiscoveryDocument structs (#14)
- Loading branch information
Showing
3 changed files
with
121 additions
and
125 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,26 +1,42 @@ | ||
import Foundation | ||
|
||
public protocol DiscoveryDocument: Sendable { | ||
var issuer: String { get } | ||
var authorizationEndpoint: String { get } | ||
var tokenEndpoint: String { get } | ||
var issuer: String? { get } | ||
var authorizationEndpoint: String? { get } | ||
var tokenEndpoint: String? { get } | ||
var userInfoEndpoint: String? { get } | ||
var revocationEndpoint: String { get } | ||
var introspectionEndpoint: String { get } | ||
var jwksURI: String { get } | ||
var revocationEndpoint: String? { get } | ||
var introspectionEndpoint: String? { get } | ||
var jwksURI: String? { get } | ||
var registrationEndpoint: String? { get } | ||
var scopesSupported: [String]? { get } | ||
var responseTypesSupported: [String] { get } | ||
var responseTypesSupported: [String]? { get } | ||
var responseModesSupported: [String]? { get } | ||
var grantTypesSupported: [String]? { get } | ||
var acrValuesSupported: [String]? { get } | ||
var idTokenEncryptionAlgValuesSupported: [String]? { get } | ||
var idTokenEncryptionEncValuesSupported: [String]? { get } | ||
var userinfoSigningAlgValuesSupported: [String]? { get } | ||
var userinfoEncryptionAlgValuesSupported: [String]? { get } | ||
var userinfoEncryptionEncValuesSupported: [String]? { get } | ||
var requestObjectSigningAlgValuesSupported: [String]? { get } | ||
var requestObjectEncryptionAlgValuesSupported: [String]? { get } | ||
var requestObjectEncryptionEncValuesSupported: [String]? { get } | ||
var tokenEndpointAuthMethodsSupported: [String]? { get } | ||
var tokenEndpointAuthSigningAlgValuesSupported: [String]? { get } | ||
var displayValuesSupported: [String]? { get } | ||
var claimTypesSupported: [String]? { get } | ||
var claimsSupported: [String]? { get } | ||
var serviceDocumentation: String? { get } | ||
var claimsLocalesSupported: [String]? { get } | ||
var uiLocalesSupported: [String]? { get } | ||
var claimsParameterSupported: Bool? { get } | ||
var requestParameterSupported: Bool? { get } | ||
var requestUriParameterSupported: Bool? { get } | ||
var requireRequestUriRegistration: Bool? { get } | ||
var opPolicyURI: String? { get } | ||
var opTosURI: String? { get } | ||
var extend: [String: Any] { get set } | ||
var resourceServerRetriever: ResourceServerRetriever? { get } | ||
var subjectTypesSupported: [String] { get } | ||
var claimsSupported: [String]? { get } | ||
// Additional optional claims can be added here following the same pattern. | ||
} | ||
var subjectTypesSupported: [String]? { get } // Made optional to align with OAuthDiscoveryDocument | ||
} |
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