Skip to content

Commit 410a00c

Browse files
authored
Merge pull request hestiacp#1546 from mgkeeley/main
Mitigate XSS attack in Lets Encrypt exchange
2 parents b7848ec + bf20bd8 commit 410a00c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

bin/v-add-letsencrypt-domain

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ for auth in $authz; do
281281
if [ "$WEB_SYSTEM" = 'nginx' ] || [ "$PROXY_SYSTEM" = 'nginx' ]; then
282282
conf="$HOMEDIR/$user/conf/web/$domain/nginx.conf_letsencrypt"
283283
sconf="$HOMEDIR/$user/conf/web/$domain/nginx.ssl.conf_letsencrypt"
284-
echo 'location ~ "^/\.well-known/acme-challenge/(.*)$" {' \
284+
echo 'location ~ "^/\.well-known/acme-challenge/([-_A-Za-z0-9]+)$" {' \
285285
> $conf
286286
echo ' default_type text/plain;' >> $conf
287287
echo ' return 200 "$1.'$THUMB'";' >> $conf

0 commit comments

Comments
 (0)