# Copyright (c) 2010 Flowerfire, Inc. All Rights Reserved. win_route_web = { plugin_version = "1.0.1" # Initial creation - 1.0 # 2011-07-25 - 1.0.1 - MSG - Edited info lines. info.1.manufacturer = "Kerio" info.1.device = "WinRoute Web" info.1.version.1 = "" # The name of the log format log.format.format_label = "WinRoute Web Log Format" log.miscellaneous.log_data_type = "proxy_server" log.miscellaneous.log_format_type = "proxy_server" # The log is in this format if any of the first ten lines match this regular expression log.format.autodetect_regular_expression = `^\\[[0-9][0-9]/[A-Z][a-z][a-z]/[0-9][0-9][0-9][0-9] [0-9][0-9]:[0-9][0-9]:[0-9][0-9]\\] [0-9.]+ - [^ ]+ ` # This regular expression is used to parse the log fields out of the log entry # log.format.parsing_regular_expression = `^\\[([0-9][0-9]/[A-Z][a-z][a-z]/[0-9][0-9][0-9][0-9] [0-9][0-9]:[0-9][0-9]:[0-9][0-9])\\] ([0-9.]+) ([^ ]+) \\"([^"]+)\\" ([^$]+)$` # The format of dates and times in this log log.format.date_format = "dd/mmm/yyyy" log.format.time_format = "hh:mm:ss" # All log field parsing will be done using the parsing filters log.format.parse_only_with_filters = "true" # Log fields log.fields = { date = "" time = "" hostname = { type = "host" hierarchy_dividers = "." left_to_right = false leading_divider = "false" } # hostname authenticated_user = "" page_title = "" page = { type = "page" hierarchy_dividers = "/?" left_to_right = true leading_divider = "true" } # page } # log.fields # Database fields database.fields = { date_time = "" day_of_week = "" hour_of_day = "" hostname = "" authenticated_user = "" page_title = "" page = "" file_type = { type = "string" } # file_type location = "" } # database.fields database.numerical_fields = { hits = { default = true requires_log_field = false } } # database.numerical_fields log.parsing_filters.parse = ` if (matches_regular_expression(current_log_line(), '^\\[([0-9][0-9]/[A-Z][a-z][a-z]/[0-9][0-9][0-9][0-9]) ([0-9][0-9]:[0-9][0-9]:[0-9][0-9])\\] ([0-9.]+) ([^ ]+) \\"([^"]+)\\" ([^$]+)$')) then ( set_collected_field('', 'date', $1); set_collected_field('', 'time', $2); set_collected_field('', 'hostname', $3); set_collected_field('', 'authenticated_user', $4); set_collected_field('', 'page_title', $5); set_collected_field('', 'page', $6); accept_collected_entry('', false); ); # if currnet log line ` log.filters = { not_authenticated = { label = "$lang_admin.log_filters.not_authenticated_label" comment = "$lang_admin.log_filters.not_authenticated_comment" value = "if (authenticated_user eq '-') then authenticated_user = 'not authenticated';" } # not_authenticated mark_entry = { label = '$lang_admin.log_filters.mark_entry_label' comment = '$lang_admin.log_filters.mark_entry_comment' value = 'hits = 1;' } # mark_entry } # log.filters create_profile_wizard_options = { # How the reports should be grouped in the report menu report_groups = { date_time_group = "" content_group = { page = true page_title = true file_type = true } } # report_groups } # create_profile_wizard_options } # win_route_web