This repository has been archived by the owner on Sep 6, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 76
update insecure transport to plaintext/2.0.0 #37
Merged
Merged
Changes from 3 commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
9c3ec25
add plaintext/2.0.0 (with ugly protoc hack)
yusefnapora f2cf104
gofmt
yusefnapora d23f421
gofmt (for real this time)
yusefnapora 5a543a7
add `go_package` option to proto files
yusefnapora 01c9fdf
Revert "add `go_package` option to proto files"
yusefnapora 2363ef9
less hacky protobuf imports
yusefnapora ca33db4
add doc comment for PublicKeyFromProto
yusefnapora 95ea126
clean up handshake
yusefnapora c5f2bcb
go fmt, lol
yusefnapora 18de79c
use network.MessageSizeMax for ggio reader
yusefnapora File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This causes pretty severe API breakage.
Transport
option of the go-libp2p constructor.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The private key is unnecessary here. The public key should do.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should deprecate the
New
function and make aWithIdentity()
function that the public key, and returns a function of signaturefunc(id peer.ID) *Transport
that can then be used with the go-libp2p constructor.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Adding a new constructor function and deprecating the old is definitely the way to go 👍
I added the private key to avoid returning
nil
fromLocalPrivateKey
- if we don't care about that then we can just take the public key.