docs: complete BE-011 rate-limiter-tier-policies hardening - #808
Open
Hollujay wants to merge 4 commits into
Open
docs: complete BE-011 rate-limiter-tier-policies hardening#808Hollujay wants to merge 4 commits into
Hollujay wants to merge 4 commits into
Conversation
- Add explicit 'untrusted tier header' security assumption (req 10.1) - Add 'Pluggable Store (RateLimitStore)' interface documentation for distributed deployments (reqs 11.2-11.6) - Expand abuse scenarios and failure paths (reqs 10.6-10.7) - Mark spec tracker tasks 7-10 complete (property suite verified, app wiring verified, 100% middleware coverage)
A merge artifact (RevoraOrg#635/RevoraOrg#642) left two identical 'const amlAuditRepo = new InMemorySecurityAuditRepository()' declarations in createApp, breaking module load (SyntaxError) and failing tsc (TS2451). Removes the second declaration.
Includes compiled scripts/reconcile-replay.js artifact and lockfile entries for @open-draft/* (msw dev deps).
…site-strict-optin # Conflicts: # package-lock.json
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #684
Summary
Completes the Rate Limiter Tier Policies (BE-011) capability for the Revora backend: the core middleware, unit tests, property-based tests, and application wiring were completed in prior work; this PR finalises the security documentation, marks the implementation-plan tracker complete, and includes supporting artifacts.
What's in this PR
1. Hardened security documentation —
docs/rate-limiter-tier-policies.mdx-revora-rate-tieris treated as untrusted client input; elevation totrusted/internalalways requires a matching shared secret (Requirement 10.1).RateLimitStore)" section: documents theRateLimitStoreinterface contract (increment/reset/clear?), the semantics the fixed-window middleware relies on (deterministicresetAt), and implementor guidance for distributed deployments (RedisINCR/EXPIRE, failure-mode guidance) — Requirements 11.2–11.6.2. Implementation plan tracker —
.kiro/specs/rate-limiter-tier-policies/tasks.mdMarks tasks 7–10 complete, all verified:
rateLimitStore,resolveTier,rateLimitMiddleware.createStartupAuthTierLimitermounted onPOST /api/v1/startup/register,app.set('trust proxy', 1)present,/healthregistered outside the rate-limited router with an integration test proving isolation.Verification
npm run test:coverage:backend-011rateLimit.tscoveragestartupAuthRateTierPolicy.tscoverageSecurity notes
STARTUP_AUTH_TIER_SECRET; missing/invalid secrets fail safe to thestandardtier without revealing whether a secret exists (no oracle).x-revora-rate-tieris never trusted without a matching secret.Related
.kiro/specs/rate-limiter-tier-policies/(requirements.md, design.md, tasks.md)docs/rate-limiter-tier-policies.mddocs/startup-auth-brute-force-mitigation.md,docs/startup-auth-service.md