Commit Graph
83 Commits
Author SHA1 Message Date
Josh Patterson 72f60fcaa9 FIX: remove the docker socket from so-telegraf
so-telegraf mounted /var/run/docker.sock and joined the host docker group on
every node type. The :ro flag blocks write() to the inode, not connect() plus
HTTP over the socket, so any code execution inside the container could reach
POST /containers/create with Privileged:true and become root on the host.

No telegraf script used the socket; the only consumer was the native
[[inputs.docker]] plugin, and group_add 920 existed solely to feed it.
Container metrics now come from so-container-stats, a collector that runs on
the host from cron and writes influx line protocol to a file telegraf already
had mounted. This is the pattern so-status, so-raid-status and
so-elasticagent-status already use, so the privileged docker access stays on
the host side where root cron already ran it.

The collector runs as somon, a service account in the docker group with no
login shell and a locked password, rather than root. Docker group membership
is still root-equivalent on the host, so this is defense in depth rather than
a privilege boundary.

The telegraf scripts were root:939 mode 770, letting socore rewrite them for
code execution inside the container; they are now 750, which still allows the
read and execute telegraf needs. The container also ran with no group, giving
it gid 0, and now runs as 939:939. That alone would have broken
lasthighstate.sh, which reached /opt/so/log/salt only via the root group and
could not tell an unreadable file from a missing one, so it silently reported
a 56 year highstate age. Only the lasthighstate file is bind mounted now, and
the script tests readability instead of existence.

Everything inputs.docker collected beyond the five fields the shipped
dashboards query is available per stat under telegraf:container_stats,
annotated for SOC so an operator can enable it without editing files. Defaults
reproduce the previous output exactly. With every stat enabled the emitted
field set matches what inputs.docker wrote, verified by running the plugin
against the live socket and diffing: 53 fields, no type mismatches, no field
present on one side only.

Two deliberate differences: max_usage carries the real cgroup peak where the
daemon reports 0 on cgroup v2, and host-network containers emit no
docker_container_net row, matching inputs.docker. Docker label tags are not
restored, since nothing queries them and they cost significant cardinality.

so-status, the influxdb size cron, so-elasticagent-status, so-raid-status and
so-common-status-check truncated their output in place while telegraf read it,
so telegraf periodically saw an empty file and logged a parse error or emitted
empty values. They now write aside and rename. Measured on a live manager, the
old so-status cron left status.log empty for 215 of 10997 reads.

Tested on a fresh install, a converted grid and a 3.0 upgrade.
2026-09-24 14:30:25 -04:00
Mike Reeves fcbea1a1c4 Add 3.4.0 option to discussion template 2026-09-08 15:14:26 -04:00
Mike Reeves 12bb16e89c Add version 3.3.0 to discussion template 2026-07-29 14:22:42 -04:00
Josh Patterson 9e7e6edae0 Add unit tests for _beacons and wire into CI
Add 100%-coverage unit tests for the three custom salt beacons
(postgres_pillar_beacon, rules_beacon, zeek) and add salt/_beacons to
the python-test workflow's paths trigger and matrix.

To pass the workflow's flake8 lint over the whole directory:
- zeek.py: reindent to 4 spaces, drop trailing blank line, noqa the
  Salt-injected __salt__ references (F821); no logic change.
- postgres_pillar_beacon.py: noqa C901 on beacon() (complexity 13 > 12).
2026-07-16 15:28:22 -04:00
Mike Reeves aa78978740 Add 3.2.0 option to discussion template 2026-05-21 15:57:57 -04:00
Jason Ertel 76f4ccf8c8 Merge pull request #15705 from Security-Onion-Solutions/3/main
Merge pr/workflow changes back to dev
2026-04-01 10:57:34 -04:00
Jason Ertel 80540da52f pr/workflow changes 2026-04-01 10:48:47 -04:00
Jason Ertel e4ba3d6a2a pr/workflow changes 2026-04-01 10:47:59 -04:00
Mike Reeves 1e2b51eae6 Add version 3.1.0 to discussion template options 2026-03-31 13:53:00 -04:00
Jason Ertel 812f65eee8 revisit workflows 2026-03-27 16:11:31 -04:00
Jorge Reyes f2b6d59c65 exclude oscap profile from gitleaks 2026-03-23 14:17:39 -05:00
Mike Reeves 625bfb3ba7 Rebuild analyzer source-packages wheels for Python 3.14
The so-soc Dockerfile base image moved to python:3.14.3-slim but
analyzer source-packages still contained cp313 wheels for pyyaml and
charset_normalizer, causing pip install failures at container startup.

Replace all cp313 wheels with cp314 builds (pyyaml 6.0.3,
charset_normalizer 3.4.6) across all 14 analyzers and update the
CI python-test workflow to match.
2026-03-16 18:58:23 -04:00
Doug Burks 72193b0249 Remove version 3.0.0 from 2.4 discussion template 2026-03-13 10:51:25 -04:00
Doug Burks 589de8e361 Update discussion template by removing unsupported options
Removed unsupported network installation options for Red Hat, Ubuntu, and Debian.
2026-03-13 10:48:15 -04:00
Doug Burks 914cd8b611 Add discussion template for Security Onion 3.0 2026-03-12 13:52:41 -04:00
Doug Burks 845290595e Delete .github/DISCUSSION_TEMPLATE/3.0.yml 2026-03-12 13:52:14 -04:00
Doug Burks 544b60d111 Add discussion template for version 3.0 2026-03-12 13:51:27 -04:00
Mike Reeves aa0787b0ff Add version 2.4.211 to discussion template 2026-03-12 13:11:43 -04:00
Jason Ertel 2c4d833a5b update 2.4 references to 3 2026-03-05 11:05:19 -05:00
Mike Reeves ac022acbbe Add version 3.0.0 to discussion template 2026-03-02 15:22:10 -05:00
Jason Ertel 9bd5e1897a prepare for nextgen docs 2026-02-27 13:09:55 -05:00
Jason Ertel 4f59e46235 Add version 2.4.201 to discussion template 2026-01-15 14:38:40 -05:00
Mike Reeves 032e0abd61 Update 2-4.yml 2025-12-16 11:23:53 -05:00
Jason Ertel 7c45db2295 add support to so-yaml for using yaml file content for values 2025-11-11 16:57:54 -05:00
Jason Ertel f348c7168f bump version 2025-10-24 16:19:24 -04:00
Doug Burks e01d0f81ea Update 2-4.yml 2025-09-17 14:22:40 -04:00
Mike Reeves d02093295b Update 2-4.yml 2025-08-12 10:59:17 -04:00
Josh Patterson b0f5218775 add quotes 2025-06-27 10:58:14 -04:00
Josh Patterson 8fdc7049f9 add missing , 2025-06-27 10:53:03 -04:00
Josh Patterson daaad3699c allow wheel files 2025-06-25 17:20:17 -04:00
Mike Reeves 5e62d3ecb2 Update 2-4.yml 2025-06-25 13:58:57 -04:00
Mike Reeves 510c7a0c19 Update 2-4.yml 2025-05-12 10:48:12 -04:00
Jason Ertel 95d8e0f318 stop double workflow runs 2025-05-01 15:46:04 -04:00
Jason Ertel ba4df4c8b6 dep updates 2025-05-01 15:36:20 -04:00
Jason Ertel 86eab6fda2 dep updates 2025-05-01 15:31:26 -04:00
Mike Reeves eef4b82afb Update 2-4.yml 2025-03-31 11:46:03 -04:00
Mike Reeves 54f3a8cb91 Update 2-4.yml 2025-03-24 15:16:43 -04:00
Mike Reeves 5234b21743 Update 2-4.yml 2025-03-11 13:25:43 -04:00
Doug Burks 5dc9200ee7 Add files via upload 2025-02-20 13:19:22 -05:00
Doug Burks 2be5384980 Create config.yml 2025-02-20 13:19:08 -05:00
Doug Burks 25dfc182a9 Delete .github/ISSUE_TEMPLATE 2025-02-20 13:18:02 -05:00
Jorge Reyes a3dba9b566 Merge pull request #14255 from Security-Onion-Solutions/foxtrot
ES 8.17.1
2025-02-18 14:58:46 -06:00
Jorge Reyes f991d8a10a Update .gitleaks.toml 2025-02-18 14:37:20 -06:00
Mike Reeves d2ac6ec10f Update 2-4.yml 2025-02-12 11:29:07 -05:00
Jason Ertel bf19c6e730 ca download; ignore shard errors on startup; clarify oidc id 2025-02-05 15:04:04 -05:00
Mike Reeves d4f1772d2e Update 2-4.yml 2024-12-18 10:36:15 -05:00
Doug Burks ba4fbb9953 Update 2-4.yml 2024-10-07 16:05:45 -04:00
Doug Burks 9eb76a95ca Update 2-4.yml 2024-08-30 11:25:51 -04:00
Mike Reeves caec424e44 Update .gitleaks.toml 2024-06-25 14:47:50 -04:00
Jason Ertel 89cb8b79fd restrict workflows to so 2024-04-29 08:07:19 -04:00