diff --git a/conf/options/charon-logging.opt b/conf/options/charon-logging.opt index 31ebf6c32..e850c4487 100644 --- a/conf/options/charon-logging.opt +++ b/conf/options/charon-logging.opt @@ -2,37 +2,38 @@ charon.filelog {} Section to define file loggers, see LOGGER CONFIGURATION in **strongswan.conf**(5). -charon.filelog. { # } - is the full path to the log file. +charon.filelog. { # } + may be the full path to the log file if it only contains + characters permitted in section names. Is ignored if _path_ is specified. -charon.filelog..path = - Optional path to the log file. Overrides the section name, may be used +charon.filelog..path = + Optional path to the log file. Overrides the section name. Must be used if the path contains characters that aren't allowed in section names. -charon.filelog..default = 1 +charon.filelog..default = 1 Default loglevel. Specifies the default loglevel to be used for subsystems for which no specific loglevel is defined. -charon.filelog.. = +charon.filelog.. = Loglevel for a specific subsystem. -charon.filelog..append = yes +charon.filelog..append = yes If this option is enabled log entries are appended to the existing file. -charon.filelog..flush_line = no +charon.filelog..flush_line = no Enabling this option disables block buffering and enables line buffering. -charon.filelog..ike_name = no +charon.filelog..ike_name = no Prefix each log entry with the connection name and a unique numerical identifier for each IKE_SA. -charon.filelog..time_format +charon.filelog..time_format Prefix each log entry with a timestamp. The option accepts a format string as passed to **strftime**(3). -charon.filelog..time_add_ms = no +charon.filelog..time_add_ms = no Adds the milliseconds within the current second after the timestamp (separated by a dot, so _time_format_ should end with %S or %T). diff --git a/conf/strongswan.conf.5.tail.in b/conf/strongswan.conf.5.tail.in index a93fe020a..830ed4f2e 100644 --- a/conf/strongswan.conf.5.tail.in +++ b/conf/strongswan.conf.5.tail.in @@ -15,12 +15,15 @@ does not have any effect. There are currently two types of loggers: .TP .B File loggers -Log directly to a file and are defined by specifying the full path to the -file as subsection in the +Log directly to a file and are defined by specifying an arbitrarily named +subsection in the .B charon.filelog -section. To log to the console the two special filenames +section. The full path to the file is configured in the \fIpath\fR setting of +that subsection, however, if it only contains characters permitted in section +names, the setting may also be omitted and the path specified as name of the +subsection. To log to the console the two special filenames .BR stdout " and " stderr -can be used. +may be used. .TP .B Syslog loggers Log into a syslog facility and are defined by specifying the facility to log to @@ -108,7 +111,8 @@ Also include sensitive material in dumps, e.g. keys .EX charon { filelog { - /var/log/charon.log { + charon { + path = /var/log/charon.log time_format = %b %e %T append = no default = 1