mirror of https://github.com/bjdgyc/anylink.git
修复sniNewParser切片越界的问题
This commit is contained in:
parent
d5205c74cf
commit
710cfe4244
|
@ -56,7 +56,7 @@ func sniNewParser(b []byte) (uint8, string) {
|
|||
sessionIDLength := int(rest[current])
|
||||
current += 1
|
||||
current += sessionIDLength
|
||||
if current >= restLen {
|
||||
if current+1 >= restLen {
|
||||
return acc_proto_https, ""
|
||||
}
|
||||
cipherSuiteLength := (int(rest[current]) << 8) + int(rest[current+1])
|
||||
|
|
Loading…
Reference in New Issue