Commit graph

17661 commits

Author SHA1 Message Date
Arne Welzel
280e7acc6e Merge remote-tracking branch 'origin/topic/awelzel/4035-btest-openssl-sha1-certs'
* origin/topic/awelzel/4035-btest-openssl-sha1-certs:
  external/subdir-btest.cfg: Set OPENSSL_ENABLE_SHA1_SIGNATURES=1
  btest/x509_verify: Drop OpenSSL 1.0 hack
  testing/btest: Use OPENSSL_ENABLE_SHA1_SIGNATURES
2025-02-04 09:52:55 +01:00
Arne Welzel
8b645243cb external/subdir-btest.cfg: Set OPENSSL_ENABLE_SHA1_SIGNATURES=1
We already do something similar for OPENSSL_ENABLE_MD5_VERIFY=1
2025-02-04 09:44:06 +01:00
Arne Welzel
ad370c0c37 btest/x509_verify: Drop OpenSSL 1.0 hack
We do not have a distro in CI anymore that ships OpenSSL 1.0,
drop the hack.
2025-02-04 09:44:03 +01:00
Arne Welzel
bb2e20d353 testing/btest: Use OPENSSL_ENABLE_SHA1_SIGNATURES
This reverts the call to update-crypto-policies in the Fedora 41 image
and instead sets OPENSSL_ENABLE_SHA1_SIGNATURES in the individual tests.
This allows RHEL 10 or Fedora 41 users to run the tests in question
without needing to fiddle with system settings.

Fixes #4035
2025-02-04 09:43:26 +01:00
Arne Welzel
0290a73544 Merge remote-tracking branch 'origin/topic/timw/add-missing-quic-zam-baseline'
* origin/topic/timw/add-missing-quic-zam-baseline:
  Add ZAM baseline for new scripts.base.protocols.quic.analyzer-confirmations btest
2025-02-04 09:18:42 +01:00
Tim Wojtulewicz
c8eab363fb Merge remote-tracking branch 'philipp-tg/asrep_enc_part'
* philipp-tg/asrep_enc_part:
  Make enc_part value from kerberos response available to scripts
2025-02-03 18:41:53 -07:00
Tim Wojtulewicz
f0d7984bac Merge remote-tracking branch 'origin/topic/timw/add-note-about-pe-pcap'
* origin/topic/timw/add-note-about-pe-pcap:
  Add note to Traces/README about possible malware in pe/pe.trace
  Fix formatting of Traces/README entry for modbus-eit.trace
2025-02-03 18:34:15 -07:00
Christian Kreibich
073aad9241 Merge branch 'topic/christian/remove-supervisednode-initcluster-decl'
* topic/christian/remove-supervisednode-initcluster-decl:
  Remove unused SupervisedNode::InitCluster declaration
2025-02-03 16:53:23 -08:00
Tim Wojtulewicz
0f4461fdbf Add ZAM baseline for new scripts.base.protocols.quic.analyzer-confirmations btest 2025-02-03 13:40:15 -07:00
Arne Welzel
44304973fb Merge remote-tracking branch 'origin/topic/awelzel/4198-4201-quic-maintenance'
* origin/topic/awelzel/4198-4201-quic-maintenance:
  QUIC/decrypt_crypto: Rename all_data to data
  QUIC: Confirm before forwarding data to SSL
  QUIC: Parse all QUIC packets in a UDP datagram
  QUIC: Only slurp till packet end, not till &eod
2025-02-03 17:52:20 +01:00
Arne Welzel
93bc4e4669 QUIC/decrypt_crypto: Rename all_data to data
...for consistency.
2025-02-03 17:36:41 +01:00
Arne Welzel
5d9d3921a6 QUIC: Confirm before forwarding data to SSL
Fixes #4201
2025-02-03 17:36:41 +01:00
Arne Welzel
6a14e64a17 QUIC: Parse all QUIC packets in a UDP datagram
A UDP datagram may contain multiple QUIC packets, but the parser so far
handled only the very first packet, ignoring any subsequent packets.

Fixes #4198
2025-02-03 17:36:37 +01:00
Arne Welzel
744917aa69 QUIC: Only slurp till packet end, not till &eod
This doesn't change behavior, but avoids slurping in more data than
needed. A UDP packet an contain multiple QUIC packets and we'd read
all following ones instead just the one we're interested in.
2025-02-03 17:26:57 +01:00
Christian Kreibich
4324bab58b Remove unused SupervisedNode::InitCluster declaration
The move of the cluster table initialization to the script layer removed
the implementation, but overlooked this declaration. See:
737b1a2013
2025-01-31 20:33:07 -08:00
zeek-bot
65a79b1dec Update doc submodule [nomail] [skip ci] 2025-02-01 00:14:20 +00:00
Christian Kreibich
8ef333ff32 Merge branch 'topic/christian/management-multinode-metrics-ports'
* topic/christian/management-multinode-metrics-ports:
  Bump cluster testsuite to pull in updated Prometheus tests
  Management framework: move up addition of agent IPs into deployable cluster configs
  Support multiple instances per host addr in auto metrics generation
  When auto-generating metrics ports for worker nodes, get them more uniform across instances.
