MCPcopy Create free account
hub / github.com/pion/dtls / WithPaddingLengthGenerator

Function WithPaddingLengthGenerator

options.go:532–541  ·  view source on GitHub ↗

WithPaddingLengthGenerator sets the padding length generator. Returns an error if the generator is nil.

(fn func(uint) uint)

Source from the content-addressed store, hash-verified

530// WithPaddingLengthGenerator sets the padding length generator.
531// Returns an error if the generator is nil.
532func WithPaddingLengthGenerator(fn func(uint) uint) Option {
533 return sharedOption(func(c *dtlsConfig) error {
534 if fn == nil {
535 return errNilPaddingLengthGenerator
536 }
537 c.paddingLengthGenerator = fn
538
539 return nil
540 })
541}
542
543// WithHelloRandomBytesGenerator sets the hello random bytes generator.
544// Returns an error if the generator is nil.

Callers 1

Calls 1

sharedOptionFuncType · 0.85

Tested by 1

Used in the wild real call sites across dependent graphs

searching dependent graphs…