Field manual · BAC · Chapter 2
Vertical Privilege Escalation
Climbing the castle wall
Chapter 2: vertical privilege escalation: climbing the castle wall
Section titled “Chapter 2: vertical privilege escalation: climbing the castle wall”Why care: these five paths cover almost every way a standard-user account ends up with admin power. None of them need more than a proxy.
Five vertical escalation paths
Section titled “Five vertical escalation paths”2.1 Route one: unprotected endpoint (forced browsing)
Section titled “2.1 Route one: unprotected endpoint (forced browsing)”GET /admin/users HTTP/1.1Cookie: session=<standard-user session>Response: 200 OK, full user list, from a standard-user account.
Admin routes accessible with a normal session because the only authorization was the UI not showing you the link.
Variants:
/admin, /internal, /backoffice, /manage, /console, /_admin/api/admin/*, /api/internal/*, /api/private/*/actuator, /actuator/env (Spring Boot — reveals configs, sometimes creds)/graphql admin resolversThe naming tells you the developer thought of this space as “separate from users.” Thinking isn’t gating.
2.2 Route two: parameter-based role trust
Section titled “2.2 Route two: parameter-based role trust”The endpoint checks your session for “logged in” but a parameter decides your privileges:
GET /api/dashboard?role=adminPOST /api/reports {"role": "admin", "query": "all_users"}GET /api/orders?view=internal (support view, anyone can add it)The developer assumes the frontend only sends role=admin for an admin session. That assumption fails the moment you open a proxy, because the browser is on your machine and you control every byte it sends.
2.3 Route three: mass assignment: you promote yourself
Section titled “2.3 Route three: mass assignment: you promote yourself”POST /api/register {"username":"l33t","password":"...", "role":"admin"}PUT /api/users/me {"name":"l33t", "is_admin": true}PUT /api/users/me {"name":"l33t", "isAdmin": 1, "admin": true} (try them all)Frameworks like Rails/Laravel/Django bind incoming JSON to model attributes by name. If the users table has an is_admin column, and the update endpoint doesn’t blacklist it, then {"is_admin": true} is a promotion letter you wrote yourself.
The synonym game (fill a payload sheet):
role, roles, userRole, isAdmin, is_admin, admin, superuser,permissions, scopes, plan, tier, accountType, account_type,verified, emailVerified, status, active, balance, creditsOne of them will occasionally be the backdoor. Which one? The only way to find out is to try it. Use your own account so the change is provably yours, and keep it reversible: change it back or re-register, and note it in the report.
The Kubernetes/dashboards classic: audit logging endpoints, feature flags, “betaAccess” fields. PUT /users/me {"betaAccess": true} on a SaaS app with paid feature flags unlocks paid features for free, and that pays well.
2.4 Route four: stepping up through integer or enum roles
Section titled “2.4 Route four: stepping up through integer or enum roles”GET /api/session → {"userId": 8842, "role": 2}When role is an integer (1=user, 2=manager, 3=admin), the values usually ascend in privilege order. Whenever an endpoint accepts a role, plan, or tier number, test +1 and +2 on your own account. Verify a downgrade first (safe), then a single upgrade on your own account as proof of concept:
PATCH /api/users/me {"plan": 2} → check response, is plan now "premium"?PATCH /api/subscription {"tier": 3} → same idea2.5 Route five: registration as the gate-crash
Section titled “2.5 Route five: registration as the gate-crash”The most-underrated registration hacks:
POST /register {"email": "standarduser@x.com", "inviteCode": "ADMIN-l33t"}Invitation codes, invite roles, “first 100 users are admins” legacy logic, and promo-code tier upgrades all live in registration. Teams test that endpoint least.
Next step: Chapter 3 covers the other place vertical bugs hide, how identity is carried in sessions and tokens, not just which endpoint you hit.
Open local graph around this page
Linked from here
Links out to
No outgoing internal links on this page.
Broken Access ControlFor authorized security research only: bug bounty programs, your own systems, or scoped engagements with written permission.