Always use '-t' mode for your cgi scripts, it instructs Perl to taint any outside input. Also remember, anything you put in a cookie is stored in plain text unless you encrypt it before you place it in the cookie.#!/usr/bin/perl -t use CGI; my $q = CGI->new; $session{"user_id"}=$userid; $session{"password"}=$passwd; $session{"timecode"}=$time; $cookie = $q->cookie(-name=>'sessionID', -value=>\%session, -expires=>'+6h', -secure=>0); print $q->redirect(-uri=>"index.cgi", -cookie=>$cookie);
In reply to Re: Cookies Tutorial
by K_M_McMahon
in thread Cookies Tutorial
by titanic_fanataic
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |