PHP Classes

class_sql_inject: Detect attempts to perform SQL injection attacks

Recommend this page to a friend!
     
  Info   View files Files   Install with Composer Install with Composer   Download Download   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
StarStarStar 43%Total: 7,165 All time: 270 This week: 40Up
Version License Categories
class_sql_inject 1.0GNU General Publi...Databases, Security
Description 

Author

This class is meant to search in your SQL data values for special characters that may change the meaning of your SQL data and execute actions that may compromise the security of servers.

When some of these suspicious character sequences is found in HTTP POST request values ($_POST), you can:
- Destroy the current session
- Redirect to a new page
- Log the activity

To check the request values do the following:

$bDestroy_session = TRUE;
$url_redirect = 'index.php';
$sqlinject = new sql_inject('./path_to_log.log',$bDestroy_session,$url_redirect);
$sql_inject->test($your_sql_data);

This class requires PHP 4 or later.

Notice: this class recognise only some of the known types of SQL injection methods and so it is not yet ready to deal with all possible ways to perform this kind of attack.

Picture of MARY Matthieu
Name: MARY Matthieu <contact>
Classes: 19 packages by
Country: France, Metropolitan
Age: 45
All time rank: 251 in France, Metropolitan
Week rank: 164 Down1 in France, Metropolitan Equal

  Files folder image Files (3)  
File Role Description
Plain text file class_sql_inject.php Class class file
Accessible without login Plain text file class_sql_inject_examples.php Example an examples of some SQL_injections attempt detect by the class
Accessible without login Plain text file LICENCE Lic. copy of GPL licence

The PHP Classes site has supported package installation using the Composer tool since 2013, as you may verify by reading this instructions page.
Install with Composer Install with Composer
 Version Control Unique User Downloads Download Rankings  
 0%
Total:7,165
This week:0
All time:270
This week:40Up
 User Ratings  
 
 All time
Utility:65%StarStarStarStar
Consistency:60%StarStarStarStar
Documentation:-
Examples:50%StarStarStar
Tests:-
Videos:-
Overall:43%StarStarStar
Rank:3547