summaryrefslogtreecommitdiff
path: root/pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku/MobileBKUConnector.java
diff options
context:
space:
mode:
authorAndreas Abraham <andreas.abraham@egiz.gv.at>2019-11-05 16:20:44 +0100
committerAndreas Abraham <andreas.abraham@egiz.gv.at>2019-11-05 16:20:44 +0100
commit03b9af56efaec1adecfadc09327a14dc116a9c3a (patch)
tree9c3f5238dbbed83d1449b81e6a84796538bbd229 /pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku/MobileBKUConnector.java
parent02bae5a8841e77f4409778576ffcebf3ab582d5e (diff)
downloadpdf-over-03b9af56efaec1adecfadc09327a14dc116a9c3a.tar.gz
pdf-over-03b9af56efaec1adecfadc09327a14dc116a9c3a.tar.bz2
pdf-over-03b9af56efaec1adecfadc09327a14dc116a9c3a.zip
support of all cases when pressing the sms tan button
Diffstat (limited to 'pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku/MobileBKUConnector.java')
-rw-r--r--pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku/MobileBKUConnector.java29
1 files changed, 13 insertions, 16 deletions
diff --git a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku/MobileBKUConnector.java b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku/MobileBKUConnector.java
index 891ff9f4..09e8d17d 100644
--- a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku/MobileBKUConnector.java
+++ b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku/MobileBKUConnector.java
@@ -88,20 +88,17 @@ public class MobileBKUConnector implements BkuSlConnector {
try {
String responseData = handler.postCredentials();
- if (responseData.contains("undecided.aspx?sid=")) { //$NON-NLS-1$
- // handle polling
+ if (responseData.contains("undecided.aspx?sid=")) { //$NON-NLS-1$
+ // handle polling
this.state.showOpenAppMessageWithSMSandCancel();
- if (((ATrustStatus) this.state.getStatus()).isSmsTan()) {
- ATrustHandler aHandler = (ATrustHandler) handler;
- String response = aHandler.postSMSRequest();
- aHandler.handleCredentialsResponse(response);
- } else if (handleErrorMessage()) {
- throw new SignatureException(new IllegalStateException());
- } else {
- handler.handlePolling(responseData);
- }
-
+ if (((ATrustStatus) this.state.getStatus()).isSmsTan()) {
+ ATrustHandler aHandler = (ATrustHandler) handler;
+ String response = aHandler.postSMSRequest();
+ aHandler.handleCredentialsResponse(response);
+ } else if (handleErrorMessage()) {
+ throw new SignatureException(new IllegalStateException());
+ }
} else {
// Now we have received some data lets check it:
@@ -149,7 +146,7 @@ public class MobileBKUConnector implements BkuSlConnector {
enterTAN = false;
}
}
- if (enterTAN && !aStatus.getTanField() && !aStatus.isSmsTan()) {
+ if (enterTAN && !aStatus.getTanField()) {
try {
this.state.showFingerPrintInformation();
@@ -158,9 +155,9 @@ public class MobileBKUConnector implements BkuSlConnector {
throw new SignatureException(new IllegalStateException());
} catch (Exception ex) {
log.error("Error in PostCredentialsThread", ex); //$NON-NLS-1$
- this.state.setThreadException(ex);
- this.state.displayError(ex);
- throw new SignatureException(ex);
+ this.state.setThreadException(new IllegalStateException());
+ //this.state.displayError(ex);
+ throw new SignatureException(new IllegalStateException());
}
if (this.state.getSMSStatus()) {