Fat-Free Framework: Bcrypt Class Reference

Fat-Free-Framework

Fat-Free Framework  3.1.0 API Reference
Bcrypt Class Reference

Lightweight password hashing library. More...

Inheritance diagram for Bcrypt:
Prefab

Public Member Functions

 hash ($pw, $salt=NULL, $cost=10)
 
 verify ($pw, $hash)
 

Public Attributes

const E_Cost ='Invalid cost parameter'
 
const E_Salt ='Invalid salt (must be at least 22 alphanumeric characters)'
 

Additional Inherited Members

- Static Public Member Functions inherited from Prefab
static instance ()
 

Detailed Description

Lightweight password hashing library.

Member Function Documentation

Bcrypt::hash (   $pw,
  $salt = NULL,
  $cost = 10 
)

Generate bcrypt hash of string

Returns
string|FALSE
Parameters
$pwstring
$saltstring
$costint
Bcrypt::verify (   $pw,
  $hash 
)

Verify password against hash using timing attack resistant approach

Returns
bool
Parameters
$pwstring
$hashstring

The documentation for this class was generated from the following file:
  • bcrypt.php
Generated on Mon Aug 19 2013 21:27:46 for Fat-Free Framework by   doxygen 1.8.4