sarg
2.4.0
About: SARG ia a Squid Analysis Report Generator. Fossies Dox: sarg-2.4.0.tar.gz ("unofficial" and yet experimental doxygen-generated source code documentation) 
|
Go to the documentation of this file.
23 #ifdef HAVE_SYS_TIME_H
29 #ifdef HAVE_SYS_RESOURCE_H
30 #include <sys/resource.h>
35 #if defined(HAVE_SYS_DIRENT_H) && !defined(HAVE_DIRENT_H)
36 #include <sys/dirent.h>
41 #ifdef HAVE_SYS_SOCKET_H
42 #include <sys/socket.h>
50 #ifdef HAVE_NETINET_IN_H
51 #include <netinet/in.h>
53 #ifdef HAVE_ARPA_INET_H
54 #include <arpa/inet.h>
56 #ifdef HAVE_SYS_STAT_H
65 #ifdef HAVE_SYS_WAIT_H
81 #ifdef HAVE_GDFONTMB_H
90 #ifdef HAVE_INTTYPES_H
105 #ifdef HAVE_EXECINFO_H
106 #include <execinfo.h>
111 #ifdef HAVE_STDBOOL_H
121 #ifdef HAVE_FNMATCH_H
125 #if defined(HAVE_FOPEN64)
126 #define _FILE_OFFSET_BITS 64
127 #define MY_FOPEN fopen64
129 #define MY_FOPEN fopen
132 #if !defined(HAVE_BZERO)
133 #define bzero(mem,size) memset(mem,0,size)
136 #if defined(IBERTY_LIB) && !defined(HAVE_MKSTEMP)
137 int mkstemps(
char *
template,
int suffixlen);
138 #define mkstemp(template) mkstemps(template,0)
142 #define pgettext(msgctxt,msgid) (msgid)
143 #define ngettext(singular,plural,number) (plural)
147 #if defined(ENABLE_NLS) && defined(HAVE_LIBINTL_H)
148 #define _(String) gettext(String)
150 #define N_(String) gettext_noop(String)
152 #define N_(String) (String)
155 #define _(String) (String)
156 #define N_(String) (String)
159 #if defined(__MINGW32__)
160 #define mkdir(p,m) _mkdir(p)
163 #define WIFEXITED(S) 1
167 #define WEXITSTATUS(S) (S)
173 # define __attribute__(x)
177 #define MAX_URL_LEN 40000
178 #define MAX_TRUNCATED_URL 250
179 #define MAX_USER_LEN 256
180 #define MAX_USER_FNAME_LEN 128
181 #define MAX_IP_LEN 64
182 #define MAX_DATETIME_LEN 32
183 #define MAX_REDIRECTOR_LOGS 64
184 #define MAX_REDIRECTOR_FILELEN 1024
189 #define MAX_DATETIME_DAYS 1000
191 #define REPORT_TYPE_USERS_SITES 0x0001UL
192 #define REPORT_TYPE_SITE_USER_TIME_DATE 0x0002UL
193 #define REPORT_TYPE_TOPUSERS 0x0004UL
194 #define REPORT_TYPE_TOPSITES 0x0008UL
195 #define REPORT_TYPE_SITES_USERS 0x0010UL
196 #define REPORT_TYPE_DATE_TIME 0x0020UL
197 #define REPORT_TYPE_DENIED 0x0040UL
198 #define REPORT_TYPE_AUTH_FAILURES 0x0080UL
199 #define REPORT_TYPE_DOWNLOADS 0x0100UL
200 #define REPORT_TYPE_USERAGENT 0x0200UL
202 #define DATA_FIELD_USER 0x0001UL
203 #define DATA_FIELD_DATE 0x0002UL
204 #define DATA_FIELD_TIME 0x0004UL
205 #define DATA_FIELD_URL 0x0008UL
206 #define DATA_FIELD_CONNECT 0x0010UL
207 #define DATA_FIELD_BYTES 0x0020UL
208 #define DATA_FIELD_IN_CACHE 0x0040UL
209 #define DATA_FIELD_OUT_CACHE 0x0080UL
210 #define DATA_FIELD_ELAPSED 0x0100UL
212 #define TOPUSERFIELDS_NUM 0x0001UL
213 #define TOPUSERFIELDS_DATE_TIME 0x0002UL
214 #define TOPUSERFIELDS_USERID 0x0004UL
215 #define TOPUSERFIELDS_CONNECT 0x0008UL
216 #define TOPUSERFIELDS_BYTES 0x0010UL
217 #define TOPUSERFIELDS_SETYB 0x0020UL
218 #define TOPUSERFIELDS_IN_CACHE_OUT 0x0040UL
219 #define TOPUSERFIELDS_USED_TIME 0x0080UL
220 #define TOPUSERFIELDS_MILISEC 0x0100UL
221 #define TOPUSERFIELDS_PTIME 0x0200UL
222 #define TOPUSERFIELDS_TOTAL 0x0400UL
223 #define TOPUSERFIELDS_AVERAGE 0x0800UL
224 #define TOPUSERFIELDS_USERIP 0x1000UL
226 #define USERREPORTFIELDS_CONNECT 0x0001UL
227 #define USERREPORTFIELDS_BYTES 0x0002UL
228 #define USERREPORTFIELDS_SETYB 0x0004UL
229 #define USERREPORTFIELDS_IN_CACHE_OUT 0x0008UL
230 #define USERREPORTFIELDS_USED_TIME 0x0010UL
231 #define USERREPORTFIELDS_MILISEC 0x0020UL
232 #define USERREPORTFIELDS_PTIME 0x0040UL
233 #define USERREPORTFIELDS_TOTAL 0x0080UL
234 #define USERREPORTFIELDS_AVERAGE 0x0100UL
236 #define INDEX_YES 0x0001UL
237 #define INDEX_NO 0x0002UL
238 #define INDEX_ONLY 0x0004UL
240 #define INDEX_TREE_DATE 0x0001UL
241 #define INDEX_TREE_FILE 0x0002UL
243 #define INDEXFIELDS_DIRSIZE 0x0001UL
245 #define NTLMUSERFORMAT_USER 0x0001UL
246 #define NTLMUSERFORMAT_DOMAINUSER 0x0002UL
248 #define RECORDWITHOUTUSER_IP 0x0001UL
249 #define RECORDWITHOUTUSER_IGNORE 0x0002UL
250 #define RECORDWITHOUTUSER_EVERYBODY 0x0004UL
252 #define DATAFILEURL_IP 0x0001UL
253 #define DATAFILEURL_NAME 0x0002UL
255 #define DISPLAY_BYTES 0x0001UL
256 #define DISPLAY_ABBREV 0x0002UL
258 #define DATETIME_ELAP 0x0001UL
259 #define DATETIME_BYTE 0x0002UL
261 #define REALTIME_UNAUTH_REC_SHOW 0x0001UL
262 #define REALTIME_UNAUTH_REC_IGNORE 0x0002UL
264 #define SORT_REVERSE 0x0001
266 #define TOPUSER_SORT_REVERSE SORT_REVERSE
267 #define TOPUSER_SORT_BYTES 0x0002UL
268 #define TOPUSER_SORT_USER 0x0004UL
269 #define TOPUSER_SORT_CONNECT 0x0008UL
270 #define TOPUSER_SORT_TIME 0x0010UL
272 #define TOPSITE_SORT_REVERSE SORT_REVERSE
273 #define TOPSITE_SORT_BYTES 0x0002UL
274 #define TOPSITE_SORT_CONNECT 0x0004UL
275 #define TOPSITE_SORT_TIME 0x0008UL
276 #define TOPSITE_SORT_USER 0x0010UL
278 #define USER_SORT_REVERSE SORT_REVERSE
279 #define USER_SORT_BYTES 0x0002UL
280 #define USER_SORT_SITE 0x0004UL
281 #define USER_SORT_CONNECT 0x0008UL
282 #define USER_SORT_TIME 0x0010UL
285 #define HTML_JS_NONE 0x0000
286 #define HTML_JS_SORTTABLE 0x0001
290 #define ALIAS_PREFIX '*'
293 #define MAX_USER_LIMITS 16
296 #define INDEX_HTML_FILE "index.html"
#define MAX_REDIRECTOR_FILELEN
bool AnonymousOutputFiles
True to use anonymous file and directory names in the report.
unsigned long int TopsitesSort
char HostAliasFile[512]
The name of the file containing the host names to replace by an alias in the report.
char LDAPNativeCharset[20]
Character set to convert the LDAP returned string to.
bool DansguardianFilterOutDate
char UserInvalidChar[255]
bool RedirectorFilterOutDate
char LDAPFilterSearch[512]
char RedirectorLogFormat[4096]
bool KeepTempLog
True to keep the temporary files for inspection.
char ParsedOutputLog[20000]
char HeaderBgColor[20000]
int SquidGuardReportLimit
struct tm start
The first date of the period.
unsigned long int DataFileFields
char LogoTextColor[20000]
char DansGuardianConf[20000]
unsigned long int lines_read
Count the number of lines read from the input log files.
char SquidGuarddbHome[255]
unsigned long int DisplayedValues
char GraphDaysBytesBarColor[255]
unsigned long int UserSort
unsigned long int IndexFields
The columns to show in the index of the reports.
char wwwDocumentRoot[20000]
unsigned long int ReportType
char SortTableJs[256]
The full path to sorttable.js if the table in the reports must be dynamicaly sorted.
unsigned long int IndexTree
How to display the index of the reports.
char html[90]
The HTML representation of the date.
unsigned long int datetimeby
unsigned long int TopUserFields
char UserAliasFile[512]
The name of the file containing the user names to replace by an alias in the report.
char ParsedOutputLogCompress[512]
unsigned long int RealtimeUnauthRec
char ExcludeString[20000]
bool BytesInSitesUsersReport
char ExternalCSSFile[20000]
int RedirectorLogFromCmdLine
unsigned long int NtlmUserFormat
unsigned long int UserReportFields
char AuthUserTemplateFile[1024]
char text[90]
The textual representation of the date.
int NumLogSuccessiveErrors
The number of consecutive errors allowed in an input log file before the process is interrupted.
char SquidGuardConf[20000]
char PrivacyStringColor[30]
unsigned long int TopuserSort
#define MAX_REDIRECTOR_LOGS
char DataFileDelimiter[3]
unsigned long int RecordsWithoutUser
char RedirectorLogs[64][1024]
int DansGuardianReportLimit
struct periodstruct period
int realtime_access_log_lines
unsigned long int DataFileUrl
char MailUtility[PATH_MAX]
bool ShowReadStatistics
if true, show the number of lines read from the input log file during the reading of the file.
unsigned long int nusers
Count the number of users.
struct tm end
The last date of the period.
unsigned long int records_kept
Count the number of records kept for the processing.