You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Note, a group is external and can have only one alias:
# vault write identity/group name="test" type="external" policies="<VAULT_POLICY>"
Key Value
--- -----
id 4a25c087-e6b9-e04c-2eee-99834495e55f
name test
# vault write identity/group-alias name="test" \
mount_accessor=auth_jwt_ea4facf6 \
canonical_id="4a25c087-e6b9-e04c-2eee-99834495e55f"
Key Value
--- -----
canonical_id 4a25c087-e6b9-e04c-2eee-99834495e55f
id 7450a1a1-eae0-d8bc-2e82-0a6d3e078e0b
# vault write auth/test-jwt/login jwt=<FRESH_JWT>
Key Value
--- -----
token <TOKEN>
token_accessor <TOKEN_ACCESSOR>
token_duration 768h
token_renewable true
token_policies ["default"]
identity_policies ["<VAULT_POLICY>"]
policies ["default" "<VAULT_POLICY>"] !! Everything is OK, we've got a policy from the group-alias
token_meta_role auth-jwt
# vault login -method=oidc -path=test-oidc
Complete the login via your OIDC provider. Launching browser to:
...
Success! You are now authenticated. The token information displayed below
is already stored in the token helper. You do NOT need to run "vault login"
again. Future Vault requests will automatically use this token.
Key Value
--- -----
token <TOKEN>
token_accessor <TOKEN_ACCESSOR>
token_duration 768h
token_renewable true
token_policies ["default"]
identity_policies []
policies ["default"] !! Everything is OK, we have no group-alias bounded to the auth_oidc_4ac006ff accessor
token_meta_role auth-oidc
Rewrite the same alias with another mount_accessor:
# vault write identity/group-alias name="test" \
mount_accessor=auth_oidc_4ac006ff \
canonical_id="4a25c087-e6b9-e04c-2eee-99834495e55f"
Key Value
--- -----
canonical_id 4a25c087-e6b9-e04c-2eee-99834495e55f
id 7373e79e-0ae6-72a5-b7b5-1fd2823e46a0
Try to log in again:
# vault login -method=oidc -path=test-oidc
Complete the login via your OIDC provider. Launching browser to:
...
Success! You are now authenticated. The token information displayed below
is already stored in the token helper. You do NOT need to run "vault login"
again. Future Vault requests will automatically use this token.
Key Value
--- -----
token <TOKEN>
token_accessor <TOKEN_ACCESSOR>
token_duration 768h
token_renewable true
token_policies ["default"]
identity_policies ["<VAULT_POLICY>"]
policies ["default" "<VAULT_POLICY>"] !! Everything is OK, now we get the policy via the alias bounded to the OIDC accessor
token_meta_role auth-oidc
# vault write auth/test-jwt/login jwt=<FRESH_JWT>
Key Value
--- -----
token <TOKEN>
token_accessor <TOKEN_ACCESSOR>
token_duration 768h
token_renewable true
token_policies ["default"]
identity_policies ["<VAULT_POLICY>"]
policies ["default" "<VAULT_POLICY>"] NB!! Here is your policy, it should not be here because you have no alias with the auth_jwt_ea4facf6 accessor
token_meta_role auth-jwt
Now let's roll back changes for the test group-alias:
# vault write identity/group-alias name="test" \
mount_accessor=auth_jwt_ea4facf6 \
canonical_id="4a25c087-e6b9-e04c-2eee-99834495e55f"
Key Value
--- -----
canonical_id 4a25c087-e6b9-e04c-2eee-99834495e55f
id 008502d0-ed74-de12-a505-9f16c22a78fd
And log in again with OIDC method:
vault login -method=oidc -path=test-oidc
Complete the login via your OIDC provider. Launching browser to:
...
Success! You are now authenticated. The token information displayed below
is already stored in the token helper. You do NOT need to run "vault login"
again. Future Vault requests will automatically use this token.
Key Value
--- -----
token <TOKEN>
token_accessor <TOKEN_ACCESSOR>
token_duration 768h
token_renewable true
token_policies ["default"]
identity_policies ["<VAULT_POLICY>"]
policies ["default" "<VAULT_POLICY>"] !! Your policy is still here!
token_meta_role auth-oidc
The text was updated successfully, but these errors were encountered:
Vault version:
1.4.3
IdP:
Keycloak 10.0.2
Minimal reproducible scenario:
Note, a group is external and can have only one alias:
Rewrite the same alias with another mount_accessor:
Try to log in again:
Now let's roll back changes for the test group-alias:
And log in again with OIDC method:
The text was updated successfully, but these errors were encountered: