# Copyright (c) 2010 Flowerfire, Inc. All Rights Reserved. lancom_router = { plugin_version = "1.0" # 2007-09-11 - 1.0 - KBB - added version number and changed file name from beta_lancom_router.cfg # The name of the log format log.format.format_label = "Lancom Router" log.miscellaneous.log_data_type = "syslog_required" log.miscellaneous.log_format_type = "network_device" # The log is in this format if any of the first ten lines match this regular expression log.format.autodetect_regular_expression = "PACKET_ALERT: Dst: [0-9]+\\.[0-9]+\\.[0-9]+\\.[0-9]+:[0-9]+ \\{[^}]*\\}, Src: [0-9]+\\.[0-9]+\\.[0-9]+\\.[0-9]+:[0-9]+ \\([A-Z]+\\)" # Log fields log.fields = { destination_ip = "" destination_port = "" source_ip = "" source_port = "" protocol = "" matched_filter = "" actions = "" } # log.fields # # Log Parsing Filters log.parsing_filters.parse = ` if (matches_regular_expression(v.syslog_message, '^PACKET_ALERT: Dst: ([0-9.]+):([0-9]+) \\\\{[^}]*\\\\}, Src: ([0-9.]+):([0-9]+) \\\\(([A-Z]*)\\\\)')) then ( # Accept the previous entry if (get_collected_field('', 'destination_ip') ne '(empty)') then ( v.date = get_collected_field('', 'date'); v.time = get_collected_field('', 'time'); v.logging_device = get_collected_field('', 'logging_device'); v.syslog_priority = get_collected_field('', 'syslog_priority'); accept_collected_entry('', false); set_collected_field('', 'date', v.date); set_collected_field('', 'time', v.date); set_collected_field('', 'logging_device', v.logging_device); set_collected_field('', 'syslog_priority', v.syslog_priority); ); set_collected_field('', 'destination_ip', $1); set_collected_field('', 'destination_port', $2); set_collected_field('', 'source_ip', $3); set_collected_field('', 'source_port', $4); set_collected_field('', 'protocol', $5); ); # if PACKET_ALERT else if (matches_regular_expression(v.syslog_message, '^PACKET_INFO: matched filter: (.*)$')) then ( set_collected_field('', 'matched_filter', $1); ); else if (matches_regular_expression(v.syslog_message, '^PACKET_INFO: actions: *(.*)$')) then ( set_collected_field('', 'actions', $1); ); ` # Database fields database.fields = { destination_ip = "" destination_port = "" source_ip = "" source_port = "" protocol = "" matched_filter = "" actions = "" } # database.fields # Log Filters log.filters = { mark_entry = { label = '$lang_admin.log_filters.mark_entry_label' comment = '$lang_admin.log_filters.mark_entry_comment' value = 'packets = 1;' } # mark_entry } # log.filters database.numerical_fields = { packets = { label = "$lang_stats.field_labels.packets" default = true requires_log_field = false type = "int" display_format_type = "integer" entries_field = true } # packets } # database.numerical_fields create_profile_wizard_options = { host_tracking = true # How the reports should be grouped in the report menu report_groups = { date_time_group = "" destination_ip = true destination_port = true source_ip = true source_port = true protocol = true matched_filter = true actions = true } # report_groups } # create_profile_wizard_options } # lancom_router