diff options
author | Thomas <> | 2021-03-22 18:40:26 +0100 |
---|---|---|
committer | Thomas <> | 2021-03-22 18:40:26 +0100 |
commit | 578ad0d6bc408edf9e6c875156054374f5fd8337 (patch) | |
tree | 11ca8a04bd045e20d4b381fc76762d21b9e5abaa /moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/tsl/timer | |
parent | eb37b2c969c85ca966f0a0ad1d8b9941647a7f6a (diff) | |
download | moa-sig-578ad0d6bc408edf9e6c875156054374f5fd8337.tar.gz moa-sig-578ad0d6bc408edf9e6c875156054374f5fd8337.tar.bz2 moa-sig-578ad0d6bc408edf9e6c875156054374f5fd8337.zip |
change to EGIZ codestyle
Diffstat (limited to 'moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/tsl/timer')
-rw-r--r-- | moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/tsl/timer/TSLUpdaterTimerTask.java | 94 |
1 files changed, 33 insertions, 61 deletions
diff --git a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/tsl/timer/TSLUpdaterTimerTask.java b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/tsl/timer/TSLUpdaterTimerTask.java index b5a7a8c..1a377b6 100644 --- a/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/tsl/timer/TSLUpdaterTimerTask.java +++ b/moaSig/moa-sig-lib/src/main/java/at/gv/egovernment/moa/spss/tsl/timer/TSLUpdaterTimerTask.java @@ -1,77 +1,49 @@ package at.gv.egovernment.moa.spss.tsl.timer;
-import iaik.asn1.ObjectID;
-import iaik.pki.store.certstore.CertStoreException;
-import iaik.pki.store.certstore.CertStoreParameters;
-import iaik.pki.store.truststore.TrustStoreException;
-import iaik.pki.store.truststore.TrustStoreProfile;
-import iaik.pki.store.utils.StoreUpdater;
-import iaik.server.ConfigurationData;
-import iaik.x509.X509Certificate;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.security.cert.CertificateException;
-import java.util.ArrayList;
-import java.util.Date;
-import java.util.Iterator;
-import java.util.Map;
import java.util.TimerTask;
import at.gv.egovernment.moa.sig.tsl.exception.TslException;
import at.gv.egovernment.moa.sig.tsl.exception.TslUpdateException;
-import at.gv.egovernment.moa.spss.MOAApplicationException;
-import at.gv.egovernment.moa.spss.api.common.TSLConfiguration;
-import at.gv.egovernment.moa.spss.server.config.ConfigurationException;
-import at.gv.egovernment.moa.spss.server.config.ConfigurationProvider;
-import at.gv.egovernment.moa.spss.server.config.TrustProfile;
-import at.gv.egovernment.moa.spss.server.iaik.config.IaikConfigurator;
-import at.gv.egovernment.moa.spss.server.iaik.pki.store.truststore.TrustStoreProfileImpl;
-import at.gv.egovernment.moa.spss.server.logging.TransactionId;
import at.gv.egovernment.moa.spss.server.monitoring.ServiceStatusContainer;
import at.gv.egovernment.moa.spss.tsl.TSLServiceFactory;
import at.gv.egovernment.moa.spss.util.MessageProvider;
import at.gv.egovernment.moaspss.logging.LogMsg;
import at.gv.egovernment.moaspss.logging.Logger;
-import at.gv.egovernment.moaspss.util.StringUtils;
-
public class TSLUpdaterTimerTask extends TimerTask {
-
- @Override
- public void run() {
-
- try {
- Logger.info("Start TSL Update");
- TSLServiceFactory.getTSLServiceClient().updateTSLInformation();
- Logger.info("Finished TSL Update");
-
- //set global TSL client status
- ServiceStatusContainer.setStatus(true);
- ServiceStatusContainer.setStatusMsg(ServiceStatusContainer.STATUS_OK);
-
- } catch (TslUpdateException e) {
- MessageProvider msg = MessageProvider.getInstance();
- Logger.error(new LogMsg(msg.getMessage("tsl.00", null)), e);
-
- //set global TSL client status
- ServiceStatusContainer.setStatus(false);
- ServiceStatusContainer.setStatusMsg(
- new LogMsg(msg.getMessage("tsl.00", null)).toString());
-
- } catch (TslException e) {
- MessageProvider msg = MessageProvider.getInstance();
- Logger.error(new LogMsg(msg.getMessage("tsl.00", null)), e);
-
- //set global TSL client status
- ServiceStatusContainer.setStatus(false);
- ServiceStatusContainer.setStatusMsg(
- new LogMsg(msg.getMessage("tsl.00", null)).toString());
-
- }
- }
+ @Override
+ public void run() {
+
+ try {
+ Logger.info("Start TSL Update");
+ TSLServiceFactory.getTSLServiceClient().updateTSLInformation();
+ Logger.info("Finished TSL Update");
+
+ // set global TSL client status
+ ServiceStatusContainer.setStatus(true);
+ ServiceStatusContainer.setStatusMsg(ServiceStatusContainer.STATUS_OK);
+
+ } catch (final TslUpdateException e) {
+ final MessageProvider msg = MessageProvider.getInstance();
+ Logger.error(new LogMsg(msg.getMessage("tsl.00", null)), e);
+
+ // set global TSL client status
+ ServiceStatusContainer.setStatus(false);
+ ServiceStatusContainer.setStatusMsg(
+ new LogMsg(msg.getMessage("tsl.00", null)).toString());
+
+ } catch (final TslException e) {
+ final MessageProvider msg = MessageProvider.getInstance();
+ Logger.error(new LogMsg(msg.getMessage("tsl.00", null)), e);
+
+ // set global TSL client status
+ ServiceStatusContainer.setStatus(false);
+ ServiceStatusContainer.setStatusMsg(
+ new LogMsg(msg.getMessage("tsl.00", null)).toString());
+
+ }
+
+ }
}
|