Skip to content
CSRF Disclosed report Beginner

CSRF Leads to Logout any Loggedin user from their session

The logout endpoint on the site accepted cross-site form submissions without a CSRF token, so an attacker could force any logged-in user to be logged out by getting them to load a crafted page. The impact is limited to logging the victim out of their session.

DeadSniper Follow

Originally disclosed on Bugcrowd

Informational View original
  • Disclosed after 8 months

Summary by DeadSniper

As this is informational finding for you so we can disclose it publicly

Report details

  • Submitted

    24 Apr 2021 09:04:00 UTC

  • Target Location

    https://www.20min.ch

  • Target category

    Web App

  • VRT

    Cross-Site Request Forgery (CSRF) > Action-Specific > Logout

  • Priority

    P5

  • Bug URL

    https://www.20min.ch/profile

  • Description

    Hi Team👋,

    I found CSRF while logging out from the account. While exploiting this poc by sending it to a user, any logged-in user can be logout from their session.

    SUMMARY📝:

    Cross-Site Request Forgery (CSRF) is an attack that forces an end user to execute unwanted actions on a web application in which they're currently authenticated. ... If the victim is an administrative account, CSRF can compromise the entire web application.

    STEPS TO REPRODUCE🔥:

    ⚡ Login to user 1 Account ⚡ Then Logout and intercept the request in BurpSuite ⚡ Right Click >> Engagement Tools >> Generate CSRF POC ⚡ Copy the entire HTML code and save it ⚡ Now Run this CSRF Exploit where 2nd Account is logged in ⚡ User Logout ⚜(CSRF EXPLOIT!)⚜

    IMPACT💥:

    Logout any victim into the attacker account, send the HTML made by the attacker, and then logout him from the Session.

    POC✨:

    POC Video Attached Below and also, the CODE THAT I USED IS GIVEN BELOW...

  • Extra info

    <html> <!-- CSRF PoC - generated by Burp Suite Professional --> <body> <script>history.pushState('', '', '/')</script>
    <form action="https://api.20min.ch/user/v1/logout">
    
      <input type="hidden" name="redirect" value="https&#58;&#47;&#47;www&#46;20min&#46;ch&#47;" />
    
      <input type="submit" value="Submit request" />
    
    </form>
    
    </body> </html>

The original report as published on Bugcrowd, by DeadSniper. Images and videos are our own copies; raw HTML is shown as text. View it on Bugcrowd.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the logout endpoint accepted state-changing requests without a per-session anti-CSRF token or origin check.

Impact

An attacker could log any logged-in user out of their session by getting them to load a crafted page; no other account action is shown to be possible.

What the attacker needed

Victim is logged in; victim loads attacker's page

How it was found

  1. Log in to the first account.
  2. Log out and intercept the logout request in Burp Suite.
  3. Use Burp's engagement tools to generate a CSRF proof-of-concept page.
  4. Save the generated HTML.
  5. Open the page while a second account is logged in.
  6. The second user is logged out.

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 report has not been written yet. The Original tab links to the source.

When you log in to a website, your browser holds a cookie that proves who you are. A cross-site request forgery (CSRF) trick makes your browser send a request to that site from a different page, and the site treats it as if you asked for it. Here the request was a logout, so the worst that happened is you got signed out.

What is CSRF?

Another site makes a signed-in user's browser perform an action they did not intend.

More from 20 Minuten

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Cross-site request forgery (CSRF)

The lesson behind this report.

Another site makes a signed-in user's browser perform an action they did not intend.