Hi,
I an very new to CGI and want to know how to make the
CGI(with perl) pages presently working on http work on
https.

I have the following webpage Logout.cgi.

#!/opt/plat/bin/perl

use strict;
use Time::localtime;
use CGI;
use CGI::Carp 'fatalsToBrowser';
use lib "/opt/appl/web/cgi-bin";
use GS;
use Funct;

my $input = new CGI;
my $gs = GS->new();

print $input->header;

use Session;
my $sess = Session->new();
my $sessCookie = $input->cookie('session');
my $userId = undef;
my $sessId = undef;
if (defined $sessCookie)
{
  ($userId, $sessId) =
$sess->validateSession($sessCookie);
}

if ((not defined $userId) or (not defined $sessId))
{
  &Func::DisplayAccessDeniedPage();
  exit;
}

if (not defined $input->param)
{
  print "<html>\n<head><title>Logout</title><link
rel='stylesheet' type='text/css'
href='/style/WorkSpace.css'></head>";
  print "\n<body>";

  &Funct::DisplayHeader("Logout");
  &Func::BeginContentTable();

  Func::DisplayInfoMessage("This will terminate your
login session, Are you sure you want to continue?");

  print " <br> <center><form action='logout.cgi'
METHOD=post TARGET=_top>   <input name=logout
TYPE=submit VALUE=Logout> </form></center>";

  Func::EndContentTable();
  Func::DisplayFooter();
}
else
{
  $sess->deleteSession($userId, $sessId);

  print "<html><title>Link to login screen</title>
<body onload=deleteCookie('session')><meta
http-equiv=\"refresh\" content=\"0;
URL=/cgi-in/logon.cgi\">
<script language=javascript src='/js/Validation.js'
type='text/javascript'></script> </body> </html>";
}

print $input->end_html();


Presently the above script works fine for http, when I
invoke by http://<ip address>/logout.cgi. I want to
know if any changes has to be made to the above script
to make it work with https i.e by https://<ip
address>/logout.cgi.

Also want to know if any configuration changes need to
be made in the apache web server.

Thanks in advance

Regards
Krishna

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>


Reply via email to