Thursday 26 January 2017

What is Cross Site Request Forgery (CSRF) and how it works


Reference: Hacking and Securing Web Applications


What is CSRF?



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. 

CSRF attacks specifically target state-changing requests, not theft of data, since the attacker has no way to see the response to the forged request. 

With a little help of social engineering (such as sending a link via email or chat), an attacker may trick the users of a web application into executing actions of the attacker's choosing. 

If the victim is a normal user, a successful CSRF attack can force the user to perform state changing requests like transferring funds, changing their email address, and so forth. If the victim is an administrative account, CSRF can compromise the entire web application.

Below picture is a simple explanation of CSRF attacks where the legacy website can be a banking website as an example. Attacker, can use the current available session initiate a money transfer to his/her own account.



How to protect yourself against CSRF?

1- First of all, avoid clicking on links and browse website which you are unsure of their safety. Especially when you have logged in to other important websites.
2- Second, always use security softwares like antivirus and anti spyware.
3- Beware of phishing attempts on emails, attachments, etc.
4- Use a safe browser when doing critical tasks and avoid browsing other websites using that browser
5- Always keep your browser up to date
6- Use tools or plugins to clear browser cookies on regular bases

No comments:

Post a Comment