<https://javalin.io/tutorials/auth-example>
# javalin
j
The piece I was missing was this:
Copy code
private val Context.userRoles: Set<ApiRole>
    get() = this.basicAuthCredentials()?.let { (username, password) ->
        userRoleMap[Pair(username, password)] ?: setOf()
    } ?: setOf()
This is helpful do you know if there are plans to build out Javalin extension for things like OAuth, SSO etc. so that consumers don’t need to implement this functionality?
t
no plans
i actively want to avoid responsibility for security
someone has published a jwt thing though
j
Thanks for the info
t
you're very welcome