chore(docs): tighten CSP and remove external widgets#36685
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
There was a problem hiding this comment.
Code Review Agent Run #7062e4
Actionable Suggestions - 1
-
docs/static/.htaccess - 1
- Incomplete CSP for Kapa AI · Line 25-25
Review Details
-
Files reviewed - 1 · Commit Range:
5e7fe33..5e7fe33- docs/static/.htaccess
-
Files skipped - 0
-
Tools
- Whispers (Secret Scanner) - ✔︎ Successful
- Detect-secrets (Secret Scanner) - ✔︎ Successful
Bito Usage Guide
Commands
Type the following command in the pull request comment and save the comment.
-
/review- Manually triggers a full AI review. -
/pause- Pauses automatic reviews on this pull request. -
/resume- Resumes automatic reviews. -
/resolve- Marks all Bito-posted review comments as resolved. -
/abort- Cancels all in-progress reviews.
Refer to the documentation for additional commands.
Configuration
This repository uses Default Agent You can customize the agent settings here or contact your Bito workspace admin at evan@preset.io.
Documentation & Help
5e7fe33 to
f634952
Compare
f634952 to
d1eddc6
Compare
|
Sorry, but the correct way to override the CSP is to provide a list of hostnames using the a variable definition of the form. SetEnv CSP_PROJECT_DOMAINS "host1 host2 host3" as described here: https://infra.apache.org/tools/csp.html As mentioned previously [1], the CSP itself must not be replaced. [1] #35845 (comment) |
d1eddc6 to
b21a0be
Compare
|
@sebbASF Thanks for the guidance! I've updated the .htaccess to use the correct The domains included are:
Let me know if any of these need VP Data Privacy approval or if the format needs adjustment. |
✅ Deploy Preview for superset-docs-preview ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Updates .htaccess to use the ASF-required format for CSP overrides: - Use SetEnv CSP_PROJECT_DOMAINS instead of Header set Content-Security-Policy - Document each required domain with its purpose - Reference ASF CSP documentation Required domains: - widget.kapa.ai: AI chatbot widget - *.googleapis.com, *.google.com, *.gstatic.com: Google Calendar, reCAPTCHA - *.github.com, *.githubusercontent.com: GitHub images in docs - *.algolia.net, *.algolianet.com: Algolia DocSearch Fixes: #35845 Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
b21a0be to
4f9468e
Compare
|
All the CSP exclusions need to be supported by links to a document (webpage or email etc) that provides the permission. For example, kapa.ai and algolia are documented here: https://privacy.apache.org/faq/committers.html Note that there are conditions on how some exceptions can be included. Any other exceptions must have explicit permission from Privacy. |
Fixes the pre-commit trailing-whitespace failure. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
@sebbASF Done - each domain in |
Code Review Agent Run #03f562Actionable Suggestions - 0Additional Suggestions - 2
Review Details
Bito Usage GuideCommands Type the following command in the pull request comment and save the comment.
Refer to the documentation for additional commands. Configuration This repository uses Documentation & Help |
Summary
Tightens the Content-Security-Policy in
.htaccessand removes unused external widgets to address ASF compliance concerns.CSP Changes:
*.run.appdomain fromdefault-srcframe-src *toframe-src 'self' calendar.google.com(only iframe is Google Calendar on community page)README Changes:
next.ossinsight.io)Investigation findings for remaining CSP domains:
*.github.com- Needed for user-attachment images in docs:docs/developer_portal/extensions/architecture.md(2 architecture diagrams)docs/versioned_docs/version-6.0.0/intro.md(video)*.googleapis.com,*.google.com,*.gstatic.com- Kept - Used by kapa.ai reCAPTCHA and Google Calendar embedFixes: #35845
Test Plan
🤖 Generated with Claude Code