Skip to content
CSRF Write-up Beginner

I Found a Bug That Could Silently Flip Anyone’s Content Preferences on a Major Adult Site.

Account preference endpoints changed persistent user settings via plain GET requests, and the session cookies were set with SameSite=None, so any cross-origin page could trigger the change. An attacker could silently flip a logged-in victim's content orientation preference by getting them to load a page with a hidden image.

anshbohra10 Follow

Published on medium.com

So there I was on a perfectly normal Friday evening, doing what any well-adjusted adult does with their free time, auditing cookie attributes on a major adult video platform for a bug bounty program.

anshh.bohara, on medium.com

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 combination of a state-changing action exposed over GET and session cookies set with SameSite=None, with no CSRF token or origin check.

Impact

An attacker could silently and permanently change a logged-in victim's content preference, which the author argues carries harassment potential on an adult platform; the report was submitted but the endpoint was out of scope.

What the attacker needed

Victim is logged in; victim loads an attacker page; no click needed

The fix

State-changing actions should use POST with a server-validated CSRF token, and session cookies should be set to SameSite=Lax or Strict rather than None.

How it was found

  1. Create a victim test account with the orientation preference set to straight.
  2. Serve a page from a different origin containing a hidden image pointing at the preference endpoint.
  3. Load the page so the browser sends the request with the session cookies attached.
  4. Observe the server redirect and the cookie being reissued.
  5. Check the account and confirm the preference changed.

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.

A website can be tricked into acting on your logged-in session by another site you visit. Here, a simple hidden image on an attacker's page made the victim's browser send a request that changed their saved preference, because the site used a read-style request for a change and its login cookie was sent along with requests from other sites.

What is CSRF?

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

More by anshbohra10

View all

3 more disclosed reports, best first.

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.