Copilot commented on code in PR #810: URL: https://github.com/apache/skywalking-website/pull/810#discussion_r2724884940
##########
.htaccess:
##########
@@ -4,7 +4,9 @@ ErrorDocument 404 /404.html
Header always set Content-Security-Policy "default-src 'self' https: data:
'unsafe-inline'; \
frame-src 'self' https://www.youtube.com https://player.bilibili.com
https://hcaptcha.com https://*.hcaptcha.com; \
script-src 'self' 'unsafe-inline' 'unsafe-eval' https://*.algolianet.com
https://*.algolia.net https://*.algolia.io https://api.github.com
https://kapa-widget-proxy-la7dkmplpq-uc.a.run.app https://hcaptcha.com
https://*.hcaptcha.com; \
- connect-src 'self' https://*.algolianet.com https://*.algolia.net
https://*.algolia.io https://api.github.com
https://kapa-widget-proxy-la7dkmplpq-uc.a.run.app; \
+ connect-src 'self' https://*.algolianet.com https://*.algolia.net
https://*.algolia.io https://api.github.com
https://kapa-widget-proxy-la7dkmplpq-uc.a.run.app https://*.hcaptcha.com; \
Review Comment:
In CSP, `https://*.hcaptcha.com` does not match the apex host
`https://hcaptcha.com`. If hCaptcha makes XHR/fetch calls to
`https://hcaptcha.com` (common for verification endpoints), they will still be
blocked. Consider adding `https://hcaptcha.com` explicitly to `connect-src`
alongside the wildcard.
```suggestion
connect-src 'self' https://*.algolianet.com https://*.algolia.net
https://*.algolia.io https://api.github.com
https://kapa-widget-proxy-la7dkmplpq-uc.a.run.app https://hcaptcha.com
https://*.hcaptcha.com; \
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
