How to prevent Cross Site Scripting(XSS) injection attack in your Website?

How to prevent Cross Site Scripting(XSS) injection attack in your Website? [EASY TIPS]

In this article we will explain you about Cross-site scripting and steps to prevent Cross Site Scripting(XSS) attack in your Website.

Video Tutorial– “How to prevent Cross Site Scripting(XSS) injection attack in your Website”

What is Cross Site Scripting(XSS) Attack? [EXPLAINED]

Cross-site Scripting (XSS) is a client-side code injection attack. The attacker aims to execute malicious scripts in a web browser of the victim by including malicious code in a legitimate web page or web application. The actual attack occurs when the victim visits the web page or web application that executes the malicious code.

How to prevent XSS attacks in your website? [STEP-BY-STEP]

Step::1 Login to cPanel and open File Manager section

How to prevent Cross Site Scripting(XSS) injection attack in your Website

Step::2 Go to public_html

How to prevent Cross Site Scripting(XSS) injection attack in your Website

Step::3 Now find .htaccess file and right click over and choose the Edit option

How to prevent Cross Site Scripting(XSS) injection attack in your Website

Step::4 Copy the code given below:

Options +FollowSymLinks
RewriteEngine On
RewriteCond %{QUERY_STRING} (<|%3C).*script.*(>|%3E) [NC,OR]
RewriteCond %{QUERY_STRING} GLOBALS(=|[|%[0-9A-Z]{0,2}) [OR]
RewriteCond %{QUERY_STRING} _REQUEST(=|[|%[0-9A-Z]{0,2})
RewriteRule ^(.*)$ index.php [F,L]

How to prevent Cross Site Scripting(XSS) injection attack in your Website

Step::5 Paste this code in your .htaccess file and click on Save changes

How to prevent Cross Site Scripting(XSS) injection attack in your Website

Thanks for Reading this article !!! We hope this was helpful to you all.

For more information, kindly follow us on social media like Twitter and Facebook and for video tutorials, subscribe to our YouTube channelhttps://youtube.com/redserverhost.com 

Facebook Page https://facebook.com/redserverhost

Twitter Pagehttps://twitter.com/redserverhost.com

If you have any suggestions or problems related to this tutorial, please let us know via the comment section below.

Tags: cheap linux hostingbuy linux hostingcheap reseller hostingbuy reseller hostingbest reseller hostingcheap web hostingcheapest web hostingcheapest reseller hosting,  cheap reseller hostcheap linux hostcheapest linux hostingbest linux hostingbest web hosting