VeraCrypt
aboutsummaryrefslogtreecommitdiff
path: root/DcsCfg/DcsCfgMain.c
diff options
context:
space:
mode:
authorkavsrf <kavsrf@gmail.com>2017-03-27 16:01:33 +0300
committerMounir IDRASSI <mounir.idrassi@idrix.fr>2017-06-18 15:41:15 +0200
commit3cddd24df26085682c819a3c8e9e3ce21a2872da (patch)
treef97065bd54266978df4cae2fe91127c3f58278cd /DcsCfg/DcsCfgMain.c
parent51088d231d73cbe14516d553e97237e7f5a4f147 (diff)
downloadVeraCrypt-DCS-3cddd24df26085682c819a3c8e9e3ce21a2872da.tar.gz
VeraCrypt-DCS-3cddd24df26085682c819a3c8e9e3ce21a2872da.zip
smart card tests via DcsCfg
Diffstat (limited to 'DcsCfg/DcsCfgMain.c')
-rw-r--r--DcsCfg/DcsCfgMain.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/DcsCfg/DcsCfgMain.c b/DcsCfg/DcsCfgMain.c
index c289bf8..3abd759 100644
--- a/DcsCfg/DcsCfgMain.c
+++ b/DcsCfg/DcsCfgMain.c
@@ -40,6 +40,8 @@ https://opensource.org/licenses/LGPL-3.0
#define OPT_DISK_END L"-de"
#define OPT_DISK_BOOT L"-db"
#define OPT_USB_LIST L"-ul"
+#define OPT_USB_SELECT L"-us"
+#define OPT_SC_APDU L"-scapdu"
#define OPT_TOUCH_LIST L"-tl"
#define OPT_TOUCH_TEST L"-tt"
#define OPT_GRAPH_LIST L"-gl"
@@ -123,6 +125,8 @@ STATIC CONST SHELL_PARAM_ITEM ParamList[] = {
{ OPT_VOLUME_DECRYPT,TypeValue },
{ OPT_VOLUME_CHANGEPWD,TypeValue },
{ OPT_USB_LIST, TypeFlag },
+ { OPT_USB_SELECT, TypeValue },
+ { OPT_SC_APDU, TypeValue },
{ OPT_TOUCH_LIST, TypeFlag },
{ OPT_TOUCH_TEST, TypeValue },
{ OPT_GRAPH_LIST, TypeFlag },
@@ -409,6 +413,18 @@ DcsCfgMain(
PrintUsbList();
}
+ if (ShellCommandLineGetFlag(Package, OPT_USB_SELECT)) {
+ CHAR16 * opt;
+ opt = (CHAR16*)ShellCommandLineGetValue(Package, OPT_USB_SELECT);
+ UsbIndex = StrDecimalToUintn(opt);
+ }
+
+ if (ShellCommandLineGetFlag(Package, OPT_SC_APDU)) {
+ CHAR16 * opt;
+ opt = (CHAR16*)ShellCommandLineGetValue(Package, OPT_SC_APDU);
+ UsbScApdu(opt);
+ }
+
// Randoms
if (ShellCommandLineGetFlag(Package, OPT_RND_LOAD)) {
CONST CHAR16* opt = NULL;