Documentation
¶
Index ¶
- Constants
- Variables
- func CheckOrCreateConfigDir() error
- func CreateConfigDir(path string) error
- func FileExists(path string) bool
- func FinalizeHighRatePolicy(conf *Config, expandedInputs int) error
- func FormattedVersion() string
- func HighRatePolicyRequested(opts *ConfigOptions) bool
- func HostURLFromRequest(req Request) string
- func MarkExplicitOptions(options *ConfigOptions, names ...string)
- func ParseVarSelector(sel string) (source, key string, err error)
- func RandomString(n int) string
- func RequestContainsKeyword(req Request, kw string) bool
- func StrInSlice(key string, slice []string) bool
- func UniqStringSlice(inslice []string) []string
- func UrlEqual(url1, url2 *url.URL) bool
- func ValidateVarSource(source, key string) error
- func Version() string
- type AuditLogger
- type AutocalibrationStrategy
- type CapacityAck
- type CapacityAdvisor
- type CapacityCause
- type CapacityProposal
- type CapacitySubscription
- type Config
- type ConfigOptionProvenance
- type ConfigOptions
- type EffectiveConcurrencyReport
- type FilterOptions
- type FilterProvider
- type FlagMetadata
- type FlagRegistry
- type GeneralOptions
- type HTTP3Fingerprint
- type HTTP3PreflightReport
- type HTTPOptions
- type HighRatePolicyReport
- type InputOptions
- type InputProvider
- type InputProviderConfig
- type InternalInputProvider
- type MatcherManager
- type MatcherOptions
- type Multierror
- type OutputOptions
- type OutputProvider
- type PreflightConfig
- type PreflightProbeReport
- type Progress
- type ProtocolPreflightReport
- type ProtocolPreflightTimings
- type RegisteredFlag
- type Request
- type RequestStrategyPreflightReport
- type Response
- type ResponseOptimizationReport
- type Result
- type RunDrainTelemetry
- type RunEligibilityTelemetry
- type RunLogicalLedgerTelemetry
- type RunPreparedRequestHeaderFallbackTelemetry
- type RunPreparedRequestHeadersTelemetry
- type RunProtocolTelemetry
- type RunQUICDiagnosticsTelemetry
- type RunQUICSlotTelemetry
- type RunRequestStrategyTelemetry
- type RunResponseLatencyTelemetry
- type RunResponseTelemetry
- type RunTelemetry
- type RunTransportAttempt
- type RunTransportAttemptLifecycleRecorder
- type RunTransportAttemptRecorder
- type RunTransportAttemptRole
- type RunTransportMethodTelemetry
- type RunTransportRoleTelemetry
- type RunTransportTelemetry
- type RunWorkerCapacityTelemetry
- type RunnerProvider
- type Scraper
- type ScraperResult
- type ValueRange
- type VarExtract
Constants ¶
const ( VarSourceAuto = "auto" VarSourceForm = "form" VarSourceMeta = "meta" VarSourceCookie = "cookie" VarSourceHeader = "header" HarnessRunHeader = "X-H3fuzz-Harness-Run" HarnessRoleHeader = "X-H3fuzz-Harness-Role" )
Sources a VarExtract can select a value from by name instead of by regex. VarSourceAuto tries form, meta, cookie and header, in that order.
const ( SectionHTTP = "http" SectionGeneral = "general" SectionCompat = "compat" SectionMatcher = "matcher" SectionFilter = "filter" SectionInput = "input" SectionOutput = "output" )
Section keys — the help groups, in display order (rendered by help.go).
const ( MaxHTTP3Connections = 256 MaxHTTP3Streams = 4096 MaxHTTP3Workers = 65_536 MaxHTTP3ProbeTimeoutSecs = 60 DefaultHTTP3TargetRPS = 100_000 )
Variables ¶
var ( // VERSION is the linker injection target for the release version: goreleaser // sets it to the git tag via -ldflags -X (see .goreleaser.yml). Do not delete // it because nothing in this package appears to read it; the linker reference // is invisible to a Go-source search, and -X against a missing symbol fails // silently. The literal below is a placeholder, not a real version, and is // only ever seen when the ldflags injection, the VCS metadata and the module // version are all unavailable. VERSION = "0.0.0" // VERSION_APPENDIX marks a non-release build. goreleaser empties it via -X, // which is how Version() tells a release binary from a development one. VERSION_APPENDIX = "-dev" CONFIGDIR = filepath.Join(xdg.ConfigHome, "h3fuzz") HISTORYDIR = filepath.Join(CONFIGDIR, "history") SCRAPERDIR = filepath.Join(CONFIGDIR, "scraper") AUTOCALIBDIR = filepath.Join(CONFIGDIR, "autocalibration") )
var VarSources = []string{VarSourceForm, VarSourceMeta, VarSourceCookie, VarSourceHeader}
VarSources lists the sources that can be named in a "[source]key" spec, in the order VarSourceAuto tries them.
Functions ¶
func CheckOrCreateConfigDir ¶
func CheckOrCreateConfigDir() error
func CreateConfigDir ¶
func FileExists ¶
FileExists checks if the filepath exists and is not a directory. Returns false in case it's not possible to describe the named file.
func FinalizeHighRatePolicy ¶
FinalizeHighRatePolicy applies the documented latency/headroom formula after protocol and request-strategy qualification have completed. expandedInputs is the input provider's post-extension total.
func FormattedVersion ¶
func FormattedVersion() string
FormattedVersion returns the version prepared for display. Released versions are prefixed with "v" (e.g. "v2.2.0"); development builds are returned unprefixed (e.g. "git-20260613-aabbccdd") since a "v" reads as noise there.
func HighRatePolicyRequested ¶
func HighRatePolicyRequested(opts *ConfigOptions) bool
HighRatePolicyRequested reports whether any CLI-only high-rate policy option was supplied. It lets process modes such as the web console reject the policy before they bypass normal scan configuration.
func HostURLFromRequest ¶
HostURLFromRequest gets a host + path without the filename or last part of the URL path
func MarkExplicitOptions ¶
func MarkExplicitOptions(options *ConfigOptions, names ...string)
MarkExplicitOptions records canonical option names observed by a CLI or UI.
func ParseVarSelector ¶
ParseVarSelector splits "[source]key" into its source and key, or returns VarSourceAuto for a bare key. The tag is a prefix because field names can end in brackets (PHP's "data[_Token][key]") and contain colons (JSF's "loginForm:token"); only the first "]" closes the tag.
func RandomString ¶
RandomString returns a random string of length of parameter n
func RequestContainsKeyword ¶
RequestContainsKeyword checks if a keyword is present in any field of a request
func StrInSlice ¶
func UniqStringSlice ¶
UniqStringSlice returns an unordered slice of unique strings. The duplicates are dropped
func ValidateVarSource ¶
ValidateVarSource checks a source/key pair, whether it came from the CLI or a config file.
func Version ¶
func Version() string
Version returns the ffuf version string.
It resolves through four sources, in this order:
- Release builds have VERSION injected via -ldflags by goreleaser and VERSION_APPENDIX emptied, so they report a plain semantic version like "2.2.0" with no manual constant bump required.
- Builds from a source checkout report a "git-<UTC date>-<short commit>" identifier derived from the VCS metadata `go build` embeds, e.g. "git-20260613-aabbccdd". VCS metadata takes precedence over the module version below, because a working tree can sit on a tagged commit while carrying uncommitted changes.
- Binaries produced by `go install github.com/assetnote/h3fuzz@vX.Y.Z` carry no VCS metadata, but the toolchain records the module version they were built from, so report that.
- Failing all of those, VERSION+VERSION_APPENDIX, which is a placeholder rather than a real version.
Types ¶
type AuditLogger ¶
type AuditLogger interface {
Close()
Write(data interface{}) error
}
AuditLogger is responsible for providing auditing output of every request/response sent and recieved by FFUF
type AutocalibrationStrategy ¶
type CapacityAck ¶
type CapacityAck struct {
ExecutionGeneration uint64 `json:"execution_generation"`
Epoch uint64 `json:"epoch"`
ProposedWorkers int `json:"proposed_workers"`
ActualLiveWorkers int `json:"actual_live_workers"`
RemainingInputCap int `json:"remaining_input_cap"`
SupervisorState string `json:"supervisor_state"`
AcknowledgedAt time.Time `json:"acknowledged_at"`
}
CapacityAck reports the actual live worker count after a supervisor applies a proposal. Shrinks are acknowledged only after retiring workers finish their current task.
type CapacityAdvisor ¶
type CapacityAdvisor interface {
SubscribeCapacity(executionGeneration uint64) (CapacitySubscription, error)
}
CapacityAdvisor is the narrow bidirectional seam between a transport pool and the engine's request-worker supervisor.
type CapacityCause ¶
type CapacityCause string
CapacityCause identifies why an adaptive request-worker target changed.
const ( CapacityCauseSubscriberReady CapacityCause = "subscriber_ready" CapacityCausePoolGrowth CapacityCause = "pool_growth" CapacityCausePoolShrink CapacityCause = "pool_shrink" CapacityCauseRepublish CapacityCause = "republish" )
type CapacityProposal ¶
type CapacityProposal struct {
ExecutionGeneration uint64 `json:"execution_generation"`
Epoch uint64 `json:"epoch"`
DesiredWorkers int `json:"desired_workers"`
Cause CapacityCause `json:"cause"`
PublishedAt time.Time `json:"published_at"`
}
CapacityProposal is the pool's latest desired application-worker capacity. ExecutionGeneration prevents a queued recursion job from consuming an update intended for the supervisor that preceded it. Epoch orders updates within and across generations for one process.
type CapacitySubscription ¶
type CapacitySubscription interface {
Proposals() <-chan CapacityProposal
Acknowledge(CapacityAck)
Close()
}
CapacitySubscription is a bounded, latest-value worker-capacity stream. Proposals and acknowledgements are both non-blocking and coalescing.
type Config ¶
type Config struct {
AuditLog string `json:"auditlog"`
AutoCalibration bool `json:"autocalibration"`
AutoCalibrationKeyword string `json:"autocalibration_keyword"`
AutoCalibrationPerHost bool `json:"autocalibration_perhost"`
AutoCalibrationStrategies []string `json:"autocalibration_strategies"`
AutoCalibrationStrings []string `json:"autocalibration_strings"`
Cancel context.CancelFunc `json:"-"`
Colors bool `json:"colors"`
CommandKeywords []string `json:"-"`
CommandLine string `json:"cmdline"`
ConfigFile string `json:"configfile"`
Context context.Context `json:"-"`
Data string `json:"postdata"`
Debuglog string `json:"debuglog"`
Delay optRange `json:"delay"`
DirSearchCompat bool `json:"dirsearch_compatibility"`
Encoders []string `json:"encoders"`
Extensions []string `json:"extensions"`
FilterMode string `json:"fmode"`
FollowRedirects bool `json:"follow_redirects"`
HarnessRunID string `json:"-" toml:"-"`
Headers map[string]string `json:"headers"`
IgnoreBody bool `json:"ignorebody"`
IgnoreWordlistComments bool `json:"ignore_wordlist_comments"`
InputMode string `json:"inputmode"`
InputNum int `json:"cmd_inputnum"`
InputProviders []InputProviderConfig `json:"inputproviders"`
InputShell string `json:"inputshell"`
Json bool `json:"json"`
MatcherManager MatcherManager `json:"matchers"`
MatcherMode string `json:"mmode"`
MaxTime int `json:"maxtime"`
MaxTimeJob int `json:"maxtime_job"`
Method string `json:"method"`
Noninteractive bool `json:"noninteractive"`
OutputDirectory string `json:"outputdirectory"`
OutputFile string `json:"outputfile"`
OutputFormat string `json:"outputformat"`
OutputSkipEmptyFile bool `json:"OutputSkipEmptyFile"`
RunTelemetry string `json:"-" toml:"-"`
ProfilingEnabled bool `json:"-" toml:"-"`
QuicTelemetry bool `json:"-" toml:"-"`
QuicQlogDir string `json:"-" toml:"-"`
ProgressFrequency int `json:"-"`
ProxyURL string `json:"proxyurl"`
Quiet bool `json:"quiet"`
Rate int64 `json:"rate"`
Raw bool `json:"raw"`
Recursion bool `json:"recursion"`
RecursionDepth int `json:"recursion_depth"`
RecursionStrategy string `json:"recursion_strategy"`
ReplayProxyURL string `json:"replayproxyurl"`
RequestFile string `json:"requestfile"`
RequestProto string `json:"requestproto"`
ScraperFile string `json:"scraperfile"`
Scrapers string `json:"scrapers"`
ScraperNeedsResponseBody bool `json:"-" toml:"-"`
SNI string `json:"sni"`
StopOn403 bool `json:"stop_403"`
StopOnAll bool `json:"stop_all"`
StopOnErrors bool `json:"stop_errors"`
Threads int `json:"threads"`
ThreadsExplicit bool `json:"-" toml:"-"`
Timeout int `json:"timeout"`
Url string `json:"url"`
Verbose bool `json:"verbose"`
Wordlists []string `json:"wordlists"`
Http1 bool `json:"http1,omitempty"`
Http2 bool `json:"http2"`
Http2Selected bool `json:"-" toml:"-"`
Http3 bool `json:"http3"`
NoHttp3 bool `json:"no_http3"`
Http3Fingerprint bool `json:"http3_fingerprint"`
NoResponseOptimization bool `json:"no_response_optimization"`
Http3Connections int `json:"http3_connections"`
Http3MaxConnections int `json:"http3_max_connections"`
Http3MaxWorkers int `json:"http3_max_workers"`
Http3MaxWorkersExplicit bool `json:"-" toml:"-"`
Http3Streams int `json:"http3_streams"`
Http3ProbeTimeout int `json:"http3_probe_timeout"`
Http3Selected bool `json:"-" toml:"-"`
Http3ConnectionsActive int `json:"-" toml:"-"`
Http3Reason string `json:"-" toml:"-"`
ResponseOptimizationStrategy string `json:"-" toml:"-"`
ResponseOptimizationReason string `json:"-" toml:"-"`
ProtocolPreflight ProtocolPreflightReport `json:"-" toml:"-"`
HighRatePolicy *HighRatePolicyReport `json:"-" toml:"-"`
ClientCert string `json:"client-cert"`
ClientKey string `json:"client-key"`
Preflights []PreflightConfig `json:"preflights"`
Postflights []PreflightConfig `json:"postflights"`
PreflightMode string `json:"preflight_mode"`
PreflightError string `json:"preflight_error"`
PreflightAnyHost bool `json:"preflight_anyhost"`
// RateLimitFunc blocks until the shared rate limiter allows another request.
// The engine sets it so preflight/postflight requests (sent from the runner,
// outside the dispatch loop) also honor -rate and -p. Nil means unmetered.
RateLimitFunc func() `json:"-" toml:"-"`
// Options retains the raw ConfigOptions this Config was built from, so the
// configuration can be re-serialized (FFUFHASH history and similar features)
// directly, with no hand-maintained reverse mapper. Set by ConfigFromOptions;
// nil for a Config assembled by other means.
Options *ConfigOptions `json:"-"`
}
func ConfigFromOptions ¶
func ConfigFromOptions(parseOpts *ConfigOptions, ctx context.Context, cancel context.CancelFunc) (*Config, error)
ConfigFromOptions parses the values in ConfigOptions struct, ensures that the values are sane, and creates a Config struct out of them.
func NewConfig ¶
func NewConfig(ctx context.Context, cancel context.CancelFunc) Config
NewConfig returns a Config ready for ConfigFromOptions to populate. It sets ONLY what ConfigFromOptions does not: the context, non-nil slice/map fields (which are appended to or indexed during parsing), and the few defaults for fields that are not copied from the options. Every other default lives once in NewConfigOptions and flows in through ConfigFromOptions — listing it here too would just duplicate that single source.
func (*Config) SetContext ¶
func (c *Config) SetContext(ctx context.Context, cancel context.CancelFunc)
type ConfigOptionProvenance ¶
type ConfigOptionProvenance struct {
Threads bool `json:"threads,omitempty"`
Http3Connections bool `json:"http3_connections,omitempty"`
Http3MaxConnections bool `json:"http3_max_connections,omitempty"`
Http3MaxWorkers bool `json:"http3_max_workers,omitempty"`
Http3Streams bool `json:"http3_streams,omitempty"`
Scrapers bool `json:"scrapers,omitempty"`
Http3HighRate bool `json:"-" toml:"-"`
Http3HighRateAcknowledge bool `json:"-" toml:"-"`
Http3TargetRPS bool `json:"-" toml:"-"`
Http3LatencyMS bool `json:"-" toml:"-"`
}
ConfigOptionProvenance keeps values that equal their defaults distinguishable from omission across config, history, web, and imported-command round trips.
type ConfigOptions ¶
type ConfigOptions struct {
Filter FilterOptions `json:"filters"`
General GeneralOptions `json:"general"`
HTTP HTTPOptions `json:"http"`
Input InputOptions `json:"input"`
Matcher MatcherOptions `json:"matchers"`
Output OutputOptions `json:"output"`
Provenance ConfigOptionProvenance `json:"provenance,omitempty" toml:"-"`
}
func NewConfigOptions ¶
func NewConfigOptions() *ConfigOptions
NewConfigOptions returns a newly created ConfigOptions struct with default values
func ReadConfig ¶
func ReadConfig(configFile string) (*ConfigOptions, error)
func ReadDefaultConfig ¶
func ReadDefaultConfig() (*ConfigOptions, error)
type FilterOptions ¶
type FilterOptions struct {
Mode string `json:"mode" ffuf:"fmode" section:"filter" usage:"Filter set operator. Either of: and, or"`
Lines string `` /* 133-byte string literal not displayed */
Regexp string `json:"regexp" ffuf:"fr" section:"filter" usage:"Filter regexp"`
Size string `json:"size" ffuf:"fs" section:"filter" usage:"Filter HTTP response size. Comma separated list of sizes and ranges"`
Status string `` /* 129-byte string literal not displayed */
Time string `` /* 153-byte string literal not displayed */
Words string `` /* 133-byte string literal not displayed */
}
type FilterProvider ¶
type FilterProvider interface {
Filter(response *Response) (bool, error)
Repr() string
ReprVerbose() string
}
FilterProvider is a generic interface for both Matchers and Filters
type FlagMetadata ¶
type FlagMetadata struct {
Name string `json:"name"`
JSONPath string `json:"json_path,omitempty"`
Section string `json:"section"`
Type string `json:"type"`
Default interface{} `json:"default,omitempty"`
Usage string `json:"usage"`
Aliases []string `json:"aliases"`
Repeatable bool `json:"repeatable"`
Hidden bool `json:"hidden"`
Choices []string `json:"choices,omitempty"`
Min *int `json:"min,omitempty"`
Max *int `json:"max,omitempty"`
Available bool `json:"available"`
}
FlagMetadata is the machine-readable description of one canonical command line option. The web console consumes this instead of maintaining a second, inevitably stale list of ffuf flags.
func DescribeFlags ¶
func DescribeFlags(opts *ConfigOptions) []FlagMetadata
DescribeFlags derives API metadata from the same struct tags used by RegisterFlags. Defaults are copied through JSON so callers cannot mutate opts through slice values stored in the returned descriptions.
type FlagRegistry ¶
type FlagRegistry struct {
// contains filtered or unexported fields
}
FlagRegistry is the single source of truth describing every CLI flag, used to drive the segmented help output. It is produced by RegisterFlags.
func RegisterFlags ¶
func RegisterFlags(fs *flag.FlagSet, o *ConfigOptions) *FlagRegistry
RegisterFlags is the single source of truth for CLI flag registration. It walks the `ffuf:`-tagged fields of ConfigOptions via reflection and registers each on fs — using the field's CURRENT value as the default, which preserves the config-file < command-line precedence — then applies the explicit supplement. It returns a FlagRegistry describing every flag for the segmented help.
type GeneralOptions ¶
type GeneralOptions struct {
AutoCalibration bool `json:"autocalibration" ffuf:"ac" section:"general" usage:"Automatically calibrate filtering options"`
AutoCalibrationKeyword string `json:"autocalibration_keyword" ffuf:"ack" section:"general" usage:"Autocalibration keyword"`
AutoCalibrationPerHost bool `json:"autocalibration_per_host" ffuf:"ach" section:"general" usage:"Per host autocalibration"`
AutoCalibrationStrategies []string `` /* 164-byte string literal not displayed */
AutoCalibrationStrings []string `` /* 158-byte string literal not displayed */
Colors bool `json:"colors" ffuf:"c" section:"general" usage:"Colorize output."`
ConfigFile string `toml:"-" json:"config_file" ffuf:"config" section:"general" usage:"Load configuration from a file"`
HarnessRunID string `` /* 145-byte string literal not displayed */
Delay string `` /* 145-byte string literal not displayed */
Json bool `json:"json" ffuf:"json" section:"general" usage:"JSON output, printing newline-delimited JSON records"`
MaxTime int `json:"maxtime" ffuf:"maxtime" section:"general" usage:"Maximum running time in seconds for entire process."`
MaxTimeJob int `json:"maxtime_job" ffuf:"maxtime-job" section:"general" usage:"Maximum running time in seconds per job."`
Noninteractive bool `json:"noninteractive" ffuf:"noninteractive" section:"general" usage:"Disable the interactive console functionality"`
Quiet bool `json:"quiet" ffuf:"s" section:"general" usage:"Do not print additional information (silent mode)"`
Rate int `json:"rate" ffuf:"rate" section:"general" usage:"Rate of requests per second"`
ScraperFile string `json:"scraperfile" ffuf:"scraperfile" section:"general" usage:"Custom scraper file path"`
Scrapers string `json:"scrapers" ffuf:"scrapers" section:"general" usage:"Active scraper groups"`
Searchhash string `json:"-" ffuf:"search" section:"general" usage:"Search for a FFUFHASH payload from h3fuzz history"`
ShowVersion bool `toml:"-" json:"-" ffuf:"V" section:"general" usage:"Show version information."`
StopOn403 bool `json:"stop_on_403" ffuf:"sf" section:"general" usage:"Stop when > 95% of responses return 403 Forbidden"`
StopOnAll bool `json:"stop_on_all" ffuf:"sa" section:"general" usage:"Stop on all error cases. Implies -sf and -se."`
StopOnErrors bool `json:"stop_on_errors" ffuf:"se" section:"general" usage:"Stop on spurious errors"`
Threads int `json:"threads" ffuf:"t" section:"general" usage:"Number of concurrent threads."`
Verbose bool `` /* 132-byte string literal not displayed */
Web bool `toml:"-" json:"-" ffuf:"web" section:"general" usage:"Start the authenticated h3fuzz web console"`
WebListen string `toml:"-" json:"-" ffuf:"web-listen" section:"general" usage:"Web console listen address in host:port form"`
WebDatabase string `toml:"-" json:"-" ffuf:"web-db" section:"general" usage:"Web console SQLite database path"`
WebTLSCertificate string `` /* 143-byte string literal not displayed */
WebTLSPrivateKey string `toml:"-" json:"-" ffuf:"web-key" section:"general" usage:"PEM TLS private key for the web console (requires -web-cert)"`
WebPlainHTTP bool `` /* 154-byte string literal not displayed */
WebAllowRemote bool `toml:"-" json:"-" ffuf:"web-allow-remote" section:"general" usage:"Allow the web console to bind to a non-loopback address"`
WebAllowInputCmd bool `toml:"-" json:"-" ffuf:"web-allow-input-cmd" section:"general" usage:"Allow web sessions to execute input-cmd commands"`
}
type HTTP3Fingerprint ¶
type HTTP3Fingerprint struct {
Target string `json:"target"`
Supported bool `json:"supported"`
HighRateReady bool `json:"high_rate_ready"`
Reason string `json:"reason,omitempty"`
ALPN string `json:"alpn,omitempty"`
QUICVersion string `json:"quic_version,omitempty"`
HTTPVersion string `json:"http_version,omitempty"`
StatusCode int `json:"status_code,omitempty"`
ConnectionReused bool `json:"connection_reused"`
ConcurrentStreamsCompleted int `json:"concurrent_streams_completed"`
ConcurrentStreamsAttempted int `json:"concurrent_streams_attempted"`
QUICDatagrams bool `json:"quic_datagrams"`
HTTP3Datagrams bool `json:"http3_datagrams"`
RemoteAddr string `json:"remote_addr,omitempty"`
ElapsedMillis int64 `json:"elapsed_ms"`
}
HTTP3Fingerprint is the machine-readable result produced by -http3-fingerprint and by the automatic protocol probe. A successful QUIC handshake alone is not enough: Supported is set only after ALPN h3 was negotiated and a complete HTTP response was received.
type HTTP3PreflightReport ¶
type HTTP3PreflightReport struct {
Advertised bool `json:"advertised"`
Advertisement string `json:"advertisement,omitempty"`
AdvertisementProbe PreflightProbeReport `json:"advertisement_probe"`
Negotiated bool `json:"negotiated"`
NegotiationProbe PreflightProbeReport `json:"negotiation_probe"`
Fingerprint HTTP3Fingerprint `json:"fingerprint"`
}
HTTP3PreflightReport retains both discovery and direct negotiation evidence. Servers are often HTTP/3 capable without advertising Alt-Svc (or advertise it while UDP is blocked), so the two facts must not be collapsed into one flag.
type HTTPOptions ¶
type HTTPOptions struct {
Cookies []string `` /* 155-byte string literal not displayed */
Data string `json:"data" ffuf:"d" alias:"data,data-ascii,data-binary" section:"http" usage:"POST data"`
FollowRedirects bool `json:"follow_redirects" ffuf:"r" section:"http" usage:"Follow redirects"`
Headers []string `` /* 141-byte string literal not displayed */
Http1 bool `json:"http1,omitempty" ffuf:"http1" section:"http" usage:"Force HTTP/1.1 for the target"`
Http3 bool `json:"http3" ffuf:"http3" section:"http" usage:"Force HTTP/3 for the target"`
NoHttp3 bool `json:"no_http3" ffuf:"no-http3" section:"http" usage:"Disable automatic HTTP/3 detection"`
Http3Fingerprint bool `` /* 138-byte string literal not displayed */
NoResponseOptimization bool `` /* 146-byte string literal not displayed */
Http3Connections int `` /* 126-byte string literal not displayed */
Http3MaxConnections int `` /* 135-byte string literal not displayed */
Http3MaxWorkers int `` /* 129-byte string literal not displayed */
Http3Streams int `json:"http3_streams" ffuf:"http3-streams" section:"http" usage:"Maximum concurrent HTTP/3 request streams per connection"`
Http3ProbeTimeout int `json:"http3_probe_timeout" ffuf:"http3-probe-timeout" section:"http" usage:"HTTP/3 capability probe timeout in seconds"`
Http3HighRate bool `` /* 130-byte string literal not displayed */
Http3HighRateAcknowledge bool `` /* 153-byte string literal not displayed */
Http3TargetRPS int `` /* 139-byte string literal not displayed */
Http3LatencyMS float64 `` /* 151-byte string literal not displayed */
IgnoreBody bool `json:"ignore_body" ffuf:"ignore-body" section:"http" usage:"Do not fetch the response content."`
Method string `json:"method" ffuf:"X" section:"http" usage:"HTTP method to use"`
ProxyURL string `` /* 138-byte string literal not displayed */
Raw bool `json:"raw" ffuf:"raw" section:"http" usage:"Do not encode URI"`
Recursion bool `` /* 137-byte string literal not displayed */
RecursionDepth int `json:"recursion_depth" ffuf:"recursion-depth" section:"http" usage:"Maximum recursion depth."`
RecursionStrategy string `` /* 169-byte string literal not displayed */
ReplayProxyURL string `json:"replay_proxy_url" ffuf:"replay-proxy" section:"http" usage:"Replay matched requests using this proxy."`
SNI string `json:"sni" ffuf:"sni" section:"http" usage:"Target TLS SNI, does not support FUZZ keyword"`
Timeout int `json:"timeout" ffuf:"timeout" section:"http" usage:"HTTP request timeout in seconds."`
URL string `json:"url" ffuf:"u" section:"http" usage:"Target URL"`
Http2 bool `json:"http2" ffuf:"http2" section:"http" usage:"Skip HTTP/3 and prefer HTTP/2; falls back to HTTP/1.1"`
ClientCert string `` /* 139-byte string literal not displayed */
ClientKey string `` /* 145-byte string literal not displayed */
// Preflights/Postflights are not plain flags: -preflight and -preflight-var
// bind positionally (a -preflight-var attaches to the preceding -preflight), so
// they are appended by the extraFlags Func callbacks in flags.go rather than a
// tagged field. The json/toml tags carry them through config files and history.
Preflights []PreflightConfig `json:"preflights" toml:"preflights"`
Postflights []PreflightConfig `json:"postflights" toml:"postflights"`
PreflightMode string `` /* 148-byte string literal not displayed */
PreflightError string `` /* 141-byte string literal not displayed */
PreflightAnyHost bool `` /* 236-byte string literal not displayed */
}
The `ffuf`, `section`, `usage`, `kind` and `alias` struct tags are the single source of truth for CLI flags (see flags.go / RegisterFlags). A field with an `ffuf` tag becomes a flag; the help section, usage text, (for []string) the value kind, and any compatibility aliases come from the tags. The only flags NOT backed by a field are the dummy `copy as curl` compat flags (-i/-k/-compressed), declared explicitly in flags.go because they have no value to bind.
type HighRatePolicyReport ¶
type HighRatePolicyReport struct {
Enabled bool `json:"enabled"`
Acknowledged bool `json:"acknowledged"`
TargetRPS int `json:"target_rps"`
TargetRPSSource string `json:"target_rps_source"`
LatencyMS float64 `json:"latency_ms"`
LatencySource string `json:"latency_source"`
Headroom float64 `json:"headroom"`
DesiredWorkers int `json:"desired_workers"`
ConnectionMode string `json:"connection_mode"`
ConnectionCapacity int `json:"connection_capacity"`
ConnectionCapacitySource string `json:"connection_capacity_source"`
StreamsPerConnection int `json:"streams_per_connection"`
StreamsSource string `json:"streams_source"`
StreamCapacity int `json:"stream_capacity"`
HTTP3MaxWorkers int `json:"http3_max_workers"`
HTTP3MaxWorkersSource string `json:"http3_max_workers_source"`
HardWorkerLimit int `json:"hard_worker_limit"`
EffectiveWorkers int `json:"effective_workers"`
ExecutionWorkers int `json:"execution_workers"`
ExpandedInputs int `json:"expanded_inputs"`
RecommendedMinimumInputs uint64 `json:"recommended_minimum_inputs"`
InputDurationHeadroom bool `json:"input_duration_headroom"`
Provisioned bool `json:"provisioned"`
Protocol string `json:"protocol"`
Method string `json:"method"`
ResponseOptimization string `json:"response_optimization"`
Rate int64 `json:"rate"`
Delay string `json:"delay"`
Noninteractive bool `json:"noninteractive"`
TelemetryPath string `json:"telemetry_path"`
DowngradeFatal bool `json:"downgrade_fatal"`
}
HighRatePolicyReport records the complete opt-in ceiling-test policy and its sizing decision. It is runtime evidence, not a persisted user setting.
type InputOptions ¶
type InputOptions struct {
DirSearchCompat bool `` /* 129-byte string literal not displayed */
Encoders []string `json:"encoders" ffuf:"enc" kind:"wordlist" section:"input" usage:"Encoders for keywords, eg. 'FUZZ:urlencode b64encode'"`
Extensions string `json:"extensions" ffuf:"e" section:"input" usage:"Comma separated list of extensions. Extends FUZZ keyword."`
IgnoreWordlistComments bool `json:"ignore_wordlist_comments" ffuf:"ic" section:"input" usage:"Ignore wordlist comments"`
InputMode string `` /* 132-byte string literal not displayed */
InputNum int `json:"input_num" ffuf:"input-num" section:"input" usage:"Number of inputs to test. Used in conjunction with --input-cmd."`
InputShell string `json:"input_shell" ffuf:"input-shell" section:"input" usage:"Shell to be used for running command"`
Inputcommands []string `` /* 178-byte string literal not displayed */
Request string `json:"request_file" ffuf:"request" section:"input" usage:"File containing the raw http request"`
RequestProto string `json:"request_proto" ffuf:"request-proto" section:"input" usage:"Protocol to use along with raw request"`
Wordlists []string `` /* 159-byte string literal not displayed */
}
type InputProvider ¶
type InputProvider interface {
ActivateKeywords([]string)
AddProvider(InputProviderConfig) error
Keywords() []string
Next() bool
Position() int
SetPosition(int)
Reset()
Value() map[string][]byte
Total() int
}
InputProvider interface handles the input data for RunnerProvider
type InputProviderConfig ¶
type InternalInputProvider ¶
type InternalInputProvider interface {
Keyword() string
Next() bool
Position() int
SetPosition(int)
ResetPosition()
IncrementPosition()
Value() []byte
Total() int
Active() bool
Enable()
Disable()
}
InternalInputProvider interface handles providing input data to InputProvider
type MatcherManager ¶
type MatcherManager interface {
SetCalibrated(calibrated bool)
SetCalibratedForHost(host string, calibrated bool)
AddFilter(name string, option string, replace bool) error
// AddFilters validates an additive batch and publishes it as one update.
// It is used by embedded/live frontends so workers can observe either the
// complete old set or the complete new set, never a partially applied form.
AddFilters(options map[string]string) error
AddPerDomainFilter(domain string, name string, option string) error
RemoveFilter(name string)
AddMatcher(name string, option string) error
GetFilters() map[string]FilterProvider
GetMatchers() map[string]FilterProvider
FiltersForDomain(domain string) map[string]FilterProvider
CalibratedForDomain(domain string) bool
Calibrated() bool
// Matches reports whether resp passes the configured matchers and filters.
// perHost selects the per-domain filter set; matcherMode/filterMode are the
// and/or combination modes.
Matches(resp *Response, perHost bool, matcherMode string, filterMode string) bool
}
MatcherManager provides functions for managing matchers and filters
type MatcherOptions ¶
type MatcherOptions struct {
Mode string `json:"mode" ffuf:"mmode" section:"matcher" usage:"Matcher set operator. Either of: and, or"`
Lines string `json:"lines" ffuf:"ml" section:"matcher" usage:"Match amount of lines in response"`
Regexp string `json:"regexp" ffuf:"mr" section:"matcher" usage:"Match regexp"`
Size string `json:"size" ffuf:"ms" section:"matcher" usage:"Match HTTP response size"`
Status string `json:"status" ffuf:"mc" section:"matcher" usage:"Match HTTP status codes, or \"all\" for everything."`
Time string `` /* 149-byte string literal not displayed */
Words string `json:"words" ffuf:"mw" section:"matcher" usage:"Match amount of words in response"`
}
type Multierror ¶
type Multierror struct {
// contains filtered or unexported fields
}
func (*Multierror) Add ¶
func (m *Multierror) Add(err error)
func (*Multierror) ErrorOrNil ¶
func (m *Multierror) ErrorOrNil() error
type OutputOptions ¶
type OutputOptions struct {
AuditLog string `json:"audit_log" ffuf:"audit-log" section:"output" usage:"Write audit log containing all requests, responses and config"`
DebugLog string `json:"debug_log" ffuf:"debug-log" section:"output" usage:"Write all of the internal logging to the specified file."`
OutputDirectory string `json:"output_directory" ffuf:"od" section:"output" usage:"Directory path to store matched results to."`
OutputFile string `json:"output_file" ffuf:"o" section:"output" usage:"Write output to file"`
OutputFormat string `` /* 155-byte string literal not displayed */
OutputSkipEmptyFile bool `json:"output_skip_empty" ffuf:"or" section:"output" usage:"Don't create the output file if we don't have results"`
ProfileCPU string `json:"-" toml:"-" ffuf:"profile-cpu" cli_only:"true" section:"output" usage:"Write a CPU profile to a new owner-only file"`
ProfileHeap string `` /* 143-byte string literal not displayed */
ProfileMutex string `` /* 145-byte string literal not displayed */
ProfileBlock string `` /* 137-byte string literal not displayed */
QuicTelemetry bool `` /* 139-byte string literal not displayed */
QuicQlogDir string `` /* 138-byte string literal not displayed */
RunTelemetry string `` /* 160-byte string literal not displayed */
}
type OutputProvider ¶
type OutputProvider interface {
Banner()
Finalize() error
Progress(status Progress)
Info(infostring string)
Error(errstring string)
Raw(output string)
Warning(warnstring string)
Result(resp Response)
PrintResult(res Result)
SaveFile(filename, format string) error
GetCurrentResults() []Result
SetCurrentResults(results []Result)
FilterCurrentResults(keep func(Result) bool)
SetPaused(paused bool)
PendingResults() int
Reset()
Cycle()
}
OutputProvider is responsible of providing output from the RunnerProvider
type PreflightConfig ¶
type PreflightConfig struct {
RequestFile string `json:"request_file" toml:"request_file"`
Vars []VarExtract `json:"vars" toml:"vars"`
}
PreflightConfig is one raw HTTP request file executed around the fuzzing request, with optional variable extractions from its response.
type PreflightProbeReport ¶
type PreflightProbeReport struct {
Attempted bool `json:"attempted"`
Successful bool `json:"successful"`
Reliable bool `json:"reliable,omitempty"`
Reason string `json:"reason,omitempty"`
Requests int `json:"requests"`
ElapsedMillis int64 `json:"elapsed_ms"`
MeanLatencyMS float64 `json:"mean_latency_ms,omitempty"`
}
PreflightProbeReport records one bounded capability check. Attempted is kept separate from Successful so callers can distinguish a negative result from a check that was unnecessary or disabled by configuration.
type Progress ¶
type Progress struct {
StartedAt time.Time
ReqCount int
// CompletedCount is the number of logical inputs that reached a terminal
// outcome in the current progress cycle. Retries do not increment it.
CompletedCount int
ResponseCount int
ReqTotal int
ReqSec int64
QueuePos int
QueueTotal int
ErrorCount int
}
type ProtocolPreflightReport ¶
type ProtocolPreflightReport struct {
SchemaVersion int `json:"schema_version"`
RanAt time.Time `json:"ran_at"`
CompletedAt time.Time `json:"completed_at"`
SelectedProtocol string `json:"selected_protocol"`
DowngradeReason string `json:"downgrade_reason,omitempty"`
HTTP3 HTTP3PreflightReport `json:"http3"`
RequestStrategy RequestStrategyPreflightReport `json:"request_strategy"`
EffectiveConcurrency EffectiveConcurrencyReport `json:"effective_concurrency"`
Timings ProtocolPreflightTimings `json:"timings"`
}
ProtocolPreflightReport is the complete, immutable decision record produced before request workers start. It is runtime-only configuration state and can be safely persisted by embedders such as the web console.
type RegisteredFlag ¶
RegisteredFlag is one flag's help metadata.
type Request ¶
type Request struct {
Method string
Host string
Url string
Headers map[string]string
Data []byte
Input map[string][]byte
Position int
Raw string
Error string
Timestamp time.Time
}
Request holds the meaningful data that is passed for runner for making the query
func BaseRequest ¶
BaseRequest returns a base request struct populated from the main config
func CopyRequest ¶
CopyRequest performs a deep copy of a request and returns a new struct
func NewRequest ¶
func RecursionRequest ¶
RecursionRequest returns a base request for a recursion target
func SniperRequests ¶
SniperRequests returns an array of requests, each with one of the templated locations replaced by a keyword
type RequestStrategyPreflightReport ¶
type RequestStrategyPreflightReport struct {
Selected string `json:"selected"`
Reason string `json:"reason"`
ProbeRequests int `json:"probe_requests"`
FullGET PreflightProbeReport `json:"full_get"`
HEAD PreflightProbeReport `json:"head"`
Range PreflightProbeReport `json:"range"`
}
type Response ¶
type Response struct {
StatusCode int64
Headers map[string][]string
Data []byte
ContentLength int64
ContentWords int64
ContentLines int64
ContentType string
Cancelled bool
Request *Request
Raw string
ResultFile string
ScraperData map[string][]string
Duration time.Duration
Timestamp time.Time
}
Response struct holds the meaningful data returned from request and is meant for passing to filters
func (*Response) GetRedirectLocation ¶
GetRedirectLocation returns the redirect location for a 3xx redirect HTTP response
func (*Response) SetScraperData ¶
SetScraperData lazily creates the scraper result map. Most responses have no scraper matches, so allocating this map in NewResponse put an otherwise unused object on every request's hot path.
type ResponseOptimizationReport ¶
type ResponseOptimizationReport struct {
Strategy string `json:"strategy"`
Reason string `json:"reason"`
ProbeRequests int `json:"probe_requests"`
}
ResponseOptimizationReport describes the response-minimisation decision made before a scan. Strategy is one of "get", "head", "range", or "user-head". ProbeRequests are deliberately accounted separately from fuzzing inputs.
type Result ¶
type Result struct {
Input map[string][]byte `json:"input"`
Position int `json:"position"`
StatusCode int64 `json:"status"`
ContentLength int64 `json:"length"`
ContentWords int64 `json:"words"`
ContentLines int64 `json:"lines"`
ContentType string `json:"content-type"`
RedirectLocation string `json:"redirectlocation"`
Url string `json:"url"`
Duration time.Duration `json:"duration"`
ScraperData map[string][]string `json:"scraper"`
ResultFile string `json:"resultfile"`
Host string `json:"host"`
HTMLColor string `json:"-"`
// Printed reports whether this result has already been shown to the user
// (streamed live, or surfaced in the "N new matches" summary on resume). It
// is the single source of truth for the interactive console's pending count,
// so filtering a held result out of CurrentResults also drops it from the
// count. Not serialized to any output format.
Printed bool `json:"-"`
}
type RunDrainTelemetry ¶
type RunDrainTelemetry struct {
WorkersDrained bool `json:"workers_drained"`
RunnerClosed bool `json:"runner_closed"`
CloseError string `json:"close_error,omitempty"`
LimiterInUse int64 `json:"limiter_in_use"`
LimiterWaiters int64 `json:"limiter_waiters"`
TrackedConnectionGenerations uint64 `json:"tracked_connection_generations"`
Complete bool `json:"complete"`
}
type RunEligibilityTelemetry ¶
type RunLogicalLedgerTelemetry ¶
type RunLogicalLedgerTelemetry struct {
ExpectedExpandedInputs *uint64 `json:"expected_expanded_inputs"`
AssignedIDs uint64 `json:"assigned_ids"`
ScheduledTransitions uint64 `json:"scheduled_transitions"`
SuccessTerminalStates uint64 `json:"success_terminal_states"`
ErrorTerminalStates uint64 `json:"error_terminal_states"`
PendingScheduledStates uint64 `json:"pending_scheduled_states"`
IDGaps uint64 `json:"id_gaps"`
DuplicateScheduleTransitions uint64 `json:"duplicate_schedule_transitions"`
DuplicateTerminalTransitions uint64 `json:"duplicate_terminal_transitions"`
InvalidTransitions uint64 `json:"invalid_transitions"`
OutOfRangeIDs uint64 `json:"out_of_range_ids"`
AnomalySampleIDs []uint64 `json:"anomaly_sample_ids"`
}
type RunPreparedRequestHeadersTelemetry ¶
type RunPreparedRequestHeadersTelemetry struct {
Enabled bool `json:"enabled"`
AccountingEnabled bool `json:"accounting_enabled"`
Attempts uint64 `json:"attempts"`
Hits uint64 `json:"hits"`
Fallbacks uint64 `json:"fallbacks"`
FallbackReasons RunPreparedRequestHeaderFallbackTelemetry `json:"fallback_reasons"`
}
RunPreparedRequestHeadersTelemetry accounts for quic-go's explicitly enabled prepared request-header writer. Fallback reasons are mutually exclusive. Attempts must equal Hits+Fallbacks, and Fallbacks must equal the sum of FallbackReasons.
type RunProtocolTelemetry ¶
type RunProtocolTelemetry struct {
Selected string `json:"selected"`
SelectionReason string `json:"selection_reason,omitempty"`
HTTP3Selected bool `json:"http3_selected"`
HTTP3InitialConnections int `json:"http3_initial_connections,omitempty"`
HTTP3FinalConnections int `json:"http3_final_connections,omitempty"`
HTTP3OpenedConnections int `json:"http3_opened_connections,omitempty"`
}
type RunQUICDiagnosticsTelemetry ¶
type RunQUICDiagnosticsTelemetry struct {
LifecycleEnabled bool `json:"lifecycle_enabled"`
AggregateEnabled bool `json:"aggregate_enabled"`
QLogEnabled bool `json:"qlog_enabled"`
GenerationsStarted uint64 `json:"generations_started"`
ConnectionsOpened uint64 `json:"connections_opened"`
ConnectionsClosed uint64 `json:"connections_closed"`
DialAttempts uint64 `json:"dial_attempts"`
DialSuccesses uint64 `json:"dial_successes"`
DialFailures uint64 `json:"dial_failures"`
HandshakeSuccesses uint64 `json:"handshake_successes"`
HandshakeFailures uint64 `json:"handshake_failures"`
InternallyRecoveredApplicationAttempts uint64 `json:"internally_recovered_application_attempts"`
FinalApplicationErrors uint64 `json:"final_application_errors"`
CallerCancellations uint64 `json:"caller_cancellations"`
DeadlineCancellations uint64 `json:"deadline_cancellations"`
RequestRejections uint64 `json:"request_rejections"`
RequestStreamErrors uint64 `json:"request_stream_errors"`
ConnectionErrors uint64 `json:"connection_errors"`
PacketsSent *uint64 `json:"packets_sent"`
PacketsLost *uint64 `json:"packets_lost"`
PTOCountChanges *uint64 `json:"pto_count_changes"`
LatestRTTNS *uint64 `json:"latest_rtt_ns"`
SmoothedRTTNS *uint64 `json:"smoothed_rtt_ns"`
MinimumRTTNS *uint64 `json:"minimum_rtt_ns"`
CongestionWindowBytes *uint64 `json:"congestion_window_bytes"`
BytesInFlight *uint64 `json:"bytes_in_flight"`
QLogFilesCreated uint64 `json:"qlog_files_created"`
QLogCreateErrors uint64 `json:"qlog_create_errors"`
Slots []RunQUICSlotTelemetry `json:"slots"`
}
RunQUICDiagnosticsTelemetry contains bounded, opt-in QUIC transport observations. Packet and recovery metrics are pointers because a missing dependency signal is different from an observed zero.
type RunQUICSlotTelemetry ¶
type RunQUICSlotTelemetry struct {
SlotID int `json:"slot_id"`
GenerationsStarted uint64 `json:"generations_started"`
LatestGeneration uint64 `json:"latest_generation"`
LatestAttributedGeneration uint64 `json:"latest_attributed_generation"`
LiveGenerations uint64 `json:"live_generations"`
DialAttempts uint64 `json:"dial_attempts"`
DialSuccesses uint64 `json:"dial_successes"`
DialFailures uint64 `json:"dial_failures"`
ConnectionsOpened uint64 `json:"connections_opened"`
ConnectionsClosed uint64 `json:"connections_closed"`
HandshakeSuccesses uint64 `json:"handshake_successes"`
HandshakeFailures uint64 `json:"handshake_failures"`
InternalAttempts uint64 `json:"internal_attempts"`
InternalRetries uint64 `json:"internal_retries"`
}
RunQUICSlotTelemetry is one bounded row per configured pool slot. It records monotonic generation identity without retaining an event history.
type RunRequestStrategyTelemetry ¶
type RunRequestStrategyTelemetry struct {
Method string `json:"method"`
Range string `json:"range,omitempty"`
AutomaticOptimizationEnabled bool `json:"automatic_optimization_enabled"`
SelectedOptimization string `json:"selected_optimization"`
SelectionReason string `json:"selection_reason,omitempty"`
OptimizedAttempts uint64 `json:"optimized_attempts"`
OptimizedSuccesses uint64 `json:"optimized_successes"`
FullGETFallbacks uint64 `json:"full_get_fallbacks"`
FallbackTransportErrors uint64 `json:"fallback_transport_errors"`
FallbackUntrustworthy uint64 `json:"fallback_untrustworthy_responses"`
}
type RunResponseLatencyTelemetry ¶
type RunResponseLatencyTelemetry struct {
SchemaVersion int `json:"schema_version"`
Source string `json:"source"`
Scope string `json:"scope"`
Clock string `json:"clock"`
Unit string `json:"unit"`
Method string `json:"method"`
SampleCount uint64 `json:"sample_count"`
P99UpperBoundNS uint64 `json:"p99_upper_bound_ns"`
MaximumTrackableNS uint64 `json:"maximum_trackable_ns"`
OverflowCount uint64 `json:"overflow_count"`
}
RunResponseLatencyTelemetry is a bounded final-attempt time-to-first-byte summary for successful main logical responses. P99UpperBoundNS is the upper edge of the histogram bucket containing the nearest-rank p99 sample, so consumers can use it as a conservative bound without mistaking QUIC RTT for request latency.
type RunResponseTelemetry ¶
type RunResponseTelemetry struct {
MainRequestSpanNS *uint64 `json:"main_request_span_ns"`
ScheduledLogicalInputs uint64 `json:"scheduled_logical_inputs"`
TerminalLogicalOutcomes uint64 `json:"terminal_logical_outcomes"`
SuccessfulLogicalResponses uint64 `json:"successful_logical_responses"`
TerminalLogicalErrors uint64 `json:"terminal_logical_errors"`
Latency *RunResponseLatencyTelemetry `json:"latency,omitempty"`
// Schema-v1 fields remain decodable so in-process readers can consume old
// artifacts. Version-2 writers leave them absent.
Scheduled uint64 `json:"scheduled,omitempty"`
CompletedResponses uint64 `json:"completed_responses,omitempty"`
Errors uint64 `json:"errors,omitempty"`
Retries uint64 `json:"retries,omitempty"`
}
type RunTelemetry ¶
type RunTelemetry struct {
SchemaVersion int `json:"schema_version"`
RunID *string `json:"run_id"`
EligibleMode string `json:"eligible_mode"`
Protocol RunProtocolTelemetry `json:"protocol"`
RequestStrategy RunRequestStrategyTelemetry `json:"request_strategy"`
Responses RunResponseTelemetry `json:"responses"`
Workers RunWorkerCapacityTelemetry `json:"workers"`
LogicalLedger RunLogicalLedgerTelemetry `json:"logical_ledger"`
Transport RunTransportTelemetry `json:"transport"`
QUIC RunQUICDiagnosticsTelemetry `json:"quic"`
Eligibility RunEligibilityTelemetry `json:"eligibility"`
Drain RunDrainTelemetry `json:"drain"`
HighRatePolicy *HighRatePolicyReport `json:"high_rate_policy,omitempty"`
}
RunTelemetry is an opt-in, machine-readable account of a completed run. It deliberately keeps logical fuzz inputs separate from lower-level HTTP/3 transport attempts, which can also include bounded startup probes and retries.
type RunTransportAttempt ¶
type RunTransportAttempt struct {
Role RunTransportAttemptRole
Method string
Optimized bool
Completed bool
SurfacedError bool
}
type RunTransportAttemptLifecycleRecorder ¶
type RunTransportAttemptLifecycleRecorder interface {
BeginRunTransportAttempt()
EndRunTransportAttempt()
}
RunTransportAttemptLifecycleRecorder is an optional, narrower hot-path hook used to measure actual simultaneous main-work transport calls. Preflight, postflight, fingerprint, qualification, and warmup traffic never receives it.
type RunTransportAttemptRecorder ¶
type RunTransportAttemptRecorder interface {
RecordRunTransportAttempt(RunTransportAttempt)
}
type RunTransportAttemptRole ¶
type RunTransportAttemptRole string
const ( RunTransportRoleInitial RunTransportAttemptRole = "initial" RunTransportRoleOptimizationFallback RunTransportAttemptRole = "optimization_fallback" RunTransportRoleEngineRetry RunTransportAttemptRole = "engine_retry" RunTransportRoleEngineRetryOptimizationFallback RunTransportAttemptRole = "engine_retry_optimization_fallback" )
type RunTransportTelemetry ¶
type RunTransportTelemetry struct {
CompletedResponses uint64 `json:"completed_responses"`
Errors uint64 `json:"errors"`
InFlight int64 `json:"in_flight"`
ApplicationAttempts uint64 `json:"application_attempts"`
CompletedAttempts uint64 `json:"completed_attempts"`
SurfacedAttemptErrors uint64 `json:"surfaced_attempt_errors"`
ApplicationRetries uint64 `json:"application_retries"`
ObservedPreHandlerApplicationFailures uint64 `json:"observed_pre_handler_application_failures"`
InternalAttempts *uint64 `json:"internal_attempts"`
InternalRetries *uint64 `json:"internal_retries"`
OptimizedAttempts uint64 `json:"optimized_attempts"`
FullGETRecoveries uint64 `json:"full_get_recoveries"`
AttemptRoles RunTransportRoleTelemetry `json:"attempt_roles"`
Methods RunTransportMethodTelemetry `json:"methods"`
PreparedRequestHeaders RunPreparedRequestHeadersTelemetry `json:"prepared_request_headers"`
}
type RunWorkerCapacityTelemetry ¶
type RunWorkerCapacityTelemetry struct {
ExecutionGeneration uint64 `json:"execution_generation"`
ProposalEpoch uint64 `json:"proposal_epoch"`
AcknowledgementGeneration uint64 `json:"acknowledgement_generation"`
AcknowledgementEpoch uint64 `json:"acknowledgement_epoch"`
StaleProposals uint64 `json:"stale_proposals"`
StaleAcknowledgements uint64 `json:"stale_acknowledgements"`
LateAfterTimeoutAcknowledgements uint64 `json:"late_after_timeout_acknowledgements"`
RepublishedProposals uint64 `json:"republished_proposals"`
TimedOutProposals uint64 `json:"timed_out_proposals"`
SupersededProposals uint64 `json:"superseded_proposals"`
MissingListenerProposals uint64 `json:"missing_listener_proposals"`
ProposedWorkers int `json:"proposed_workers"`
AcknowledgedLiveWorkers int `json:"acknowledged_live_workers"`
DesiredWorkers int `json:"desired_workers"`
LiveWorkers int `json:"live_workers"`
RetiringWorkers int `json:"retiring_workers"`
PeakWorkers int `json:"peak_workers"`
PeakMainInFlight int64 `json:"peak_main_in_flight"`
RemainingInputCap int `json:"remaining_input_cap"`
SupervisorState string `json:"supervisor_state"`
}
RunWorkerCapacityTelemetry reconciles the pool's proposal state with the engine supervisor's actual worker lifecycle.
type RunnerProvider ¶
type RunnerProvider interface {
Prepare(input map[string][]byte, basereq *Request) (Request, error)
Execute(req *Request) (Response, error)
Dump(req *Request) ([]byte, error)
}
RunnerProvider is an interface for request executors
type ScraperResult ¶
type ValueRange ¶
type ValueRange struct {
Min, Max int64
}
func ValueRangeFromString ¶
func ValueRangeFromString(instr string) (ValueRange, error)
type VarExtract ¶
type VarExtract struct {
Name string `json:"name" toml:"name"`
Regex string `json:"regex" toml:"regex"`
Source string `json:"source,omitempty" toml:"source,omitempty"`
Key string `json:"key,omitempty" toml:"key,omitempty"`
// Compiled is the precompiled Regex. ConfigFromOptions sets it once so the hot
// path never recompiles per request; nil when a VarExtract is built directly.
Compiled *regexp.Regexp `json:"-" toml:"-"`
}
VarExtract names a variable to capture from a preflight/postflight response. The value is either the first capture group of Regex, run against the body and then, if that finds nothing, the headers; or, when Source is set, the form field, meta tag, cookie or header called Key. The captured value is substituted into the keyword Name wherever it appears in later requests.