org.http4k.contract.security.providers.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of http4k-contract Show documentation
Show all versions of http4k-contract Show documentation
http4k typesafe HTTP contracts and OpenApi support
package org.http4k.contract.security
import org.http4k.core.Filter
import org.http4k.core.NoOp
import org.http4k.core.Uri
fun OAuthSecurity.Companion.googleCloudEndpoints(issuer: String, jwksUri: Uri, audiences: List) = ImplicitOAuthSecurity(
Uri.of(""),
emptyList(),
Filter.NoOp,
"googleCloudEndpointsOAuth",
null,
mapOf(
"x-google-issuer" to issuer,
"x-google-jwks_uri" to jwksUri.toString(),
"x-google-audiences" to audiences.joinToString(",")
)
)