What is Cross Site Request Forgery (CSRF)?

Duane Chambers
3 min readSep 16, 2021

Cross Site Request Forgery is a malicious web scripting attack that allows an external user to gain unauthorized control over a web page via a link in a resource tree. Cross-Site Request Forging occurs when an unsuspecting victim visits an innocent-looking website that requests information. The unsuspecting victim interprets this not as a welcome message or a request for information but also allows the user to access sensitive information on that specific web page.

This is done by placing an embedded script (typically JavaScript) on the website’s outer layer. The website’s scripting engine acts as an “app” and “helper” to the CSRF attacker. Cross-Site Request Forging is a common technique used in phishing scams asking for personal information and bank account numbers via an email attachment.
This technique is not only used by spammers and hackers to gain private information for their evil purposes. Cross-Site Request Forgeries are capable of targeting legitimate websites even if they don’t use appropriate security measures. Many Web browsers don’t display the requested information, so the information that traverses the web can’t be seen on the screen. Cross-Site request forgeries can be misleading and may even be considered fraud to Web browsers. This is why it is important to make necessary changes and modifications to your web server to protect yourself from these attacks.
Cross-Site request forgeries can be caused by insecure web servers, outdated content authors, hosting providers who are not aware of DNS rules, poor browser configuration, the poor security and scripting updates, data from trusted sites, excessive use of HTTP verbs on web pages, and poor SSL/TLS encryption. You can protect yourself against this attack by disabling the Allow Access feature on all pages that you are trying to access. You may also want to create a separate webserver to host all your e-commerce websites. This will allow you to restrict access to certain areas. In addition, your scripts and e-commerce applications should be protected from Flash threats or JavaScript. You might also consider software that can log and monitor requests to your computer.

What is Cross-Site Request Forgery exactly? Cross-Site request forgery occurs when hackers or other entities with malicious intent send carefully constructed requests to vulnerable web servers. Because it doesn’t know how to answer these requests, the server is unaware. Hackers often use this technique to trick the server into retrieving requested information from an alternative location. This attack is called “phishing,” and it is the most popular. Hackers often use software to track your internet traffic and then use that information to phish.
You should now be able to understand Cross-Site Request Forgery and how important it can be blocked. This can be done by adding the Cross Site Request Forgery filter on your WordPress website. After activating the plugin, you’ll be able to enter a list containing domains you wish to block. This will block all requests to these domains.

--

--

Duane Chambers

I provide advisory services for corporations and executives regarding network architecture, test design/execution, network virtualization and datacenter design.