always add audience restriction to condition
authorlajoie <lajoie@ab3bd59b-922f-494d-bb5f-6f0a3c29deca>
Thu, 19 Jun 2008 06:03:10 +0000 (06:03 +0000)
committerlajoie <lajoie@ab3bd59b-922f-494d-bb5f-6f0a3c29deca>
Thu, 19 Jun 2008 06:03:10 +0000 (06:03 +0000)
git-svn-id: https://subversion.switch.ch/svn/shibboleth/java-idp/branches/REL_2@2741 ab3bd59b-922f-494d-bb5f-6f0a3c29deca

src/main/java/edu/internet2/middleware/shibboleth/idp/profile/saml1/AbstractSAML1ProfileHandler.java

index d17589c..2f23c45 100644 (file)
@@ -290,6 +290,8 @@ public abstract class AbstractSAML1ProfileHandler extends AbstractSAMLProfileHan
         Collection<String> audiences;
 
         AudienceRestrictionCondition audienceRestriction = audienceRestrictionConditionBuilder.buildObject();
+        conditions.getAudienceRestrictionConditions().add(audienceRestriction);
+        
         Audience audience = audienceBuilder.buildObject();
         audience.setUri(requestContext.getInboundMessageIssuer());
         audienceRestriction.getAudiences().add(audience);
@@ -302,7 +304,6 @@ public abstract class AbstractSAML1ProfileHandler extends AbstractSAMLProfileHan
                 audience.setUri(audienceUri);
                 audienceRestriction.getAudiences().add(audience);
             }
-            conditions.getAudienceRestrictionConditions().add(audienceRestriction);
         }
 
         return conditions;