Gossamer Forum
Home : Products : DBMan : Installation :

Cannot login: returns to login screen

Quote Reply
Cannot login: returns to login screen
Hi

I recently inherited a site with DBMan installed and moved it from a Linux server to a Sun Cobalt Raq with Unix.

Logins no longer work - the user is kicked back to the login screen every time. I have tried giving default users (who are not required to login) admin rights and deleted the contents of the .pass file. This gets me to the users screen, but any attempt to add a user does the same thing and takes me to the login screen without writing to the .pass file.

Attached is the .cfg file

TIA
Quote Reply
Re: [stratrat] Cannot login: returns to login screen In reply to
I would guess that it has something to do with a

.htaccess or .htpasswd file or setting.
Quote Reply
Re: [stratrat] Cannot login: returns to login screen In reply to
Hmmm... if I try guest/guest I get taken right back to the login screen. However, if I try admin/admin I get "Page not found" error because it is trying to take me to "http://server/cgi-bin/dbman/db.cgi"

Double check your db.cgi and default.cfg files and see where this URL is coming from - it could point you in the right direction.
Quote Reply
Re: [Watts] Cannot login: returns to login screen In reply to
That's in default.cfg, but the database (and .cfg) I am using is called "publishers". I just tried changing the setting in default.cfg and now guest-guest shows the same bad behaviour as the other logins. Tried deleting default.cfg - just in case - no joy.

Alan
Quote Reply
Re: [joematt] Cannot login: returns to login screen In reply to
I don't think it would be .htaccess or htpassword. I have neither in the directory.
Quote Reply
Re: [stratrat] Cannot login: returns to login screen In reply to
What about the parent directory cgi-bin ?

Also try running it in the cgi-bin and not a sub-directory.
Quote Reply
Re: [stratrat] Cannot login: returns to login screen In reply to
What if you renamed db.cgi to publishers.cgi (don't forget to change in the cfg file) and chmoded it to 755.

Try it and see what happens...
Quote Reply
Re: [Watts] Cannot login: returns to login screen In reply to
No renaming does not work - same behaviour.
Quote Reply
Re: [Watts] Cannot login: returns to login screen In reply to
Something I just noticed which might have bearing: there is a second database called "freelance" - when I try to log in there the script kicks me back to the publishers' login screen. Could something be stripping/dropping the uid, pw and db from the url?
Quote Reply
Re: [stratrat] Cannot login: returns to login screen In reply to
Okay... see what you have in db.cgi for this section:

Code:
# If you run into problems, set $db_script_path to the full path
# to your directory.
$db_script_path = ".";

# Load the form information and set the config file and userid.
local(%in) = &parse_form;
$in{'db'} ? ($db_setup = $in{'db'}) : ($db_setup = 'default');
$in{'uid'} ? ($db_uid = $in{'uid'}): ($db_uid = '');

# Required Librariers
# --------------------------------------------------------
# Make sure we are using perl 5.003, load the config file, and load the auth file.
eval {
unshift (@INC, $db_script_path);
require 5.003; # We need at least Perl 5.003
unless ($db_setup =~ /^[A-Za-z0-9]+$/) { die "Invalid config file name: $db_setup"; }
require "$db_setup.cfg"; # Database Definition File
require "auth.pl"; # Authorization Routines

Try changing default to the name of your config file. Do not add the ".cfg" - just call it publishers or whatever. Also make sure you haven't renamed auth.pl, or if you have change it here.
Quote Reply
Re: [Watts] Cannot login: returns to login screen In reply to
PS: I run mutiple db's but I have them in separate directories to keep myself from getting confused.

Example:

cgi-bin/publishers/
publishers.cgi, publisher.cfg, publishers.html, etc

cgi-bin/freelance/
freelance.cgi, freelance.cfg, freelance.html, etc
Quote Reply
Re: [Watts] Cannot login: returns to login screen In reply to
I had the full path in $db_script_path which I have now returned to "." - still the same behaviour.

Otherwise $db_setup = 'publishers' which is correct and auth.pl has not been renamed.

I think I'll try reinstall from scratch in a new directory and see what happens.

Thanks