body

package
v2.8.0-dev Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 18, 2026 License: Apache-2.0, BSD-3-Clause, Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsBodySupported

func IsBodySupported(contentType string) bool

IsBodySupported checks if the body should be analyzed based on content type

func NewEncodable

func NewEncodable(contentType string, reader *io.ReadCloser, limit int) (libddwaf.Encodable, error)

NewEncodable creates a new libddwaf.Encodable from an io.ReadCloser with a size limit It reads up to 'limit' bytes from the reader and returns an error if reading fails If the content is larger than 'limit', it will be truncated and the returned Encodable will have the truncated flag set to true The given reader is not closed by this function and is replaced by a new io.ReadCloser that reads the all the data as if this function had not been called.

func NewEncodableFromData

func NewEncodableFromData(contentType string, data []byte, truncated bool) (libddwaf.Encodable, error)

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL