-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #231 from crocs-muni/devel
add new version 1.8.0
- Loading branch information
Showing
195 changed files
with
37,072 additions
and
613 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -56,11 +56,24 @@ public class AlgTestJClient { | |
public static final String ALGTEST_USE_SIMULATOR = "JCARDSIM"; // use simulator instead of real card | ||
public static final String ALGTEST_USE_CUSTOM_AID = "AID="; // use custom AID for applet (if default one is changed for some reason) | ||
|
||
/** | ||
* Version 1.8.0 (19.12.2020) | ||
* + testing of modular Cipher and Signature .getInstance variants | ||
* + testing of OneShot variants | ||
* + testing of InitializedMessageDigest | ||
*/ | ||
public final static String ALGTEST_JCLIENT_VERSION_1_8_0 = "1.8.0"; | ||
/** | ||
* Version 1.7.10 (29.11.2020) | ||
* + parsing memory overhead for object allocation | ||
* + added request for sending data to public database | ||
*/ | ||
//public final static String ALGTEST_JCLIENT_VERSION_1_7_10 = "1.7.10"; | ||
/** | ||
* Version 1.7.9 (22.07.2019) | ||
* - no changes, updating version with card applet | ||
*/ | ||
public final static String ALGTEST_JCLIENT_VERSION_1_7_9 = "1.7.9"; | ||
//public final static String ALGTEST_JCLIENT_VERSION_1_7_9 = "1.7.9"; | ||
/** | ||
* Version 1.7.8 (18.05.2019) | ||
* - no changes, updating version with card applet | ||
|
@@ -155,26 +168,29 @@ public class AlgTestJClient { | |
/** | ||
* Current version | ||
*/ | ||
public final static String ALGTEST_JCLIENT_VERSION = ALGTEST_JCLIENT_VERSION_1_7_9; | ||
public final static String ALGTEST_JCLIENT_VERSION = ALGTEST_JCLIENT_VERSION_1_8_0; | ||
|
||
public final static int STAT_OK = 0; | ||
|
||
// If required to be run with simulator, run as: >java -cp "AlgTestJClient.jar;jcardsim-3.0.5-SNAPSHOT.jar" -noverify algtestjclient.AlgTestJClient JCARDSIM | ||
static boolean USE_JCARDSIM = false; | ||
|
||
// Unique start time in milisconds | ||
static long m_appStartTime = 0; | ||
|
||
/** | ||
* @param args the command line arguments | ||
*/ | ||
|
||
static DirtyLogger m_SystemOutLogger = null; | ||
public static void main(String[] args) throws IOException, Exception { | ||
String logFileName = String.format("ALGTEST_log_%d.log", System.currentTimeMillis()); | ||
String logFileName = String.format("ALGTEST_log_%s.log", AlgTestJClient.getStartTime()); | ||
FileOutputStream systemOutLogger = new FileOutputStream(logFileName); | ||
m_SystemOutLogger = new DirtyLogger(systemOutLogger, true); | ||
|
||
m_SystemOutLogger.println("\n----------------------------------------------------------------------- "); | ||
m_SystemOutLogger.println("JCAlgTest " + ALGTEST_JCLIENT_VERSION + " - comprehensive tool for JavaCard smart card testing."); | ||
m_SystemOutLogger.println("Visit jcalgtest.org for results from 60+ cards. CRoCS lab 2007-2017."); | ||
m_SystemOutLogger.println("Visit jcalgtest.org for results from 100+ cards. CRoCS lab 2007-2021."); | ||
m_SystemOutLogger.println("Please check if you use the latest version at\n https://github.com/crocs-muni/JCAlgTest/releases/latest."); | ||
|
||
m_SystemOutLogger.println("-----------------------------------------------------------------------\n"); | ||
|
@@ -229,7 +245,7 @@ else if (args[0].equals(ALGTEST_PERFORMANCE)){ | |
Scanner sc = new Scanner(System.in); | ||
int answ = sc.nextInt(); | ||
m_SystemOutLogger.println(String.format("%d", answ)); | ||
switch (answ){ | ||
switch (answ) { | ||
// In this case, SinglePerApdu version of AlgTest is used. | ||
case 1: | ||
selectedTerminal = selectTargetReader(); | ||
|
@@ -274,6 +290,24 @@ else if (args[0].equals(ALGTEST_PERFORMANCE)){ | |
/* fix arguments processing | ||
} | ||
*/ | ||
printSendRequest(); | ||
} | ||
|
||
static long getStartTime() { | ||
if (m_appStartTime == 0) { | ||
m_appStartTime = System.currentTimeMillis(); | ||
} | ||
return m_appStartTime; | ||
} | ||
|
||
static void printSendRequest() { | ||
System.out.println("\n-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*"); | ||
System.out.println("KIND REQUEST: Please consider sending us your results to extend info openly"); | ||
System.out.println("available to all JavaCard enthusiasts at http://jcalgtest.org."); | ||
System.out.println("The results are important even if a card of same type is already in database."); | ||
System.out.println("Send *.log and *.csv files from the current directory to <[email protected]>."); | ||
System.out.println("Thank you very much!"); | ||
System.out.println("-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*-*"); | ||
} | ||
|
||
static void performKeyHarvest() throws CardException { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.