Commit Graph

21 Commits

Author SHA1 Message Date
Matt Joiner c6ee03f449 gofumpt 2021-11-08 14:47:01 +11:00
YenForYang a8db640c62
Drop bradfitz/iter dependency (#605)
* Drop bradfitz/iter dependency

`range iter.N` looks nice and doesn't allocate, but unfortunately using a `range` expression blocks a function from being inlined wherever it's used (for now). It's not that we need inlining in all cases, but I do think a C-style for loop looks just as nice and is probably clearer to the majority. There also aren't any clear disadvantages to changing (unless you just happen to dislike the look of C)

* Update misc_test.go

* Update rlreader_test.go

* Update torrent_test.go

* Update bench_test.go

* Update client_test.go

* Update iplist_test.go

* Update mse_test.go

* Update peerconn_test.go

* Update peerconn.go

* Update order_test.go

* Update decoder_test.go

* Update main.go

* Update bench-piece-mark-complete.go

* Update main.go

* Update torrent.go

* Update iplist_test.go

* Update main.go
2021-09-14 13:46:50 +10:00
Shubhendra Singh Chauhan 0cdb33ede0 fixed code quality issues using DeepSource
* Added .deepsource.toml

* Removed empty default in select

* Removed unnecessary use of slice

* Fixed check for empty string
2021-01-30 15:23:49 +11:00
Matt Joiner 176ba51313 Add benchmark for receiving handshakes with large skey counts 2021-01-04 11:33:46 +11:00
Matt Joiner 73823ee61d Add mse.ReceiveHandshakeEx 2021-01-04 10:49:28 +11:00
Matt Joiner ea4be5cecb mse: Fix race in BenchmarkStreamRC4 2019-10-01 18:11:44 +10:00
Matt Joiner fc03dcb859 Set the connection.cryptoMethod
It was unwittingly dropped from received connections, and may never have been set for initiated connections.
2018-02-16 10:59:56 +11:00
Matt Joiner 066cdd520b Add mse.CryptoMethod type 2018-02-16 10:36:29 +11:00
Matt Joiner 4190856b6c sortimports 2017-12-01 18:12:29 +11:00
Matt Joiner 9bf50493c3 mse: Move sliceIter into test file 2017-11-04 17:07:42 +11:00
Matt Joiner 881f1a7e35 Support plaintext crypto method for protocol header encryption 2017-09-13 18:20:20 +10:00
Matt Joiner 29e06fb83c mse: Support plaintext crypto mode 2017-09-13 16:19:14 +10:00
Matt Joiner f1d292203e mse: Add a read/write benchmark 2017-09-13 00:58:54 +10:00
Matt Joiner 69f4c5a7e9 Minor comments and test improvement 2016-09-16 12:13:06 +10:00
Seth Hoenig 9f4bf70e17 refactor struct identifiers to follow conventional go names 2016-04-18 23:11:11 -05:00
Matt Joiner 3aa78763aa Use rogpeppe's sortimports to fix this goimports ordering madness 2015-03-26 17:18:08 +11:00
Matt Joiner 0d5c10ef53 mse: Check that readUntil doesn't read indefinitely while synchronizing 2015-03-18 18:16:27 +11:00
Matt Joiner 8e8d75dda1 Support initial payload, and improve tests 2015-03-13 14:30:48 +11:00
Matt Joiner d57f5896d4 mse: Tons of fixes and improvements 2015-03-13 06:16:49 +11:00
Matt Joiner 13a5b8b279 msg: Return usable object after handshake 2015-03-12 20:29:48 +11:00
Matt Joiner 954e03952a mse: Got basic message stream encryption working with some tests
Not complete yet.
2015-03-12 20:03:29 +11:00