2021-11-05 16:14:18 +11:00

39 lines
748 B
Java

public class Q2 {
//Setup_Request: Hello
//SETUP: Server's RSA public key
//Client_Hello:IDc
//Server_Hello: IDs , SID
//Ephemeral DH exchange
//Finished, check the shared key
//Data exchange
/**
* Opens the client and server in seperate terminals
* @param args
*/
public static void main(String[] args)
{
// try
// {
// Runtime.getRuntime().exec("cmd /c start cmd.exe /K \"java Q2Server\"");
// Thread.sleep(500); //Just to ensure the server has enough time to open
// Runtime.getRuntime().exec("cmd /c start cmd.exe /K \"java Q2Client\"");
// }
// catch (Exception e)
// {
// e.printStackTrace();
// }
Q2Tools toolbox = new Q2Tools();
toolbox.fastModularExpon(5, 117, 19);
}
}