-
Notifications
You must be signed in to change notification settings - Fork 407
(1/4) Enum Dispatch NOISE State Machine & Unit Tests #691
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
Closed
julianknutsen
wants to merge
45
commits into
lightningdevkit:main
from
julianknutsen:new-state-machine
Closed
Changes from all commits
Commits
Show all changes
45 commits
Select commit
Hold shift + click to select a range
244faa7
Squash changes from 494 into a single commit
julianknutsen ba37213
Fix compilation bug in 494.
julianknutsen 98bc0da
tests: Add unit tests to handshake/mod.rs
julianknutsen 52da509
delete: Remove duplicate tests
julianknutsen bfe6c4c
refactor: Create enum-dispatch NOISE state machine
julianknutsen c154f09
refactor: Use new state machine in PeerHandshake
julianknutsen 9445fea
refactor: Move helper functions to the states.rs
julianknutsen a0d6690
refactor: Structure initialize_state based on RFC
julianknutsen a68af2d
refactor: Structure calculate_act_message based on RFC
julianknutsen abf9241
refactor: Structure process_act_message based on RFC
julianknutsen 3eb3146
refactor: Structure creation of Act3 based on RFC
julianknutsen dbd1a21
refactor: Structure receiving of Act3 data based on RFC
julianknutsen c88535a
refactor: Inline single use constructors
julianknutsen 41a8ac0
refactor: Pull public key generation to the initial states
julianknutsen 8f17345
refactor: Remove HandshakeHash wrapper struct
julianknutsen 988e767
refactor: Combine duplicate code path for act1 and act2
julianknutsen 1e81642
refactor: Introduce ChainingKey type alias
julianknutsen de5a2e8
refactor: Remove Act object
julianknutsen e0a1e71
refactor: Remove get_remote_pubkey interface
julianknutsen 2f67eed
refactor: Clean up process_peer_data
julianknutsen ab4ff64
refactor: Doc and variable name cleanup in handshake/mod.rs
julianknutsen f29936b
tests: Finish testing handshake/mod.rs
julianknutsen ab277b4
refactor: Clean up use of Sha256 in states.rs
julianknutsen 57f95fe
refactor: Clean up hkdf::derive and add test
julianknutsen ea0ff51
refactor: Rename Handshake2 and related structs/enums
julianknutsen 816a83c
refactor: Clean up visibility/imports in handshake/
julianknutsen 9c5a4b7
tests: Leverage RFC test vectors in unit tests
julianknutsen 3ae7604
refactor: Simplify logic for init message sending
julianknutsen afd0334
refactor: Clean up unused variable warnings
julianknutsen ab2258c
refactor: Hide empty next() requirement inside PeerHandshake
julianknutsen cc5cc9a
refactor: Remove unnecessary copy_from_slice calls in states.rs
julianknutsen b617dfa
tests: Add new fuzz testing for PeerHandshake
julianknutsen 4435b12
delete: Remove peer_channel_encryptor.rs
julianknutsen a123f5e
fix: Allow partial act messages to be received
julianknutsen 070d19b
fix: Conduit::Decryptor should not panic on decryption failure
julianknutsen 3a43c21
test: Update handshake fuzz test to cover more cases
julianknutsen ec5803c
review: Split outbound initialization into new()/set_up()
julianknutsen 1189e84
feature: Tighten the constraints for act message sizes
julianknutsen 229c35f
perf: Replace Vec w/ static arrays for act buffers
julianknutsen 753b517
perf: Remove Vec from chacha::encrypt/decrypt
julianknutsen a7a25ca
review: Non-controversial renames, nits, small fixups
julianknutsen b8136be
review: rename hkdf -> hkdf5869rfc.rs
julianknutsen 8c6da10
review: Explicitly set version in Act creation
julianknutsen 19a0f42
review: ActBuilder::fill() returns the number of bytes consumed
julianknutsen 30286c0
docs: Add license to new peers/ files
julianknutsen 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
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains hidden or 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 hidden or 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.
Lets move peers up to its own top-level module.
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 was just straight for #494, but it seems fine to make it a top-level. Added #718