replace random nonces with message sequence numbers in tcp crypto
Since TCP is reliable, we do not need to transmit the nonce itself; the recipient can simply construct the nonce from its own message counter. Hence there is no message envelope and we can thus remove a whole layer of encoding.
This commit is contained in:
1 parent
87f47a60ae
commit
696bfe464c
3 files changed
+45
-79
No files matched your search
@@ -446,7 +446,7 @@ func (conn *LocalConnection) receiveTCP(decoder *gob.Decoder) {
|
||||
usingPassword := conn.SessionKey != nil
|
||||
var receiver TCPReceiver
|
||||
if usingPassword {
|
||||
receiver = NewEncryptedTCPReceiver(conn.SessionKey)
|
||||
receiver = NewEncryptedTCPReceiver(conn.SessionKey, conn.outbound)
|
||||
} else {
|
||||
receiver = NewSimpleTCPReceiver()
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user