Commit Graph

17 Commits

Author SHA1 Message Date
Vincent Bernat
1ec89aac1f build: fix various lint issues
revive default configuration has changed in 1.3.0. Some stuff is a bit
silly (like empty blocks), but I find it easier to follow that than to
try to tweak the configuration.
2023-03-21 00:01:13 +01:00
Vincent Bernat
050d8115bb inlet/core: accept unknown interfaces
If SNMP polling succeeds but the interface does not exist, accept the
interface.
2023-02-14 12:20:41 +01:00
Vincent Bernat
86b31d2a29 inlet/snmp: implement negative caching for SNMP poller 2023-02-14 09:42:56 +01:00
Vincent Bernat
a912da7fa1 build: use gofumpt
Undecided if we need to use it. I think it's nice.
2023-02-11 10:03:45 +01:00
Vincent Bernat
61bcfa53b4 inlet/core: convert classifier cache to internal cache helper
This also reduce the amount of `time.Now()` to one per flow. Far lower
than it previously was. `time.Now()` should usually be quick, but on
some VM, it can be slow (100 times) due to a missing or dysfunctional
TSC.

We also modify the SNMP component to not rely on clock either (it must be
externally provided). Internally, it can still use the system clock (not
on the hot path).
2023-02-01 09:11:11 +01:00
Vincent Bernat
577e27f7d4 inlet/snmp: move cache to helpers
We will reuse this implementation for classifiers too.
2023-02-01 09:11:11 +01:00
Vincent Bernat
68433c0a51 inlet/snmp: fix race condition introduced in tests in latest commit 2022-09-24 20:34:45 +02:00
Vincent Bernat
af58717da6 inlet/snmp: add inlet.snmp.agents to override exporter IP address 2022-09-24 20:27:48 +02:00
Vincent Bernat
6bfd3a0bd0 inlet/snmp: use netip.Addr internally instead of string
Also, make SubnetMap use `netip.Addr` as well.
2022-08-27 08:13:57 +02:00
Vincent Bernat
0a4275d87d inlet/snmp: add ability to set a version for SNMP
This is mostly useless as we don't provide a way to specify SNMPv3
authentication. We won't keep this config option as is.
2022-08-14 00:57:33 +02:00
Vincent Bernat
3f1dc38052 Revert "inlet/snmp: do not deprecate default-community"
This reverts commit e5d3d3fbc3. When
adding SNMPv3, it will be odd to have this. Just put the extra mile to
deprecate it correctly.
2022-08-13 21:33:53 +02:00
Vincent Bernat
e5d3d3fbc3 inlet/snmp: do not deprecate default-community
We did not handle all cases, notably the case where default-community
was not set explicitely by the user. This seems a lot of code for
little gain, let's keep things simple.
2022-08-01 07:15:50 +02:00
Vincent Bernat
1bbaf4de24 inlet/snmp: accept subnets for communities
Also deprecate `default-community`.
2022-07-31 23:38:54 +02:00
Vincent Bernat
8be1bca4fd license: AGPL-3.0-only
```
git ls-files \*.js \*.go \
  | xargs sed -i '1i // SPDX-FileCopyrightText: 2022 Free Mobile\n// SPDX-License-Identifier: AGPL-3.0-only\n'
git ls-files \*.vue \
  | xargs sed -i '1i <!-- SPDX-FileCopyrightText: 2022 Free Mobile -->\n<!-- SPDX-License-Identifier: AGPL-3.0-only -->\n'
```
2022-06-29 11:42:28 +02:00
Vincent Bernat
ce9bd6a4da tests: add an helper to start/stop components 2022-04-13 17:02:14 +02:00
Vincent Bernat
93da599adf cmd: take configuration as a mandatory argument (+ other changes)
The other changes are:
 - rename configure service to orchestrator service
 - turn DefaultConfiguration variables into functions
2022-04-10 15:14:39 +02:00
Vincent Bernat
1dc253764d global: split Akvorado into 3 services 2022-04-01 20:21:53 +02:00