Gossamer Forum
Home : Products : DBMan : Customization :

Auth id number

Quote Reply
Auth id number
When someone logs in for the first time on a given day, is it possible for them to have the same auth number each time they log in thereafter for the period of time specified in the .cfg?

eg: name.96113778081401 is first assigned.
My $auth_time = 21600; # 6 hours
If I log in again during the following 6 hours I get the same
name.96113778081401
6 hours after the first login though the file id deleted and then the next time I am assigned a new number.

Make sense?
As always.....Thanks!
Adam

Quote Reply
Re: Auth id number In reply to
In auth.pl, sub check_password, after

elsif ($in{'login'}) { # The user is trying to login.

add

Code:

opendir (AUTHDIR, "$auth_dir") || &cgierr("unable to open directory in auth_check_password: $auth_dir. Reason: $!");
@files = readdir(AUTHDIR); # Read in list of files in directory..
closedir (AUTHDIR);
FILE: foreach $file (@files) {
next if ($file =~ /^\./); # Skip "." and ".." entries..
next if ($file =~ /^index/); # Skip index.htm type files..
if ($file =~ /^$in{'userid'}\./) {
$db_uid = $file;
return ('ok', $db_uid, &auth_check_permissions($db_uid));
}
}
That should do it, although I haven't tested it.


JPD
http://www.jpdeni.com/dbman/