Repository navigation
test(oidc-auth): port the OIDC authorization tests to testkit - #5787
Draft
matthewgrossman wants to merge 13 commits into
Draft
matthewgrossman wants to merge 13 commits into
matthewgrossman wants to merge 13 commits into
Conversation
|
Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually. Contributors can view more details about this message here. |
|
🌿 Preview your docs: https://nvidia-preview-pr-5787.docs.buildwithfern.com/openshell |
Member
Author
|
/ok to test c29be49 |
|
Label |
Member
Author
|
/ok to test 8b9ac69 |
Member
Author
|
/ok to test 6740fa3 |
Member
Author
|
/ok to test 82b5c06 |
This was referenced Nov 23, 2026
matthewgrossman
force-pushed
the
test/5731-port-oidc-auth-tests/matthewgrossman
branch
2 times, most recently
from
November 24, 2026 04:46
7ed684b to
84a2058
Compare
This was referenced Nov 24, 2026
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
…eflight Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
…file Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
… list Signed-off-by: Matthew Grossman <mgrossman@nvidia.com>
matthewgrossman
force-pushed
the
test/5731-port-oidc-auth-tests/matthewgrossman
branch
from
November 24, 2026 06:00
84a2058 to
1dc7b8b
Compare
matthewgrossman
changed the base branch from
main
to
test/5728-share-environment-helpers/matthewgrossman
November 24, 2026 06:00
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Port the OIDC tests in
e2e/rust/tests/oidc_pkce.rsto 13 testkit tests intests/suites/features/oidc-auth. They run in a new<base>-oidctmachine environment that reuses the Keycloak setup.Related Issue
Closes #5731
Part of #5281
Stacked on #5780 (the
gateway_overridesrole, the environment contract table and the typedProfile/Credentialbuilders, for #5728). This PR targets #5780's branch; merge #5780 first.Changes
<base>-oidcenvironment (tests/tmachine): theoidc_gatewayrole applies anoidcoverride block throughgateway_overrides. It sets[openshell.gateway.oidc]to trust the Keycloak realm and sets[openshell.gateway.mtls_auth] operator_enabled = truein place ofenabled. It also re-signs testkit's client certificate as an operator (OU=operator), so testkit's own connection sets up and cleans up without signing in as a user. The suite's setup fails with a pointer to the role if the certificate signs in as a user.The block also sets
[openshell.gateway.tls]to the pathsgenerate-certswrites.config preflight(the unit's firstExecStartPre) acceptsoperator_enabledonly with an explicit client CA, and doesn't pick up the local TLS files the packaged gateway otherwise finds on its own.keycloak-support:User,Session(a signed-in user's SDK client and CLI),browser_login(the PKCE flow with a recordedxdg-open) and token-claim helpers. These are shaped so test(e2e): migrate the Python E2E suites to Rust #5624'soidc_authz.rscan move onto them.Cli::without_envandCli::in_workspace;Workspace::track_sandbox,track_providerandimport_profile.oidc-authsuite: 13 tests following the issue's mapping table. Per-user clients verify the gateway against its CA and send only a bearer token (no--gateway-insecure, no client certificate). Denials are checked by gRPC code and message. One CLI test checks the remediation command a workspace user sees.ubuntu-docker-rootful-oidcwithdeb. All 13 tests pass there, so the suite has notests/suites/unsupported.yamlentries. The test target isoidc-authwithharness = falseand atestkit::main()entry point.oidc_pkce.rskeeps only the 4 tests decision D drops:admin_can_delete_workspace,second_workspace_user_cannot_read_first_users_workspace,workspace_admin_can_create_sandboxandworkspace_admin_can_delete_sandbox. Thee2e:oidc-pkcetasks stay.Notes for review:
role 'openshell-admin' required,not a member of workspace '<ws>', and so on).client_credentials_grantare left to test(e2e): migrate the Python E2E suites to Rust #5624.Testing
cargo clippy -D warningsandcargo fmtfor testkit,keycloak-supportand the features workspaceoidc_pkce.rscompiles clean of new warnings with--features e2e-oidc-pkceubuntu-docker-rootful-oidcCI row passesChecklist