tokengrid, a strong authentication token grid PHP class
Last update: 2008-04-23, release 1.3
The tokengrid class is a Strong Authentication Token Grid solution
to secure the access to sensitive data through the Internet.
It is a good protection against Sniffing and Phishing processes.
This kind of token cards are also used by some Swiss Banks for
authentication purpose.
This class provides everything to implement a complete solution,
including ready to print token grids in XHTML format.
Array-based intermediate output can be used to produce
PDF token grids using for example TCPDF (www.tcpdf.org).
USAGE
require_once('tokengrid.class.php');
$token_grid = new TokenGrid([$x_grid_size = 10[, $y_grid_size = 10[, $token_length = 4[, $grid_salt = 'T@kenGr!D']]]])
EXAMPLES
Example 1 (create a grid)
require_once('tokengrid.class.php');
$token_grid = new TokenGrid(10, 10, 4, "MySalt");
echo $token_grid->GetXhtmlGrid("SpecificUserId");
Example 2 (ask for a token)
require_once('tokengrid.class.php');
$token_grid = new TokenGrid(10, 10, 4, "MySalt");
$random_position = $token_grid->GetRandomGridPosition("SpecificUserId");
echo "Please enter the token at the position ".$random_position;
Example 3 (check a token)
require_once('tokengrid.class.php');
$token_grid = new TokenGrid(10, 10, 4, "MySalt");
if ($token_grid->CheckToken($_POST['random_position'], 'SpecificUserId', $_POST['token']))
{
echo "Token is valid";
}
LICENCE
Copyright (c) 2008, SysCo systemes de communication sa
SysCo (tm) is a trademark of SysCo systemes de communication sa
(http://www.sysco.ch/)
All rights reserved.
The tokengrid class is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public License as
published by the Free Software Foundation, either version 3 of the License,
or (at your option) any later version.
The tokengrid class is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with the tokengrid class
If not, see <http://www.gnu.org/licenses/>.
|