Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

ip_match doesn't seem to work

by mwhiting (Beadle)
on Feb 27, 2015 at 15:54 UTC ( [id://1118086]=perlquestion: print w/replies, xml ) Need Help??

mwhiting has asked for the wisdom of the Perl Monks concerning the following question:

This is something of a ressurection of a question from this past month.

I am using Session Id's and have started trying to use -ip_match so that you can't cut and paste an url with the session id embedded in it from one computer to the next. But since I have added -ip_match I don't get any different results when accessing the same script from computers with different IP's. I modified my Use statement to be:

use CGI::Session qw/-ip-match/;

instead of my usual use cgi::Session; line. I also tried adding

$session::IP_MATCH = 1;

to the mix, after the creation of the session object, and still I see no difference in the results on browsers with different ip's. The different computers still access the session info just fine and pass the authentication using info in the session variable.

What am I missing here in the use of -ip_match ? Your help would be greatly appreciated!   :)

Replies are listed 'Best First'.
Re: ip_match doesn't seem to work
by toolic (Bishop) on Feb 27, 2015 at 16:11 UTC
    use CGI::Session qw/-ip-match/;
    Change the 2nd dash to an underscore:
    use CGI::Session qw/-ip_match/;
Re: ip_match doesn't seem to work
by Anonymous Monk on Feb 28, 2015 at 00:16 UTC
    copy/paste is your friend :) whether you're doing it from the docs or from the nodes
Re: ip_match doesn't seem to work
by mwhiting (Beadle) on Mar 02, 2015 at 16:16 UTC

    OK - my silly mistake! I usually cut and paste. :) Thanks for pointing that out, nothing like another pair of eyes to fix a problem!

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: perlquestion [id://1118086]
Front-paged by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (10)
As of 2024-04-23 08:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found