freedomofpress / freedomofpress/webcat-docs

document CSP explicitly

Open
#38 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
2
Forks
2
Avg merge
19h 27m
Merged PRs (30d)
1

Description

The existing CSP docs list the specific attributes that should be included, which is a good overview of what's necessary. However, for someone setting up the integration, there's still a lot of work required to port that to their specific config. Let's offer some quick config snippets for common platforms:

  • nginx
  • traefik, via middleware
  • caddy
  • cloudflare

It's also worth noting that given the requirement for CSP to be served via headers, popular static-site hosting like Github Pages cannot work, because GHP does not allow header configuration AFAIK. If a site-operator fronts a GHP site with e.g. Cloudflare, or some other reverse proxy within their control, then CSP headers are configurable, and the website should be validated.

Related but separate is the ask for CSP-check-in-code.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the existing CSP docs linked in the issue and review how the listed attributes map to configuration on nginx, Traefik middleware, Caddy, and Cloudflare. Add concise snippets for those platforms and document the GitHub Pages header limitation, including the reverse-proxy case; the work is done when an integration operator can configure and validate CSP from the documentation.

Written by the indexing model from the issue text.

Assessment

Tech stack
nginx
Domain
documentation
Issue type
Documentation
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.