Remove the v1 user routes and keep complete simulation and report results final
I maintainer di solito rispondono entro 3 giorni
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 45/100
Direzione di ricerca
Start by locating the v1 user-profile and user-policy route definitions and the PATCH handlers for simulation and report; the issue gives no file or test names. Read how those handlers authorize requests and determine whether a stored result is complete. Done means the legacy routes are removed and updates to complete results are accepted unchanged when identical or rejected with 409 when they differ; run the relevant API tests.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
The 2026-10-22 security review of the deployed API found two authorization gaps in v1 routes.
- Legacy user routes.
/{country_id}/user-profile(GET, POST, PUT) and/{country_id}/user-policy(GET, POST, PUT) read and change user profiles and saved policies by auser_id,auth0_idor recordidtaken from the request, and check no credential. App v2 does not call them, and #4017 reports no production requests to them in the 30 days to 2026-10-19. Signed-in users' saved work is served by the/v2routes, which take the owner from the verified credential. - Result updates.
PATCH /{country_id}/simulationandPATCH /{country_id}/reporttake no credential and can replace a result that is already complete. These records are shared (identical requests reuse one record), so one caller's update changes what every viewer of that record sees.
Plan:
- Remove the v1 user routes. #4017 removes them too, but it is held for the legacy site's shutdown because of the other routes it removes.
- Make a complete result final: an update that repeats it is accepted and changes nothing, and one that would change it answers 409. Today the browser that ran the calculation writes its result, so there is no compute-worker credential to require; making the server the only writer of results is a follow-up.
- Lingua principale
- Python
- Stelle
- 18
- Fork
- 33
- Merge medio
- 2g 18h
- PR unite (30g)
- 36
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di PolicyEngine/policyengine-api
-
Difficoltà 1/5 1-3 ore Idoneità per principianti 88/100
PolicyEngine/policyengine-api#3911 ·
I maintainer di solito rispondono entro 3 giorni
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 82/100
PolicyEngine/policyengine-api#3910 ·
I maintainer di solito rispondono entro 3 giorni
-
Remove the unauthenticated v2 household listForse già presa @MaxGhenis l’ha presa 2 giorni fa. Aperta
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 20/100
PolicyEngine/policyengine-api#4031 ·
I maintainer di solito rispondono entro 3 giorni
-
Store the metadata v3 reads in the v2 catalog, from PolicyEngine.py's public recordsForse già presa Una pull request collegata a questa issue è aperta o già unita. Aperta
Difficoltà 4/5 3-5 giorni Idoneità per principianti 48/100
PolicyEngine/policyengine-api#4022 ·
I maintainer di solito rispondono entro 3 giorni
-
Publish v2 catalog regions from the Public API's own region reference filesForse già presa Una pull request collegata a questa issue è aperta o già unita. Aperta
Difficoltà 5/5 Più di una settimana Idoneità per principianti 38/100
PolicyEngine/policyengine-api#4019 ·
I maintainer di solito rispondono entro 3 giorni
Tutte le issue di PolicyEngine/policyengine-api
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
UKGovernmentBEIS/optstop#10 ·
-
maintenance
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
pollen-robotics/reachy_mini#1508 ·
I maintainer di solito rispondono entro 1 giorno
-
[BUG] `cloud-keys.env` values retain enclosing quotes causing 401 Unauthorized, and missing utf-8 encoding crashes on WindowsForse già presa @divyanshu07-code l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 77/100
open-jarvis/OpenJarvis#1192 · 1 commento ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
sylvainmetayer/homelab#851 ·
I maintainer di solito rispondono entro 1 giorno