Changeset 56 for trunk


Ignore:
Timestamp:
01/12/10 11:24:00 (15 years ago)
Author:
Kris Deugau
Message:

/trunk

fix checkUser sub - use a different variable for the input password

vs the stored password. *headdesk*

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/DNSDB.pm

    r55 r56  
    527527  my $dbh = shift;
    528528  my $user = shift;
    529   my $pass = shift;
     529  my $inpass = shift;
    530530
    531531  my $sth = $dbh->prepare("SELECT user_id,group_id,password,firstname,lastname FROM users WHERE username=?");
     
    535535
    536536  if ($pass =~ m|^\$1\$([A-Za-z0-9/.]+)\$|) {
    537     $loginfailed = 1 if $pass ne unix_md5_crypt($pass,$1);
     537    $loginfailed = 1 if $pass ne unix_md5_crypt($inpass,$1);
    538538  } else {
    539     $loginfailed = 1 if $pass ne $pass;
     539    $loginfailed = 1 if $pass ne $inpass;
    540540  }
    541541
Note: See TracChangeset for help on using the changeset viewer.