socket improvement

This commit is contained in:
kepler155c@gmail.com
2017-05-09 01:57:00 -04:00
parent ab73e3f2f9
commit f866d2bd58
10 changed files with 158 additions and 98 deletions

View File

@@ -53,7 +53,7 @@ local secretKey = os.getSecretKey()
local publicKey = modexp(exchange.base, secretKey, exchange.primeMod)
local password = SHA1.sha1(password)
socket:write(Crypto.encrypt({ pk = publicKey }, password))
socket:write(Crypto.encrypt({ pk = publicKey, dh = os.getComputerID() }, password))
print(socket:read(2) or 'No response')