Skip Menu |

This queue is for tickets about the CGI-Application-Plugin-Authentication CPAN distribution.

Report information
The Basics
Id: 19998
Status: rejected
Priority: 0/
Queue: CGI-Application-Plugin-Authentication

People
Owner: Nobody in particular
Requestors: epratomo [...] acm.org
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in:
  • 0.09
  • 0.10
Fixed in: (no value)



Subject: Store::Session problem
Hi, Data saved through $session->save() is not flushed to session files. This makes successful login always goes back to the login page. Err.. not always, sometimes the session files get synced. this behaviour is a bit random. My proposed fix is to add $session->flush just before return 1 in sub save in CGI::Application::Plugin::Authentication::Store::Session. Tested with CAP::Authentication version 0.09 and 0.10 # perl -v This is perl, v5.8.0 built for i386-linux-thread-multi (with 1 registered patch, see perl -V for more detail) That's the perl rpm from RedHat 9. # rpm -qf `which perl` perl-5.8.0-88.3
I use the Session store in my applications, and I never seem to run into the flushing problems that others have been seeing with newer versions of CGI::Session. I am hesitant to add this because it could cause a lot more load on the application (ie the session could be flushed multiple times). This is really a problem with either CGI::Session, or your code. CGI::Session is supposed to flush the session automatically when the object goes out of scope. I would rather that you add an explicit flush in your own code to compensate for this problem that you are seeing. It would be as simple as this: sub teardown { my $self = shift; $self->session->flush; } Cheers, Cees