Skip to content

Public /api/demo can evict real history (no rate limit, unscoped prune) #10

Description

@royalpinto007

Problem

Public, tokenless POST /api/demo writes into the refund-agent suite while the 50-run prune selects newest runs with no suite filter, so anyone can evict real history with demo spam.

Where

app/api/demo/route.ts (public write) + prune in app/api/runs/route.ts / demo/route.ts (no suite scope).

Acceptance

Add a failing test first asserting repeated demo POSTs are throttled (429) or the prune is per-suite. Then fix.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions