Was miscomputing the Accept attribute in various rules.
authorcantor <cantor@ab3bd59b-922f-494d-bb5f-6f0a3c29deca>
Tue, 1 Nov 2005 00:51:51 +0000 (00:51 +0000)
committercantor <cantor@ab3bd59b-922f-494d-bb5f-6f0a3c29deca>
Tue, 1 Nov 2005 00:51:51 +0000 (00:51 +0000)
git-svn-id: https://subversion.switch.ch/svn/shibboleth/java-idp/trunk@1889 ab3bd59b-922f-494d-bb5f-6f0a3c29deca

src/edu/internet2/middleware/shibboleth/aap/provider/XMLAAPProvider.java

index 3ffae34..d2a46db 100644 (file)
@@ -135,8 +135,8 @@ public class XMLAAPProvider implements AAP, PluggableConfigurationComponent {
                     Element se=(Element)vlist.item(i);
                     Node valnode=se.getFirstChild();
                     if (valnode != null && valnode.getNodeType()==Node.TEXT_NODE) {
                     Element se=(Element)vlist.item(i);
                     Node valnode=se.getFirstChild();
                     if (valnode != null && valnode.getNodeType()==Node.TEXT_NODE) {
-                        String accept=se.getAttributeNS(null,"Accept");
-                        if (XML.isEmpty(accept) || XML.safeCompare(flag,"1") || XML.safeCompare(flag,"true"))
+                        flag=XML.assign(se.getAttributeNS(null,"Accept"));
+                        if (XML.isEmpty(flag) || XML.safeCompare(flag,"1") || XML.safeCompare(flag,"true"))
                             anySiteRule.scopeAccepts.add(new Rule(toValueType(se),valnode.getNodeValue()));
                         else
                             anySiteRule.scopeDenials.add(new Rule(toValueType(se),valnode.getNodeValue()));
                             anySiteRule.scopeAccepts.add(new Rule(toValueType(se),valnode.getNodeValue()));
                         else
                             anySiteRule.scopeDenials.add(new Rule(toValueType(se),valnode.getNodeValue()));
@@ -155,8 +155,8 @@ public class XMLAAPProvider implements AAP, PluggableConfigurationComponent {
                         Element ve=(Element)vlist.item(j);
                         Node valnode=ve.getFirstChild();
                         if (valnode != null && valnode.getNodeType()==Node.TEXT_NODE) {
                         Element ve=(Element)vlist.item(j);
                         Node valnode=ve.getFirstChild();
                         if (valnode != null && valnode.getNodeType()==Node.TEXT_NODE) {
-                            String accept=ve.getAttributeNS(null,"Accept");
-                            if (XML.isEmpty(accept) || XML.safeCompare(flag,"1") || XML.safeCompare(flag,"true"))
+                               flag=XML.assign(ve.getAttributeNS(null,"Accept"));
+                            if (XML.isEmpty(flag) || XML.safeCompare(flag,"1") || XML.safeCompare(flag,"true"))
                                 anySiteRule.valueAccepts.add(new Rule(toValueType(ve),valnode.getNodeValue()));
                             else
                                 anySiteRule.valueDenials.add(new Rule(toValueType(ve),valnode.getNodeValue()));
                                 anySiteRule.valueAccepts.add(new Rule(toValueType(ve),valnode.getNodeValue()));
                             else
                                 anySiteRule.valueDenials.add(new Rule(toValueType(ve),valnode.getNodeValue()));
@@ -180,8 +180,8 @@ public class XMLAAPProvider implements AAP, PluggableConfigurationComponent {
                     Node valnode=se.getFirstChild();
                     if (valnode != null && valnode.getNodeType()==Node.TEXT_NODE)
                     {
                     Node valnode=se.getFirstChild();
                     if (valnode != null && valnode.getNodeType()==Node.TEXT_NODE)
                     {
-                        String accept=se.getAttributeNS(null,"Accept");
-                        if (XML.isEmpty(accept) || XML.safeCompare(flag,"1") || XML.safeCompare(flag,"true"))
+                       flag=XML.assign(se.getAttributeNS(null,"Accept"));
+                        if (XML.isEmpty(flag) || XML.safeCompare(flag,"1") || XML.safeCompare(flag,"true"))
                             srule.scopeAccepts.add(new Rule(toValueType(se),valnode.getNodeValue()));
                         else
                             srule.scopeDenials.add(new Rule(toValueType(se),valnode.getNodeValue()));
                             srule.scopeAccepts.add(new Rule(toValueType(se),valnode.getNodeValue()));
                         else
                             srule.scopeDenials.add(new Rule(toValueType(se),valnode.getNodeValue()));
@@ -200,8 +200,8 @@ public class XMLAAPProvider implements AAP, PluggableConfigurationComponent {
                         Element ve=(Element)vlist.item(j);
                         Node valnode=ve.getFirstChild();
                         if (valnode != null && valnode.getNodeType()==Node.TEXT_NODE) {
                         Element ve=(Element)vlist.item(j);
                         Node valnode=ve.getFirstChild();
                         if (valnode != null && valnode.getNodeType()==Node.TEXT_NODE) {
-                            String accept=ve.getAttributeNS(null,"Accept");
-                            if (XML.isEmpty(accept) || XML.safeCompare(flag,"1") || XML.safeCompare(flag,"true"))
+                               flag=XML.assign(ve.getAttributeNS(null,"Accept"));
+                            if (XML.isEmpty(flag) || XML.safeCompare(flag,"1") || XML.safeCompare(flag,"true"))
                                 srule.valueAccepts.add(new Rule(toValueType(ve),valnode.getNodeValue()));
                             else
                                 srule.valueDenials.add(new Rule(toValueType(ve),valnode.getNodeValue()));
                                 srule.valueAccepts.add(new Rule(toValueType(ve),valnode.getNodeValue()));
                             else
                                 srule.valueDenials.add(new Rule(toValueType(ve),valnode.getNodeValue()));