|
Squid Web Cache master
|
#include <Token.h>
Public Member Functions | |
| Token () | |
| ~Token () | |
| int | parse (const char *def, enum Quoting *quote) |
Static Public Member Functions | |
| static void | Init () |
| Initialize the format token registrations. | |
Public Attributes | ||
| ByteCode_t | type | |
| const char * | label | |
| struct { | ||
| char * string | ||
| ProxyProtocol::Two::FieldType headerId | ||
| the cached ID of the parsed header or zero More... | ||
| struct { | ||
| char * header | ||
| char * element | ||
| char separator | ||
| } header | ||
| uint8_t byteValue | ||
| } | data | |
| int | widthMin | |
| minimum field width | ||
| int | widthMax | |
| maximum field width | ||
| enum Quoting | quote | |
| bool | left | |
| bool | space | |
| bool | zero | |
| int | divisor | |
| Token * | next | |
Private Member Functions | |
| const char * | scanForToken (TokenTableEntry const table[], const char *cur) |
| Format::Token::Token | ( | ) |
Definition at line 740 of file Token.cc.
References data, and ProxyProtocol::Two::htUnknown.
| Format::Token::~Token | ( | ) |
|
static |
Register all components custom format tokens.
Definition at line 255 of file Token.cc.
References Format::FmtConfig::registerTokens(), Format::TheConfig, Format::TokenTableAdapt, Format::TokenTableIcap, Format::TokenTableProxyProtocol, Format::TokenTableSsl, and Format::TokenTableTransport.
Referenced by SquidMain().
parses a single token. Returns the token length in characters, and fills in this item with the token information. def is for sure null-terminated.
Definition at line 355 of file Token.cc.
References Config, cur, DBG_CRITICAL, DBG_IMPORTANT, DBG_PARSE_NOTE, debugs, ProxyProtocol::FieldNameToFieldType(), Here, Format::LFT_ADAPTATION_LAST_ALL_HEADERS, Format::LFT_ADAPTATION_LAST_HEADER, Format::LFT_ADAPTATION_LAST_HEADER_ELEM, Format::LFT_ADAPTED_REQUEST_ALL_HEADERS, Format::LFT_ADAPTED_REQUEST_HEADER, Format::LFT_ADAPTED_REQUEST_HEADER_ELEM, Format::LFT_BYTE, Format::LFT_CLIENT_EUI, Format::LFT_CLIENT_REQ_URLPATH, Format::LFT_DNS_WAIT_TIME, Format::LFT_HTTP_SENT_STATUS_CODE, Format::LFT_HTTP_SENT_STATUS_CODE_OLD_30, Format::LFT_ICAP_IO_TIME, Format::LFT_ICAP_REP_ALL_HEADERS, Format::LFT_ICAP_REP_HEADER, Format::LFT_ICAP_REP_HEADER_ELEM, Format::LFT_ICAP_REQ_ALL_HEADERS, Format::LFT_ICAP_REQ_HEADER, Format::LFT_ICAP_REQ_HEADER_ELEM, Format::LFT_ICAP_TOTAL_TIME, Format::LFT_ICAP_TR_RESPONSE_TIME, Format::LFT_NONE, Format::LFT_NOTE, Format::LFT_PEER_RESPONSE_TIME, Format::LFT_PROXY_PROTOCOL_RECEIVED_ALL_HEADERS, Format::LFT_PROXY_PROTOCOL_RECEIVED_HEADER, Format::LFT_PROXY_PROTOCOL_RECEIVED_HEADER_ELEM, Format::LFT_REPLY_ALL_HEADERS, Format::LFT_REPLY_HEADER, Format::LFT_REPLY_HEADER_ELEM, Format::LFT_REQUEST_ALL_HEADERS, Format::LFT_REQUEST_HEADER, Format::LFT_REQUEST_HEADER_ELEM, Format::LFT_REQUEST_URLGROUP_OLD_2X, Format::LFT_REQUEST_URLPATH_OLD_31, Format::LFT_REQUEST_VERSION, Format::LFT_REQUEST_VERSION_OLD_2X, Format::LFT_SERVER_LOCAL_IP, Format::LFT_SERVER_LOCAL_IP_OLD_27, Format::LFT_STRING, Format::LFT_TIME_START, Format::LFT_TIME_SUBSECOND, Format::LFT_TIME_TO_HANDLE_REQUEST, Format::LFT_TLS_SERVER_NEGOTIATED_VERSION, Format::LFT_TLS_SERVER_RECEIVED_HELLO_VERSION, Format::LFT_TLS_SERVER_SUPPORTED_VERSION, Format::LFT_TOTAL_SERVER_SIDE_RESPONSE_TIME, SquidConfig::log_mime_hdrs, Format::LOG_QUOTE_MIMEBLOB, Format::LOG_QUOTE_NONE, Format::LOG_QUOTE_QUOTES, Format::LOG_QUOTE_RAW, Format::LOG_QUOTE_SHELL, Format::LOG_QUOTE_URL, SquidConfig::logTlsServerHelloDetails, SquidConfig::onoff, TexcHere, Format::TheConfig, Format::FmtConfig::tokens, Format::TokenTable1C, Format::TokenTable2C, Format::TokenTableMisc, ToSBuf(), xisdigit, xmalloc, xstrdup, xstrncpy(), and zero.
Referenced by Format::AssembleOne(), and Format::Format::parse().
|
private |
Scans a token table to see if the next token exists there returns a pointer to next unparsed byte and updates type member if found
Definition at line 276 of file Token.cc.
References Format::TokenTableEntry::configTag, cur, and debugs.
| struct { ... } Format::Token::data |
Referenced by Token().
| struct { ... } Format::Token::header |
| ProxyProtocol::Two::FieldType Format::Token::headerId |
| Token* Format::Token::next |
Definition at line 73 of file Token.h.
Referenced by accessLogInit(), Format::Format::assemble(), and Format::Format::parse().
| bool Format::Token::space |
Definition at line 70 of file Token.h.
Referenced by parse_externalAclHelper().
| ByteCode_t Format::Token::type |
Definition at line 50 of file Token.h.
Referenced by parse_externalAclHelper().