Make sure groups have names.
authorcantor <cantor@ab3bd59b-922f-494d-bb5f-6f0a3c29deca>
Mon, 20 Jun 2005 02:25:28 +0000 (02:25 +0000)
committercantor <cantor@ab3bd59b-922f-494d-bb5f-6f0a3c29deca>
Mon, 20 Jun 2005 02:25:28 +0000 (02:25 +0000)
git-svn-id: https://subversion.switch.ch/svn/shibboleth/java-idp/trunk@1635 ab3bd59b-922f-494d-bb5f-6f0a3c29deca

src/edu/internet2/middleware/shibboleth/common/ServiceProviderMapper.java

index a451d33..264f05b 100644 (file)
@@ -134,12 +134,15 @@ public class ServiceProviderMapper {
                if (provider != null) {
                        EntitiesDescriptor parent = provider.getEntitiesDescriptor();
                        while (parent != null) {
-                               if (relyingParties.containsKey(parent.getName())) {
-                                       log.info("Found matching Relying Party for group (" + parent.getName() + ").");
-                                       return (RelyingParty) relyingParties.get(parent.getName());
-                               } else {
-                                       log.debug("Provider is a member of group (" + parent.getName()
-                                                       + "), but no matching Relying Party was found.");
+                               if (parent.getName() != null) {
+                                       if (relyingParties.containsKey(parent.getName())) {
+                                               log.info("Found matching Relying Party for group (" + parent.getName() + ").");
+                                               return (RelyingParty) relyingParties.get(parent.getName());
+                                       }
+                                       else {
+                                               log.debug("Provider is a member of group (" + parent.getName()
+                                                               + "), but no matching Relying Party was found.");
+                                       }
                                }
                                parent = parent.getEntitiesDescriptor();
                        }