I've recently been handed administration of a system that is built on perl CGI scripts and MySQL. Unfortunately, I am no perl guru and the system is not functioning as it did on the old server.
The scripts are based of off CGI.pm, but I don't think that they use it directly. Whatever the case, whenever a user logs into a webpage their username and password are authenticated and a cookie is sent to their system. They are then sent to a redirect screen while the cookie is verified. For some reason, the cookie is never verified and the user is told that their cookie has expired or doesn't exist and to check the settings on their browser. However, I can see the cookie on the local machine and the session key info it stores matches up with the info on the server.
This problem can be bypassed at the redirect screen by clicking a link that forces the redirect and modifies the cookie. After bypassing it this way, I can then log in and out normally without forcing the redirect.
Based on the error message generated, I've narrowed down the offending code to these lines:
$skey = $query->cookie(-name=>'skey');
unless ($skey) {
if ($query->referer =~ /login/) {
t_error("session_key_login");
}
else {
t_error("session_key_expired");
}
}
What I'm getting is the "session_key_expired" error, so the quey->cookie seems to be failing.
Has anyone here ever had a problem similar to this? I've replicated it on multplie platforms and browsers and the behavior is consistent. I'm beginning to reach my wits end.
The scripts are based of off CGI.pm, but I don't think that they use it directly. Whatever the case, whenever a user logs into a webpage their username and password are authenticated and a cookie is sent to their system. They are then sent to a redirect screen while the cookie is verified. For some reason, the cookie is never verified and the user is told that their cookie has expired or doesn't exist and to check the settings on their browser. However, I can see the cookie on the local machine and the session key info it stores matches up with the info on the server.
This problem can be bypassed at the redirect screen by clicking a link that forces the redirect and modifies the cookie. After bypassing it this way, I can then log in and out normally without forcing the redirect.
Based on the error message generated, I've narrowed down the offending code to these lines:
$skey = $query->cookie(-name=>'skey');
unless ($skey) {
if ($query->referer =~ /login/) {
t_error("session_key_login");
}
else {
t_error("session_key_expired");
}
}
What I'm getting is the "session_key_expired" error, so the quey->cookie seems to be failing.
Has anyone here ever had a problem similar to this? I've replicated it on multplie platforms and browsers and the behavior is consistent. I'm beginning to reach my wits end.