This repository has been archived by the owner on Apr 26, 2024. It is now read-only.
Validate data passed to REST api endpoints #13147
Labels
A-Validation
500 (mostly) errors due to lack of event/parameter validation
T-Task
Refactoring, removal, replacement, enabling or disabling functionality, other engineering tasks.
Milestone
Tracking issue for https://github.com/matrix-org/synapse/milestone/9
List files which contain rest endpoints as follows:
As with #12651 (comment), we should concentrate on finding something which provides good error messages first, and good type information second. I think Pydantic is the best choice; I've had a go with it in https://github.com/matrix-org/synapse/commits/dmr/oidc-config-pydantic for validating some of our config. The rest endpoint payloads should be considerably simpler to validate.
To generate todo lists for each individual file, use the following write-only program:
app
federation
http
metrics
rest/admin
rest/client
synapse/rest/client/devices.py
#14052synapse/rest/client/filter.py
#14265synapse/rest/client/keys.py
#14266rest/key
rest/media
rest/synapse/client
rest miscellaneous
The text was updated successfully, but these errors were encountered: