check / check (push) Successful in 17m6s
`smallwebwaf` with no command now prints the commands and exits with status 2. The image runs rproxy, or servewaf with SMALLWEBWAF_COMMAND=servewaf. The passing-on code, its settings and its log fields and metric go. internal/proxy keeps the checks, answers, reports and own endpoints; its tests run through the real rproxy. The documents describe the pair. Judgement call: clients.json keeps token_refused, since state files refuse unknown fields. Deviation: script/gitea-requests sets SWWAF_LOG_REQUEST_HEADERS, to label requests. Model: opus-5-5
21 lines
653 B
Go
21 lines
653 B
Go
// Command smallwebwaf is a web application firewall. `smallwebwaf rproxy` is
|
|
// the reverse proxy in front of one app, which asks servewaf about each request.
|
|
// `smallwebwaf servewaf` decides, for many sites, and keeps what lasts.
|
|
// `smallwebwaf healthcheck` is the container's health check. Everything it does
|
|
// is in internal/smallwebwaf.
|
|
package main
|
|
|
|
import (
|
|
"os"
|
|
|
|
"sneak.berlin/go/smallwebwaf/internal/smallwebwaf"
|
|
)
|
|
|
|
// Version is the version of the binary, set when it is built with
|
|
// -ldflags "-X main.Version=...".
|
|
var Version = "dev" //nolint:gochecknoglobals // the linker sets it
|
|
|
|
func main() {
|
|
os.Exit(smallwebwaf.Main(Version))
|
|
}
|