samlify icon indicating copy to clipboard operation
samlify copied to clipboard

allowCreate attribute not set correctly

Open D-32 opened this issue 11 months ago • 2 comments

samlify.ServiceProvider({
	metadata: metadata,
	allowCreate: 'true',
})

If I don't set the allowCreate property the SAML request XML will have an empty attribute, which causes it to be invalid: <samlp:NameIDPolicy Format="urn:oasis:names:tc:SAML:1.1:nameid-format:unspecified" AllowCreate=""/>

If I set it to true (as a boolean) as specified in ServiceProviderSettings it crashes due to string.replace is not a function. Only if I set it to the string "true" does it work. So this is my workaround, but it's of course not ideal.

Thanks for all your work on this library @tngan 🙏

D-32 avatar Mar 11 '24 20:03 D-32