[java-idp-testbed COMMIT] in /trunk/src/test: java/idp/c14n/TestC14N.java resources/c14n/attribute-resolver.xml resou...

noreply at shibboleth.net noreply at shibboleth.net
Thu Feb 20 14:23:36 EST 2014


Author: rdw
Date: Thu Feb 20 14:23:35 2014
New Revision: 153

URL: http://svn.shibboleth.net/view/java-idp-testbed?rev=153&view=rev
Log:
IDP-371 IDP-359 Action for Direct NameID C14N and test

Added:
    trunk/src/test/resources/c14n/webflows/directNameID-flow.xml   (with props)
Modified:
    trunk/src/test/java/idp/c14n/TestC14N.java
    trunk/src/test/resources/c14n/attribute-resolver.xml
    trunk/src/test/resources/c14n/test-webflow-config.xml
    trunk/src/test/resources/c14n/webflows/beans.xml

Modified: trunk/src/test/java/idp/c14n/TestC14N.java
URL: http://svn.shibboleth.net/view/java-idp-testbed/trunk/src/test/java/idp/c14n/TestC14N.java?rev=153&r1=152&r2=153&view=diff
==============================================================================
--- trunk/src/test/java/idp/c14n/TestC14N.java (original)
+++ trunk/src/test/java/idp/c14n/TestC14N.java Thu Feb 20 14:23:35 2014
@@ -68,4 +68,18 @@
         Assert.assertTrue(result.isEnded());
 
     }
+    
+    @Test public void testDirectNameID() {
+
+        FlowExecutionResult result = flowExecutor.launchExecution("directNameID", null, externalContext);
+        Assert.assertEquals("directNameID", result.getFlowId());
+
+        FlowExecutionOutcome outcome = result.getOutcome();
+        log.debug("flow outcome {}", outcome);
+        Assert.assertNotNull(outcome);
+        Assert.assertEquals(outcome.getId(), "end");
+        Assert.assertTrue(result.isEnded());
+
+    }
+
 }

Modified: trunk/src/test/resources/c14n/attribute-resolver.xml
URL: http://svn.shibboleth.net/view/java-idp-testbed/trunk/src/test/resources/c14n/attribute-resolver.xml?rev=153&r1=152&r2=153&view=diff
==============================================================================
--- trunk/src/test/resources/c14n/attribute-resolver.xml (original)
+++ trunk/src/test/resources/c14n/attribute-resolver.xml Thu Feb 20 14:23:35 2014
@@ -22,4 +22,9 @@
         <resolver:AttributeEncoder xsi:type="enc:SAML2StringNameID" nameFormat="urn:oasis:names:tc:SAML:2.0:nameid-format:transient"/>
     </resolver:AttributeDefinition>
 
+    <resolver:AttributeDefinition id="Principal" xsi:type="ad:PrincipalName" >
+        <resolver:AttributeEncoder xsi:type="enc:SAML1StringNameIdentifier" nameFormat="urn:mace:shibboleth:1.0:nameIdentifier"/>
+        <resolver:AttributeEncoder xsi:type="enc:SAML2StringNameID" nameFormat="urn:oasis:names:tc:SAML:2.0:nameid-format:transient"/>
+    </resolver:AttributeDefinition>
+
 </resolver:AttributeResolver>

Modified: trunk/src/test/resources/c14n/test-webflow-config.xml
URL: http://svn.shibboleth.net/view/java-idp-testbed/trunk/src/test/resources/c14n/test-webflow-config.xml?rev=153&r1=152&r2=153&view=diff
==============================================================================
--- trunk/src/test/resources/c14n/test-webflow-config.xml (original)
+++ trunk/src/test/resources/c14n/test-webflow-config.xml Thu Feb 20 14:23:35 2014
@@ -9,6 +9,7 @@
     <webflow:flow-registry id="testFlowRegistry" parent="flowRegistry" base-path="classpath:/c14n/webflows" flow-builder-services="flowBuilderServices">
         <webflow:flow-location id="transientNameID" path="/transientNameID-flow.xml" />
         <webflow:flow-location id="cryptoTransientNameID" path="/cryptoTransientNameID-flow.xml" />
+        <webflow:flow-location id="directNameID" path="/directNameID-flow.xml" />
     </webflow:flow-registry>      
     
     <webflow:flow-executor id="flowExecutor" flow-registry="testFlowRegistry"/>

Modified: trunk/src/test/resources/c14n/webflows/beans.xml
URL: http://svn.shibboleth.net/view/java-idp-testbed/trunk/src/test/resources/c14n/webflows/beans.xml?rev=153&r1=152&r2=153&view=diff
==============================================================================
--- trunk/src/test/resources/c14n/webflows/beans.xml (original)
+++ trunk/src/test/resources/c14n/webflows/beans.xml Thu Feb 20 14:23:35 2014
@@ -16,6 +16,7 @@
         <bean id="ResolveAttributes" class="net.shibboleth.idp.profile.impl.ResolveAttributes" p:id="Resolver" c:resolverService-ref="shibboleth.AttributeResolverService" scope="prototype" />
         <bean id="PopulateC14N" class = "idp.c14n.actions.SetupForC14N"  scope="prototype" p:id="c14nThing" p:attributeName="transientId" />
         <bean id="PopulateC14NCrypto" class = "idp.c14n.actions.SetupForC14N"  scope="prototype" p:id="c14ncryptoThing" p:attributeName="cryptoTransientId" />
+        <bean id="PopulateC14NDirect" class = "idp.c14n.actions.SetupForC14N"  scope="prototype" p:id="c14nThing" p:attributeName="Principal" />
         <bean id="TestAfterC14N" class = "idp.c14n.actions.TestAfterC14N"  scope="prototype" p:id="c14nTest" />
 		
 </beans>



More information about the commits mailing list