1 package FS::Auth::internal;
2 #use base qw( FS::Auth );
5 use Crypt::Eksblowfish::Bcrypt qw(bcrypt_hash);
6 use FS::Record qw( qsearchs );
10 my($self, $username, $check_password ) = @_;
12 my $access_user = qsearchs('access_user', { 'username' => $username,
18 if ( $access_user->_password_encoding eq 'bcrypt' ) {
20 my( $cost, $salt, $hash ) = split(',', $access_user->_password);
22 my $check_hash = bcrypt_hash( { key_nul => 1,
33 return 0 if $access_user->_password eq 'notyet'
34 || $access_user->_password eq '';
36 $access_user->_password eq $check_password;
42 #sub change_password {