OAuth2ServerSettings

class OAuth2ServerSettings : OAuthServerSettings

OAuth2 server settings

Constructors

<init>

OAuth2ServerSettings(
    name: String,
    authorizeUrl: String,
    accessTokenUrl: String,
    requestMethod: HttpMethod = HttpMethod.Get,
    clientId: String,
    clientSecret: String,
    defaultScopes: List<String> = emptyList(),
    accessTokenRequiresBasicAuth: Boolean = false,
    nonceManager: NonceManager = GenerateOnlyNonceManager,
    authorizeUrlInterceptor: URLBuilder.() -> Unit = {})
OAuth2ServerSettings(
    name: String,
    authorizeUrl: String,
    accessTokenUrl: String,
    requestMethod: HttpMethod = HttpMethod.Get,
    clientId: String,
    clientSecret: String,
    defaultScopes: List<String> = emptyList(),
    accessTokenRequiresBasicAuth: Boolean = false,
    stateProvider: OAuth2StateProvider,
    authorizeUrlInterceptor: URLBuilder.() -> Unit = {})

Properties

accessTokenRequiresBasicAuth

val accessTokenRequiresBasicAuth: Boolean

to send BASIC auth header when an access token is requested

accessTokenUrl

val accessTokenUrl: String

OAuth server access token request URL

authorizeUrl

val authorizeUrl: String

OAuth server authorization page URL

authorizeUrlInterceptor

val authorizeUrlInterceptor: URLBuilder.() -> Unit

an interceptor function to customize authorization URL

clientId

val clientId: String

client id parameter (provided by OAuth server vendor)

clientSecret

val clientSecret: String

client secret parameter (provided by OAuth server vendor)

defaultScopes

val defaultScopes: List<String>

OAuth scopes used by default

nonceManager

val nonceManager: NonceManager

to be used to produce and verify nonce values

requestMethod

val requestMethod: HttpMethod

HTTP request method to be used to acquire access token (see vendors documentation)

stateProvider

val stateProvider: OAuth2StateProvider

for backward compatibility, use nonceManager instead

Inherited Properties

name

val name: String

configuration name

version

val version: OAuthVersion

OAuth version (1a or 2)