Skip to content

Commit

Permalink
chore: Configure Snort logging on macOS
Browse files Browse the repository at this point in the history
  • Loading branch information
bengo237 committed Sep 12, 2024
1 parent 61c5587 commit 8973302
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions scripts/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,20 @@ install_snort_linux() {
start_snort_linux
}

# Function to configure Snort logging on macOS
configure_snort_logging_macos() {
local config_file="$SNORT_CONF_PATH"
local content_to_add='alert_fast =\n{\n file = true\n}'

info_message "Configuring Snort logging"
if ! grep -q "$content_to_add" "$config_file"; then
echo -e "$content_to_add" | maybe_sudo tee -a "$config_file" > /dev/null
success_message "Snort logging configured in $config_file"
else
info_message "Snort logging is already configured in $config_file"
fi
}

# Function to update ossec.conf on macOS (M1 and Intel)
update_ossec_conf_macos() {
local content_to_add="<!-- snort -->
Expand Down

0 comments on commit 8973302

Please sign in to comment.