Author: anil.saldhana(a)jboss.com
Date: 2012-02-24 16:20:43 -0500 (Fri, 24 Feb 2012)
New Revision: 1442
Added:
federation/trunk/picketlink-fed-core/src/test/resources/signatures/saml11assertion.xml
Removed:
federation/trunk/picketlink-fed-core/src/test/resources/signatures/saml2assertion.xml
Modified:
federation/trunk/picketlink-fed-core/src/test/java/org/picketlink/test/identity/federation/core/util/XMLSignatureUtilUnitTestCase.java
Log:
change file name
Modified:
federation/trunk/picketlink-fed-core/src/test/java/org/picketlink/test/identity/federation/core/util/XMLSignatureUtilUnitTestCase.java
===================================================================
---
federation/trunk/picketlink-fed-core/src/test/java/org/picketlink/test/identity/federation/core/util/XMLSignatureUtilUnitTestCase.java 2012-02-24
21:18:50 UTC (rev 1441)
+++
federation/trunk/picketlink-fed-core/src/test/java/org/picketlink/test/identity/federation/core/util/XMLSignatureUtilUnitTestCase.java 2012-02-24
21:20:43 UTC (rev 1442)
@@ -90,7 +90,7 @@
@Test
public void testSAML2Assertion() throws Exception
{
- String fileName = "signatures/saml2assertion.xml";
+ String fileName = "signatures/saml11assertion.xml";
ClassLoader tcl = Thread.currentThread().getContextClassLoader();
InputStream is = tcl.getResourceAsStream(fileName);
if (is == null)
@@ -103,10 +103,8 @@
KeyPair keyPair = KeyStoreUtil.generateKeyPair("RSA");
Element tokenElement = (Element) rstrDocument.getFirstChild();
+ rstrDocument = XMLSignatureUtil.sign(rstrDocument, tokenElement, keyPair,
DigestMethod.SHA1, signatureMethod, "");
- rstrDocument = XMLSignatureUtil.sign(rstrDocument, tokenElement, keyPair,
DigestMethod.SHA1, signatureMethod, "#"
- + tokenElement.getAttribute("ID"));
-
assertNotNull(rstrDocument);
System.out.println(DocumentUtil.asString(rstrDocument));
Added:
federation/trunk/picketlink-fed-core/src/test/resources/signatures/saml11assertion.xml
===================================================================
---
federation/trunk/picketlink-fed-core/src/test/resources/signatures/saml11assertion.xml
(rev 0)
+++
federation/trunk/picketlink-fed-core/src/test/resources/signatures/saml11assertion.xml 2012-02-24
21:20:43 UTC (rev 1442)
@@ -0,0 +1,17 @@
+<saml:Assertion xmlns:saml="urn:oasis:names:tc:SAML:1.0:assertion"
+ AssertionID="ID_4756863b-eb25-4572-935f-af4ccc8a34ac"
IssueInstant="2012-02-24T15:57:15.975Z"
+ Issuer="PicketLinkSTS" MajorVersion="1"
MinorVersion="1">
+ <saml:Conditions NotBefore="2012-02-24T15:57:15.975Z"
+ NotOnOrAfter="2012-02-24T17:57:15.975Z" />
+ <saml:AuthenticationStatement
+ AuthenticationInstant="2012-02-24T15:57:15.975Z"
AuthenticationMethod="urn:picketlink:auth">
+ <saml:Subject>
+ <saml:NameIdentifier
+ Format="urn:oasis:names:tc:SAML:1.1:nameid-format:unspecified">admin</saml:NameIdentifier>
+ <saml:SubjectConfirmation>
+ <saml:ConfirmationMethod>urn:oasis:names:tc:SAML:1.0:cm:bearer
+ </saml:ConfirmationMethod>
+ </saml:SubjectConfirmation>
+ </saml:Subject>
+ </saml:AuthenticationStatement>
+</saml:Assertion>
\ No newline at end of file
Deleted:
federation/trunk/picketlink-fed-core/src/test/resources/signatures/saml2assertion.xml
===================================================================
---
federation/trunk/picketlink-fed-core/src/test/resources/signatures/saml2assertion.xml 2012-02-24
21:18:50 UTC (rev 1441)
+++
federation/trunk/picketlink-fed-core/src/test/resources/signatures/saml2assertion.xml 2012-02-24
21:20:43 UTC (rev 1442)
@@ -1,17 +0,0 @@
-<saml:Assertion xmlns:saml="urn:oasis:names:tc:SAML:1.0:assertion"
- AssertionID="ID_4756863b-eb25-4572-935f-af4ccc8a34ac"
IssueInstant="2012-02-24T15:57:15.975Z"
- Issuer="PicketLinkSTS" MajorVersion="1"
MinorVersion="1">
- <saml:Conditions NotBefore="2012-02-24T15:57:15.975Z"
- NotOnOrAfter="2012-02-24T17:57:15.975Z" />
- <saml:AuthenticationStatement
- AuthenticationInstant="2012-02-24T15:57:15.975Z"
AuthenticationMethod="urn:picketlink:auth">
- <saml:Subject>
- <saml:NameIdentifier
- Format="urn:oasis:names:tc:SAML:1.1:nameid-format:unspecified">admin</saml:NameIdentifier>
- <saml:SubjectConfirmation>
- <saml:ConfirmationMethod>urn:oasis:names:tc:SAML:1.0:cm:bearer
- </saml:ConfirmationMethod>
- </saml:SubjectConfirmation>
- </saml:Subject>
- </saml:AuthenticationStatement>
-</saml:Assertion>
\ No newline at end of file
Show replies by date