Trong Huu Nguyen
66cf08e602
refactor(openid/logout): simplify logout logic
...
As we already clear any local sessions before redirecting to the
Identity Provider, and the callback always redirects to a pre-configured URL,
there isn't really any need to maintain and verify state in the logout
callback.
In other words, the logout callback handler is simply a redirect handler.
2022-07-12 15:09:49 +02:00
Trong Huu Nguyen
c321cff4eb
test(openid/client): add missing tests
2022-07-12 14:28:17 +02:00
Trong Huu Nguyen
42938ee8b3
refactor(handler): deduplicate configuration
2022-07-05 14:43:40 +02:00
Trong Huu Nguyen
a4c3e72fc9
fix(router/handler): use long-lived context for refreshing jwks
2022-07-05 13:18:38 +02:00
Trong Huu Nguyen
1f5635239a
refactor: split out openid client, config and provider
...
There's a bunch of changes here, but in essence:
- split out openid configuration
- separate openid configuration between client/rp and provider
- consolidate client and provider related code in separate packages
These changes allow for simplification of the Handler, as well as a
bunch of test/mock code as the configuration is now instantiated
seperately from the client/provider code.
2022-07-05 13:09:00 +02:00
Trong Huu Nguyen
10dddd00bc
refactor(router): begin extraction of openid client
2022-07-04 15:18:42 +02:00
Trong Huu Nguyen
32dd80b5da
feat: add handler for logout callbacks
2022-05-10 08:52:07 +02:00
Trong Huu Nguyen
18fffcc755
deps: migrate from lestrrat-go/jwx to lestrrat-go/jwx/v2
2022-05-05 11:09:03 +02:00
Trong Huu Nguyen
f0318b269e
fix: ensure jwk set is refreshed regularly
2022-03-01 07:49:51 +01:00
Trong Huu Nguyen
834c79ef1d
style: go fmt
2022-01-25 15:59:57 +01:00
Trong Huu Nguyen
b40dbffa19
refactor: clean up tests
...
Co-Authored-By: Youssef Bel Mekki <youssef.bel.mekki@nav.no >
2022-01-25 15:58:19 +01:00
Trong Huu Nguyen
24cae11ba2
refactor: split out session ID generation to own file, add tests
...
Co-Authored-By: Youssef Bel Mekki <youssef.bel.mekki@nav.no >
2022-01-25 15:33:45 +01:00
ybelMekk
abc8bd1835
fix: clean up tests and fix name
2022-01-25 12:08:42 +01:00
ybelMekk
768aa7af49
fix: test to only check for generated session_state, remove frontChannel from CheckIframe test.
2022-01-25 11:35:56 +01:00
ybelMekk
74c1592d0a
remove: unused function
2022-01-24 22:57:43 +01:00
ybelMekk
bc5f5138e4
add: handle trigger of logout for third-party and session_state
2022-01-24 22:44:45 +01:00
ybelMekk
e4c47f59e8
fix: create function for externalSessionId add random string generator. fix tests to reflect provider with checkSessionIframe Session management.
2022-01-23 21:37:36 +01:00
Trong Huu Nguyen
3a35584a21
refactor: restructure and group related packages into subpackages
2021-10-20 09:03:14 +02:00
Trong Huu Nguyen
be585f9902
refactor: simplify config for acr_values and ui_locales; validate on startup
2021-10-17 20:24:34 +02:00
Trong Huu Nguyen
e8e1fc7632
refactor: clean up tests and mock setup
2021-10-16 10:50:22 +02:00
Trong Huu Nguyen
77d0438411
feat: use latest go-chi v5, add middlewares for panic recovery and logging
...
Co-Authored-By: Sindre Rødseth Hansen <sindre.rodseth.hansen@nav.no >
2021-10-05 11:45:42 +02:00
Trong Huu Nguyen
70516c3efb
refactor: more cleanups; split up route handlers
2021-10-04 19:10:19 +02:00