-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Correctly implement QUIC sniffer when handling multiple initial packe…
…ts (#3310) * Correctly implement QUIC sniffer when handling multiple initial packets * Only parse token for initial packet Signed-off-by: Vigilans <vigilans@foxmail.com> * Update test case for QUIC sniffer * Fix testcases * Third packet in `Handshake[2]; packet 1-3` mistakenly copied UDP header into payload, making the payload length 1278 instead of 1250 * Introduce `protocol.ErrProtoNeedMoreData` to allow sniffer to fetch more packets until complete --------- Signed-off-by: Vigilans <vigilans@foxmail.com> Co-authored-by: Shelikhoo <xiaokangwang@outlook.com> Co-authored-by: dyhkwong <50692134+dyhkwong@users.noreply.github.com>
- Loading branch information
1 parent
807d4b2
commit 8ceba34
Showing
5 changed files
with
446 additions
and
177 deletions.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,9 @@ | ||
package protocol | ||
|
||
import ( | ||
"errors" | ||
) | ||
|
||
//go:generate go run github.com/v2fly/v2ray-core/v5/common/errors/errorgen | ||
|
||
var ErrProtoNeedMoreData = errors.New("protocol matches, but need more data to complete sniffing") |
Oops, something went wrong.