microsoft / microsoft/AzureTRE

Validation Missing from API Endpoints

Open
#1,123 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug good first issue
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

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

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.