/// <param name="args"> </param> public static void Main(string[] args) { string saltString = "BEB25379D1A8581EB5A727673A2441EE"; string a = "60975527035CF2AD1989806F0407210BC81EDC04E2762A56AFD529DDDA2D4393"; string b = "E487CB59D31AC550471E81F00F6928E01DDA08E974A004F49E61F5D105284D20"; RemotePassword server = new RemotePassword(); RemotePassword client = new RemotePassword(); string verifier = server.computeVerifier("alice", "password123", saltString); string clientKey = client.setClientPrivateKey(a); string serverKey = server.setServerPrivateKey(b, verifier); byte[] key1 = client.computeSessionKey("alice", "password123", saltString, serverKey); byte[] key2 = server.computeSessionKey(clientKey, verifier); Console.WriteLine(); }
/// <param name="args"> </param> public static void Main(string[] args) { string saltString = "BEB25379D1A8581EB5A727673A2441EE"; string a = "60975527035CF2AD1989806F0407210BC81EDC04E2762A56AFD529DDDA2D4393"; string b = "E487CB59D31AC550471E81F00F6928E01DDA08E974A004F49E61F5D105284D20"; RemotePassword server = new RemotePassword(); RemotePassword client = new RemotePassword(); string verifier = server.computeVerifier("alice", "password123", saltString); string clientKey = client.setClientPrivateKey(a); string serverKey = server.setServerPrivateKey(b, verifier); byte[] key1 = client.computeSessionKey("alice", "password123", saltString, serverKey); byte[] key2 = server.computeSessionKey(clientKey, verifier); Console.WriteLine(); }