Summary
The batch update API in Tandoor Recipes allowed any authenticated user within a Space to modify any recipe in that Space, including those marked as private by other users.
Because object-level authorization checks were not enforced on the batch endpoint, users could expose private recipes, grant themselves access, and tamper with metadata they did not own.
Affected context
This vulnerability occurs in Tandoor Recipes deployments where multiple users share a Space and rely on per-recipe privacy controls.
The issue is specific to the PUT /api/recipe/batch_update/ endpoint, which processes updates for multiple recipes at once but previously did not apply the same object-level permission checks as the single-recipe endpoint (PUT /api/recipe/{id}/).
Any authenticated user in the Space could submit recipe identifiers they do not own or should not see, and the system would accept and apply changes regardless of the recipes' private status or sharing configuration.
Exploit preconditions
- Attack surface: HTTP API for Tandoor Recipes, specifically
PUT /api/recipe/batch_update/ - Required access: Valid authenticated user account within the same Space as the target recipes
- Trigger point: Sending a batch update request that includes IDs of recipes owned by other users, including those marked as private
- Why exploitation is possible: The batch update endpoint did not perform per-object authorization checks and implicitly trusted that any recipe IDs submitted by an authenticated user were authorized, bypassing the stricter object-level controls enforced on single-recipe update endpoints
Why this happens
The core issue is a missing or inconsistent object-level authorization check on a bulk operation endpoint.
While single-object endpoints enforced ownership or explicit sharing rules before allowing a recipe to be updated, the batch endpoint assumed that all recipe IDs in the request were valid for the caller and did not re-verify access on each resource.
This aligns with CWE-639: Authorization Bypass Through User-Controlled Key, where clients can directly reference internal object identifiers and the server fails to confirm that the caller is authorized to act on those objects.
The abstract pattern is: a multi-object or convenience API path reuses internal identifiers but omits the per-object permission enforcement present in the canonical, fine-grained endpoints.
Potential impact
- Unauthorized modification of private recipes owned by other users in the same Space
- Forced exposure of private recipes by changing visibility or sharing settings
- Unauthorized self-grant of access via manipulation of shared lists or collaborator metadata
- Tampering with recipe metadata (titles, tags, notes, meal plans) to disrupt or poison other users' data
- Loss of trust in privacy boundaries within shared Spaces and potential leakage of sensitive personal or dietary information
General mitigation guidance
Mitigation focuses on enforcing consistent, centralized authorization checks across all endpoints that reference shared objects:
- Apply the same object-level permission logic to batch and helper endpoints that is used for single-object operations, ensuring every recipe ID is checked against the caller's rights.
- Centralize access control in reusable service or policy layers instead of duplicating logic in each handler, reducing the chance that a new endpoint omits checks.
- Favor server-side derivation of accessible object IDs (e.g., querying allowed recipes for a user) over trusting arbitrary IDs supplied in the request body.
- Implement privacy and ownership models that clearly distinguish between Space membership and per-object access, avoiding assumptions that "same Space" implies "full access."
- Use least-privilege defaults for new endpoints, denying access by default and requiring explicit authorization checks before performing modifications.
How teams detect issues like this
To detect similar authorization issues, teams can:
- Use static analysis or custom linters to flag endpoints that directly accept object IDs from clients without invoking shared authorization helpers or policies.
- Perform targeted code reviews of bulk or batch APIs, verifying that they call the same per-object access control routines as single-object endpoints.
- Introduce automated tests that attempt cross-user access for each API route, including batch operations, using separate user accounts and private objects.
- Employ application-level logging and monitoring that records which user updates which object, then periodically review for anomalies such as frequent cross-owner modifications.
- Integrate security testing tools (DAST / API fuzzers) configured to probe IDOR scenarios by replaying the same request with different object IDs.

