Gossamer Forum
Home : Products : DBMan : Customization :

changing default.pass delimeter

Quote Reply
changing default.pass delimeter
I have made some mods to allow me to include extra info about a user and store it as extra fields in the default.pass (email, contact name, company name, etc) this info can then be placed into any of the pages when a user has logged on and it currently prefills some info when they go to add and also says hi Joe Bloggs, Smile kinda nice..

But I also want to assign a webaddress for them and store it in the default.pass, heres the prob, http: that : is also the delimeter and will cause problems. i could just use the www.someone.com and add the http: later.
I was wondering if anyone has changed the default.pass delimeter and what the hassles are.

Cheers chmod..
Quote Reply
Re: [chmod] changing default.pass delimeter In reply to
Figured it out.
Use a regular expression to swap the : on the way in and swap it back on the way out, easy I just needed to think of it.
Going in..
Code:
$in{'fieldname'} =~ s/:/\|/g;
Coming out..
Code:
$fieldname =~ s/\|/:/g;
Quote Reply
Re: [chmod] changing default.pass delimeter In reply to
Just in case - I actually changed the delimiter to "|". Hassles were minimal to non-existent.

You just have to go through auth.pl, look for where a line is split on the delimiter or where it is joined using the delimiter, and change the delimiter there. If I remember correctly, db.cgi doesn't read from or write to the password file.
kellner
Quote Reply
Re: [kellner] changing default.pass delimeter In reply to
Cheers Kellner,
I might just do that..

Just a quickie anyone know if the password crypt can include | when it encrypts the password, before I do any more..

chmod
Quote Reply
Re: [chmod] changing default.pass delimeter In reply to
In sub admin display (cgi file)

it has:

my @salt_chars = ('A' .. 'Z', 0 .. 9, 'a' .. 'z', '.', '/');
my $salt = join '', @salt_chars[rand 64, rand 64];
my $encrypted = crypt($in{'password'}, $salt);

it looks like the only symbols it uses is a period and slash ?

Unoffical DBMan FAQ
http://redundantcartridge.com/dbman/
Quote Reply
Re: [LoisC] changing default.pass delimeter In reply to
Sorry to drag this thread up again, but..

I`ve been trying to figure why a : is used in the default.pass instead of a |

any ideas or is that just the way it came out.

cheers chmod

PS I havn`t been thinking about it all year its just a project revisited Tongue

Last edited by:

chmod: Mar 13, 2003, 6:42 AM
Quote Reply
Re: [chmod] changing default.pass delimeter In reply to
I expect it was just a random choice. A pipe would be just as effective. Anything that isn't used in the password itself is a suitable delimiter.

Last edited by:

Paul: Mar 13, 2003, 7:25 AM
Quote Reply
Re: [Paul] changing default.pass delimeter In reply to
cheers Paul,
I just found it odd to use a different deliminator for the password file, I kinda suspected it was a random thing.

chmod
Quote Reply
Re: [chmod] changing default.pass delimeter In reply to
Don't they use a colon when separating usernames and passwords in .htpasswd files?