]> git.ipfire.org Git - thirdparty/squid.git/commit - src/errorpage.cc
Configurable SSL error details messages
authorChristos Tsantilas <chtsanti@users.sourceforge.net>
Fri, 17 Jun 2011 07:46:48 +0000 (10:46 +0300)
committerChristos Tsantilas <chtsanti@users.sourceforge.net>
Fri, 17 Jun 2011 07:46:48 +0000 (10:46 +0300)
commit02259ff8a34ba3740c13c4e38e81af79d6ea849b
treeaab7cfc95b308d97100b7e5c1c26e9f2d8cd15aa
parent8d55d7ef16402d9634e011df1cf3795bc2438a99
Configurable SSL error details messages

This project adds support for a translatable and customisable error detail file
(errors/templates/error_details.txt). The file is stored like we store error
page templates today. Inside the file, an HTTP-like format used that can be
later extended to other error details (and beyond):

name: value
details: "value"
descr: "value"

or

name: value
details: "multi
     line
     value"
descr: "value with a \"quoted string\" inside"

The code supports future translations, just like Squid already support error
page translations.

This is a Measurement Factory project
----

Some Technical details:
 - The errorpage code which is related to loading and parsing error templates
   moved to TemplateFile class. This class is used as base class for
   ErrorPageFile class which used to load error page templates.
 - The HttpHeader parser used to parse error details
 - The  error details for various languages cached to memory
 - The ErrorDetailsList  used to store a list of error details for a
   language/locale
 - The ErrorDetailsManager is a class used to load and manage multiple error
   details list (ErrorDetailsList objects) for many languages. It also
   implements a simple cache.
15 files changed:
configure.ac
errors/Makefile.am
errors/templates/error-details.txt [new file with mode: 0644]
scripts/mk-error-details-po.pl [new file with mode: 0644]
scripts/update-pot.sh
src/HttpHeader.cc
src/HttpHeader.h
src/errorpage.cc
src/errorpage.h
src/ssl/ErrorDetail.cc
src/ssl/ErrorDetail.h
src/ssl/ErrorDetailManager.cc [new file with mode: 0644]
src/ssl/ErrorDetailManager.h [new file with mode: 0644]
src/ssl/Makefile.am
src/ssl/support.h