Summary
Tabbycat's tournament API can allow unauthenticated users to create, modify, or delete tournaments because an authorization check may grant access when a view has no tournament attribute. If the API is reachable, these operations could also trigger deletion of associated teams and speakers.
Affected context
The issue occurs in the TournamentViewSet API when PerTournamentPermissionRequired evaluates a view without a tournament attribute and returns an allow decision. Requests to /api/v1/tournaments may therefore receive write access without the expected authorization check.
Exploit preconditions
- Attack surface: The tournament API endpoint at
/api/v1/tournaments - Required access: No authentication is required, according to the vulnerability description
- Trigger point: A POST, PUT, PATCH, or DELETE request handled by
TournamentViewSet - Why exploitation is possible: The permission check allows access when the view lacks a tournament attribute
Why this happens
The authorization logic treats a missing tournament attribute as sufficient reason to allow access. This is an incorrect authorization decision, mapping to CWE-863: Incorrect Authorization. The underlying insecure pattern is granting a protected operation access when required resource context is absent, rather than denying access or validating the context explicitly.
Potential impact
- Unauthenticated users may create tournaments
- Existing tournaments may be modified or deleted
- Deleting a tournament may also delete associated teams and speakers
- Tournament data and service availability may be disrupted
General mitigation guidance
Defensive patterns focus on making authorization decisions explicit and fail-closed:
- Deny access when required resource or tournament context is missing
- Apply authentication and authorization checks consistently to every write operation
- Derive resource context from trusted server-side data and validate it before permitting changes
- Limit permissions to the minimum actions and resources required
- Use automated tests to verify that unauthenticated and unauthorized requests cannot perform write operations
How teams detect issues like this
- Review permission code for allow decisions based on missing attributes or resource context
- Use static analysis or code review checks to flag permissive defaults in authorization logic
- Add policy tests covering unauthenticated POST, PUT, PATCH, and DELETE requests
- Monitor API logs for unauthenticated write attempts and unexpected tournament deletions
- Enforce centralized authorization policies that require explicit permission for each write action

