Skip to content

Commit

Permalink
Check iss, iat & exp when validating JWT in OPA policy
Browse files Browse the repository at this point in the history
  • Loading branch information
garryod committed Apr 8, 2024
1 parent a5e6e50 commit 131ef26
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion policy/token.rego
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jwks := fetch_jwks(jwks_url).raw_body
valid := io.jwt.decode_verify(input.token, {
"cert": jwks,
"iss": "https://authn.diamond.ac.uk/realms/master",
"time": time.now_ns(),
"aud": "account",
})

claims := valid[2]

0 comments on commit 131ef26

Please sign in to comment.