microsoft / microsoft/AzureTRE
Validation Missing from API Endpoints
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 235
- Forks
- 192
- Avg merge
- 1d 23h
- Merged PRs (30d)
- 13
Description
When calling the various POST endpoints it's possible to post a workspace service template payload to the register workspace template api, and vice versa. Neither call will return an error. Both will register a template that's not useful.
In both cases, the payload sent to these APIs has a resourceType property that could have been used to validate the payload.
Validation could be added, and an error could be returned when inappropriate payloads are posted to these APIs.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Locate the POST endpoints for registering workspace and workspace service templates, then inspect how each handles the payload's resourceType property. Confirm the expected resource types and add validation so mismatched payloads return an error while appropriate payloads continue to register successfully.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure, python
- Domain
- api, backend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100