Skip to content
This repository has been archived by the owner. It is now read-only.

Latest commit

 

History

History
executable file
·
35 lines (23 loc) · 606 Bytes

README.md

File metadata and controls

executable file
·
35 lines (23 loc) · 606 Bytes

Laravel XSS FILTER

This package add an additional filter to prevent xss attack.

Installation

Require the package in composer.json:

"ali-sharifi/xss-cleaner-filter": "dev-master"

Then in your project root directory run :

	composer update

Then, include the following in the array on service providers in config/app.php:

'AliSharifi\XssCleanerFilter\XssCleanerFilterServiceProvider' ,

Usage

You can clean your input HTML code from Xss attacks using xss filter :

<?php

Route::post('/',array('before' => 'xss',function(){
		//
}));