Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^2: how do I force a specific session, not my own, to end?

by Anonymous Monk
on Mar 08, 2013 at 20:39 UTC ( #1022487=note: print w/ replies, xml ) Need Help??


in reply to Re: how do I force a specific session, not my own, to end?
in thread how do I force a specific session, not my own, to end?

:) hurricane

sub ban_user { my $banneduser = shift; my $purge = sub { my( $session ) = @_; next if $session->is_empty; # <-- already expired?! if ( ($session->param('user_id') eq $bad_user_id) ) { $session->delete(); $session->flush(); } }; DeAuthorize( $banneduser ); CGI::Session->find( $dsn, $purge, $dsn_args ); }


Comment on Re^2: how do I force a specific session, not my own, to end?
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1022487]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (6)
As of 2015-07-29 23:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (269 votes), past polls