Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
neoppod
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Levin Zimmermann
neoppod
Commits
c3fb22a4
Commit
c3fb22a4
authored
Jan 15, 2021
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
X move handshake do to neonet
parent
fad6baf1
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
2 deletions
+8
-2
go/neo/neonet/newlink.go
go/neo/neonet/newlink.go
+7
-0
go/neo/proto/proto.go
go/neo/proto/proto.go
+1
-2
No files found.
go/neo/neonet/newlink.go
View file @
c3fb22a4
...
...
@@ -185,6 +185,13 @@ func _handshakeServer(ctx context.Context, conn net.Conn, version uint32) (enc p
return
peerEnc
,
rxbuf
,
nil
}
// handshake hello:
//
// - 00 00 00 <ver> for 'N' encoding, and
// - 92 c4 03 NEO ... for 'M' encoding (= msgpack of (b"NEO", <ver>))
//
// the first byte is different from TLS handshake (0x16).
func
txHello
(
errctx
string
,
conn
net
.
Conn
,
version
uint32
,
enc
proto
.
Encoding
)
(
err
error
)
{
defer
xerr
.
Context
(
&
err
,
errctx
)
...
...
go/neo/proto/proto.go
View file @
c3fb22a4
...
...
@@ -76,8 +76,7 @@ import (
const
(
// The protocol version must be increased whenever upgrading a node may require
// to upgrade other nodes. It is encoded as a 4-bytes big-endian integer and
// the high order byte 0 is different from TLS Handshake (0x16). XXX update for msgpack
// to upgrade other nodes.
Version
=
6
// length of packet header in 'N'-encoding
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment