Skip to content

Generate SP metadata without knowing IdP cert #336

@nwalters512

Description

@nwalters512

Is your feature request related to a problem? Please describe.

I use the MultiSamlStrategy Passport strategy. I'd like to provide metadata URLs to our IdPs, which I can build with MultiSamlStrategy#generateServiceProviderMetadata.

This works fine if I know the IdP's cert and can have getSamlOptions return an option object with cert. However, during initial setup, I may not immediately know the IdP's certificate. I should still be able to generate metadata for them, as (as far as I know) that metadata doesn't depend on their own certificate. However, if getSamlOptions returns cert: null (because I don't yet know it), the following assertion fails:

assertRequired(ctorOptions.cert, "cert is required");

Describe the solution you'd like

Since the XML metadata doesn't depend on the IdP's cert, I'd like to be able to generate it before I do in fact know their cert.

Describe alternatives you've considered

When someone asks for our metadata URL, I can of course say "no, you give me your metadata URL first so I can get your cert". However, it would be very nice to be able to always provide it first.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions