Skip to content

Commit 891cb15

Browse files
committed
Merge branch 'development' of https://github.com/mmguero-dev/Malcolm into v24.11.0_merge_cisagov
2 parents b01f69c + 0aecb45 commit 891cb15

File tree

102 files changed

+2309
-1009
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

102 files changed

+2309
-1009
lines changed

Dockerfiles/arkime.Dockerfile

+2-2
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ ENV PYTHONDONTWRITEBYTECODE 1
3333
ENV PYTHONUNBUFFERED 1
3434

3535
ENV ARKIME_DIR "/opt/arkime"
36-
ENV ARKIME_VERSION "5.4.0"
36+
ENV ARKIME_VERSION "5.5.0"
3737
ENV ARKIME_DEB_URL "https://github.com/arkime/arkime/releases/download/v${ARKIME_VERSION}/arkime_${ARKIME_VERSION}-1.debian12_XXX.deb"
3838
ENV ARKIME_JA4_SO_URL "https://github.com/arkime/arkime/releases/download/v${ARKIME_VERSION}/ja4plus.XXX.so"
3939
ENV ARKIME_LOCALELASTICSEARCH no
@@ -149,7 +149,7 @@ RUN export DEBARCH=$(dpkg --print-architecture) && \
149149
mkdir -p "${ARKIME_DIR}"/plugins && \
150150
curl -fsSL -o "${ARKIME_DIR}/plugins/ja4plus.${DEBARCH}.so" "$(echo "${ARKIME_JA4_SO_URL}" | sed "s/XXX/${DEBARCH}/g")" && \
151151
chmod 755 "${ARKIME_DIR}/plugins/ja4plus.${DEBARCH}.so" && \
152-
python3 -m pip install --break-system-packages --no-compile --no-cache-dir beautifulsoup4 pyzmq watchdog==5.0.3 && \
152+
python3 -m pip install --break-system-packages --no-compile --no-cache-dir beautifulsoup4 pyzmq watchdog==6.0.0 && \
153153
ln -sfr $ARKIME_DIR/bin/npm /usr/local/bin/npm && \
154154
ln -sfr $ARKIME_DIR/bin/node /usr/local/bin/node && \
155155
ln -sfr $ARKIME_DIR/bin/npx /usr/local/bin/npx && \

Dockerfiles/dashboards.Dockerfile

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM opensearchproject/opensearch-dashboards:2.17.1
1+
FROM opensearchproject/opensearch-dashboards:2.18.0
22

33
LABEL maintainer="[email protected]"
44
LABEL org.opencontainers.image.authors='[email protected]'
@@ -42,10 +42,10 @@ RUN export BINARCH=$(uname -m | sed 's/x86_64/amd64/' | sed 's/aarch64/arm64/')
4242
# Malcolm manages authentication and encryption via NGINX reverse proxy
4343
/usr/share/opensearch-dashboards/bin/opensearch-dashboards-plugin remove securityDashboards --allow-root && \
4444
cd /tmp && \
45-
# unzip transformVis.zip opensearch-dashboards/transformVis/opensearch_dashboards.json opensearch-dashboards/transformVis/package.json && \
46-
# sed -i "s/2\.16\.0/2\.17\.0/g" opensearch-dashboards/transformVis/opensearch_dashboards.json && \
47-
# sed -i "s/2\.16\.0/2\.17\.0/g" opensearch-dashboards/transformVis/package.json && \
48-
# zip transformVis.zip opensearch-dashboards/transformVis/opensearch_dashboards.json opensearch-dashboards/transformVis/package.json && \
45+
unzip transformVis.zip opensearch-dashboards/transformVis/opensearch_dashboards.json opensearch-dashboards/transformVis/package.json && \
46+
sed -i "s/2\.17\.1/2\.18\.0/g" opensearch-dashboards/transformVis/opensearch_dashboards.json && \
47+
sed -i "s/2\.17\.1/2\.18\.0/g" opensearch-dashboards/transformVis/package.json && \
48+
zip transformVis.zip opensearch-dashboards/transformVis/opensearch_dashboards.json opensearch-dashboards/transformVis/package.json && \
4949
cd /usr/share/opensearch-dashboards/plugins && \
5050
/usr/share/opensearch-dashboards/bin/opensearch-dashboards-plugin install file:///tmp/transformVis.zip --allow-root && \
5151
rm -rf /tmp/transformVis /tmp/opensearch-dashboards && \

Dockerfiles/file-monitor.Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ RUN export BINARCH=$(uname -m | sed 's/x86_64/amd64/' | sed 's/aarch64/arm64/')
159159
python-magic \
160160
stream-zip \
161161
supervisor \
162-
watchdog==5.0.3 \
162+
watchdog==6.0.0 \
163163
yara-python && \
164164
curl -fsSL -o /usr/local/bin/supercronic "${SUPERCRONIC_URL}${BINARCH}" && \
165165
chmod +x /usr/local/bin/supercronic && \

Dockerfiles/filebeat.Dockerfile

+4-5
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM docker.elastic.co/beats/filebeat-oss:8.15.3
1+
FROM docker.elastic.co/beats/filebeat-oss:8.16.0
22

33
# Copyright (c) 2024 Battelle Energy Alliance, LLC. All rights reserved.
44
LABEL maintainer="[email protected]"
@@ -74,7 +74,7 @@ ENV SUPERCRONIC_CRONTAB "/etc/crontab"
7474
ENV YQ_VERSION "4.44.3"
7575
ENV YQ_URL "https://github.com/mikefarah/yq/releases/download/v${YQ_VERSION}/yq_linux_"
7676

77-
ENV EVTX_VERSION "0.8.3"
77+
ENV EVTX_VERSION "0.8.4"
7878
ENV EVTX_URL "https://github.com/omerbenamram/evtx/releases/download/v${EVTX_VERSION}/evtx_dump-v${EVTX_VERSION}-XXX-unknown-linux-gnu"
7979

8080
USER root
@@ -100,15 +100,14 @@ RUN export EVTXARCH=$(uname -m | sed 's/arm64/aarch64/') && \
100100
psmisc \
101101
python3-pip \
102102
python3-setuptools \
103-
python3.9 \
103+
python3 \
104104
rsync \
105105
tar \
106106
tini \
107107
unar \
108108
unzip \
109109
xz-utils && \
110-
ln -s -f -r /usr/bin/python3.9 /usr/bin/python3 && \
111-
python3.9 -m pip install --no-compile --no-cache-dir patool entrypoint2 pyunpack python-magic ordered-set supervisor watchdog==5.0.3 && \
110+
python3 -m pip install --no-compile --no-cache-dir --break-system-packages patool entrypoint2 pyunpack python-magic ordered-set supervisor watchdog==6.0.0 && \
112111
curl -fsSL -o /usr/local/bin/supercronic "${SUPERCRONIC_URL}${BINARCH}" && \
113112
chmod +x /usr/local/bin/supercronic && \
114113
curl -fsSL -o /usr/local/bin/yq "${YQ_URL}${BINARCH}" && \

Dockerfiles/logstash.Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM docker.elastic.co/logstash/logstash-oss:8.15.3
1+
FROM docker.elastic.co/logstash/logstash-oss:8.16.0
22

33
LABEL maintainer="[email protected]"
44
LABEL org.opencontainers.image.authors='[email protected]'

Dockerfiles/netbox.Dockerfile

+2
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ ENV SUPERCRONIC_CRONTAB "/etc/crontab"
3131

3232
ENV NETBOX_INITIALIZERS_VERSION "50d077d"
3333
ENV NETBOX_TOPOLOGY_VERSION "4.0.1"
34+
ENV NETBOX_HEALTHCHECK_VERSION "0.2.0"
3435

3536
ENV YQ_VERSION "4.44.3"
3637
ENV YQ_URL "https://github.com/mikefarah/yq/releases/download/v${YQ_VERSION}/yq_linux_"
@@ -86,6 +87,7 @@ RUN export BINARCH=$(uname -m | sed 's/x86_64/amd64/' | sed 's/aarch64/arm64/')
8687
"${NETBOX_PATH}/venv/bin/python" -m pip install --break-system-packages --no-compile --no-cache-dir \
8788
"git+https://github.com/tobiasge/netbox-initializers@${NETBOX_INITIALIZERS_VERSION}" \
8889
"git+https://github.com/netbox-community/netbox-topology-views@v${NETBOX_TOPOLOGY_VERSION}" \
90+
"git+https://github.com/netbox-community/netbox-healthcheck-plugin@v${NETBOX_HEALTHCHECK_VERSION}" \
8991
psycopg2 \
9092
pynetbox \
9193
python-magic \

Dockerfiles/opensearch.Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM opensearchproject/opensearch:2.17.1
1+
FROM opensearchproject/opensearch:2.18.0
22

33
# Copyright (c) 2024 Battelle Energy Alliance, LLC. All rights reserved.
44
LABEL maintainer="[email protected]"

Dockerfiles/pcap-monitor.Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ RUN apt-get -q update && \
6868
python-magic \
6969
pyzmq \
7070
requests \
71-
watchdog==5.0.3 && \
71+
watchdog==6.0.0 && \
7272
groupadd --gid ${DEFAULT_GID} ${PGROUP} && \
7373
useradd -M --uid ${DEFAULT_UID} --gid ${DEFAULT_GID} ${PUSER}
7474

Dockerfiles/suricata.Dockerfile

+1-1
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,7 @@ RUN export BINARCH=$(uname -m | sed 's/x86_64/amd64/' | sed 's/aarch64/arm64/')
108108
apt-get install -q -y --no-install-recommends -t bookworm-backports \
109109
suricata=${SURICATA_VERSION_PATTERN} \
110110
suricata-update && \
111-
python3 -m pip install --break-system-packages --no-compile --no-cache-dir watchdog==5.0.3 && \
111+
python3 -m pip install --break-system-packages --no-compile --no-cache-dir watchdog==6.0.0 && \
112112
curl -fsSL -o /usr/local/bin/supercronic "${SUPERCRONIC_URL}${BINARCH}" && \
113113
chmod +x /usr/local/bin/supercronic && \
114114
curl -fsSL -o /usr/bin/yq "${YQ_URL}${BINARCH}" && \

Dockerfiles/zeek.Dockerfile