2025-01-31 15:59:22 -08:00
Christian Kreibich
93eb99ca2e Bump cluster testsuite to pull in updated Prometheus tests 2025-01-31 15:58:04 -08:00
Philipp Tekeser-Glasz
135e2f9c67 Make enc_part value from kerberos response available to scripts 2025-01-31 12:58:14 +00:00
Christian Kreibich
ea88257d4d Management framework: move up addition of agent IPs into deployable cluster configs
Since the changes to port autoassignment in the preceding commits leverage agent
IP address information, we need to ensure that this information is available at
the time of autoassignment. The controller learns IP addresses from connecting
agents, and previously used that information at deploy time. This moves the
augmentation of the cluster config up to port autoassignment time.
2025-01-30 16:43:12 -08:00
Michael Dopheide
0c0769b1b2 Support multiple instances per host addr in auto metrics generation 2025-01-30 16:41:27 -08:00
Michael Dopheide
b120f39bd7 When auto-generating metrics ports for worker nodes, get them more uniform across instances. 2025-01-30 16:41:27 -08:00
Tim Wojtulewicz
a5b0a9467d Add note to Traces/README about possible malware in pe/pe.trace 2025-01-30 13:28:35 -07:00
Tim Wojtulewicz
430e3ab940 Fix formatting of Traces/README entry for modbus-eit.trace 2025-01-30 13:28:17 -07:00
Tim Wojtulewicz
7172b682f2 Merge remote-tracking branch 'origin/topic/timw/packing'
* origin/topic/timw/packing:
  Pack some classes for better memory usages
2025-01-30 10:51:23 -07:00
Tim Wojtulewicz
572adf3f23 Pack some classes for better memory usages
- Analyzer: Reduce from 208 bytes to 192 bytes, remove one cache line
- EventGroup: Reduce from 104 bytes to 96 bytes
- Packet: Reduce from 200 bytes to 184 bytes, remove one cache line
- threading::Value: Reduce from 48 bytes to 40 bytes
- ConnTuple: push hole to the end of struct
- TCP_Reassembler: Reduce from 240 bytes to 232 bytes
2025-01-30 10:50:29 -07:00
Tim Wojtulewicz
99023b14d5 Merge remote-tracking branch 'origin/topic/etyp/type-const'
* origin/topic/etyp/type-const:
  Make types into constants
2025-01-24 15:47:40 -07:00
Tim Wojtulewicz
5d9aa52122 Revert "Merge remote-tracking branch 'origin/topic/etyp/type-const'"
This reverts commit 53982aabfa, reversing
changes made to 8c28e47dc1.
2025-01-24 15:47:01 -07:00
Tim Wojtulewicz
1b122a919d Update doc submodule [nomail] [skip ci] 2025-01-24 15:43:37 -07:00
Tim Wojtulewicz
53982aabfa Merge remote-tracking branch 'origin/topic/etyp/type-const'
* origin/topic/etyp/type-const:
  Make types into constants
2025-01-24 15:43:06 -07:00
Evan Typanski
0c27aa6c50 Make types into constants
Closes #4173

This allows types to be used in expressions, but they can't be
reassigned. Note that this was meant to be a special "type expression" -
but that is unnecessary complexity.

Type expressions would allow access to the type without going through
its constant value, but the constant value is never changed, so it's
simply a few more checks if necessary when functionality gets expanded.
This way, ZAM and other code will not need updates, so the potential for
increased work in the future is probably not worth caring about.
2025-01-24 13:57:28 -05:00
Tim Wojtulewicz
8c28e47dc1 Merge remote-tracking branch 'origin/topic/timw/rst-linting'
* origin/topic/timw/rst-linting:
  Fix errors from rst linting on the generated docs
2025-01-24 11:42:32 -07:00
Tim Wojtulewicz
c1a8f8b763 Fix errors from rst linting on the generated docs 2025-01-24 11:41:36 -07:00
Evan Typanski
efe1ad2581 Make types into constants
Closes #4173

This allows types to be used in expressions, but they can't be
reassigned. Note that this was meant to be a special "type expression" -
but that is unnecessary complexity.

Type expressions would allow access to the type without going through
its constant value, but the constant value is never changed, so it's
simply a few more checks if necessary when functionality gets expanded.
This way, ZAM and other code will not need updates, so the potential for
increased work in the future is probably not worth caring about.
2025-01-24 11:16:10 -05:00
zeek-bot
fdf887ce3b Update doc submodule [nomail] [skip ci] 2025-01-24 00:14:23 +00:00
Tim Wojtulewicz
cc1fdb4203 Merge remote-tracking branch 'origin/topic/etyp/options-segfault-fix'
* origin/topic/etyp/options-segfault-fix:
  Fix options parsing segfault
2025-01-23 11:49:59 -07:00
Tim Wojtulewicz
ec0b44e5b0 Merge remote-tracking branch 'origin/topic/timw/merge-init-bare-sections'
* origin/topic/timw/merge-init-bare-sections:
  Minor whitespace cleanup in init-bare.zeek
  Add missing export blocks to init-bare.zeek
  Merge some GLOBAL module sections in init-bare
  Merge Tunnel module sections in init-bare
2025-01-23 11:21:38 -07:00
Tim Wojtulewicz
4eef4f4e33 Minor whitespace cleanup in init-bare.zeek 2025-01-23 11:21:08 -07:00
Tim Wojtulewicz
aab8f6575a Add missing export blocks to init-bare.zeek 2025-01-23 11:21:08 -07:00
Tim Wojtulewicz
9b75de4e09 Merge some GLOBAL module sections in init-bare 2025-01-23 11:21:08 -07:00
Tim Wojtulewicz
f6e091452b Merge Tunnel module sections in init-bare 2025-01-23 11:21:08 -07:00
Evan Typanski
30ccee263e Fix options parsing segfault
A command like this would segfault:

zeek -b test.zeek --debug

The issue was that `getopt_long` was using a null element to determine
what the end of the options array is. If it saw a non-null element after
`--debug` it would say it's the argument for optarg, even if it's beyond
`zeek_args.size()`. Instead, just make sure the array is
null-terminated.
2025-01-23 11:41:11 -05:00
Arne Welzel
cb44a6ca53 Merge remote-tracking branch 'origin/topic/awelzel/lookup-connection-zam-follow-up'
* origin/topic/awelzel/lookup-connection-zam-follow-up:
  script_opt: Use emit_builtin_error() for Lookup-Conn
2025-01-23 16:46:43 +01:00
Arne Welzel
3b4b379950 script_opt: Use emit_builtin_error() for Lookup-Conn
Still create a separate baseline file because ZAM doesn't provide
detailed location information.

Patch for ZBI.op provided by @vpax
2025-01-23 09:35:22 +01:00
Tim Wojtulewicz
7e5a9c3a82 Merge remote-tracking branch 'origin/topic/awelzel/lookup-connection-tweaks'
* origin/topic/awelzel/lookup-connection-tweaks:
  session/Manager: Emit explicit errors for FindConnection() with proto=65535
  IPAddr/ConnKey: Protect from uninitialized conn_id
  IPAddr/ConnKey: Promote transport to uint16_t
  session/Manager: Header cleanup
2025-01-21 16:49:09 -07:00
Arne Welzel
92f2f66a60 Merge remote-tracking branch 'origin/topic/vern/standalone-lambdas'
* origin/topic/vern/standalone-lambdas:
  fixes for -O gen-standalone-C++ generation of lambdas
2025-01-20 10:27:46 +01:00
Arne Welzel
17836ef7d9 session/Manager: Emit explicit errors for FindConnection() with proto=65535
We silently broke users constructing conn_id records manually and
subsequently using them with lookup_connection() or connection_exists().

This is an attempt to at least report a runtime error about the situation
so it doesn't go completely unnoticed.
2025-01-17 17:57:49 +01:00
Arne Welzel
ec0a85f553 IPAddr/ConnKey: Protect from uninitialized conn_id
Check if the non-default fields exist using HasField()
and use GetField() for proto such that it'll initialize
the default value which GetFieldAs<> doesn't do.
default
2025-01-17 17:53:02 +01:00
Arne Welzel
1105c8fe7d IPAddr/ConnKey: Promote transport to uint16_t
Instead of a separate bool field which is also stored in the session
table, promote the transport field to uint16_t and encode an invalid
ConnKey as transport 2**16-2
2025-01-17 17:53:02 +01:00
Arne Welzel
33fd324ebb session/Manager: Header cleanup 2025-01-17 17:45:05 +01:00