PHP Classes
elePHPant
Icontem

Firewall: Accept or deny requests depending on IP address

Recommend this page to a friend!
  Info   View files View files (4)   DownloadInstall with Composer Download .zip   Reputation   Support forum (1)   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2010-05-11 (6 years ago) RSS 2.0 feedStarStarStarStar 70%Total: 1,403 This week: 2All time: 2,681 This week: 591Up
Version License PHP version Categories
firewall 1.0GNU General Publi...5.0Networking, HTTP, PHP 5, Security
Description Author

This class can be used to accept or deny requests depending on the user machine IP address.

It can look at the current user IP address and decide to accept or deny the request depending on rules defined in a separate rules file. It can also detect IP addresses behind proxies.

The rules define whether to accept or deny requests from individual IP addresses or whole ranges.

When the current user IP address is denied, it can either redirect the user to another page using Javascript, show a given message, or issue a denied access response header.

Innovation Award
PHP Programming Innovation award nominee
April 2010
Number 3


Prize: One downloadable copy of PhpED Professional
Some times it is necessary to block the access to users from certain IP addresses for some reason.

This class implements a solution to automate blocking accesses to site users from certain addresses using a simple archive to define the IP and ranges to block.

Manuel Lemos
Picture of Temperini Mirko
  Performance   Level  
Name: Temperini Mirko <contact>
Classes: 3 packages by
Country: Italy Italy
Innovation award
Innovation award
Nominee: 2x

  Files folder image Files  
File Role Description
Accessible without login Plain text file example.php Example example file
Plain text file firewall.class.php Class firewall source code
Accessible without login Plain text file forbidden.tpl Data aa funny blue death screen
Accessible without login Plain text file rules.table Data the rules table

 Version Control Unique User Downloads Download Rankings  
 0%
Total:1,403
This week:2
All time:2,681
This week:591Up
 User Ratings  
 
 All time
Utility:100%StarStarStarStarStarStar
Consistency:100%StarStarStarStarStarStar
Documentation:-
Examples:100%StarStarStarStarStarStar
Tests:-
Videos:-
Overall:70%StarStarStarStar
Rank:322