Skip to content

Commit

Permalink
fix: Specify a validation function to fix authentication
Browse files Browse the repository at this point in the history
  • Loading branch information
oSumAtrIX committed Sep 29, 2024
1 parent 8b17d88 commit 53c3600
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,9 @@ internal class AuthenticationService private constructor(
fun AuthenticationConfig.jwt() {
jwt("jwt") {
realm = "ReVanced"

verifier(JWT.require(Algorithm.HMAC256(jwtSecret)).withIssuer(issuer).build())
// This is required and not optional. Authentication will fail if this is not present.
validate { JWTPrincipal(it.payload) }
}
}

Expand Down

0 comments on commit 53c3600

Please sign in to comment.