[java-idp-oidc] 30/44: JOIDC-5 Removed RedirectUri element from the metadata extension.

Henri Mikkonen henri.mikkonen at iki.fi
Thu Oct 22 13:08:42 UTC 2020


This is an automated email from the git hooks/post-receive script.

hjmikkon pushed a commit to branch main
in repository java-idp-oidc.

View the commit online:
http://git.shibboleth.net/view/?p=java-idp-oidc.git;a=commit;h=7174d839ffb88646cb9ad204b23505a787b97d9f

commit 7174d839ffb88646cb9ad204b23505a787b97d9f
Author: Henri Mikkonen <henri.mikkonen at iki.fi>
AuthorDate: Fri Jul 3 10:34:57 2020 +0300

    JOIDC-5 Removed RedirectUri element from the metadata extension.
    
    https://issues.shibboleth.net/jira/browse/JOIDC-5
    
    Redirect URIs are now set with the AssertionConsumerService
    element.
---
 .../idp/saml/oidc/xmlobject/OAuthRPExtensions.java |  9 +----
 .../idp/saml/oidc/xmlobject/RedirectUri.java       | 37 -----------------
 .../resources/schema/saml-metadata-ext-oidcmd.xsd  |  1 -
 .../oidc/xmlobject/impl/OAuthRPExtensionsImpl.java | 11 ------
 .../impl/OAuthRPExtensionsUnmarshaller.java        |  7 +---
 .../oidc/xmlobject/impl/RedirectUriBuilder.java    | 46 ----------------------
 .../saml/oidc/xmlobject/impl/RedirectUriImpl.java  | 37 -----------------
 .../oidc/xmlobject/impl/RedirectUriMarshaller.java | 26 ------------
 .../xmlobject/impl/RedirectUriUnmarshaller.java    | 26 ------------
 .../resources/saml2-metadata-oidcmd-config.xml     |  6 ---
 10 files changed, 3 insertions(+), 203 deletions(-)

diff --git a/idp-oidc-extension-api/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/OAuthRPExtensions.java b/idp-oidc-extension-api/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/OAuthRPExtensions.java
index 33b55d38..fc86b6b9 100644
--- a/idp-oidc-extension-api/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/OAuthRPExtensions.java
+++ b/idp-oidc-extension-api/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/OAuthRPExtensions.java
@@ -40,13 +40,6 @@ public interface OAuthRPExtensions extends SAMLObject {
     /** "requireAuthTime" attribute's local name. */
     public static final String REQUIRE_AUTH_TIME_ATTRIB_NAME = "requireAuthTime";
 
-    /**
-     * Gets the redirect URIs configured for this relying party.
-     * 
-     * @return the redirect URIs configured for this relying party.
-     */
-    public List<RedirectUri> getRedirectUris();
-    
     public TokenEndpointAuthMethod getTokenEndpointAuthMethod();
     
     public void setTokenEndpointAuthMethod(final TokenEndpointAuthMethod method);
@@ -143,4 +136,4 @@ public interface OAuthRPExtensions extends SAMLObject {
     
     public void setRequireAuthTime(final boolean flag);
 
-}
\ No newline at end of file
+}
diff --git a/idp-oidc-extension-api/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/RedirectUri.java b/idp-oidc-extension-api/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/RedirectUri.java
deleted file mode 100644
index e7df3381..00000000
--- a/idp-oidc-extension-api/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/RedirectUri.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (c) 2017 - 2020, GÉANT
- *
- * Licensed under the Apache License, Version 2.0 (the “License”); you may not
- * use this file except in compliance with the License. You may obtain a copy
- * of the License at
- *
- *    http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an “AS IS” BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package net.shibboleth.idp.saml.oidc.xmlobject;
-
-import javax.xml.namespace.QName;
-
-/**
- * SAML2 OIDC metadata extension 'RedirectUri'.
- */
-public interface RedirectUri extends MetadataValueSAMLObject {
-
-    /** Element name, no namespace. */
-    public static final String DEFAULT_ELEMENT_LOCAL_NAME = "RedirectUri";
-
-    /** Default element name. */
-    public static final QName DEFAULT_ELEMENT_NAME = new QName(SAML20MDOIDCMD_NS, DEFAULT_ELEMENT_LOCAL_NAME,
-            SAML20MDOIDCMD_PREFIX);
-
-    /** QName of the XSI type. */
-    public static final QName TYPE_NAME = new QName(SAML20MDOIDCMD_NS, DEFAULT_ELEMENT_LOCAL_NAME,
-    		SAML20MDOIDCMD_PREFIX);
-
-}
diff --git a/idp-oidc-extension-api/src/main/resources/schema/saml-metadata-ext-oidcmd.xsd b/idp-oidc-extension-api/src/main/resources/schema/saml-metadata-ext-oidcmd.xsd
index 611b3ab1..03c6bb0b 100644
--- a/idp-oidc-extension-api/src/main/resources/schema/saml-metadata-ext-oidcmd.xsd
+++ b/idp-oidc-extension-api/src/main/resources/schema/saml-metadata-ext-oidcmd.xsd
@@ -42,7 +42,6 @@
         </complexContent>
     </complexType>
 
