Task 02
Task 02
2. SQL Injection
SameSite Cookies: Use the SameSite attribute for cookies to control when cookies
are sent with cross-site requests. Setting it to Strict or Lax can help prevent CSRF
attacks.
Check the Referer Header: While not completely reliable, you can check the
Referer header in the request to see if it matches the expected origin.
However, this header can be easily spoofed or not sent at all.
User Interaction: For sensitive operations, require the user to re-authenticate
or confirm the action (e.g., by entering a password or clicking a confirmation
button).