Detection is CAPI community blocklists plus AppSec inline WAF, not Envoy
access-log parsing. Enforcement is gRPC ext_authz from Envoy Gateway.
Changes from the draft that was held:
Agent disabled rather than given an empty acquisition list. Chart 0.24.0
refuses to render the DaemonSet with acquisition: [] ("No acquisition or
additionalAcquisition configured"), and with no log tailing the agent has
nothing to do. The WAF collections moved to appsec.env, where they belong,
and base-http-scenarios was dropped since it only feeds log parsing. AppSec
registers with LAPI on its own, so it works without the agent.
Bouncer values updated for chart 0.8.0 (the app already pinned 0.8.0 while the
values were written against 0.6.3). Added waf.failOpen: true, whose chart
default is false and would deny every request if AppSec were unreachable.
SecurityPolicy now targets the whole gateway-public rather than the it-tools
listener. EG v1.3.2 rejects targetRefs.sectionName on SecurityPolicy, and
targeting the HTTPRoute instead would gate LAN traffic too since public routes
also parent gateway-internal. Blanket coverage of the public gateway is what we
want anyway, and failOpen keeps a bouncer outage from taking public apps down.
envoyproxy-public.yaml is kept as documentation but not applied. EG v1.3.2
already defaults envoyService.externalTrafficPolicy to Local, verified live on
all three gateway LB services, so the real client IP already reaches Envoy.
Not wired into the envoy-gateway kustomization yet. That lands once the
bouncer is up and healthy.
49 lines
1.6 KiB
YAML
49 lines
1.6 KiB
YAML
# CrowdSec Envoy bouncer, chart ghcr.io/kdwils/charts/envoy-proxy-bouncer 0.8.0
|
|
# gRPC ext_authz service that Envoy Gateway calls for every request on protected
|
|
# listeners. Checks the client IP against LAPI decisions and (WAF) forwards the
|
|
# request to CrowdSec AppSec for inline inspection.
|
|
#
|
|
# NOTE: this is a community project ("not tested in production, use at your own
|
|
# risk"). It is used behind failOpen: true (see the SecurityPolicy), so a bouncer
|
|
# outage lets traffic through rather than blocking your services.
|
|
|
|
# Fixed name so the SecurityPolicy backendRef / ReferenceGrant can target it.
|
|
fullnameOverride: crowdsec-envoy-bouncer
|
|
|
|
service:
|
|
type: ClusterIP
|
|
grpcPort: 8080
|
|
httpPort: 8081
|
|
|
|
config:
|
|
server:
|
|
grpcPort: 8080
|
|
httpPort: 8081
|
|
logLevel: "info"
|
|
|
|
# Envoy (public proxy) is the immediate hop and, with externalTrafficPolicy:
|
|
# Local on the LB service, presents the real client IP. If you later put another
|
|
# proxy in front (e.g. Cloudflare), set trustedProxies / trustedIPHeader so the
|
|
# bouncer reads the true client IP from X-Forwarded-For instead of banning the
|
|
# proxy.
|
|
trustedProxies: []
|
|
exemptIPs: []
|
|
|
|
# IP-decision enforcement against LAPI (same namespace).
|
|
bouncer:
|
|
enabled: true
|
|
lapiURL: "http://crowdsec-service:8080"
|
|
apiKeySecretRef:
|
|
name: crowdsec-secrets
|
|
key: bouncer-key
|
|
|
|
# WAF / AppSec inline inspection (same namespace).
|
|
waf:
|
|
enabled: true
|
|
appSecURL: "http://crowdsec-appsec-service:7422"
|
|
apiKeySecretRef:
|
|
name: crowdsec-secrets
|
|
key: bouncer-key
|
|
# Chart default is false, which would deny every request if AppSec is down.
|
|
failOpen: true
|