Skip to content

This is a simple library for providing a simple Yes/No answer on whether or not a provided SQL Query is Allowed to be Executed Based on a set of provided filters aiming to allow/disallow certain query types, tables, or fields from being used in a provided query.

License

Notifications You must be signed in to change notification settings

orware/sql-allowed-filter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SQL Allowed Filter Class for PHP

This is a simple library for providing a simple Yes/No answer on whether or not a provided SQL Query is Allowed to be Executed Based on a set of provided filters aiming to allow/disallow certain query types, tables, or fields from being used in a provided query.

Installation with Composer

curl -s http://getcomposer.org/installer | php
php composer.phar require orware/sql-allowed-filter

OR

composer require orware/sql-allowed-filter

Usage

use Orware\Sql\AllowedFilter;

$filter = new AllowedFilter();

$filter->setQuery("select * from test");

// Uses default filters (defaults are pretty open to allow anything so $result should be true):
$result = $filter->canExecuteQuery();

About

This is a simple library for providing a simple Yes/No answer on whether or not a provided SQL Query is Allowed to be Executed Based on a set of provided filters aiming to allow/disallow certain query types, tables, or fields from being used in a provided query.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages