sdk/golang/Standard Library/GoNetHttpHttputil
Standard Library

GoNetHttpHttputil

Go stdlib package — net/http/httputil. Auto-indexed from CDN. Method-level security roles have not been annotated; rule writers should inspect the source before use.

Other Methods

.ClientConn.Close()Neutral
#
Signature
ClientConn.Close() error

Close calls Hijack and then also closes the underlying connection.

.ClientConn.Do()Neutral
#
Signature
ClientConn.Do(req *http.Request) (*http.Response, error)

Do is convenience method that writes a request and reads a response.

.ClientConn.Hijack()Neutral
#
Signature
ClientConn.Hijack() (net.Conn, *bufio.Reader)

Hijack detaches the ClientConn and returns the underlying connection as well

.ClientConn.Pending()Neutral
#
Signature
ClientConn.Pending() int

Pending returns the number of unanswered requests

.ClientConn.Read()Neutral
#
Signature
ClientConn.Read(req *http.Request) (*http.Response, error)

Read reads the next response from the wire. A valid response might be

.ClientConn.Write()Neutral
#
Signature
ClientConn.Write(req *http.Request) error

Write writes a request. An ErrPersistEOF error is returned if the connection

.DumpRequest()Neutral
#
Signature
DumpRequest(req *http.Request, body bool) ([]byte, error)

DumpRequest returns the given request in its HTTP/1.x wire

.DumpRequestOut()Neutral
#
Signature
DumpRequestOut(req *http.Request, body bool) ([]byte, error)

DumpRequestOut is like DumpRequest but for outgoing client requests. It

.DumpResponse()Neutral
#
Signature
DumpResponse(resp *http.Response, body bool) ([]byte, error)

DumpResponse is like DumpRequest but dumps a response.

.NewChunkedReader()Neutral
#
Signature
NewChunkedReader(r io.Reader) io.Reader

NewChunkedReader returns a new chunkedReader that translates the data read from r

Fully-Qualified Names

FQNField
net/http/httputilfqns[0]

Wrong FQN → 0 findings. Verify with: change fqns to garbage → must produce 0 results.

Import

go.mod
// standard library — no go.mod entry required
rule.py
from codepathfinder.go_rule import ...  # net/http/httputil