github.com/xxf098/lite-proxy@v0.15.1-0.20230422081941-12c69f323218/transport/ssr/tools/bufPool.go (about) 1 package tools 2 3 import ( 4 "bytes" 5 "crypto/rand" 6 "io" 7 ) 8 9 func AppendRandBytes(b *bytes.Buffer, length int) { 10 b.ReadFrom(io.LimitReader(rand.Reader, int64(length))) 11 }