Skip to content

Instantly share code, notes, and snippets.

View baghayi's full-sized avatar
🌴
On vacation

Hüsen Baghayi baghayi

🌴
On vacation
View GitHub Profile
@baghayi
baghayi / bcrypt.php
Created November 4, 2011 21:13 — forked from rk/bcrypt.php
Simple bcrypt object to wrap crypt() with.
<?php
// Originally by Andrew Moore
// Src: http://stackoverflow.com/questions/4795385/how-do-you-use-bcrypt-for-hashing-passwords-in-php/6337021#6337021
//
// Heavily modified by Robert Kosek, from data at php.net/crypt
class Bcrypt {
private $rounds;
private $prefix;