Change exchange messages

This commit is contained in:
Joren Schipman 2024-05-04 01:02:40 +02:00
parent 3463cf0481
commit 04db12a77f
Signed by untrusted user who does not match committer: Joren
GPG Key ID: 280E33DFBC0F1B55

View File

@ -74,7 +74,7 @@ func handleConnection(conn net.Conn, privateKey *rsa.PrivateKey) {
log.Printf("Error decrypting key: %v", err)
return
}
conn.Write([]byte("Received key\n"))
conn.Write([]byte("OK\n"))
ivData, err := bufio.NewReader(conn).ReadString('\n')
if err != nil {
@ -86,7 +86,7 @@ func handleConnection(conn net.Conn, privateKey *rsa.PrivateKey) {
log.Printf("Error decrypting IV: %v", err)
return
}
conn.Write([]byte("Received IV\n"))
conn.Write([]byte("OK\n"))
uidData, err := bufio.NewReader(conn).ReadString('\n')
if err != nil {
@ -98,7 +98,7 @@ func handleConnection(conn net.Conn, privateKey *rsa.PrivateKey) {
log.Printf("Error decrypting UID: %v", err)
return
}
conn.Write([]byte("Received UID\n"))
conn.Write([]byte("OK\n"))
fmt.Println("Exchange, OK!")