-    <element name="RedirectUri" type="anyURI" />
     <element name="TokenEndpointAuthMethod" type="anyURI" />
     <element name="GrantType" type="anyURI" />
     <element name="ResponseType" type="anyURI" />
diff --git a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/OAuthRPExtensionsImpl.java b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/OAuthRPExtensionsImpl.java
index e1642429..3379e64b 100644
--- a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/OAuthRPExtensionsImpl.java
+++ b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/OAuthRPExtensionsImpl.java
@@ -36,7 +36,6 @@ import net.shibboleth.idp.saml.oidc.xmlobject.InitiateLoginUri;
 import net.shibboleth.idp.saml.oidc.xmlobject.JwksUri;
 import net.shibboleth.idp.saml.oidc.xmlobject.OAuthRPExtensions;
 import net.shibboleth.idp.saml.oidc.xmlobject.PostLogoutRedirectUri;
-import net.shibboleth.idp.saml.oidc.xmlobject.RedirectUri;
 import net.shibboleth.idp.saml.oidc.xmlobject.RequestObjectEncryptionResponseAlg;
 import net.shibboleth.idp.saml.oidc.xmlobject.RequestObjectEncryptionResponseEnc;
 import net.shibboleth.idp.saml.oidc.xmlobject.RequestObjectSignedResponseAlg;
