mirror of
https://github.com/xvzc/SpoofDPI.git
synced 2024-12-22 14:26:31 +00:00
remove buffer-size parameter
This commit is contained in:
parent
173b5da2a5
commit
874256c9bc
@ -13,6 +13,8 @@ import (
|
||||
"github.com/xvzc/SpoofDPI/util"
|
||||
)
|
||||
|
||||
const BUFFER_SIZE = 1024
|
||||
|
||||
type Proxy struct {
|
||||
addr string
|
||||
port int
|
||||
@ -31,7 +33,7 @@ func New(config *util.Config) *Proxy {
|
||||
windowSize: *config.WindowSize,
|
||||
allowedPattern: config.AllowedPattern,
|
||||
resolver: dns.NewResolver(config),
|
||||
bufferSize: *config.BufferSize,
|
||||
bufferSize: BUFFER_SIZE,
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -22,7 +22,6 @@ type Config struct {
|
||||
AllowedPattern []*regexp.Regexp
|
||||
WindowSize *int
|
||||
Version *bool
|
||||
BufferSize *int
|
||||
}
|
||||
|
||||
type StringArray []string
|
||||
@ -59,7 +58,6 @@ when not given, the client hello packet will be sent in two parts:
|
||||
fragmentation for the first data packet and the rest
|
||||
`)
|
||||
config.Version = flag.Bool("v", false, "print spoof-dpi's version; this may contain some other relevant information")
|
||||
config.BufferSize = flag.Int("buffer-size", 1024, "buffer size, in number of bytes, is the maximum amount of data that can be read at once from a remote resource")
|
||||
var allowedPattern StringArray
|
||||
flag.Var(
|
||||
&allowedPattern,
|
||||
|
Loading…
Reference in New Issue
Block a user