[java-identity-provider COMMIT] in /trunk: idp-conf/src/main/resources/system/flows/saml/saml-abstract-beans.xml idp-...

noreply at shibboleth.net noreply at shibboleth.net
Tue Mar 25 16:21:12 EDT 2014


Author: scantor
Date: Tue Mar 25 16:21:12 2014
New Revision: 5639

URL: http://svn.shibboleth.net/view/java-identity-provider?rev=5639&view=rev
Log:
Fix a bug in predicate, and add Format-based determination of policy.

Modified:
    trunk/idp-conf/src/main/resources/system/flows/saml/saml-abstract-beans.xml
    trunk/idp-saml-impl/src/test/java/net/shibboleth/idp/saml/impl/profile/ExtractSubjectFromRequestTest.java

Modified: trunk/idp-conf/src/main/resources/system/flows/saml/saml-abstract-beans.xml
URL: http://svn.shibboleth.net/view/java-identity-provider/trunk/idp-conf/src/main/resources/system/flows/saml/saml-abstract-beans.xml?rev=5639&r1=5638&r2=5639&view=diff
==============================================================================
--- trunk/idp-conf/src/main/resources/system/flows/saml/saml-abstract-beans.xml (original)
+++ trunk/idp-conf/src/main/resources/system/flows/saml/saml-abstract-beans.xml Tue Mar 25 16:21:12 2014
@@ -63,6 +63,13 @@
                     p:requesterIdLookupStrategy-ref="shibboleth.RelyingPartyIdLookup.Simple">
                 <property name="objectLookupStrategy">
                     <bean class="net.shibboleth.idp.saml.impl.profile.ExtractSubjectFromRequest.SubjectNameLookupFunction" />
+                </property>
+                <property name="formats">
+                    <util:list>
+                        <value>urn:mace:shibboleth:1.0:nameIdentifier</value>
+                        <value>urn:oasis:names:tc:SAML:2.0:nameid-format:persistent</value>
+                        <value>urn:oasis:names:tc:SAML:2.0:nameid-format:transient</value>
+                    </util:list>
                 </property>
             </bean>
         </property>

Modified: trunk/idp-saml-impl/src/test/java/net/shibboleth/idp/saml/impl/profile/ExtractSubjectFromRequestTest.java
URL: http://svn.shibboleth.net/view/java-identity-provider/trunk/idp-saml-impl/src/test/java/net/shibboleth/idp/saml/impl/profile/ExtractSubjectFromRequestTest.java?rev=5639&r1=5638&r2=5639&view=diff
==============================================================================
--- trunk/idp-saml-impl/src/test/java/net/shibboleth/idp/saml/impl/profile/ExtractSubjectFromRequestTest.java (original)
+++ trunk/idp-saml-impl/src/test/java/net/shibboleth/idp/saml/impl/profile/ExtractSubjectFromRequestTest.java Tue Mar 25 16:21:12 2014
@@ -36,6 +36,7 @@
 import org.opensaml.saml.saml1.core.Request;
 import org.opensaml.saml.saml1.profile.SAML1ActionTestingSupport;
 import org.opensaml.saml.saml2.core.AuthnRequest;
+import org.opensaml.saml.saml2.core.NameID;
 import org.opensaml.saml.saml2.profile.SAML2ActionTestingSupport;
 import org.springframework.webflow.execution.Event;
 import org.springframework.webflow.execution.RequestContext;
@@ -99,6 +100,7 @@
         request.setSubject(SAML2ActionTestingSupport.buildSubject("foo"));
         prc.getInboundMessageContext().setMessage(request);
         
+        request.getSubject().getNameID().setFormat(NameID.TRANSIENT);
         request.getSubject().getNameID().setNameQualifier("foo");
         Event event = action.execute(rc);
         ActionTestingSupport.assertEvent(event, AuthnEventIds.INVALID_SUBJECT);
@@ -126,6 +128,7 @@
                 SAML1ActionTestingSupport.buildSubject("foo"));
         prc.getInboundMessageContext().setMessage(request);
         
+        request.getAttributeQuery().getSubject().getNameIdentifier().setFormat(NameID.TRANSIENT);
         request.getAttributeQuery().getSubject().getNameIdentifier().setNameQualifier("foo");
         Event event = action.execute(rc);
         ActionTestingSupport.assertEvent(event, AuthnEventIds.INVALID_SUBJECT);



More information about the commits mailing list