diff --git a/broker/saml/src/main/java/org/keycloak/broker/saml/SAMLIdentityProvider.java b/broker/saml/src/main/java/org/keycloak/broker/saml/SAMLIdentityProvider.java index c389b1df4a..8dc36a1193 100644 --- a/broker/saml/src/main/java/org/keycloak/broker/saml/SAMLIdentityProvider.java +++ b/broker/saml/src/main/java/org/keycloak/broker/saml/SAMLIdentityProvider.java @@ -199,7 +199,7 @@ public class SAMLIdentityProvider extends AbstractIdentityProvider keyDescriptor = idpDescriptor.getKeyDescriptor(); - String defaultPublicKey = null; + String defaultCertificate = null; if (keyDescriptor != null) { for (KeyDescriptorType keyDescriptorType : keyDescriptor) { @@ -91,22 +91,22 @@ public class SAMLIdentityProviderFactory extends AbstractIdentityProviderFactory Element x509KeyInfo = DocumentUtil.getChildElement(keyInfo, new QName("dsig", "X509Certificate")); if (KeyTypes.SIGNING.equals(keyDescriptorType.getUse())) { - samlIdentityProviderConfig.setSigningPublicKey(x509KeyInfo.getTextContent()); + samlIdentityProviderConfig.setSigningCertificate(x509KeyInfo.getTextContent()); } else if (KeyTypes.ENCRYPTION.equals(keyDescriptorType.getUse())) { samlIdentityProviderConfig.setEncryptionPublicKey(x509KeyInfo.getTextContent()); } else if (keyDescriptorType.getUse() == null) { - defaultPublicKey = x509KeyInfo.getTextContent(); + defaultCertificate = x509KeyInfo.getTextContent(); } } } - if (defaultPublicKey != null) { - if (samlIdentityProviderConfig.getSigningPublicKey() == null) { - samlIdentityProviderConfig.setSigningPublicKey(defaultPublicKey); + if (defaultCertificate != null) { + if (samlIdentityProviderConfig.getSigningCertificate() == null) { + samlIdentityProviderConfig.setSigningCertificate(defaultCertificate); } if (samlIdentityProviderConfig.getEncryptionPublicKey() == null) { - samlIdentityProviderConfig.setEncryptionPublicKey(defaultPublicKey); + samlIdentityProviderConfig.setEncryptionPublicKey(defaultCertificate); } } diff --git a/forms/common-themes/src/main/resources/theme/admin/base/resources/partials/realm-identity-provider-saml.html b/forms/common-themes/src/main/resources/theme/admin/base/resources/partials/realm-identity-provider-saml.html index 5a87057295..e5ba81f2ac 100755 --- a/forms/common-themes/src/main/resources/theme/admin/base/resources/partials/realm-identity-provider-saml.html +++ b/forms/common-themes/src/main/resources/theme/admin/base/resources/partials/realm-identity-provider-saml.html @@ -52,11 +52,11 @@
- +
-