@@ -58,9 +57,6 @@ import net.shibboleth.idp.saml.oidc.xmlobject.UserInfoSignedResponseAlg;
  */
 public class OAuthRPExtensionsImpl extends RoleDescriptorImpl implements OAuthRPExtensions {
 
-    /** Redirect URIs configured for this entity. */
-    private final XMLObjectChildrenList<RedirectUri> redirectUris;
-    
     /** Token endpoint authentication method for this entity. */
     private TokenEndpointAuthMethod tokenEndpointAuthMethod;
     
@@ -151,7 +147,6 @@ public class OAuthRPExtensionsImpl extends RoleDescriptorImpl implements OAuthRP
     protected OAuthRPExtensionsImpl(final String namespaceURI, final String elementLocalName,
             final String namespacePrefix) {
         super(namespaceURI, elementLocalName, namespacePrefix);
-        redirectUris = new XMLObjectChildrenList<>(this);
         responseTypes = new XMLObjectChildrenList<>(this);
         grantTypes = new XMLObjectChildrenList<>(this);
         scopes = new XMLObjectChildrenList<>(this);
@@ -170,12 +165,6 @@ public class OAuthRPExtensionsImpl extends RoleDescriptorImpl implements OAuthRP
         return null;
     }
     
-    /** {@inheritDoc} */
-    @Override
-    public List<RedirectUri> getRedirectUris() {
-        return redirectUris;
-    }
-
     /** {@inheritDoc} */
     @Override
     public List<ResponseType> getResponseTypes() {
diff --git a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/OAuthRPExtensionsUnmarshaller.java b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/OAuthRPExtensionsUnmarshaller.java
index c7e30723..05e0b9e7 100644
--- a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/OAuthRPExtensionsUnmarshaller.java
+++ b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/OAuthRPExtensionsUnmarshaller.java
@@ -34,7 +34,6 @@ import net.shibboleth.idp.saml.oidc.xmlobject.InitiateLoginUri;
 import net.shibboleth.idp.saml.oidc.xmlobject.JwksUri;
 import net.shibboleth.idp.saml.oidc.xmlobject.OAuthRPExtensions;
 import net.shibboleth.idp.saml.oidc.xmlobject.PostLogoutRedirectUri;
-import net.shibboleth.idp.saml.oidc.xmlobject.RedirectUri;
 import net.shibboleth.idp.saml.oidc.xmlobject.RequestObjectEncryptionResponseAlg;
 import net.shibboleth.idp.saml.oidc.xmlobject.RequestObjectEncryptionResponseEnc;
 import net.shibboleth.idp.saml.oidc.xmlobject.RequestObjectSignedResponseAlg;
@@ -61,9 +60,7 @@ public class OAuthRPExtensionsUnmarshaller extends AbstractSAMLObjectUnmarshalle
             throws UnmarshallingException {
         final OAuthRPExtensions descriptor = (OAuthRPExtensions) parentSAMLObject;
 
-        if (childSAMLObject instanceof RedirectUri) {
-            descriptor.getRedirectUris().add((RedirectUri) childSAMLObject);
-        } else if (childSAMLObject instanceof ResponseType) {
+        if (childSAMLObject instanceof ResponseType) {
             descriptor.getResponseTypes().add((ResponseType) childSAMLObject);
         } else if (childSAMLObject instanceof GrantType) {
             descriptor.getGrantTypes().add((GrantType) childSAMLObject);
@@ -136,4 +133,4 @@ public class OAuthRPExtensionsUnmarshaller extends AbstractSAMLObjectUnmarshalle
 
         }
     }
-}
\ No newline at end of file
+}
diff --git a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/RedirectUriBuilder.java b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/RedirectUriBuilder.java
deleted file mode 100644
index 46508a40..00000000
--- a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/RedirectUriBuilder.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*
- * Copyright (c) 2017 - 2020, GÉANT
- *
- * Licensed under the Apache License, Version 2.0 (the “License”); you may not
- * use this file except in compliance with the License. You may obtain a copy
- * of the License at
- *
- *    http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an “AS IS” BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package net.shibboleth.idp.saml.oidc.xmlobject.impl;
-
-import org.opensaml.saml.common.AbstractSAMLObjectBuilder;
-
-import net.shibboleth.idp.saml.oidc.xmlobject.Constants;
-import net.shibboleth.idp.saml.oidc.xmlobject.RedirectUri;
-
-/**
- * Builder of {@link RedirectUriImpl}.
- */
-public class RedirectUriBuilder extends AbstractSAMLObjectBuilder<RedirectUri> {
-
-    /**
-     * Constructor.
-     */
-    public RedirectUriBuilder() {
-
-    }
-
-    /** {@inheritDoc} */
-    public RedirectUri buildObject() {
-        return buildObject(Constants.SAML20MDOIDCMD_NS, RedirectUri.DEFAULT_ELEMENT_LOCAL_NAME,
-                Constants.SAML20MDOIDCMD_PREFIX);
-    }
-
-    /** {@inheritDoc} */
-    public RedirectUri buildObject(final String namespaceURI, final String localName, final String namespacePrefix) {
-        return new RedirectUriImpl(namespaceURI, localName, namespacePrefix);
-    }
-}
\ No newline at end of file
diff --git a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/RedirectUriImpl.java b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/RedirectUriImpl.java
deleted file mode 100644
index c9492e38..00000000
--- a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/RedirectUriImpl.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/*
- * Copyright (c) 2017 - 2020, GÉANT
- *
- * Licensed under the Apache License, Version 2.0 (the “License”); you may not
- * use this file except in compliance with the License. You may obtain a copy
- * of the License at
- *
- *    http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an “AS IS” BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package net.shibboleth.idp.saml.oidc.xmlobject.impl;
-
-import net.shibboleth.idp.saml.oidc.xmlobject.RedirectUri;
-
-/**
- * Concrete implementation of {@link RedirectUri}.
- */
-public class RedirectUriImpl extends AbstractMetadataValueSAMLObject implements RedirectUri {
-
-    /**
-     * Constructor.
-     * 
-     * @param namespaceURI the namespace the element is in
-     * @param elementLocalName the local name of the XML element this Object represents
-     * @param namespacePrefix the prefix for the given namespace
-
-     */
-    protected RedirectUriImpl(final String namespaceURI, final String elementLocalName, final String namespacePrefix) {
-        super(namespaceURI, elementLocalName, namespacePrefix);
-    }
-}
\ No newline at end of file
diff --git a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/RedirectUriMarshaller.java b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/RedirectUriMarshaller.java
deleted file mode 100644
index 1e4b7b89..00000000
--- a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/RedirectUriMarshaller.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Copyright (c) 2017 - 2020, GÉANT
- *
- * Licensed under the Apache License, Version 2.0 (the “License”); you may not
- * use this file except in compliance with the License. You may obtain a copy
- * of the License at
- *
- *    http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an “AS IS” BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package net.shibboleth.idp.saml.oidc.xmlobject.impl;
-
-import net.shibboleth.idp.saml.oidc.xmlobject.RedirectUri;
-
-/**
- * A thread safe Marshaller for {@link RedirectUri} objects.
- */
-public class RedirectUriMarshaller extends AbstractMetadataValueMarshaller<RedirectUri> {
-
-}
\ No newline at end of file
diff --git a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/RedirectUriUnmarshaller.java b/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/RedirectUriUnmarshaller.java
deleted file mode 100644
index 373e5866..00000000
--- a/idp-oidc-extension-impl/src/main/java/net/shibboleth/idp/saml/oidc/xmlobject/impl/RedirectUriUnmarshaller.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Copyright (c) 2017 - 2020, GÉANT
- *
- * Licensed under the Apache License, Version 2.0 (the “License”); you may not
- * use this file except in compliance with the License. You may obtain a copy
- * of the License at
- *
- *    http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an “AS IS” BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package net.shibboleth.idp.saml.oidc.xmlobject.impl;
-
-import net.shibboleth.idp.saml.oidc.xmlobject.RedirectUri;
-
-/**
- * A thread-safe Unmarshaller for {@link RedirectUri} objects.
- */
-public class RedirectUriUnmarshaller extends AbstractMetadataValueUnmarshaller<RedirectUri> {
-
-}
\ No newline at end of file
diff --git a/idp-oidc-extension-impl/src/main/resources/saml2-metadata-oidcmd-config.xml b/idp-oidc-extension-impl/src/main/resources/saml2-metadata-oidcmd-config.xml
index 38483dcc..ee36f9c4 100644
--- a/idp-oidc-extension-impl/src/main/resources/saml2-metadata-oidcmd-config.xml
+++ b/idp-oidc-extension-impl/src/main/resources/saml2-metadata-oidcmd-config.xml
@@ -88,12 +88,6 @@
             <UnmarshallingClass className="net.shibboleth.idp.saml.oidc.xmlobject.impl.PostLogoutRedirectUriUnmarshaller"/>
         </ObjectProvider>
 
-        <ObjectProvider qualifiedName="oidcmd:RedirectUri">
-            <BuilderClass className="net.shibboleth.idp.saml.oidc.xmlobject.impl.RedirectUriBuilder"/>
-            <MarshallingClass className="net.shibboleth.idp.saml.oidc.xmlobject.impl.RedirectUriMarshaller"/>
-            <UnmarshallingClass className="net.shibboleth.idp.saml.oidc.xmlobject.impl.RedirectUriUnmarshaller"/>
-        </ObjectProvider>
-        
         <ObjectProvider qualifiedName="oidcmd:RequestObjectEncryptionResponseAlg">
             <BuilderClass className="net.shibboleth.idp.saml.oidc.xmlobject.impl.RequestObjectEncryptionResponseAlgBuilder"/>
             <MarshallingClass className="net.shibboleth.idp.saml.oidc.xmlobject.impl.RequestObjectEncryptionResponseAlgMarshaller"/>

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the commits mailing list