Skip to content

fix(pg-pkg): add rate limiting to /v2 API endpoints #224

Description

@dobby-coder

Hardening work on the pg-pkg API surface.

Task

pg-pkg has no rate-limiting middleware. Add per-IP rate limiting (e.g. via actix-governor) to the /v2 scope in pg-pkg/src/server.rs, with tighter limits on the /start, /key, and /api-key/validate endpoints.

  • add actix-governor (or equivalent) rate-limiting middleware to the pg-pkg /v2 route scope in pg-pkg/src/server.rs
  • apply stricter per-IP limits to POST /start, GET /key, GET /key/{timestamp}, and GET /api-key/validate
  • expose the rate limit via Cargo.toml feature or dependency
  • add integration tests that verify 429 responses after the limit is exceeded

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestsecuritySecurity-related issue (vulnerability, hardening, or risk)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions