Ricardo
08/12/2019, 11:41 AMdave
08/12/2019, 12:36 PMRicardo
08/12/2019, 2:10 PMOAuthSecurity
because Google Cloud Endpoint delegates actual authentication to a proxy. I think OAuthSecurity
requires a provider, but we don't.OAuthSecurity
and make the provider optional?SecurityRenderer
. Not sure if this was deliberate?dave
08/12/2019, 2:29 PMdata class OAuthSecurity(
val authorizationUrl: Uri,
val tokenUrl: Uri,
val scopes: List<OAuthScope> = emptyList(),
override val filter: Filter,
val name: String = "oauthSecurity"
) : Security {
companion object {
operator fun invoke(oAuthProvider: OAuthProvider,
customScopes: List<OAuthScope>? = null) = OAuthSecurity(
oAuthProvider.providerConfig.authUri,
oAuthProvider.providerConfig.tokenUri,
customScopes ?: oAuthProvider.scopes.map { OAuthScope(it, "") },
oAuthProvider.authFilter
)
}
}
Ricardo
08/12/2019, 3:58 PMOAuthSecurity
in that case with the new values as optional and add it to the SecurityRenderer
.