diff --git a/docs/docs/CHANGELOG.md b/docs/docs/CHANGELOG.md index 5dcb7bfb..cb77fad2 100644 --- a/docs/docs/CHANGELOG.md +++ b/docs/docs/CHANGELOG.md @@ -32,6 +32,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Gate pprof endpoints behind `metrics.debug` in the policy file. - Limit naive honeypot r9k delay to one second. - Fix an obscure case where adding query values to a subrequest match could cause an invalid rule match when using path based matching for protected resources. +- Fix an edge case where load average expression values could nil pointer dereference when Anubis just started up. - Fix `path_regex` and CEL `path` rules not matching when using Traefik `forwardAuth` middleware. Anubis now checks `X-Forwarded-Uri` (Traefik) in addition to `X-Original-URI` (nginx) when resolving the request path in subrequest mode ([#1628](https://github.com/TecharoHQ/anubis/issues/1628)). ## v1.25.0: Necron diff --git a/lib/policy/expressions/loadavg.go b/lib/policy/expressions/loadavg.go index cfbb2ae3..a459a185 100644 --- a/lib/policy/expressions/loadavg.go +++ b/lib/policy/expressions/loadavg.go @@ -46,7 +46,7 @@ var ( ) func init() { - globalLoadAvg = &loadAvg{} + globalLoadAvg = &loadAvg{data: &load.AvgStat{}} go globalLoadAvg.updateThread(context.Background()) }