Task · MDE-0031

Preserve Meraki credentials across legitimate shard redirects

Description

Release review finding P1.2 remains live at src/meraki_dashboard_exporter/api/client.py:42-51. Redirect authentication is currently preserved only for the configured origin, so legitimate Meraki shard or regional hosts can lose Authorization and enter a persistent 401 path. The redirect boundary must preserve credentials only for documented Meraki-owned host suffixes while stripping them for attacker-controlled lookalikes.

Acceptance Criteria

Definition of Done

Implementation Plan

Implement the host-boundary redirect credential policy in the existing API client with failing tests for legitimate Meraki shards and attacker-controlled lookalikes, then run the focused API tests.

Implementation Notes

Test-first redirect coverage now preserves Authorization only between configured or Meraki-owned HTTPS origins and strips it for attacker-controlled lookalikes. Integrated gate: 2827 passed.

Final Summary

Implemented a suffix-boundary Meraki redirect trust policy with regional/shard, lookalike, and same-origin tests; just check and just ci pass.

View the source file on GitHub