โ† Back to list

๐Ÿ”“ Improper Access Control in Spring Boot Actuator

How a Misconfigured Endpoint Exposed Internal Application Configuration

Ussef ยท 2026-03-25 01:16 ยท 33 claps ยท 2.0 min read
#broken-access-control #actuator-access-leak #spring-boot-data-leak #exposed-config-endpoint #internal-api-exposure
Open on Medium โ†—
Wiki topics: FT ยท Fine-tuning & Adaptation

๐Ÿ”“ Improper Access Control in Spring Boot Actuator

How a Misconfigured Endpoint Exposed Internal Application Configuration

๐Ÿ“Œ Introduction

During a security assessment of a B2B customer portal, I discovered an Improper Access Control vulnerability (CWE-284) affecting internal management endpoints.

The issue allowed low-privileged users to access sensitive configuration data that should only be available to administrators.

๐ŸŽฏ Target Overview

The application is built using Spring Boot and exposes internal management endpoints via: /management/* These endpoints are typically used for: โ€ข Monitoring โ€ข Debugging โ€ข Configuration inspection

๐Ÿ” Step 1 โ€” Verifying Role-Based Access Control

Before digging deeper, I verified whether RBAC (Role-Based Access Control) was properly implemented.

โœ… Admin-Only Endpoint Test GET /api/customers/{id}/users

๐Ÿ“Š Behavior

โ€ข Admin โ†’ 200 OK

โ€ข User โ†’ 401 Unauthorized

โœ”๏ธ This confirmed that authorization exists and works correctly in some parts of the application.

๐Ÿ” Step 2 โ€” JWT Analysis

Next, I analyzed the JWT tokens to understand permission differences.

๐Ÿ‘‘ Admin Token โ€ข Multiple enabled modules โ€ข Extended privileges

๐Ÿ‘ค Regular User Token โ€ข Limited modules โ€ข Restricted access

๐Ÿง  This confirmed proper privilege separation at the token level.

โธป

๐Ÿ’ฅ Step 3 โ€” Discovering the Vulnerable Endpoint

While testing internal endpoints, I found: GET /management/configprops ๐Ÿ“Š Results โ€ข Admin โ†’ 200 OK โ€ข User โ†’ 200 OK โ€ข Low-priv user โ†’ 200 OK

โ— All roles received identical sensitive data

๐Ÿงช Proof of Concept

GET /management/configprops HTTP/2 Host: <redacted> Cookie: access-token=<low-priv-user>

๐Ÿ“ฆ Exposed Information

The response included: โ€ข Application configuration โ€ข Feature flags โ€ข Security-related settings โ€ข Internal API paths โ€ข Infrastructure metadata

โธป

โš ๏ธ Impact Analysis

Even though the endpoint is read-only, the impact is serious.

โธป

๐Ÿ”“ Information Disclosure

Sensitive internal data is exposed to unauthorized users.

โธป

๐Ÿงญ Attack Surface Expansion

Attackers can: โ€ข Map internal architecture โ€ข Discover hidden endpoints โ€ข Identify enabled modules

โธป

๐Ÿš€ Attack Chaining

This can lead to: โ€ข Privilege escalation โ€ข Remote Code Execution (RCE) โ€ข Misconfiguration exploitation

โธป

โ— Security Violation

โ€ข Breaks Least Privilege Principle โ€ข Weakens Defense in Depth

โธป

๐Ÿง  Root Cause

Missing authorization checks on Spring Boot Actuator endpoints

Although RBAC exists, it was not consistently enforced across: /management/*

๐Ÿ› ๏ธ Remediation

โœ… 1. Restrict Management Endpoints /management/* โ†’ Should be accessible only by admin roles โœ… 2. Enforce Spring Security .antMatchers(โ€œ/management/**โ€).hasRole(โ€œADMINโ€) โœ… 3. Limit Actuator Exposure management.endpoints.web.exposure.include=health,info

โœ… 4. Disable Unnecessary Endpoints

Avoid exposing debugging endpoints in staging/production.

โœ… 5. Isolate Management Interface โ€ข Bind to internal network only โ€ข Never expose publicly

โธป

๐Ÿ Conclusion

This vulnerability highlights a critical lesson:

โš ๏ธ Security must be consistent โ€” not partial.

Even when RBAC is correctly implemented, a single overlooked endpoint can expose sensitive internal data.

โธป

๐Ÿ’ก Key Takeaways

โ€ข Never expose Actuator endpoints publicly โ€ข Always enforce strict authorization โ€ข Validate access control across all endpoints โ€ข Treat configuration data as sensitive

โธป

๐Ÿค Disclosure Timeline

โ€ข Vulnerability discovered and reported responsibly โ€ข Reviewed and validated by the security team โ€ข Successfully accepted and rewarded ๐ŸŽฏ

โธป

โœ๏ธ Final Thoughts

Misconfigured internal endpoints are a common yet dangerous mistake.

Always remember:

๐Ÿ” โ€œWhat is internal today can become public tomorrow.โ€


๋ฉ”ํƒ€๋ฐ์ดํ„ฐ
post_id
20a7b4c9de4f
slug
improper-access-control-in-spring-boot-actuator-20a7b4c9de4f
url
https://medium.com/@psussef/improper-access-control-in-spring-boot-actuator-20a7b4c9de4f
canonical_url
https://medium.com/@psussef/improper-access-control-in-spring-boot-actuator-20a7b4c9de4f
author_url
https://medium.com/@psussef
status
ok
fetched_at
2026-07-15 18:16:01