From 32a673d8f4ec49530f424848474641c1af025e0c Mon Sep 17 00:00:00 2001 From: Yury Kossakovsky Date: Sat, 28 Jun 2025 16:03:58 -0600 Subject: [PATCH] Update SearXNG configuration in Caddyfile - Implemented IP-based access control for basic authentication in the SearXNG section. - Enhanced security by restricting access to specific IP ranges while maintaining authentication for other users. --- Caddyfile | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Caddyfile b/Caddyfile index 31414e7..db797bb 100644 --- a/Caddyfile +++ b/Caddyfile @@ -77,7 +77,9 @@ import /etc/caddy/addons/*.conf # # SearXNG {$SEARXNG_HOSTNAME} { - basic_auth { + @protected not remote_ip 127.0.0.0/8 10.0.0.0/8 172.16.0.0/12 192.168.0.0/16 100.64.0.0/10 + + basic_auth @protected { {$SEARXNG_USERNAME} {$SEARXNG_PASSWORD_HASH} }