-
Notifications
You must be signed in to change notification settings - Fork 6.1k
How to Add a Signature to Service Provider Metadata #13661
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
I am able to add signature , so closing this open issue . |
@sumeetpri, that is great news. Can you please share how you added the signature? We are facing the same problem and adding the signature does not seem to be trivial. |
Regarding to Signing with OpenSAML, we need 3 steps to The default metadata resolver of Spring Security SAML2 org.springframework.security.saml2.provider.service.metadata.OpenSamlMetadataResolver is missing the action at step 3 (calling Signer.signObject) so the final hash will not be computed properly although we did set a valid Signature object. Line 215 in e92dd02
The below is 3 steps based on the source of Spring Security 6.2.2 Step 1. Create a Signature Line 96 in e92dd02
Step 2. Add Signature to EntityDescriptor of SP Provider
Step 3. Call Signer.signObject to compute the final hash
This is the sample demonstrating how to custom it
|
I'm currently in the process of migrating my application's authentication from Spring Security SAML Extension to Spring Security SAML. I'm using the service provider metadata to register my application with the Identity Provider (IDP). I've managed to generate the metadata for the service provider, but I'm struggling to figure out how to sign the metadata details.
In the previously generated service provider metadata, you can see the presence of the
<ds:Signature></ds:Signature>
section, which was automatically generated by Spring Security SAML Extension. However, in my migration to Spring Security SAML, I haven't found an implementation for signing the metadata in theOpenSamlMetadataResolver
.Here's a snippet of my code:
The service provider metadata generated by Spring Security SAML Extension includes a
<ds:Signature>
section as follows:My question is, how can I achieve the same feature of generating and adding the
<ds:Signature>
section in the service provider metadata using Spring Security SAML?I've already reviewed the
OpenSamlMetadataResolver
implementation, but I couldn't find a built-in way to sign the metadata. Any guidance or code examples on how to achieve this would be greatly appreciated.The text was updated successfully, but these errors were encountered: