mirror of
https://github.com/makeplane/plane.git
synced 2026-06-14 03:30:00 +00:00
fix: add WEBHOOK_ALLOWED_HOSTS allowlist for internal webhook targets (#9078)
* fix: add WEBHOOK_ALLOWED_HOSTS allowlist for internal webhook targets The IP-based allowlist alone isn't practical for containerised deployments where service IPs are dynamic. Adds a hostname-based bypass for trusted internal services (e.g. Silo via docker-compose / k8s service DNS) and makes the previously hardcoded ["plane.so"] domain blocklist configurable via WEBHOOK_DISALLOWED_DOMAINS. - validate_url accepts allowed_hosts (exact, case-insensitive match; skips DNS lookup for trusted names) - WebhookSerializer wires both settings through and lets allowlisted hosts bypass the disallowed-domain check - Exposes WEBHOOK_ALLOWED_HOSTS in aio/cli deployment env files * fix: default WEBHOOK_DISALLOWED_DOMAINS to empty for self-hosted * fix: pass WEBHOOK_ALLOWED_HOSTS to send-time webhook re-validation
This commit is contained in:
committed by
GitHub
parent
32fb88ab24
commit
761c999e0c
@@ -51,3 +51,12 @@ API_KEY_RATE_LIMIT=60/minute
|
||||
|
||||
# Live Server Secret Key
|
||||
LIVE_SERVER_SECRET_KEY=htbqvBJAgpm9bzvf3r4urJer0ENReatceh
|
||||
|
||||
# Webhook IP allowlist — comma-separated IPs or CIDR ranges allowed as webhook targets
|
||||
# even if they resolve to private networks (e.g. "10.0.0.0/8,192.168.1.0/24,172.16.0.5")
|
||||
WEBHOOK_ALLOWED_IPS=
|
||||
|
||||
# Webhook hostname allowlist — comma-separated hostnames that bypass the private-IP
|
||||
# SSRF check. Useful for trusted internal services whose container/service IPs are
|
||||
# dynamic (e.g. "silo,silo.namespace.svc.cluster.local")
|
||||
WEBHOOK_ALLOWED_HOSTS=
|
||||
|
||||
@@ -58,6 +58,8 @@ x-app-env: &app-env
|
||||
API_KEY_RATE_LIMIT: ${API_KEY_RATE_LIMIT:-60/minute}
|
||||
MINIO_ENDPOINT_SSL: ${MINIO_ENDPOINT_SSL:-0}
|
||||
LIVE_SERVER_SECRET_KEY: ${LIVE_SERVER_SECRET_KEY:-2FiJk1U2aiVPEQtzLehYGlTSnTnrs7LW}
|
||||
WEBHOOK_ALLOWED_IPS: ${WEBHOOK_ALLOWED_IPS:-}
|
||||
WEBHOOK_ALLOWED_HOSTS: ${WEBHOOK_ALLOWED_HOSTS:-}
|
||||
|
||||
services:
|
||||
web:
|
||||
|
||||
@@ -80,3 +80,12 @@ API_KEY_RATE_LIMIT=60/minute
|
||||
# Live server environment variables
|
||||
# WARNING: You must set a secure value for LIVE_SERVER_SECRET_KEY in production environments.
|
||||
LIVE_SERVER_SECRET_KEY=
|
||||
|
||||
# Webhook IP allowlist — comma-separated IPs or CIDR ranges allowed as webhook targets
|
||||
# even if they resolve to private networks (e.g. "10.0.0.0/8,192.168.1.0/24,172.16.0.5")
|
||||
WEBHOOK_ALLOWED_IPS=
|
||||
|
||||
# Webhook hostname allowlist — comma-separated hostnames that bypass the private-IP
|
||||
# SSRF check. Useful for trusted internal services whose container/service IPs are
|
||||
# dynamic (e.g. "silo,silo.namespace.svc.cluster.local")
|
||||
WEBHOOK_ALLOWED_HOSTS=
|
||||
|
||||
Reference in New Issue
Block a user