PHP CSRF Token Generation: Generate tokens to protect against CSRF attacks

Recommend this page to a friend!
  Info   View files Example   View files View files (8)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Ratings Unique User Downloads Download Rankings
Not enough user ratingsTotal: 224 All time: 8,092 This week: 210Up
Version License PHP version Categories
php-csrf-security-cl 1.0.2MIT/X Consortium ...5HTML, PHP 5, Security
Description Author

This package can generate tokens to protect against CSRF attacks.

It can create a string that is stored in a session variable and will be used to identify a real user that submits a form in the script that handles the form submission.

The package can verify whether the user really submitted the form checking the token string by comparing the string passed via an URL parameter or an hidden form input.

Tokens are valid for a configurable amount of time and are deleted after they expire.

Picture of Muhammad Umer Farooq
Name: Muhammad Umer Farooq <contact>
Classes: 46 packages by
Country: Pakistan Pakistan
Innovation award
Innovation award
Nominee: 4x

Details

PHP CSRF Class

This package can generate token for csrf security in forms and add token to url

features

1. Generate new token on refresh/reload/open 2. Delete expire tokens automatically 3. Set time ( for tokens after how many time expire) 4. Delete current token (that passed in url) 5. Debug support 6. Verify tokens is exists or not 7. Count tokens 8. Delete unnecessary tokens.

Description

This package can generate tokens to protect against CSRF attacks. It can create a string that is stored in a session variable and will be used to identify a real user that submits a form in the script that handles the form submission. The package can verify whether the user really submitted the form checking the token string by comparing the string passed via an URL parameter or an hidden form input. Tokens are valid for a configurable amount of time and are deleted after they expire.

Input class

get form https://github.com/Lablnet/PHP-Input-Class

  Files folder image Files  
File Role Description
Files folder imageClasses (2 files)
Files folder imagelib (1 file)
Accessible without login Plain text file index.php Example Example script
Accessible without login Plain text file init.php Aux. Auxiliary script
Accessible without login Plain text file LICENSE Lic. License text
Accessible without login Plain text file Readme.md Doc. Documentation
Accessible without login Plain text file start.php Example Example script

  Files folder image Files  /  Classes  
File Role Description
  Plain text file PhpInput.php Class Class source
  Plain text file Security.php Class Class source

  Files folder image Files  /  lib  
File Role Description
  Accessible without login Plain text file input.php Example Example script

 Version Control Unique User Downloads Download Rankings  
 100%
Total:224
This week:0
All time:8,092
This week:210Up

For more information send a message to info at phpclasses dot org.