Fixed attribute value consumption in AA/IdP roles.
authorcantor <cantor@ab3bd59b-922f-494d-bb5f-6f0a3c29deca>
Thu, 20 Oct 2005 16:30:44 +0000 (16:30 +0000)
committercantor <cantor@ab3bd59b-922f-494d-bb5f-6f0a3c29deca>
Thu, 20 Oct 2005 16:30:44 +0000 (16:30 +0000)
git-svn-id: https://subversion.switch.ch/svn/shibboleth/java-idp/trunk@1887 ab3bd59b-922f-494d-bb5f-6f0a3c29deca

src/edu/internet2/middleware/shibboleth/metadata/provider/XMLMetadataProvider.java

index 1f35333..1099300 100644 (file)
@@ -749,7 +749,6 @@ public class XMLMetadataProvider implements Metadata, PluggableConfigurationComp
                     copy.setAttributeNS(null,"AttributeNamespace",src.getAttributeNS(null,"NameFormat"));
                     src=XML.getFirstChildElement(src,edu.internet2.middleware.shibboleth.common.XML.SAML2ASSERT_NS,"AttributeValue");
                     while (src != null) {
-                        src=XML.getNextSiblingElement(src,edu.internet2.middleware.shibboleth.common.XML.SAML2ASSERT_NS,"AttributeValue");
                         Element val=e.getOwnerDocument().createElementNS(XML.SAML_NS,"AttributeValue");
                         NamedNodeMap attrs = src.getAttributes();
                         for (int j=0; j<attrs.getLength(); j++)
@@ -757,6 +756,7 @@ public class XMLMetadataProvider implements Metadata, PluggableConfigurationComp
                         while (src.hasChildNodes())
                             val.appendChild(src.getFirstChild());
                         copy.appendChild(val);
+                        src=XML.getNextSiblingElement(src,edu.internet2.middleware.shibboleth.common.XML.SAML2ASSERT_NS,"AttributeValue");
                     }
                     attrs.add(SAMLAttribute.getInstance(copy));
                 }
@@ -875,7 +875,6 @@ public class XMLMetadataProvider implements Metadata, PluggableConfigurationComp
                     copy.setAttributeNS(null,"AttributeNamespace",src.getAttributeNS(null,"NameFormat"));
                     src=XML.getFirstChildElement(src,edu.internet2.middleware.shibboleth.common.XML.SAML2ASSERT_NS,"AttributeValue");
                     while (src != null) {
-                        src=XML.getNextSiblingElement(src,edu.internet2.middleware.shibboleth.common.XML.SAML2ASSERT_NS,"AttributeValue");
                         Element val=e.getOwnerDocument().createElementNS(XML.SAML_NS,"AttributeValue");
                         NamedNodeMap attrs = src.getAttributes();
                         for (int j=0; j<attrs.getLength(); j++)
@@ -883,6 +882,7 @@ public class XMLMetadataProvider implements Metadata, PluggableConfigurationComp
                         while (src.hasChildNodes())
                             val.appendChild(src.getFirstChild());
                         copy.appendChild(val);
+                        src=XML.getNextSiblingElement(src,edu.internet2.middleware.shibboleth.common.XML.SAML2ASSERT_NS,"AttributeValue");
                     }
                     attrs.add(SAMLAttribute.getInstance(copy));
                 }