Repository Analysis

valyala/fasthttp

Fast HTTP package for Go. Tuned for high performance. Zero memory allocations in hot paths. Up to 10x faster than net/http

3.0 Likely human-written View on GitHub
3.0
Adjusted Score
3.0
Raw Score
100%
Time Factor
2026-05-24
Last Push
23,364
Stars
Go
Language
53,835
Lines of Code
154
Files
183
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 0HIGH 0MEDIUM 0LOW 183

Pattern Findings

183 matches across 2 categories. Click a row to expand file-level details.

Over-Commented Block175 hits · 150 pts
SeverityFileLineSnippet
LOWheader.go401 h.SetContentTypeBytes(h.bufV)
LOWheader.go421func (h *header) SetTrailer(trailer string) error {
LOWheader.go441// Return ErrBadTrailer if contain any forbidden trailers.
LOWheader.go481 ErrNeedMore = errors.New("need more data: cannot find trailing lf")
LOWheader.go921// This is suggested and enabled by default.
LOWheader.go941// The previous setting is returned.
LOWheader.go1181//
LOWheader.go1281// Copy key and/or value contents before returning if you need retaining them.
LOWheader.go1521}
LOWheader.go1541// Use SetBytesK for setting a single header for the given key.
LOWheader.go1561//
LOWheader.go1601
LOWheader.go1621// If the header is set as a Trailer (forbidden trailers will not be set, see SetTrailer for more details),
LOWheader.go1681}
LOWheader.go1721// ReleaseCookie(c)
LOWheader.go1761func (h *RequestHeader) DelAllCookies() {
LOWheader.go1781//
LOWheader.go1801// Multiple headers with the same key may be added with this function.
LOWheader.go1821// Please note that the Cookie header will not clear previous cookies,
LOWheader.go1861// SetBytesKV sets the given 'key: value' header.
LOWheader.go3481// - coNTENT-TYPe -> Content-Type
LOWserver.go21
LOWserver.go161 // By default standard logger from log package is used.
LOWserver.go181 // HeaderReceived is called after receiving the header.
LOWserver.go201 // ExpectHandler provides more control than ContinueHandler by allowing
LOWserver.go221
LOWserver.go261 //
LOWserver.go281 // the full request including body. The connection's read
LOWserver.go301 //
LOWserver.go321 MaxIdleWorkerDuration time.Duration
LOWserver.go361 //
LOWserver.go381 // Server accepts all the requests by default.
LOWserver.go401
LOWserver.go421 // Examples:
LOWserver.go441 // set to true, the Date will not be present.
LOWserver.go461 // StreamRequestBody enables request body streaming,
LOWserver.go521 // ReadTimeout is the maximum duration for reading the entire
LOWserver.go541// CompressHandlerLevel returns RequestHandler that transparently compresses
LOWserver.go561 ctx.Response.zstdBody(level)
LOWserver.go601//
LOWserver.go641 //
LOWserver.go721// The connection c must not be used after returning from the handler, if KeepHijackedConns is disabled.
LOWserver.go741// Server limits such as Concurrency, ReadTimeout, WriteTimeout, etc.
LOWserver.go761 ctx.hijackNoResponse = noResponse
LOWserver.go841 ConnectionState() tls.ConnectionState
LOWserver.go1081// See also PostArgs, FormValue and FormFile.
LOWserver.go1101// Returns ErrNoMultipartForm if request's content-type
LOWserver.go1121// multipart body size to maxBodySize bytes.
LOWserver.go1221//
LOWserver.go1421 ctx.SetBodyString(body)
LOWserver.go1441// ctx.Response.Header.SetCanonical(strLocation, "/relative?uri")
LOWserver.go1501}
LOWserver.go1521// WARNING: if path is based on user input users will be able to request
LOWserver.go1541}
LOWserver.go1601//
LOWserver.go1621
LOWserver.go1641
LOWserver.go1661}
LOWserver.go1681//
LOWserver.go1781// certFile and keyFile are paths to TLS certificate and key files.
115 more matches not shown…
Example Usage Blocks8 hits · 12 pts
SeverityFileLineSnippet
LOWfasthttpproxy/http.go13// Example usage:
LOWfasthttpproxy/http.go26// Example usage:
LOWfasthttpproxy/http.go40// Example usage:
LOWfasthttpproxy/http.go53// Example usage:
LOWfasthttpproxy/proxy_env.go17// Example usage:
LOWfasthttpproxy/proxy_env.go30// Example usage:
LOWfasthttpproxy/socks5.go11// Example usage:
LOWfasthttpproxy/socks5.go25// Example usage: