aboutsummaryrefslogtreecommitdiff
path: root/id.server/src/at/gv/egovernment/moa/id/auth
diff options
context:
space:
mode:
authorharald.bratko <harald.bratko@d688527b-c9ab-4aba-bd8d-4036d912da1d>2006-02-28 14:17:33 +0000
committerharald.bratko <harald.bratko@d688527b-c9ab-4aba-bd8d-4036d912da1d>2006-02-28 14:17:33 +0000
commitb89550cb29a6cc4b36147d3d9925709c38ba8171 (patch)
treec322649eda4fffa7cb2b61eb1a5b0657be9ca887 /id.server/src/at/gv/egovernment/moa/id/auth
parent18241a6df201ffa83e8dcc1d84e9ae8505c268f7 (diff)
downloadmoa-id-spss-b89550cb29a6cc4b36147d3d9925709c38ba8171.tar.gz
moa-id-spss-b89550cb29a6cc4b36147d3d9925709c38ba8171.tar.bz2
moa-id-spss-b89550cb29a6cc4b36147d3d9925709c38ba8171.zip
Updated for loading templates from the config file.
git-svn-id: https://joinup.ec.europa.eu/svn/moa-idspss/trunk@640 d688527b-c9ab-4aba-bd8d-4036d912da1d
Diffstat (limited to 'id.server/src/at/gv/egovernment/moa/id/auth')
-rw-r--r--id.server/src/at/gv/egovernment/moa/id/auth/AuthenticationServer.java18
1 files changed, 14 insertions, 4 deletions
diff --git a/id.server/src/at/gv/egovernment/moa/id/auth/AuthenticationServer.java b/id.server/src/at/gv/egovernment/moa/id/auth/AuthenticationServer.java
index ea9d7a0d3..c0fcc6a68 100644
--- a/id.server/src/at/gv/egovernment/moa/id/auth/AuthenticationServer.java
+++ b/id.server/src/at/gv/egovernment/moa/id/auth/AuthenticationServer.java
@@ -175,7 +175,7 @@ public class AuthenticationServer implements MOAIDAuthConstants {
session.setTarget(target);
session.setOAURLRequested(oaURL);
session.setPublicOAURLPrefix(oaParam.getPublicURLPrefix());
- session.setAuthURL(authURL);
+ session.setAuthURL(authURL);
session.setTemplateURL(templateURL);
session.setBusinessService(oaParam.getBusinessService());
String returnURL =
@@ -197,6 +197,10 @@ public class AuthenticationServer implements MOAIDAuthConstants {
ex);
}
String bkuSelectionTemplate = null;
+ // override template url by url from configuration file
+ if (oaParam.getBkuSelectionTemplateURL() != null) {
+ bkuSelectionTemplateURL = oaParam.getBkuSelectionTemplateURL();
+ }
if (bkuSelectionTemplateURL != null) {
try {
bkuSelectionTemplate = new String(FileUtils.readURL(bkuSelectionTemplateURL));
@@ -318,13 +322,19 @@ public class AuthenticationServer implements MOAIDAuthConstants {
REQ_VERIFY_IDENTITY_LINK,
session.getSessionID());
String template = null;
- if (session.getTemplateURL() != null) {
+ // override template url by url from configuration file
+ if (oaParam.getTemplateURL() != null) {
+ templateURL = oaParam.getTemplateURL();
+ } else {
+ templateURL = session.getTemplateURL();
+ }
+ if (templateURL != null) {
try {
- template = new String(FileUtils.readURL(session.getTemplateURL()));
+ template = new String(FileUtils.readURL(templateURL));
} catch (IOException ex) {
throw new AuthenticationException(
"auth.03",
- new Object[] { session.getTemplateURL(), ex.toString()},
+ new Object[] { templateURL, ex.toString()},
ex);
}
}