Description
DebugProbe currently keeps /debug/environment and /debug/json/{id} mapped in Production by default.
Tests confirm this behavior is intentional, but it should be reviewed from a security and product standpoint.
Current Behavior
When DebugProbe UI endpoints are disabled in Production, these endpoints may still remain available:
/debug/environment
/debug/json/{id}
This can expose debug-related metadata or trace details even when the main UI is not available.
Expected Behavior
Production endpoint exposure should be explicit and easy to understand.
If UI access is disabled in Production, related debug data endpoints should either also be disabled or clearly documented as intentionally available.
Suggested Fix
Review whether these endpoints should be controlled by the same Production UI protection rules.
Recommended options:
- Disable
/debug/environment and /debug/json/{id} in Production unless AllowUiInProduction = true.
- Or keep them available, but document clearly why they are safe and intended.
- Add or update tests to lock the final decision.
Result
After this review:
- Production behavior becomes clearer.
- Security expectations are easier to understand.
- DebugProbe avoids accidentally exposing sensitive debug data.
- Tests and documentation match the intended product behavior.
Description
DebugProbe currently keeps
/debug/environmentand/debug/json/{id}mapped in Production by default.Tests confirm this behavior is intentional, but it should be reviewed from a security and product standpoint.
Current Behavior
When DebugProbe UI endpoints are disabled in Production, these endpoints may still remain available:
This can expose debug-related metadata or trace details even when the main UI is not available.
Expected Behavior
Production endpoint exposure should be explicit and easy to understand.
If UI access is disabled in Production, related debug data endpoints should either also be disabled or clearly documented as intentionally available.
Suggested Fix
Review whether these endpoints should be controlled by the same Production UI protection rules.
Recommended options:
/debug/environmentand/debug/json/{id}in Production unlessAllowUiInProduction = true.Result
After this review: