mirror of
https://github.com/cmz0228/hysteria-dev.git
synced 2025-08-12 20:31:47 +00:00
cleanup: drop legacy v2 protocol support
This commit is contained in:
@@ -5,9 +5,8 @@ import (
|
||||
)
|
||||
|
||||
const (
|
||||
protocolVersion = uint8(3)
|
||||
protocolVersionV2 = uint8(2)
|
||||
protocolTimeout = 10 * time.Second
|
||||
protocolVersion = uint8(3)
|
||||
protocolTimeout = 10 * time.Second
|
||||
|
||||
closeErrorCodeGeneric = 0
|
||||
closeErrorCodeProtocol = 1
|
||||
@@ -65,12 +64,3 @@ func (m udpMessage) HeaderSize() int {
|
||||
func (m udpMessage) Size() int {
|
||||
return m.HeaderSize() + len(m.Data)
|
||||
}
|
||||
|
||||
type udpMessageV2 struct {
|
||||
SessionID uint32
|
||||
HostLen uint16 `struc:"sizeof=Host"`
|
||||
Host string
|
||||
Port uint16
|
||||
DataLen uint16 `struc:"sizeof=Data"`
|
||||
Data []byte
|
||||
}
|
||||
|
Reference in New Issue
Block a user