summaryrefslogtreecommitdiff
path: root/smcc/src/main/java/at/gv
diff options
context:
space:
mode:
Diffstat (limited to 'smcc/src/main/java/at/gv')
-rw-r--r--smcc/src/main/java/at/gv/egiz/smcc/SWCard.java11
1 files changed, 11 insertions, 0 deletions
diff --git a/smcc/src/main/java/at/gv/egiz/smcc/SWCard.java b/smcc/src/main/java/at/gv/egiz/smcc/SWCard.java
index a896c9a1..62f3e3e3 100644
--- a/smcc/src/main/java/at/gv/egiz/smcc/SWCard.java
+++ b/smcc/src/main/java/at/gv/egiz/smcc/SWCard.java
@@ -25,6 +25,7 @@
package at.gv.egiz.smcc;
import java.io.ByteArrayOutputStream;
+import java.io.File;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.IOException;
@@ -97,6 +98,16 @@ public class SWCard implements SignatureCard {
String userHome = System.getProperty("user.home");
String fs = System.getProperty("file.separator");
swCardDir = userHome + fs + BKU_USER_DIR + fs + SWCARD_DIR;
+ String swcDir = System.getProperty("mocca.swcard.directory");
+ if (swcDir != null) {
+ File f = new File(swcDir);
+ if (!f.isAbsolute()) {
+ swcDir = userHome + fs + BKU_USER_DIR + fs + swcDir;
+ f = new File(swcDir);
+ }
+ if (f.isDirectory())
+ swCardDir = swcDir;
+ }
}
/**