mirror of
https://github.com/ScuroNeko/mtg.git
synced 2026-08-31 19:14:01 +03:00
Switch to golangci-lint
This commit is contained in:
@@ -24,7 +24,8 @@ var emptyIP = [4]byte{0x00, 0x00, 0x00, 0x00}
|
||||
|
||||
// NewMiddleProxyCipher creates new block cipher to proxy<->telegram
|
||||
// connection.
|
||||
func NewMiddleProxyCipher(conn StreamReadWriteCloser, req *rpc.NonceRequest, resp *rpc.NonceResponse, secret []byte) StreamReadWriteCloser {
|
||||
func NewMiddleProxyCipher(conn StreamReadWriteCloser,
|
||||
req *rpc.NonceRequest, resp *rpc.NonceResponse, secret []byte) StreamReadWriteCloser {
|
||||
localAddr := conn.LocalAddr()
|
||||
remoteAddr := conn.RemoteAddr()
|
||||
|
||||
@@ -37,7 +38,8 @@ func NewMiddleProxyCipher(conn StreamReadWriteCloser, req *rpc.NonceRequest, res
|
||||
return NewBlockCipher(conn, enc, dec)
|
||||
}
|
||||
|
||||
func deriveKeys(purpose cipherPurpose, req *rpc.NonceRequest, resp *rpc.NonceResponse, client *net.TCPAddr, remote *net.TCPAddr, secret []byte) ([]byte, []byte) {
|
||||
func deriveKeys(purpose cipherPurpose, req *rpc.NonceRequest, resp *rpc.NonceResponse,
|
||||
client, remote *net.TCPAddr, secret []byte) ([]byte, []byte) {
|
||||
message := bytes.Buffer{}
|
||||
message.Write(resp.Nonce[:])
|
||||
message.Write(req.Nonce[:])
|
||||
|
||||
Reference in New Issue
Block a user