Lab Icon

CSRF Bank Transfer

🏦 Can you steal money without touching the keyboard?

Challenge Updated 17 Jun 2026 Solution (Pro)
CSRF Cross-Site Request Forgery Session Security Web Security Social Engineering Form Security HTTP Security State Management

🎯 Master Cross-Site Request Forgery (CSRF) attacks and understand session-based vulnerabilities
πŸ› οΈ Learn to craft malicious HTML forms and exploit state-changing web application operations
πŸ“Š CSRF vulnerabilities affect 73% of financial applications according to recent security assessments
πŸš€ Enhance your penetration testing skills with realistic banking application security scenarios

1
Flags
50
XP
48%
Success Rate

Cross-Site Request Forgery (CSRF) is a web security vulnerability that tricks authenticated users into performing unintended actions on a web application. A CSRF tutorial demonstrates how attackers craft malicious web pages that submit requests to vulnerable sites using the victim's existing session. This attack is particularly dangerous in financial applications where unauthorized transfers, password changes, or account modifications can occur without the user's knowledge.

How CSRF Attacks Work

CSRF exploits the trust that a web application has in the user's browser. When a user is logged into a banking site, their browser automatically includes session cookies with every request to that site. An attacker can create a malicious web page containing a hidden form that submits a transfer request to the banking site. If the victim visits this malicious page while logged into their bank, the browser sends the forged request complete with valid session cookies, and the bank processes it as a legitimate transaction.

CSRF Attack Vectors

Attackers deliver CSRF payloads through various methods. Hidden HTML forms with auto-submit JavaScript are the most common technique for POST-based attacks. Image tags and other elements that trigger GET requests can exploit applications that perform state changes via GET. More sophisticated attacks use XMLHttpRequest or fetch API calls, though same-origin policy restrictions limit some of these approaches. Social engineering plays a key role - the attacker must convince the victim to visit the malicious page while authenticated to the target application.

Defenses Against CSRF

The most effective CSRF defense is the synchronizer token pattern, where the server generates a unique, unpredictable token for each session or request and requires it to be included in all state-changing requests. Since the attacker cannot read the token from the target site (blocked by same-origin policy), they cannot include it in their forged request. Additional defenses include SameSite cookie attributes, checking the Origin and Referer headers, and requiring re-authentication for sensitive operations like financial transfers.

What You Will Learn

  • How Cross-Site Request Forgery attacks exploit browser trust
  • Crafting CSRF payloads using hidden forms and auto-submission
  • Why session cookies alone are insufficient for request validation
  • CSRF defense mechanisms including tokens and SameSite cookies
  • Real-world impact of CSRF in financial and critical applications

Prerequisites

Basic HTML and forms Understanding of HTTP cookies and sessions Web browser usage

Ready to hack this lab?

Create a free account and start practicing cybersecurity hands-on.

Start Hacking - It's Free
Start Your Challenge
~1-2 min setup
Dedicated server
Private instance
Standard power
New here? Here's what to do
1
Click "Start Lab" above You'll get your own private machine with an IP address
2
Explore the target Open the IP in your browser and look for vulnerabilities
3
Find and submit flags Flags are secret text strings hidden in the system - paste them below to score

Ready to hack this lab?

Create a free account to start your own dedicated server, submit flags, and earn XP on the leaderboard.

Start Hacking Free
13,000+ Hackers 100+ Labs & Courses Free
Start Hacking Free