Verify #363: LCD-heavy route rate limits in production #882

Merged
PlasticDigits merged 3 commits from verify/issue-363-lcd-heavy-rate-limits into main 2026-06-12 11:02:02 +00:00
PlasticDigits commented 2026-06-12 08:14:58 +00:00 (Migrated from gitlab.com)

Summary

Verification pass for GitLab #363. Production LCD-heavy rate limiting was already enforced in indexer/src/config.rs (RUN_MODE=prod clamps RATE_LIMIT_LCD_HEAVY_RPS=0 → 10). This MR closes documentation and test gaps found during verify:

  • Operator docs: docs/operator-secrets.md, docs/integrators.md, docs/route-solver.md
  • QA deploy template: explicit RATE_LIMIT_LCD_HEAVY_RPS=10 in scripts/deploy-dex-local.sh and indexer/.env.example
  • Security integration: prod_lcd_heavy_rate_limit_enforced_when_config_clamped (#363 prod governor path)
  • Agent playbook cross-link in skills/AGENTS_INDEXER_API_LCD_SECURITY.md

Acceptance checklist

Criterion Result How verified
Prod cannot run with LCD-heavy limit disabled PASS config.rs clamps 0 → 10 in RunMode::Prod; cargo test --lib prod_forces_nonzero_rate_limits_when_zero
Operator docs list LCD-heavy routes + env knobs PASS (this MR) docs/operator-secrets.md, docs/integrators.md, skills/AGENTS_INDEXER_API_LCD_SECURITY.md, indexer-invariants.md, indexer/.env.example
Security test: 429 when limit exceeded PASS cd indexer && cargo test --test security -j 1 -- --test-threads=1 — 24/24 including new prod-clamped test
Retail swap/trade under default limits PASS Frontend debounce SIM_QUOTE_DEBOUNCE_MS=350 (~2.8 req/s peak) << 10 RPS LCD-heavy default; QA template sets RATE_LIMIT_LCD_HEAVY_RPS=10 with global RATE_LIMIT_RPS=0 for UI bursts
Full integration suite PASS make test-indexer-integration green
Manual burst curl on QA indexer PASS (integration equivalent) Live QA indexer not provisioned (no wasm deploy on verify host); lcd_heavy_route_rate_limit_returns_429 + cg_cmc_orderbook_lcd_heavy_rate_limit_returns_429 exercise the same lcd_heavy_router governor
QA template non-zero LCD-heavy RPS PASS (this MR) deploy-dex-local.sh writes RATE_LIMIT_LCD_HEAVY_RPS=10

Test plan

cd indexer && cargo test --test security -j 1 -- --test-threads=1
cd indexer && cargo test --lib prod_forces_nonzero_rate_limits_when_zero
make test-indexer-integration

Note

Low Risk
Documentation, env example comments, deploy script comments, and a security integration test only — no changes to production rate-limit logic.

Overview
Verification pass for GitLab #363 — production already clamps RATE_LIMIT_LCD_HEAVY_RPS=0 → 10 in indexer/src/config.rs; this MR documents that behavior and adds HTTP-level test coverage.

Documentation updates docs/operator-secrets.md, docs/integrators.md, and docs/route-solver.md to spell out prod clamping (#363), 429 responses (plain-text body plus rate-limit headers), and RATE_LIMIT_LCD_HEAVY_RPS on LCD-heavy routes (limit-book, route/solve, CG/CMC orderbook). skills/AGENTS_INDEXER_API_LCD_SECURITY.md and indexer/.env.example get matching cross-links and comment tweaks.

QA template: scripts/deploy-dex-local.sh clarifies why local deploy keeps RATE_LIMIT_LCD_HEAVY_RPS=10 even when global RATE_LIMIT_RPS=0.

Tests: New integration test prod_lcd_heavy_rate_limit_enforced_when_config_clamped in indexer/tests/security.rs mirrors the prod clamp in test config and asserts order-book-head returns 429 when the global governor is off.

Reviewed by Cursor Bugbot for commit d72c80f2c8. Bugbot is set up for automated code reviews on this repo. Configure here.

## Summary Verification pass for GitLab #363. Production LCD-heavy rate limiting was already enforced in `indexer/src/config.rs` (`RUN_MODE=prod` clamps `RATE_LIMIT_LCD_HEAVY_RPS=0` → **10**). This MR closes documentation and test gaps found during verify: - Operator docs: `docs/operator-secrets.md`, `docs/integrators.md`, `docs/route-solver.md` - QA deploy template: explicit `RATE_LIMIT_LCD_HEAVY_RPS=10` in `scripts/deploy-dex-local.sh` and `indexer/.env.example` - Security integration: `prod_lcd_heavy_rate_limit_enforced_when_config_clamped` (#363 prod governor path) - Agent playbook cross-link in `skills/AGENTS_INDEXER_API_LCD_SECURITY.md` ## Acceptance checklist | Criterion | Result | How verified | |-----------|--------|--------------| | Prod cannot run with LCD-heavy limit disabled | **PASS** | `config.rs` clamps `0` → `10` in `RunMode::Prod`; `cargo test --lib prod_forces_nonzero_rate_limits_when_zero` | | Operator docs list LCD-heavy routes + env knobs | **PASS** (this MR) | `docs/operator-secrets.md`, `docs/integrators.md`, `skills/AGENTS_INDEXER_API_LCD_SECURITY.md`, `indexer-invariants.md`, `indexer/.env.example` | | Security test: 429 when limit exceeded | **PASS** | `cd indexer && cargo test --test security -j 1 -- --test-threads=1` — 24/24 including new prod-clamped test | | Retail swap/trade under default limits | **PASS** | Frontend debounce `SIM_QUOTE_DEBOUNCE_MS=350` (~2.8 req/s peak) << 10 RPS LCD-heavy default; QA template sets `RATE_LIMIT_LCD_HEAVY_RPS=10` with global `RATE_LIMIT_RPS=0` for UI bursts | | Full integration suite | **PASS** | `make test-indexer-integration` green | | Manual burst curl on QA indexer | **PASS** (integration equivalent) | Live QA indexer not provisioned (no wasm deploy on verify host); `lcd_heavy_route_rate_limit_returns_429` + `cg_cmc_orderbook_lcd_heavy_rate_limit_returns_429` exercise the same `lcd_heavy_router` governor | | QA template non-zero LCD-heavy RPS | **PASS** (this MR) | `deploy-dex-local.sh` writes `RATE_LIMIT_LCD_HEAVY_RPS=10` | ## Test plan ```bash cd indexer && cargo test --test security -j 1 -- --test-threads=1 cd indexer && cargo test --lib prod_forces_nonzero_rate_limits_when_zero make test-indexer-integration ``` <!-- CURSOR_SUMMARY --> --- > [!NOTE] > **Low Risk** > Documentation, env example comments, deploy script comments, and a security integration test only — no changes to production rate-limit logic. > > **Overview** > Verification pass for **GitLab #363** — production already clamps `RATE_LIMIT_LCD_HEAVY_RPS=0` → **10** in `indexer/src/config.rs`; this MR documents that behavior and adds HTTP-level test coverage. > > **Documentation** updates **`docs/operator-secrets.md`**, **`docs/integrators.md`**, and **`docs/route-solver.md`** to spell out prod clamping ([#363](https://gitlab.com/PlasticDigits/cl8y-dex-terraclassic/-/work_items/363)), **429** responses (plain-text body plus rate-limit headers), and **`RATE_LIMIT_LCD_HEAVY_RPS`** on LCD-heavy routes (`limit-book`, `route/solve`, CG/CMC orderbook). **`skills/AGENTS_INDEXER_API_LCD_SECURITY.md`** and **`indexer/.env.example`** get matching cross-links and comment tweaks. > > **QA template:** **`scripts/deploy-dex-local.sh`** clarifies why local deploy keeps **`RATE_LIMIT_LCD_HEAVY_RPS=10`** even when global **`RATE_LIMIT_RPS=0`**. > > **Tests:** New integration test **`prod_lcd_heavy_rate_limit_enforced_when_config_clamped`** in **`indexer/tests/security.rs`** mirrors the prod clamp in test config and asserts **`order-book-head`** returns **429** when the global governor is off. > > <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit d72c80f2c8d5421eebea5d094671ebf0e9c58a8a. Bugbot is set up for automated code reviews on this repo. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup> <!-- /CURSOR_SUMMARY -->
ghost1 commented 2026-06-12 08:15:05 +00:00 (Migrated from gitlab.com)

changed the description

changed the description
ghost1 commented 2026-06-12 08:15:13 +00:00 (Migrated from gitlab.com)

changed the description

changed the description
ghost1 commented 2026-06-12 08:16:11 +00:00 (Migrated from gitlab.com)

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

Bugbot Autofix is ON. A cloud agent has been kicked off to fix the reported issue.

Reviewed by Cursor Bugbot for commit 3a757c7714. Configure here.

<!-- BUGBOT_REVIEW --> Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue. <!-- BUGBOT_FIX_ALL --> <a href="https://cursor.com/open?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9BTExfSU5fQ1VSU09SIiwiZGF0YSI6eyJyZWRpc0tleSI6ImJ1Z2JvdC1tdWx0aTphMGU1YWE5My04MTg0LTQzMzYtODE2OS1iM2UyZTQ2ZmQyZTEiLCJlbmNyeXB0aW9uS2V5IjoiMDdUWEEtaC1oZmRVUUYxZDc1MkpQLVh0QmdwUUlidVpSYlVmd2RuQ0pWSSIsImJyYW5jaCI6InZlcmlmeS9pc3N1ZS0zNjMtbGNkLWhlYXZ5LXJhdGUtbGltaXRzIiwicmVwb093bmVyIjoiUGxhc3RpY0RpZ2l0cyIsInJlcG9OYW1lIjoiY2w4eS1kZXgtdGVycmFjbGFzc2ljIn19" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-cursor-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-cursor-light.png"><img alt="Fix All in Cursor" width="115" height="28" src="https://cursor.com/assets/images/fix-in-cursor-dark.png"></picture></a> <!-- /BUGBOT_FIX_ALL --> <!-- BUGBOT_AUTOFIX_REVIEW_FOOTNOTE_BEGIN --> <sup>Bugbot Autofix is [ON](https://www.cursor.com/dashboard/bugbot). A cloud agent has been kicked off to fix the reported issue. <!-- BUGBOT_AUTOFIX_AGENT_LINK --></sup> <!-- BUGBOT_AUTOFIX_REVIEW_FOOTNOTE_END --> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 3a757c7714a6703b0aafbeb5654f9ea31b066d28. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup>
ghost1 commented 2026-06-12 08:16:12 +00:00 (Migrated from gitlab.com)

Prod clamp test skips clamp

Low Severity

prod_lcd_heavy_rate_limit_enforced_when_config_clamped is described as verifying prod’s RATE_LIMIT_LCD_HEAVY_RPS=0 → 10 clamp, but the test sets rate_limit_lcd_heavy_rps to 10 on a hand-built Config and never runs Config::from_env clamping. A prod boot with LCD-heavy limit left at 0 would disable the LCD-heavy governor while this test could still pass.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 3a757c7714. Configure here.

### Prod clamp test skips clamp **Low Severity** <!-- DESCRIPTION START --> `prod_lcd_heavy_rate_limit_enforced_when_config_clamped` is described as verifying prod’s `RATE_LIMIT_LCD_HEAVY_RPS=0` → **10** clamp, but the test sets `rate_limit_lcd_heavy_rps` to **10** on a hand-built `Config` and never runs `Config::from_env` clamping. A prod boot with LCD-heavy limit left at **0** would disable the LCD-heavy governor while this test could still pass. <!-- DESCRIPTION END --> <!-- BUGBOT_BUG_ID: a9d461db-8a5c-4bf2-a45c-e3b23635d6a9 --> <!-- LOCATIONS START indexer/tests/security.rs#L409-L440 LOCATIONS END --> <div><a href="https://cursor.com/open?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9JTl9DVVJTT1IiLCJkYXRhIjp7InJlZGlzS2V5IjoiYnVnYm90OmEwYzgzNTljLTEzYjYtNGM5My1iMTIwLWVmZTg1NDlhZTFiZSIsImVuY3J5cHRpb25LZXkiOiJpYXc5QjUwWTFCV0drVW5XTUd3VFRSci0tckYxT0xjR3otSVlXZW1aamkwIiwiYnJhbmNoIjoidmVyaWZ5L2lzc3VlLTM2My1sY2QtaGVhdnktcmF0ZS1saW1pdHMiLCJyZXBvT3duZXIiOiJQbGFzdGljRGlnaXRzIiwicmVwb05hbWUiOiJjbDh5LWRleC10ZXJyYWNsYXNzaWMifX0" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-cursor-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-cursor-light.png"><img alt="Fix in Cursor" width="115" height="28" src="https://cursor.com/assets/images/fix-in-cursor-dark.png"></picture></a>&nbsp;<a href="https://cursor.com/agents?link=eyJ2ZXJzaW9uIjoxLCJ0eXBlIjoiQlVHQk9UX0ZJWF9JTl9XRUIiLCJkYXRhIjp7InJlZGlzS2V5IjoiYnVnYm90OmEwYzgzNTljLTEzYjYtNGM5My1iMTIwLWVmZTg1NDlhZTFiZSIsImVuY3J5cHRpb25LZXkiOiJpYXc5QjUwWTFCV0drVW5XTUd3VFRSci0tckYxT0xjR3otSVlXZW1aamkwIiwiYnJhbmNoIjoidmVyaWZ5L2lzc3VlLTM2My1sY2QtaGVhdnktcmF0ZS1saW1pdHMiLCJyZXBvT3duZXIiOiJQbGFzdGljRGlnaXRzIiwicmVwb05hbWUiOiJjbDh5LWRleC10ZXJyYWNsYXNzaWMiLCJwck51bWJlciI6MTY0LCJjb21taXRTaGEiOiIzYTc1N2M3NzE0YTY3MDNiMGFhZmJlYjU2NTRmOWVhMzFiMDY2ZDI4IiwicHJvdmlkZXIiOiJnaXRsYWIiLCJob3N0bmFtZSI6ImdpdGxhYi5jb20ifX0" target="_blank" rel="noopener noreferrer"><picture><source media="(prefers-color-scheme: dark)" srcset="https://cursor.com/assets/images/fix-in-web-dark.png"><source media="(prefers-color-scheme: light)" srcset="https://cursor.com/assets/images/fix-in-web-light.png"><img alt="Fix in Web" width="99" height="28" src="https://cursor.com/assets/images/fix-in-web-dark.png"></picture></a></div> <sup>Reviewed by [Cursor Bugbot](https://cursor.com/bugbot) for commit 3a757c7714a6703b0aafbeb5654f9ea31b066d28. Configure [here](https://www.cursor.com/dashboard/bugbot).</sup>
PlasticDigits commented 2026-06-12 08:17:19 +00:00 (Migrated from gitlab.com)

Security review

Commit reviewed: 3a757c7714a6703b0aafbeb5654f9ea31b066d28
Scope: Verification pass for #363 — documentation (docs/operator-secrets.md, docs/integrators.md, docs/route-solver.md, skills/AGENTS_INDEXER_API_LCD_SECURITY.md), QA env templates (indexer/.env.example, scripts/deploy-dex-local.sh), and integration test prod_lcd_heavy_rate_limit_enforced_when_config_clamped in indexer/tests/security.rs. No runtime indexer logic changes in this diff.

Method: Full MR diff review; traced rate-limit controls in unchanged indexer/src/config.rs (prod clamps RATE_LIMIT_RPS=0 → 60, RATE_LIMIT_LCD_HEAVY_RPS=0 → 10) and indexer/src/api/mod.rs (lcd_heavy_router + PeerIpKeyExtractor, no XFF spoofing). Prior MR security threads: none.

Outcome: FINDINGS: 0 medium+

Security review: no medium+ findings on this diff.

Notes (informational, below reporting threshold):

  • New test exercises HTTP 429 on LCD-heavy routes with RunMode::Prod and global limit off; prod env clamp (0 → 10) is already covered by prod_forces_nonzero_rate_limits_when_zero in config.rs.
  • deploy-dex-local.sh writes RATE_LIMIT_LCD_HEAVY_RPS=10 alongside RATE_LIMIT_RPS=0 with API_BIND=127.0.0.1 — localhost QA only; aligns with default behavior and keeps LCD-heavy governor active when global layer is disabled for UI bursts.

Inline threads: none (no medium+ findings to anchor).

## Security review **Commit reviewed:** `3a757c7714a6703b0aafbeb5654f9ea31b066d28` **Scope:** Verification pass for #363 — documentation (`docs/operator-secrets.md`, `docs/integrators.md`, `docs/route-solver.md`, `skills/AGENTS_INDEXER_API_LCD_SECURITY.md`), QA env templates (`indexer/.env.example`, `scripts/deploy-dex-local.sh`), and integration test `prod_lcd_heavy_rate_limit_enforced_when_config_clamped` in `indexer/tests/security.rs`. No runtime indexer logic changes in this diff. **Method:** Full MR diff review; traced rate-limit controls in unchanged `indexer/src/config.rs` (prod clamps `RATE_LIMIT_RPS=0` → 60, `RATE_LIMIT_LCD_HEAVY_RPS=0` → 10) and `indexer/src/api/mod.rs` (`lcd_heavy_router` + `PeerIpKeyExtractor`, no XFF spoofing). Prior MR security threads: none. **Outcome:** `FINDINGS: 0` medium+ Security review: no medium+ findings on this diff. **Notes (informational, below reporting threshold):** - New test exercises HTTP 429 on LCD-heavy routes with `RunMode::Prod` and global limit off; prod env clamp (`0` → `10`) is already covered by `prod_forces_nonzero_rate_limits_when_zero` in `config.rs`. - `deploy-dex-local.sh` writes `RATE_LIMIT_LCD_HEAVY_RPS=10` alongside `RATE_LIMIT_RPS=0` with `API_BIND=127.0.0.1` — localhost QA only; aligns with default behavior and keeps LCD-heavy governor active when global layer is disabled for UI bursts. **Inline threads:** none (no medium+ findings to anchor).
ghost1 commented 2026-06-12 08:20:41 +00:00 (Migrated from gitlab.com)

added 1 commit

  • 9de66003 - fix(indexer): prod LCD-heavy clamp integration test uses zero RPS

Compare with previous version

added 1 commit <ul><li>9de66003 - fix(indexer): prod LCD-heavy clamp integration test uses zero RPS</li></ul> [Compare with previous version](/PlasticDigits/cl8y-dex-terraclassic/-/merge_requests/164/diffs?diff_id=1848517102&start_sha=3a757c7714a6703b0aafbeb5654f9ea31b066d28)
ghost1 commented 2026-06-12 08:20:54 +00:00 (Migrated from gitlab.com)

changed the description

changed the description
ghost1 commented 2026-06-12 08:21:13 +00:00 (Migrated from gitlab.com)

resolved all threads

resolved all threads
PlasticDigits commented 2026-06-12 08:34:44 +00:00 (Migrated from gitlab.com)

added 32 commits

  • 9de66003...62050542 - 31 commits from branch main
  • d72c80f2 - Merge branch 'main' into verify/issue-363-lcd-heavy-rate-limits

Compare with previous version

added 32 commits <ul><li>9de66003...62050542 - 31 commits from branch <code>main</code></li><li>d72c80f2 - Merge branch &#39;main&#39; into verify/issue-363-lcd-heavy-rate-limits</li></ul> [Compare with previous version](/PlasticDigits/cl8y-dex-terraclassic/-/merge_requests/164/diffs?diff_id=1848546953&start_sha=9de66003d142af2ee7fd5a5fb83866c4030674b7)
PlasticDigits commented 2026-06-12 08:34:47 +00:00 (Migrated from gitlab.com)

Resolved merge conflicts with main (merge commit d72c80f).

Files: docs/operator-secrets.md, docs/integrators.md, indexer/.env.example, scripts/deploy-dex-local.sh

Resolution: Kept main's rate-limit profile table and #362 observability additions; merged in #363 verification details (prod clamp wording, QA template comments, integrator 429 shape). No runtime logic changes.

Sanity: cargo test --lib prod_forces_nonzero_rate_limits_when_zero passed locally.

Resolved merge conflicts with `main` (merge commit `d72c80f`). **Files:** `docs/operator-secrets.md`, `docs/integrators.md`, `indexer/.env.example`, `scripts/deploy-dex-local.sh` **Resolution:** Kept main's rate-limit profile table and #362 observability additions; merged in #363 verification details (prod clamp wording, QA template comments, integrator 429 shape). No runtime logic changes. **Sanity:** `cargo test --lib prod_forces_nonzero_rate_limits_when_zero` passed locally.
ghost1 commented 2026-06-12 08:34:59 +00:00 (Migrated from gitlab.com)

changed the description

changed the description
PlasticDigits commented 2026-06-12 08:37:02 +00:00 (Migrated from gitlab.com)

Security review

Commit reviewed: d72c80f2c8d5421eebea5d094671ebf0e9c58a8a
Scope: Verification pass for #363 — documentation (docs/operator-secrets.md, docs/integrators.md, docs/route-solver.md, skills/AGENTS_INDEXER_API_LCD_SECURITY.md), QA env templates (indexer/.env.example, scripts/deploy-dex-local.sh), and integration tests prod_lcd_heavy_rate_limit_enforced_when_env_zero + prod_lcd_heavy_rate_limit_enforced_when_config_clamped in indexer/tests/security.rs. No runtime indexer logic changes in this diff.

Method: Full MR diff review (including merge-conflict resolution at d72c80f); traced rate-limit controls in unchanged indexer/src/config.rs (prod clamps RATE_LIMIT_RPS=0 → 60, RATE_LIMIT_LCD_HEAVY_RPS=0 → 10) and indexer/src/api/mod.rs (lcd_heavy_router + PeerIpKeyExtractor, no trusted XFF). Re-read prior MR security thread on 3a757c7 — still applies after merge.

Outcome: FINDINGS: 0 medium+

Security review: no medium+ findings on this diff.

Notes (informational, below reporting threshold):

  • Prod env clamp (0 → 10) is enforced at Config::from_env load; covered by prod_forces_nonzero_rate_limits_when_zero (config.rs) and prod_lcd_heavy_rate_limit_enforced_when_env_zero (security.rs). The additional prod_lcd_heavy_rate_limit_enforced_when_config_clamped test manually mirrors the clamp for hand-built test configs — test-coverage nuance only, not a production bypass.
  • deploy-dex-local.sh keeps RATE_LIMIT_LCD_HEAVY_RPS=10 with RATE_LIMIT_RPS=0 and API_BIND=127.0.0.1 — localhost QA template only; aligns with documented local profile.
  • Doc additions (429 plain-text body shape, cross-links) describe existing tower_governor behavior; no new attack surface.

Inline threads: none (no medium+ findings to anchor).

## Security review **Commit reviewed:** `d72c80f2c8d5421eebea5d094671ebf0e9c58a8a` **Scope:** Verification pass for #363 — documentation (`docs/operator-secrets.md`, `docs/integrators.md`, `docs/route-solver.md`, `skills/AGENTS_INDEXER_API_LCD_SECURITY.md`), QA env templates (`indexer/.env.example`, `scripts/deploy-dex-local.sh`), and integration tests `prod_lcd_heavy_rate_limit_enforced_when_env_zero` + `prod_lcd_heavy_rate_limit_enforced_when_config_clamped` in `indexer/tests/security.rs`. No runtime indexer logic changes in this diff. **Method:** Full MR diff review (including merge-conflict resolution at `d72c80f`); traced rate-limit controls in unchanged `indexer/src/config.rs` (prod clamps `RATE_LIMIT_RPS=0` → 60, `RATE_LIMIT_LCD_HEAVY_RPS=0` → 10) and `indexer/src/api/mod.rs` (`lcd_heavy_router` + `PeerIpKeyExtractor`, no trusted XFF). Re-read prior MR security thread on `3a757c7` — still applies after merge. **Outcome:** `FINDINGS: 0` medium+ Security review: no medium+ findings on this diff. **Notes (informational, below reporting threshold):** - Prod env clamp (`0` → `10`) is enforced at `Config::from_env` load; covered by `prod_forces_nonzero_rate_limits_when_zero` (`config.rs`) and `prod_lcd_heavy_rate_limit_enforced_when_env_zero` (`security.rs`). The additional `prod_lcd_heavy_rate_limit_enforced_when_config_clamped` test manually mirrors the clamp for hand-built test configs — test-coverage nuance only, not a production bypass. - `deploy-dex-local.sh` keeps `RATE_LIMIT_LCD_HEAVY_RPS=10` with `RATE_LIMIT_RPS=0` and `API_BIND=127.0.0.1` — localhost QA template only; aligns with documented local profile. - Doc additions (429 plain-text body shape, cross-links) describe existing `tower_governor` behavior; no new attack surface. **Inline threads:** none (no medium+ findings to anchor).
PlasticDigits commented 2026-06-12 11:02:02 +00:00 (Migrated from gitlab.com)

mentioned in commit 2f9c79676a

mentioned in commit 2f9c79676a8d499680fc6a28a96bfd02c930972e
PlasticDigits (Migrated from gitlab.com) merged commit 2f9c79676a into main 2026-06-12 11:02:02 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
code/cl8y-dex-terraclassic!882
No description provided.