Commit graph

2104 commits

Author SHA1 Message Date
marco
eca309ec4c Merge branch 'master' into remove-dashboard 2025-04-29 09:26:28 +02:00
blotus
a79b92f280
make CTI client available in cscli notifications (#3591) 2025-04-28 18:13:53 +02:00
mmetc
5bc2b49387
allowlists: check during bulk decision import (#3588) 2025-04-28 17:11:17 +02:00
mmetc
8689783ade
refact: pkg/exprhelpers/debugger, convert switch to function dispatch (#3587) 2025-04-24 11:27:45 +02:00
mmetc
418a27596e
lint/gocritic: enable importShadow, typeUnparen, unnecessaryDefer (#3583) 2025-04-24 11:12:38 +02:00
mmetc
34e306505c
refact pkg/database: dry decision count (#3586) 2025-04-24 10:25:48 +02:00
mmetc
d46cef1bcb
refact parser Init: argument types (#3578)
* refact parser Init: argument types
* lint
* tests
* rename struct field; drop redundant nil check
2025-04-23 21:30:03 +02:00
mmetc
7c4e91d304
tests: refact localtest helper, use testify.suite (#3574) 2025-04-17 17:35:28 +02:00
mmetc
7396a103d0
refact: logrus.GetLevel() -> logrus.IsLevelEnabled() (#3579) 2025-04-17 17:35:09 +02:00
mmetc
a0fab0ac5a
fix: avoid possible race condition while compiling expressions (#3582) 2025-04-17 17:34:40 +02:00
blotus
4004868245
fix mysql client certificate support (#3575) 2025-04-16 14:39:26 +02:00
mmetc
7e280b23af
fix: error check on postoverflow config (#3576)
* fix error check on postoverflow config

* lint
2025-04-16 13:15:12 +02:00
mmetc
922c29983f
test: add cold log event assert (#3577) 2025-04-16 12:37:50 +02:00
mmetc
620bd0117a
Refact pkg/database/decisions.go (#3541) 2025-04-16 11:53:52 +02:00
mmetc
c17d42278f
replace go-acc, richgo with gotestsum (#3567) 2025-04-14 16:21:32 +02:00
mmetc
89761938c7
pkg/hubtest: use os.CopyFS() (#3539) 2025-04-04 14:54:22 +02:00
mmetc
faa5b482f6
lint/refactor: defer, reflectvaluecompare, stylecheck (#3544)
* lint: enable reflectvaluecompare
* lint: remove exception
* lint: stylecheck ST016 - methods on the same type should have the same receiver name
* lint: enable revive[time-equal]
2025-04-04 14:52:45 +02:00
blotus
48e3c8c5d4
do not return an error if we cannot fetch allowlists when starting the appsec (#3550) 2025-04-04 14:44:18 +02:00
mmetc
49927f79a1
CI: golangci-lint v2 (#3558)
* golangci-lint v2

* CI: reduce parallel jobs for hubtests
2025-04-03 16:57:56 +02:00
mmetc
6c507604b1
hubtests: correct basename check in parser tests (#3557) 2025-04-03 12:56:19 +02:00
AlteredCoder
78a6179566
Support WithUserAgent in cti client (#3542) 2025-03-31 14:44:51 +02:00
marco
eca00377af Merge branch 'master' into remove-dashboard 2025-03-25 15:06:27 +01:00
blotus
d64f196b3f
Allowlists: fix range check in LAPI endpoint (#3538) 2025-03-25 14:30:18 +01:00
mmetc
55aa1893d1
explicit message for malformed data URL in local items (#3537) 2025-03-25 11:53:49 +01:00
mmetc
0d2c2daca5
Migration script from debian/ubuntu package 1.4.6 (#3420) 2025-03-25 11:39:57 +01:00
dependabot[bot]
0106c40a5b
build(deps): bump github.com/golang-jwt/jwt/v4 from 4.5.1 to 4.5.2 (#3531) 2025-03-24 15:34:53 +01:00
mmetc
c245b1e6f8
CI: enable linter "noctx" (#3528)
* CI: enable linter "noctx"

* rename NewRequestWithContext() -> PrepareRequest()
2025-03-24 15:16:40 +01:00
mmetc
a718475422
CI: enable linter "containedctx" (#3529) 2025-03-24 15:15:43 +01:00
mmetc
f735457ca4
revert ActionPlan info/warning to StandardLogger (#3536) 2025-03-24 15:13:24 +01:00
mmetc
9a3f94dc8f
fix #3532 "reload causes crashing process" (#3534) 2025-03-24 15:10:10 +01:00
blotus
2641a6cc07
only warn about capi_whitelists_path being deprecated if actually in use (#3535) 2025-03-24 15:05:53 +01:00
blotus
3843213d5c
use replace for coraza instead of renaming the entire package (#3530) 2025-03-21 14:30:27 +01:00
mmetc
2dcc3ae0df
CI: pin hub branch during functional tests (#3526) 2025-03-20 11:28:37 +01:00
mmetc
ea1a1d733b
empty back-merge from release branch (#3527) 2025-03-20 11:25:57 +01:00
mmetc
0459a9a880
update appsec test runner (#3518) 2025-03-18 11:45:06 +01:00
blotus
663dad048b
close appsec transactions after processing request (#3515) 2025-03-17 11:36:14 +01:00
mmetc
cab99643d1
Parallel hubtest (#3509)
Hubtests are now much faster and have a --max-jobs option which defaults to the number of cpu cores.
2025-03-17 11:27:09 +01:00
blotus
f5400482a6
opensuse sets OSTYPE to linux (#3514) 2025-03-15 13:46:35 +01:00
blotus
cce41a1e6c
do not attempt to set db log level if no db config (#3510) 2025-03-13 17:38:07 +01:00
mmetc
3bc8e4f35f
empty back-merge from release branch (#3506) 2025-03-12 11:01:24 +01:00
blotus
941b3d98b9
appsec: less verbose logging for allowlists and headers check (#3498) 2025-03-12 10:55:06 +01:00
mmetc
c4f9adb799
appsec: use CA from client credentials when connecting to LAPI (#3505) 2025-03-12 10:36:30 +01:00
blotus
50a5ef5345
deprecate capi_whitelists_path (#3504) 2025-03-12 10:12:30 +01:00
mmetc
a432a6352d
appsec: support custom CA for lapi (#3503)
* apisever, appsec: refact listenAndServe..()

* RemoveAll() -> Remove()

* configure CA for tls auth request

* ignore error from os.Remove(socket) when there's no file

* appsec functional test

* lint
2025-03-12 09:33:21 +01:00
Laurence Jones
9bb7ad8c3a
enhancement: Add additional ssl options to db configuration (#3387) 2025-03-11 10:56:47 +01:00
mmetc
388dd62997
use go 1.24.1 (#3501) 2025-03-10 10:50:52 +01:00
Laurence Jones
bcce4afe5e
enhance: Flags now superceed all log levels (#3496)
* enhance: Flags now superceed all log levels

* enhance: remove global var for local scope

* test

---------

Co-authored-by: marco <marco@crowdsec.net>
2025-03-07 13:42:08 +00:00
mmetc
12a3c70860
lint: gocritic/httpNoBody (#3493)
* lint: gocritic/httpNoBody
2025-03-07 14:35:25 +01:00
blotus
a203d8ebbf
appsec: handle SendAlert() properly for out of band matches (#3497) 2025-03-05 16:04:16 +01:00
mmetc
b12ade27f4
cscli: review/update argument number checking (#3490)
* cscsli: remove unused Command.Args setting

* cscli: review/update argument number checking

cscli will consistently print the help text if the number of arguments is
wrong for the command, but not for other types of errors.

* fix func tests

* lint
2025-03-04 12:21:27 +01:00