ErrorDetailManager.cc
Go to the documentation of this file.
34 explicit ErrorDetailFile(ErrorDetailsList::Pointer const details): TemplateFile("error-details.txt", ERR_NONE) {
126Ssl::ErrorDetailsManager::getErrorDetail(Security::ErrorCode value, const HttpRequest::Pointer &request, ErrorDetailEntry &entry)
238 const int detailsParseOk = httpHeaderParseQuotedString(tmp.termedBuf(), tmp.size(), &entry.detail);
240 const int descrParseOk = httpHeaderParseQuotedString(tmp.termedBuf(), tmp.size(), &entry.descr);
int httpHeaderParseQuotedString(const char *start, const int len, String *val)
Definition: HttpHeaderTools.cc:167
Definition: ErrorDetailManager.cc:182
Definition: HttpHeader.h:72
int parse(const char *header_start, size_t len, Http::ContentLengthInterpreter &interpreter)
Definition: HttpHeader.cc:356
Definition: ErrorDetailManager.h:26
String descr
short error description (for use in debug messages or error pages)
Definition: ErrorDetailManager.h:31
String detail
for error page D macro expansion; may contain macros
Definition: ErrorDetailManager.h:30
ErrorDetailFile(ErrorDetailsList::Pointer const details)
Definition: ErrorDetailManager.cc:34
ErrorDetailsList::Pointer theDetails
Definition: ErrorDetailManager.cc:39
Definition: ErrorDetailManager.h:39
String errLanguage
The language of the error-details.txt template, if any.
Definition: ErrorDetailManager.h:50
const char * getErrorDescr(Security::ErrorCode value)
an error description for an error if exist in list.
Definition: ErrorDetailManager.cc:60
const char * getErrorDetail(Security::ErrorCode value)
an error details for an error if exist in list.
Definition: ErrorDetailManager.cc:71
bool getRecord(Security::ErrorCode value, ErrorDetailEntry &entry)
Definition: ErrorDetailManager.cc:46
Definition: ErrorDetailManager.h:60
const char * getDefaultErrorDescr(Security::ErrorCode value)
the default error description for a given error
Definition: ErrorDetailManager.cc:169
void cacheDetails(ErrorDetailsList::Pointer &errorDetails)
cache the given error details list.
Definition: ErrorDetailManager.cc:117
ErrorDetailsManager()
Definition: ErrorDetailManager.cc:98
static ErrorDetailsManager * TheDetailsManager
An instance of ErrorDetailsManager to be used by squid (ssl/ErrorDetails.*)
Definition: ErrorDetailManager.h:91
const char * getDefaultErrorDetail(Security::ErrorCode value)
the default error details for a given error
Definition: ErrorDetailManager.cc:175
ErrorDetailsList::Pointer getCachedDetails(const char *lang)
Return cached error details list for a given language if exist.
Definition: ErrorDetailManager.cc:105
bool getErrorDetail(Security::ErrorCode value, const HttpRequest::Pointer &request, ErrorDetailEntry &entry)
Definition: ErrorDetailManager.cc:126
Definition: SquidString.h:26
Definition: errorpage.h:281
bool strHdrAcptLangGetItem(const String &hdr, char *lang, int langLen, size_t &pos)
Definition: errorpage.cc:465
size_t headersEnd(const char *mime, size_t l, bool &containsObsFold)
Definition: mime_header.cc:17
int ErrorCode
Squid-defined error code (<0), an error code returned by X.509 API, or zero.
Definition: forward.h:128
Definition: Xaction.cc:40
Security::ErrorCode GetErrorCode(const char *name)
The Security::ErrorCode code of the error described by "name".
Definition: ErrorDetail.h:28
const char * GetErrorName(const Security::ErrorCode code, const bool prefixRawCode=false)
Definition: ErrorDetail.h:36