aboutsummaryrefslogtreecommitdiff
path: root/id/server/modules
diff options
context:
space:
mode:
Diffstat (limited to 'id/server/modules')
-rw-r--r--id/server/modules/moa-id-module-openID/src/main/java/at/gv/egovernment/moa/id/protocols/oauth20/json/OAuth20SignatureUtil.java4
-rw-r--r--id/server/modules/moa-id-module-openID/src/test/java/test/at/gv/egovernment/moa/id/auth/oauth/CertTest.java6
-rw-r--r--id/server/modules/module-monitoring/src/main/java/at/gv/egovernment/moa/id/monitoring/DatabaseTestModule.java6
-rw-r--r--id/server/modules/module-monitoring/src/main/java/at/gv/egovernment/moa/id/monitoring/TestManager.java4
-rw-r--r--id/server/modules/module-monitoring/src/main/resources/moaid_monitoring.beans.xml3
5 files changed, 14 insertions, 9 deletions
diff --git a/id/server/modules/moa-id-module-openID/src/main/java/at/gv/egovernment/moa/id/protocols/oauth20/json/OAuth20SignatureUtil.java b/id/server/modules/moa-id-module-openID/src/main/java/at/gv/egovernment/moa/id/protocols/oauth20/json/OAuth20SignatureUtil.java
index 9f20ee956..cd7b8312d 100644
--- a/id/server/modules/moa-id-module-openID/src/main/java/at/gv/egovernment/moa/id/protocols/oauth20/json/OAuth20SignatureUtil.java
+++ b/id/server/modules/moa-id-module-openID/src/main/java/at/gv/egovernment/moa/id/protocols/oauth20/json/OAuth20SignatureUtil.java
@@ -54,7 +54,7 @@ public final class OAuth20SignatureUtil {
} else if (key instanceof ECPrivateKey) {
Logger.debug("OAuth - going to uses SHA256withECDSA signature");
return OAuthSignatureAlgorithm.ECDSA256;
- } else if (key instanceof iaik.security.ecc.ecdsa.ECPrivateKey) {
+ } else if (key instanceof iaik.security.ec.common.ECPrivateKey) {
Logger.debug("OAuth - going to uses SHA256withECDSA signature with iaik");
return OAuthSignatureAlgorithm.ECDSA256_IAKIK;
} else {
@@ -69,7 +69,7 @@ public final class OAuth20SignatureUtil {
} else if (key instanceof ECPublicKey) {
Logger.debug("OAuth - going to uses SHA256withECDSA signature");
return OAuthSignatureAlgorithm.ECDSA256;
- } else if (key instanceof iaik.security.ecc.ecdsa.ECPublicKey) {
+ } else if (key instanceof iaik.security.ec.common.ECPublicKey) {
Logger.debug("OAuth - going to uses SHA256withECDSA signature with iaik");
return OAuthSignatureAlgorithm.ECDSA256_IAKIK;
} else {
diff --git a/id/server/modules/moa-id-module-openID/src/test/java/test/at/gv/egovernment/moa/id/auth/oauth/CertTest.java b/id/server/modules/moa-id-module-openID/src/test/java/test/at/gv/egovernment/moa/id/auth/oauth/CertTest.java
index 812591293..35bbac6e7 100644
--- a/id/server/modules/moa-id-module-openID/src/test/java/test/at/gv/egovernment/moa/id/auth/oauth/CertTest.java
+++ b/id/server/modules/moa-id-module-openID/src/test/java/test/at/gv/egovernment/moa/id/auth/oauth/CertTest.java
@@ -33,7 +33,7 @@ import org.testng.annotations.Test;
import at.gv.egovernment.moa.id.protocols.oauth20.json.OAuth20SHA256Signer;
import at.gv.egovernment.moa.id.protocols.oauth20.json.OAuth20SHA256Verifier;
import at.gv.egovernment.moa.util.KeyStoreUtils;
-import iaik.security.ec.provider.ECCelerate;
+
import net.oauth.jsontoken.crypto.Signer;
import net.oauth.jsontoken.crypto.Verifier;
@@ -119,8 +119,8 @@ public class CertTest {
}
@Test
- public void testECDSA() throws Exception {
- ECCelerate.addAsProvider();
+ public void testECDSA() throws Exception {
+ //ECCProvider.addAsProvider();
// Security.addProvider(new ECCProvider());
BasicX509Credential credential = this.getCredentials(this.ecdsaKeyStorePath);
diff --git a/id/server/modules/module-monitoring/src/main/java/at/gv/egovernment/moa/id/monitoring/DatabaseTestModule.java b/id/server/modules/module-monitoring/src/main/java/at/gv/egovernment/moa/id/monitoring/DatabaseTestModule.java
index b6d217e4c..8ae1850ce 100644
--- a/id/server/modules/module-monitoring/src/main/java/at/gv/egovernment/moa/id/monitoring/DatabaseTestModule.java
+++ b/id/server/modules/module-monitoring/src/main/java/at/gv/egovernment/moa/id/monitoring/DatabaseTestModule.java
@@ -41,8 +41,10 @@ import at.gv.egovernment.moa.util.MiscUtil;
public class DatabaseTestModule implements TestModuleInterface{
private MOASessionDBUtils dbUtils;
+ private StatisticLogDBUtils statLogUtils;
- public DatabaseTestModule(MOASessionDBUtils dbUtils){
+ public DatabaseTestModule(MOASessionDBUtils dbUtils, StatisticLogDBUtils statLogUtils){
+ this.statLogUtils = statLogUtils;
this.dbUtils = dbUtils;
}
@@ -112,7 +114,7 @@ public class DatabaseTestModule implements TestModuleInterface{
Date expioredate = new Date(new Date().getTime() - 120);
try {
- Session session = StatisticLogDBUtils.getCurrentSession();
+ Session session = statLogUtils.getCurrentSession();
List<StatisticLog> results;
diff --git a/id/server/modules/module-monitoring/src/main/java/at/gv/egovernment/moa/id/monitoring/TestManager.java b/id/server/modules/module-monitoring/src/main/java/at/gv/egovernment/moa/id/monitoring/TestManager.java
index b5ccd73f6..4224fae59 100644
--- a/id/server/modules/module-monitoring/src/main/java/at/gv/egovernment/moa/id/monitoring/TestManager.java
+++ b/id/server/modules/module-monitoring/src/main/java/at/gv/egovernment/moa/id/monitoring/TestManager.java
@@ -32,12 +32,14 @@ import org.springframework.beans.factory.annotation.Autowired;
import at.gv.egovernment.moa.id.commons.api.AuthConfiguration;
import at.gv.egovernment.moa.id.commons.api.exceptions.ConfigurationException;
import at.gv.egovernment.moa.id.commons.db.MOASessionDBUtils;
+import at.gv.egovernment.moa.id.commons.db.StatisticLogDBUtils;
import at.gv.egovernment.moa.logging.Logger;
import at.gv.egovernment.moa.util.FileUtils;
public class TestManager{
@Autowired private MOASessionDBUtils moaSessionDBUtils;
+ @Autowired(required=false) private StatisticLogDBUtils statisticLogDBUtils = null;
@Autowired private AuthConfiguration authConfig;
private Map<String, TestModuleInterface> tests = new HashMap<String, TestModuleInterface>();
@@ -92,7 +94,7 @@ public class TestManager{
Logger.debug("Start initializing MOA-ID-Auth TestManager");
//add Database test
- DatabaseTestModule test1 = new DatabaseTestModule(this.moaSessionDBUtils);
+ DatabaseTestModule test1 = new DatabaseTestModule(this.moaSessionDBUtils, this.statisticLogDBUtils);
tests.put(test1.getName(), test1);
//add IdentityLink verification test
diff --git a/id/server/modules/module-monitoring/src/main/resources/moaid_monitoring.beans.xml b/id/server/modules/module-monitoring/src/main/resources/moaid_monitoring.beans.xml
index 41fab4444..6c195e7d7 100644
--- a/id/server/modules/module-monitoring/src/main/resources/moaid_monitoring.beans.xml
+++ b/id/server/modules/module-monitoring/src/main/resources/moaid_monitoring.beans.xml
@@ -1,5 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
-<beans xmlns="http://www.springframework.org/schema/beans"
+<beans
+ xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:tx="http://www.springframework.org/schema/tx"