9#ifndef SQUID_SRC_HTTP_ONE_REQUESTPARSER_H
10#define SQUID_SRC_HTTP_ONE_REQUESTPARSER_H
unsigned int major
major version number
optimized set of C chars, with quick membership test and merge support
AnyP::ProtocolVersion msgProtocol_
what protocol label has been found in the first line (if any)
::Parser::Tokenizer Tokenizer
bool parseMethodField(Tokenizer &)
bool doParse(const SBuf &aBuf)
called from parse() to do the parsing
Http1::Parser::size_type firstLineSize() const override
size in bytes of the first line including CRLF terminator
static const CharacterSet & RequestTargetCharacters()
characters which Squid will accept in the HTTP request-target (URI)
RequestParser(const RequestParser &)=default
bool parse(const SBuf &aBuf) override
const SBuf & requestUri() const
the request-line URI if this is a request message, or an empty string.
bool skipDelimiter(const size_t count, const char *where)
~RequestParser() override
int parseRequestFirstLine()
bool parseHttpVersionField(Tokenizer &)
HttpRequestMethod method_
what request method has been found on the first line
RequestParser(RequestParser &&)=default
bool parseUriField(Tokenizer &)
SBuf uri_
raw copy of the original client request-line URI field
RequestParser(bool preserveParsed)
const SBuf & parsed() const
the accumulated parsed bytes
const HttpRequestMethod & method() const
the HTTP method if this is a request message
RequestParser & operator=(const RequestParser &)=default
bool preserveParsed_
whether to accumulate parsed bytes (in parsed_)
bool skipTrailingCrs(Tokenizer &tok)
Parse CRs at the end of request-line, just before the terminating LF.
Generic protocol-agnostic parsing tools.