OSSEC server image with configurable syslog forwarding and auto-enrollment support
7.5K
An ossec-server image with the ability to separate the ossec configuration/data from the container, meaning easy container replacements. This image is designed to be as turn key as possible, supporting out of the box:
The following directories are externalized under /var/ossec/data which allow the container to be replaced without configuration or data loss: logs, etc, stats,rules, and queue. In addition to those directories, the bin/.process_list file is symlink'ed to process_list in the data volume.
To get an up and running ossec server that supports auto-enrollment and sends HIDS notifications a syslog server, use.
docker run --name ossec-server -d -p 1514:1514/udp -p 1515:1515\
-e SYSLOG_FORWADING_ENABLED=true -e SYSLOG_FORWARDING_SERVER_IP=X.X.X.X\
-v /somepath/ossec_mnt:/var/ossec/data xetusoss/ossec-server
Once the system starts up, you can execute the standard ossec commands using docker. For example, to list active agents.
docker exec -ti ossec-server /var/ossec/bin/list_agents -a
true;true if ALERTS_TO_EMAIL is specified, otherwise falseossec@$HOSTNAME.false.514.default.Please note: All the SMTP and SYSLOG configuration variables are only applicable to the first time setup. Once the container's data volume has been initialized, all the configuration options for OSSEC can be changed.
Since this is a docker container, ossec-execd really isn't a great idea anyway. Having a log server, such as graylog, react based on log entries is the recommended approach.
On first launch, the ossec server will not start up properly and bind to port 1514, unless at least one agent to be present in the client.keys file. To avoid that issue, a local agent is setup by default. See this bug with OSSEC.
Since this image has become the de-facto standard for OSSEC on docker hub, I wanted to be very clear that we intend to maintain this image with the interest of the community in mind. If you have issues, please file them. If you have made changes you'd like to see included, pull requests are welcome!
Content type
Image
Digest
sha256:f244a2c7b…
Size
129.4 MB
Last updated
over 9 years ago
docker pull xetusoss/ossec-server