pomerium/authorize/evaluator
backport-actions-token[bot] 4e8c923ecd
add JWT timestamp formatting workaround (#4309)
add JWT timestamp formatting workaround (#4270)

Rego will sometimes serialize integers to JSON with a decimal point and
exponent. I don't completely understand this behavior.

Add a workaround to headers.rego to convert the JWT "iat" and "exp"
timestamps to a string and back to an integer. This appears to cause
Rego to serialize these values as plain integers.

Add a unit test to verify this behavior. Also add a unit test that will
fail if the Rego behavior changes, making this workaround unnecessary.

Co-authored-by: Kenneth Jenkins <51246568+kenjenkins@users.noreply.github.com>
2023-06-16 17:28:01 -07:00
..
opa add JWT timestamp formatting workaround (#4309) 2023-06-16 17:28:01 -07:00
config.go options: support multiple signing keys (#3828) 2022-12-22 09:31:09 -07:00
evaluator.go Merge pull request from GHSA-pvrc-wvj2-f59p 2023-05-26 13:34:21 -07:00
evaluator_test.go config: remove source, remove deadcode, fix linting issues (#4118) 2023-04-21 17:25:11 -06:00
functions.go upgrade to golang-lru v2 (#3771) 2022-12-02 09:25:52 -07:00
functions_test.go feature/databroker: user data and session refactor project (#926) 2020-06-19 07:52:44 -06:00
google_cloud_serverless.go config: remove source, remove deadcode, fix linting issues (#4118) 2023-04-21 17:25:11 -06:00
google_cloud_serverless_test.go authorize: move headers and jwt signing to rego (#1856) 2021-02-08 10:53:21 -07:00
headers_evaluator.go authorize: populate issuer even when policy is nil (#4213) 2023-05-31 08:59:19 -07:00
headers_evaluator_test.go add JWT timestamp formatting workaround (#4309) 2023-06-16 17:28:01 -07:00
policy_evaluator.go keep trace span context (#3724) 2022-11-04 17:52:13 -04:00
policy_evaluator_test.go Merge pull request from GHSA-pvrc-wvj2-f59p 2023-05-26 13:34:21 -07:00