Bypassing Admin Authentication Website Kampus
The admin area of a university website relied on a client-side JavaScript redirect to send unauthenticated users back to the login page, while the server still returned the admin dashboard content. By disabling JavaScript, the author could view the admin dashboard and add news items, effectively acting as an administrator.
Halo,kembali lagi ke writeup sebenarnya udah aga males si bikin writeup kaya gini cuma ya semoga aja bisa nambah ilmu kalian.
The full write-up lives on its author's site
It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
How it worked
Root cause
Likely the server did not re-check authentication or authorisation for admin pages and instead relied on a client-side JavaScript redirect to enforce the login requirement.
Impact
An unauthenticated attacker could view the admin dashboard and create news content, effectively acting as an administrator, though the text does not show whether other admin actions were possible.
What the attacker needed
Access to the admin URL; ability to disable JavaScript in the browser
How it was found
- Open the admin dashboard path in Burp Suite and observe the response contains the dashboard content plus a JavaScript alert and redirect.
- Try modifying the cookie set by the application and request the dashboard again; the redirect still occurs.
- Disable JavaScript in the Chrome browser.
- Request the admin dashboard path again and see the dashboard without being redirected.
- Add a news item; it appears blank at first, then after toggling JavaScript off and on the news item is created.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.
When you log in to a website, the server is supposed to check who you are on every request. Here, the server sent back the admin page anyway, and a script in the browser was the only thing that sent you back to the login screen. Turning off JavaScript in the browser stopped that redirect, so the admin page stayed visible and actions like adding news worked.
What is Access control?
A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.