KEYCLOAK-15465 SAML Identity Broker - SP metadata writer always emits AttributeConsumingService isDefault attribute
The isDefault attribute is defined as optional, yet if it set to null Keycloak incorrectly emits the value isDefault="null".
This commit is contained in:
parent
10077b1efe
commit
3973d47bd4
1 changed files with 4 additions and 2 deletions
|
@ -351,7 +351,9 @@ public class SAMLMetadataWriter extends BaseWriter {
|
|||
StaxUtil.writeStartElement(writer, METADATA_PREFIX, JBossSAMLConstants.ATTRIBUTE_CONSUMING_SERVICE.get(),
|
||||
JBossSAMLURIConstants.METADATA_NSURI.get());
|
||||
|
||||
StaxUtil.writeAttribute(writer, JBossSAMLConstants.ISDEFAULT.get(), "" + attributeConsumer.isIsDefault());
|
||||
if (attributeConsumer.isIsDefault() != null)
|
||||
StaxUtil.writeAttribute(writer, JBossSAMLConstants.ISDEFAULT.get(), "" + attributeConsumer.isIsDefault());
|
||||
|
||||
StaxUtil.writeAttribute(writer, JBossSAMLConstants.INDEX.get(), "" + attributeConsumer.getIndex());
|
||||
|
||||
// Service Name
|
||||
|
|
Loading…
Reference in a new issue