openwrt / openwrt/packages

snort3: enable more control over the process

Open
#20,973 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Makefile
Stars
4.6k
Forks
4k
Avg merge
3d 12h
Merged PRs (30d)
134

Description

@graysky2

Hi

When I was playing around with my snort3, I realized that it lacks some useful functionality to control the running process.
They are:

  • by providing --shell CLI option, Snort will be able to get commands, execute them and respond back to the user's console; it is useful for manual debuggiong and adjusting snort configurations
  • by providing --control-socket <file> CLI option will create a UNIX-scoket, which will be served by the running process, performing the same role as the option above; it could be useful for GUI or other backend scripts to control the running engine

Could you add the following option to Makefile?

CMAKE_OPTIONS += -DENABLE_SHELL

You might want to try the command below to get the idea (look at 'remote commands' section)
snort --help-module snort
(Some other modules support remote commands as well)

One of the noteable ability is reloading new configuration on-the-fly and dumping actual packet and module statistics.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the Snort3 package Makefile and inspect how its CMAKE_OPTIONS are passed to the build. Run snort --help-module snort to review the remote commands, then verify that enabling -DENABLE_SHELL produces the requested shell support in the built package.

Written by the indexing model from the issue text.

Assessment

Domain
build-system, cli
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.