nodeSolidServer / nodeSolidServer/node-solid-server

Needed fix for corsProxy (server operators must read)

Open
#1,768 8 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
1.8k
Forks
308
PR merge metrics
No merged PRs in 30d

Description

Action required

If you are an NSS server operator, please check that your settings use the default "corsProxy": false.
If you have a public facing server with "corsProxy": true, please change it to "corsProxy": false until the suggested fix below is deployed.

Fix

The CORS proxy needs to be changed as follows:

  • If no Origin field present in the HTTP request, respond with a 400 or similar.
  • If the Origin value in the request is not the server's configured domain (podhost.example) or a direct subdomain thereof (alice.podhost.example), respond with 400 or similar.
  • If, after satistying the above two conditions, the response received from the downstream server does not indicate an RDF content type in its headers (such as Turtle, HTML, etc.), respond with 400.
    • In particular, images, videos, PDFs etc. must result in a 400.
    • The connection to the downstream server can and should be closed prematurely if the content type is not RDF.

Contributor guide

Open the contributing guide

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 by locating the corsProxy implementation and its request-handling tests; the issue names no files or tests. Verify behavior for missing or unauthorized Origin values and for downstream responses without RDF content types. Done means those cases return 400 or similar, while allowed RDF responses continue to work.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, node.js
Domain
api, backend, security
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.