+21-8
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@ RUN export BINARCH=$(uname -m | sed 's/x86_64/amd64/' | sed 's/aarch64/arm64/')
8787
libmaxminddb0 \
8888
libpcap-dev \
8989
libpcap0.8 \
90+
librdkafka-dev \
9091
libssl-dev \
9192
libssl3 \
9293
libtcmalloc-minimal4 \
@@ -107,6 +108,7 @@ RUN export BINARCH=$(uname -m | sed 's/x86_64/amd64/' | sed 's/aarch64/arm64/')
107108
python3-setuptools \
108109
python3-tz \
109110
python3-wheel \
111+
python3-yaml \
110112
python3-zmq \
111113
rsync \
112114
supervisor \
@@ -115,7 +117,12 @@ RUN export BINARCH=$(uname -m | sed 's/x86_64/amd64/' | sed 's/aarch64/arm64/')
115117
vim-tiny \
116118
xxd \
117119
zlib1g-dev && \
118-
python3 -m pip install --break-system-packages --no-cache-dir pymisp stix2 taxii2-client dateparser && \
120+
python3 -m pip install --break-system-packages --no-cache-dir \
121+
dateparser \
122+
git+https://github.com/google/mandiant-ti-client \
123+
pymisp \
124+
stix2 \
125+
taxii2-client && \
119126
mkdir -p /tmp/zeek-packages && \
120127
bash /usr/local/bin/zeek-deb-download.sh -o /tmp/zeek-packages -z "${ZEEK_VERSION}" && \
121128
dpkg -i /tmp/zeek-packages/*.deb && \
@@ -133,6 +140,7 @@ RUN export BINARCH=$(uname -m | sed 's/x86_64/amd64/' | sed 's/aarch64/arm64/')
133140
( find "${ZEEK_DIR}"/lib/zeek/plugins/packages -type f -name "*.hlto" -exec chmod 755 "{}" \; || true ) && \
134141
mkdir -p "${ZEEK_DIR}"/share/zeek/site/intel/STIX && \
135142
mkdir -p "${ZEEK_DIR}"/share/zeek/site/intel/MISP && \
143+
mkdir -p "${ZEEK_DIR}"/share/zeek/site/intel/Mandiant && \
136144
mkdir -p "${ZEEK_DIR}"/share/zeek/site/custom && \
137145
touch "${ZEEK_DIR}"/share/zeek/site/intel/__load__.zeek && \
138146
touch "${ZEEK_DIR}"/share/zeek/site/custom/__load__.zeek && \
@@ -174,7 +182,7 @@ RUN groupadd --gid ${DEFAULT_GID} ${PUSER} && \
174182

175183
# sanity checks to make sure the plugins installed and copied over correctly
176184
# these ENVs should match the third party scripts/plugins installed by zeek_install_plugins.sh
177-
ENV ZEEK_THIRD_PARTY_PLUGINS_GREP "(Zeek::Spicy|ANALYZER_SPICY_OSPF|ANALYZER_SPICY_OPENVPN_UDP\b|ANALYZER_SPICY_IPSEC_UDP\b|ANALYZER_SPICY_TFTP|ANALYZER_SPICY_WIREGUARD|ANALYZER_SPICY_HART_IP_UDP|ANALYZER_SPICY_HART_IP_TCP|ANALYZER_SYNCHROPHASOR_TCP|ANALYZER_GENISYS_TCP|ANALYZER_SPICY_GE_SRTP|ANALYZER_SPICY_PROFINET_IO_CM|ANALYZER_S7COMM_TCP|Corelight::PE_XOR|ICSNPP::BACnet|ICSNPP::BSAP|ICSNPP::ENIP|ICSNPP::ETHERCAT|ICSNPP::OPCUA_Binary|Salesforce::GQUIC|Zeek::PROFINET|Zeek::TDS)"
185+
ENV ZEEK_THIRD_PARTY_PLUGINS_GREP "(Zeek::Spicy|ANALYZER_SPICY_OSPF|ANALYZER_SPICY_OPENVPN_UDP\b|ANALYZER_SPICY_IPSEC_UDP\b|ANALYZER_SPICY_TFTP|ANALYZER_SPICY_WIREGUARD|ANALYZER_SPICY_HART_IP_UDP|ANALYZER_SPICY_HART_IP_TCP|ANALYZER_SYNCHROPHASOR_TCP|ANALYZER_GENISYS_TCP|ANALYZER_SPICY_GE_SRTP|ANALYZER_SPICY_PROFINET_IO_CM|ANALYZER_S7COMM_TCP|Corelight::PE_XOR|ICSNPP::BACnet|ICSNPP::BSAP|ICSNPP::ENIP|ICSNPP::ETHERCAT|ICSNPP::OPCUA_Binary|Salesforce::GQUIC|Zeek::PROFINET|Zeek::TDS|Seiso::Kafka)"
178186
ENV ZEEK_THIRD_PARTY_SCRIPTS_GREP "(bro-is-darknet/main|bro-simple-scan/scan|bzar/main|callstranger-detector/callstranger|cve-2020-0601/cve-2020-0601|cve-2020-13777/cve-2020-13777|CVE-2020-16898/CVE-2020-16898|CVE-2021-38647/omigod|CVE-2021-31166/detect|CVE-2021-41773/CVE_2021_41773|CVE-2021-42292/main|cve-2021-44228/CVE_2021_44228|cve-2022-22954/main|cve-2022-26809/main|CVE-2022-3602/__load__|hassh/hassh|http-more-files-names/main|ja4/main|pingback/detect|ripple20/ripple20|SIGRed/CVE-2020-1350|zeek-EternalSafety/main|zeek-httpattacks/main|zeek-sniffpass/__load__|zerologon/main)\.(zeek|bro)"
179187

180188
RUN mkdir -p /tmp/logs && \
@@ -183,7 +191,7 @@ RUN mkdir -p /tmp/logs && \
183191
export ZEEK_THIRD_PARTY_SCRIPTS_COUNT=$(echo "$ZEEK_THIRD_PARTY_SCRIPTS_GREP" | grep -P -o "\([^)]+\)" | head -n 1 | sed "s/^(//" | sed "s/)$//" | tr '|' '\n' | wc -l) && \
184192
"$ZEEK_DIR"/bin/zeek-offline -NN local >zeeknn.log 2>/dev/null && \
185193
bash -c "(( $(grep -cP "$ZEEK_THIRD_PARTY_PLUGINS_GREP" zeeknn.log) >= $ZEEK_THIRD_PARTY_PLUGINS_COUNT)) && echo $ZEEK_THIRD_PARTY_PLUGINS_COUNT' Zeek plugins loaded correctly' || (echo 'One or more Zeek plugins did not load correctly' && cat zeeknn.log && exit 1)" && \
186-
"$ZEEK_DIR"/bin/zeek-offline -C -r /tmp/pcaps/udp.pcap local policy/misc/loaded-scripts 2>/dev/null && \
194+
"$ZEEK_DIR"/bin/zeek-offline -C -r /tmp/pcaps/udp.pcap local policy/misc/loaded-scripts >loaded_scripts.log 2>/dev/null && \
187195
bash -c "(( $(grep -cP "$ZEEK_THIRD_PARTY_SCRIPTS_GREP" loaded_scripts.log) == $ZEEK_THIRD_PARTY_SCRIPTS_COUNT)) && echo $ZEEK_THIRD_PARTY_SCRIPTS_COUNT' Zeek scripts loaded correctly' || (echo 'One or more Zeek scripts did not load correctly' && cat loaded_scripts.log && exit 1)" && \
188196
cd /tmp && \
189197
rm -rf /tmp/logs /tmp/pcaps
@@ -195,8 +203,9 @@ ARG ZEEK_PCAP_PROCESSOR=true
195203
#Whether or not to run "zeek -r XXXXX.pcap local" on each pcap file
196204
ARG ZEEK_AUTO_ANALYZE_PCAP_FILES=false
197205
ARG ZEEK_AUTO_ANALYZE_PCAP_THREADS=1
198-
#Whether or not to refresh intel at various points during processing
199-
ARG ZEEK_INTEL_REFRESH_ON_ENTRYPOINT=false
206+
#Whether or not to do first intel refresh under supervisord
207+
ARG ZEEK_INTEL_REFRESH_ON_STARTUP=false
208+
#Whether or not to do first intel refresh under zeekdeploy.sh
200209
ARG ZEEK_INTEL_REFRESH_ON_DEPLOY=false
201210
ARG ZEEK_INTEL_REFRESH_CRON_EXPRESSION=
202211
ARG ZEEK_INTEL_ITEM_EXPIRATION=-1min
@@ -219,7 +228,7 @@ ARG PCAP_NODE_NAME=malcolm
219228

220229
ENV AUTO_TAG $AUTO_TAG
221230
ENV ZEEK_PCAP_PROCESSOR $ZEEK_PCAP_PROCESSOR
222-
ENV ZEEK_INTEL_REFRESH_ON_ENTRYPOINT $ZEEK_INTEL_REFRESH_ON_ENTRYPOINT
231+
ENV ZEEK_INTEL_REFRESH_ON_STARTUP $ZEEK_INTEL_REFRESH_ON_STARTUP
223232
ENV ZEEK_INTEL_REFRESH_ON_DEPLOY $ZEEK_INTEL_REFRESH_ON_DEPLOY
224233
ENV ZEEK_INTEL_REFRESH_CRON_EXPRESSION $ZEEK_INTEL_REFRESH_CRON_EXPRESSION
225234
ENV ZEEK_AUTO_ANALYZE_PCAP_FILES $ZEEK_AUTO_ANALYZE_PCAP_FILES
@@ -249,8 +258,6 @@ ARG ZEEK_DISABLE_SSL_VALIDATE_CERTS=
249258
ARG ZEEK_DISABLE_TRACK_ALL_ASSETS=
250259
ARG ZEEK_DISABLE_DETECT_ROUTERS=true
251260
ARG ZEEK_DISABLE_BEST_GUESS_ICS=true
252-
# TODO: assess spicy-analyzer that replace built-in Zeek parsers
253-
# for now, disable them by default when a Zeek parser exists
254261
ARG ZEEK_DISABLE_SPICY_IPSEC=
255262
ARG ZEEK_DISABLE_SPICY_LDAP=
256263
ARG ZEEK_DISABLE_SPICY_OPENVPN=
@@ -260,6 +267,9 @@ ARG ZEEK_DISABLE_SPICY_TAILSCALE=
260267
ARG ZEEK_DISABLE_SPICY_TFTP=
261268
ARG ZEEK_DISABLE_SPICY_WIREGUARD=
262269
ARG ZEEK_SYNCHROPHASOR_DETAILED=
270+
ARG ZEEK_KAFKA_ENABLED=
271+
ARG ZEEK_KAFKA_BROKERS=kafka.local:9091
272+
ARG ZEEK_KAFKA_TOPIC=zeek
263273

264274
ENV ZEEK_DISABLE_STATS $ZEEK_DISABLE_STATS
265275
ENV ZEEK_DISABLE_HASH_ALL_FILES $ZEEK_DISABLE_HASH_ALL_FILES
@@ -278,6 +288,9 @@ ENV ZEEK_DISABLE_SPICY_TAILSCALE $ZEEK_DISABLE_SPICY_TAILSCALE
278288
ENV ZEEK_DISABLE_SPICY_TFTP $ZEEK_DISABLE_SPICY_TFTP
279289
ENV ZEEK_DISABLE_SPICY_WIREGUARD $ZEEK_DISABLE_SPICY_WIREGUARD
280290
ENV ZEEK_SYNCHROPHASOR_DETAILED $ZEEK_SYNCHROPHASOR_DETAILED
291+
ENV ZEEK_KAFKA_ENABLED $ZEEK_KAFKA_ENABLED
292+
ENV ZEEK_KAFKA_BROKERS $ZEEK_KAFKA_BROKERS
293+
ENV ZEEK_KAFKA_TOPIC $ZEEK_KAFKA_TOPIC
281294

282295
# This is in part to handle an issue when running with rootless podman and
283296
# "userns_mode: keep-id". It seems that anything defined as a VOLUME

0 commit comments

Comments
 (0)