Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

panic: chacha20poly1305: invalid buffer overlap #611

Open
vrde opened this issue Jan 3, 2021 · 1 comment
Open

panic: chacha20poly1305: invalid buffer overlap #611

vrde opened this issue Jan 3, 2021 · 1 comment

Comments

@vrde
Copy link

vrde commented Jan 3, 2021

Version: idena-node-linux-0.23.2

👋 My node crashed with the following message:

INFO [01-02|17:47:33.836] Peer disconnected                        id=QmPWFA7jFP3ejsfzBVZLaFTf3WfLNmX4riqm3W9fj4o4V5
INFO [01-02|17:47:36.413] metric since 2021-01-02 17:22:36.411228892 +0000 UTC
 name             bytesSent bytesReceived msgSent msgReceived
 block            0         4100          0       10
 blockRange       0         18166693      0       13
 flipBody         2463245   3279487       89      117
 flipKey          1870      0             17      0
 getBlockByHash   2574      819           66      21
 getBlocksRange   2109      0             111     0
 handshake        0         1358          0       17
 newTx            1081314   3761477       9437    32784
 proposeBlock     0         15720         0       21
 proposeProof     0         5112          0       24
 pull             1157025   325950        46281   13038
 push             343350    1564050       13734   62562
 snapshotManifest 1394      1312          17      16
 vote             0         1730357       0       11499
 total            5052881   28856435      0       0
ERROR[01-02|17:47:48.426] Proposed block is not found              err="Proposed block was not found"
INFO [01-02|17:47:48.426] Reduction started                        block=0xa64a3477ed61320b3c385c390d47c25eda7cf5268ee2c0c9eb92c9f330623af9
INFO [01-02|17:47:48.438] Reduction completed                      block=0x1d5e3c538848e6fe9a5434544d399b9ece53709d46c3fa8aea14695a21653e7f isEmpty=false
INFO [01-02|17:47:48.438] binaryBa started                         block=0x1d5e3c538848e6fe9a5434544d399b9ece53709d46c3fa8aea14695a21653e7f
panic: chacha20poly1305: invalid buffer overlap

goroutine 992523603 [running]:
golang.org/x/crypto/chacha20poly1305.(*chacha20poly1305).seal(0xc0139f9160, 0xc065a41460, 0x2, 0x20, 0xc00a82a1b0, 0xc, 0xc, 0xc065a41460, 0x3, 0x20, ...)
        /home/travis/gopath/pkg/mod/golang.org/x/crypto@v0.0.0-20200820211705-5c72a883971a/chacha20poly1305/chacha20poly1305_amd64.go:59 +0x3a2
golang.org/x/crypto/chacha20poly1305.(*chacha20poly1305).Seal(0xc0139f9160, 0xc065a41460, 0x2, 0x20, 0xc00a82a1b0, 0xc, 0xc, 0xc065a41460, 0x3, 0x20, ...)
        /home/travis/gopath/pkg/mod/golang.org/x/crypto@v0.0.0-20200820211705-5c72a883971a/chacha20poly1305/chacha20poly1305.go:62 +0xf9
github.com/flynn/noise.aeadCipher.Encrypt(0x2606440, 0xc0139f9160, 0x23b7bd8, 0xc065a41460, 0x2, 0x20, 0x1, 0x0, 0x0, 0x0, ...)
        /home/travis/gopath/pkg/mod/github.com/flynn/noise@v0.0.0-20180327030543-2492fe189ae6/cipher_suite.go:184 +0xf5
github.com/flynn/noise.(*CipherState).Encrypt(...)
        /home/travis/gopath/pkg/mod/github.com/flynn/noise@v0.0.0-20180327030543-2492fe189ae6/state.go:36
github.com/libp2p/go-libp2p-noise.(*secureSession).encrypt(0xc004086c80, 0xc065a41460, 0x2, 0x20, 0xc065a41460, 0x3, 0x20, 0x0, 0x1, 0x0, ...)
        /home/travis/gopath/pkg/mod/github.com/libp2p/go-libp2p-noise@v0.1.1/crypto.go:26 +0xc2
github.com/libp2p/go-libp2p-noise.(*secureSession).Write(0xc004086c80, 0xc065a41460, 0x3, 0x20, 0x0, 0x0, 0x0)
        /home/travis/gopath/pkg/mod/github.com/libp2p/go-libp2p-noise@v0.1.1/rw.go:116 +0x203
github.com/libp2p/go-mplex.(*Multiplex).doWriteMsg(0xc017e34100, 0xc065a41460, 0x3, 0x20, 0xbff44a516fa99201, 0x4f137c64a0d28)
        /home/travis/gopath/pkg/mod/github.com/libp2p/go-mplex@v0.1.2/multiplex.go:277 +0x6a
github.com/libp2p/go-mplex.(*Multiplex).handleOutgoing(0xc017e34100)
        /home/travis/gopath/pkg/mod/github.com/libp2p/go-mplex@v0.1.2/multiplex.go:198 +0x138
created by github.com/libp2p/go-mplex.NewMultiplex
        /home/travis/gopath/pkg/mod/github.com/libp2p/go-mplex@v0.1.2/multiplex.go:106 +0x21f

Dunno if it's something that affects the last version of go-idena, or if you have solved it yet. Feel free to close if it's not useful.

@ridenaio
Copy link
Contributor

Hi, thanks for the report!

We've added new issue for go-libp2p-noise dependency.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants