Browse Source

random size from 0

dev
BreakWa11 9 years ago
parent
commit
125c3e88fd
  1. 2
      shadowsocks/obfsplugin/http_simple.py

2
shadowsocks/obfsplugin/http_simple.py

@ -92,7 +92,7 @@ class http_simple(plain.plain):
return buf return buf
head_size = self.get_head_size(buf, 30) head_size = self.get_head_size(buf, 30)
if len(buf) - head_size > 64: if len(buf) - head_size > 64:
headlen = head_size + random.randint(1, 64) headlen = head_size + random.randint(0, 64)
else: else:
headlen = len(buf) headlen = len(buf)
headdata = buf[:headlen] headdata = buf[:headlen]

Loading…
Cancel
Save