IT lexicon Security CSRF

CSRF Cross-Site Request Forgery

Security På svenska → Updated: 2026-05-23

An attack where a malicious site tricks your browser into sending a request to another site you're logged into.

Classic: you're signed into your bank in one tab. You visit another site that has <img src="bank.com/transfer?amount=10000&to=attacker">. The browser sends the request with your session cookie automatically.

Protection: CSRF tokens (the server demands a token in the form that the attacker can't guess) and cookies with SameSite=Strict.

← Back to the lexicon