8000 Experimental SPIFFE identity provider by stianst · Pull Request #42314 · keycloak/keycloak · GitHub
[go: up one dir, main page]

Skip to content

Experimental SPIFFE identity provider - #42314

Merged
stianst merged 1 commit into
keycloak:mainfrom
stianst:spiffe-idp
Sep 4, 2025
Merged

stianst merged 1 commit into
keycloak:mainfrom
stianst:spiffe-idp

Conversation

@stianst
@stianst stianst commented Sep 3, 2025
Copy link
Copy Markdown
Contributor

Closes #42313

Signed-off-by: stianst stianst@gmail.com

@stianst
stianst marked this pull request as ready for review September 3, 2025 13:47
@stianst
stianst requested a review from a team as a code owner September 3, 2025 13:47
pedroigor
pedroigor previously approved these changes Sep 3, 2025
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The idea you proposed around separating the different aspects of the trust relationship with an identity provider should make this provider a lot simpler given that we won't need to override a lot of the methods here, right?

It should avoid decoupling the different types of providers and avoid, for instance, having spifee as an OAuth2-based broker. Or is that the case?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, so SPIFFE should only implement the methods for client assertions and nothing else. Basically move all methods from IdentityProvider to UserIdentityProvider or somethi 8000 ng like that. We also need to figure out something around configuration as there's a ton of config options only applicable to user federation, but that are part of the core IdP model stuff.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 for that. For token-exchange, we already have interfaces like for example ExchangeExternalToken if IDPs supports external-internal token exchange etc.

For the configuration, we use inheritance right now (EG. OIDCIdentityProviderConfig extends from OAuth2IdentityProviderConfig ), but maybe we can use a bit different approach, which may allow that some IDP requires multiple "kinds" of configurations (EG. if it supports for example both user-authentication as well as ClientAssertions)

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll create a follow-up issue for this; for now made a note here #42230

Closes keycloak#42313

Signed-off-by: stianst <stianst@gmail.com>
return Algorithm.ES512;
}
}
case KeyType.RSA:
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is probably similar that for KeyType.OKP , the Algorithm is EdDSA . But possibly this case could added/tested as a follow-up though... I can do that in the follow-up as I am looking at some DPoP related task, which is related: #42286

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup, I think we can extend on this quite a bit, but probably easier just as follow-ups when needed

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1 for that. For token-exchange, we already have interfaces like for example ExchangeExternalToken if IDPs supports external-internal token exchange etc.

For the configuration, we use inheritance right now (EG. OIDCIdentityProviderConfig extends from OAuth2IdentityProviderConfig ), but maybe we can use a bit different approach, which may allow that some IDP requires multiple "kinds" of configurations (EG. if it supports for example both user-authentication as well as ClientAssertions)

@stianst
stianst merged commit 320ea5a into keycloak:main Sep 4, 2025
@stianst
stianst deleted the spiffe-idp branch September 4, 2025 12:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Experimental SPIFFE identity provider

3 participants

0