aboutsummaryrefslogtreecommitdiff
path: root/id.server/src/test/abnahme/A/Test300VerifyAuthBlock.java
diff options
context:
space:
mode:
authorharald.bratko <harald.bratko@d688527b-c9ab-4aba-bd8d-4036d912da1d>2007-01-10 15:46:55 +0000
committerharald.bratko <harald.bratko@d688527b-c9ab-4aba-bd8d-4036d912da1d>2007-01-10 15:46:55 +0000
commit547b3b6eb2be2414df1524941c8cc95d83ede3c5 (patch)
tree2e31a08d5abb7655764003521191305bb2c39771 /id.server/src/test/abnahme/A/Test300VerifyAuthBlock.java
parentb224ba28efa8e3082524f1de0d6851d73fe66f03 (diff)
downloadmoa-id-spss-547b3b6eb2be2414df1524941c8cc95d83ede3c5.tar.gz
moa-id-spss-547b3b6eb2be2414df1524941c8cc95d83ede3c5.tar.bz2
moa-id-spss-547b3b6eb2be2414df1524941c8cc95d83ede3c5.zip
Adapted tests to be compileable within MOA-ID 1.4.
git-svn-id: https://joinup.ec.europa.eu/svn/moa-idspss/trunk@772 d688527b-c9ab-4aba-bd8d-4036d912da1d
Diffstat (limited to 'id.server/src/test/abnahme/A/Test300VerifyAuthBlock.java')
-rw-r--r--id.server/src/test/abnahme/A/Test300VerifyAuthBlock.java24
1 files changed, 18 insertions, 6 deletions
diff --git a/id.server/src/test/abnahme/A/Test300VerifyAuthBlock.java b/id.server/src/test/abnahme/A/Test300VerifyAuthBlock.java
index 8bf7f32ab..9bf92e54b 100644
--- a/id.server/src/test/abnahme/A/Test300VerifyAuthBlock.java
+++ b/id.server/src/test/abnahme/A/Test300VerifyAuthBlock.java
@@ -1,6 +1,7 @@
package test.abnahme.A;
import java.util.Calendar;
+import java.util.HashMap;
import org.w3c.dom.Element;
import test.abnahme.AbnahmeTestCase;
@@ -9,6 +10,7 @@ import at.gv.egovernment.moa.id.AuthenticationException;
import at.gv.egovernment.moa.id.BuildException;
import at.gv.egovernment.moa.id.ParseException;
import at.gv.egovernment.moa.id.auth.AuthenticationServer;
+import at.gv.egovernment.moa.id.auth.MOAIDAuthConstants;
import at.gv.egovernment.moa.id.auth.builder.AuthenticationDataAssertionBuilder;
import at.gv.egovernment.moa.id.auth.builder.PersonDataBuilder;
import at.gv.egovernment.moa.id.auth.builder.BPKBuilder;
@@ -187,7 +189,9 @@ public class Test300VerifyAuthBlock extends AbnahmeTestCase {
String sessionID = startAuthentication();
System.out.println(sessionID);
String infoboxReadResponse = readXmldata("InfoBoxReadResponse.xml");
- server.verifyIdentityLink(sessionID, infoboxReadResponse);
+ HashMap parameters = new HashMap(1);
+ parameters.put(MOAIDAuthConstants.PARAM_XMLRESPONSE, infoboxReadResponse);
+ server.verifyIdentityLink(sessionID, parameters);
InfoboxReadResponseParser irrp = new InfoboxReadResponseParser(infoboxReadResponse);
IdentityLink idl = irrp.parseIdentityLink();
Element domVerifyXMLSignatureRequest = new VerifyXMLSignatureRequestBuilder().build(idl, AuthConfigurationProvider.getInstance().getMoaSpAuthBlockTrustProfileID());
@@ -218,7 +222,9 @@ public class Test300VerifyAuthBlock extends AbnahmeTestCase {
String sessionID = startAuthentication();
System.out.println(sessionID);
String infoboxReadResponse = readXmldata("InfoBoxReadResponse.xml");
- server.verifyIdentityLink(sessionID, infoboxReadResponse);
+ HashMap parameters = new HashMap(1);
+ parameters.put(MOAIDAuthConstants.PARAM_XMLRESPONSE, infoboxReadResponse);
+ server.verifyIdentityLink(sessionID, parameters);
server.setSecondsSessionTimeOut(-100);
server.cleanup();
InfoboxReadResponseParser irrp = new InfoboxReadResponseParser(infoboxReadResponse);
@@ -277,7 +283,9 @@ public class Test300VerifyAuthBlock extends AbnahmeTestCase {
String sessionID = startAuthentication();
System.out.println(sessionID);
String infoboxReadResponse = readXmldata("InfoBoxReadResponse.xml");
- server.verifyIdentityLink(sessionID, infoboxReadResponse);
+ HashMap parameters = new HashMap(1);
+ parameters.put(MOAIDAuthConstants.PARAM_XMLRESPONSE, infoboxReadResponse);
+ server.verifyIdentityLink(sessionID, parameters);
InfoboxReadResponseParser irrp = new InfoboxReadResponseParser(infoboxReadResponse);
IdentityLink idl = irrp.parseIdentityLink();
Element domVerifyXMLSignatureRequest = new VerifyXMLSignatureRequestBuilder().build(idl, AuthConfigurationProvider.getInstance().getMoaSpAuthBlockTrustProfileID());
@@ -500,7 +508,9 @@ public class Test300VerifyAuthBlock extends AbnahmeTestCase {
private AuthenticationData initServer(String sessionID) throws Exception {
String infoboxReadResponse = readXmldata("InfoBoxReadResponse.xml");
- server.verifyIdentityLink(sessionID, infoboxReadResponse);
+ HashMap parameters = new HashMap(1);
+ parameters.put(MOAIDAuthConstants.PARAM_XMLRESPONSE, infoboxReadResponse);
+ server.verifyIdentityLink(sessionID, parameters);
InfoboxReadResponseParser irrp = new InfoboxReadResponseParser(infoboxReadResponse);
IdentityLink idl = irrp.parseIdentityLink();
Element domVerifyXMLSignatureRequest = new VerifyXMLSignatureRequestBuilder().build(idl, "TrustProfile1");
@@ -517,7 +527,9 @@ public class Test300VerifyAuthBlock extends AbnahmeTestCase {
private AuthenticationData initServerWithoutValidateAuthBlock(String sessionID) throws Exception {
String infoboxReadResponse = readXmldata("InfoBoxReadResponse.xml");
- server.verifyIdentityLink(sessionID, infoboxReadResponse);
+ HashMap parameters = new HashMap(1);
+ parameters.put(MOAIDAuthConstants.PARAM_XMLRESPONSE, infoboxReadResponse);
+ server.verifyIdentityLink(sessionID, parameters);
InfoboxReadResponseParser irrp = new InfoboxReadResponseParser(infoboxReadResponse);
IdentityLink idl = irrp.parseIdentityLink();
Element domVerifyXMLSignatureRequest = new VerifyXMLSignatureRequestBuilder().build(idl, "TrustProfile1");
@@ -583,7 +595,7 @@ public class Test300VerifyAuthBlock extends AbnahmeTestCase {
oaParam.getProvideIdentityLink() ? DOMUtils.serializeNode(identityLink.getSamlAssertion()) : "";
String authBlock = oaParam.getProvideAuthBlock() ? session.getAuthBlock() : "";
String samlAssertion = new AuthenticationDataAssertionBuilder().build(
- authData, prPerson, authBlock, ilAssertion, session.getBkuURL(), "", false);
+ authData, prPerson, authBlock, ilAssertion, session.getBkuURL(), "", false, null);
authData.setSamlAssertion(samlAssertion);
return authData;
}