5.39 code:
sub OpenThread {
my $ThreadFile = shift;
@forumfacts = &GetForumRecord($number);
$ThisRestrict = $forumfacts[6];
$ThisPassword = &decodeURL($forumfacts[7]);
if ($ThisRestrict eq "private") {
$ExactPath = "Forum$number/private-$ThisPassword";
} else {
$ExactPath = "Forum$number";
}
if ($ThreadFile =~ /^dddddd.cgi$/) {
open (MESSAGE, "$ForumsPath/$ExactPath/$ThreadFile");
my @mess =
;
close (MESSAGE);
my @threadguts = sort(@mess);
return(@threadguts);
********************************
New code(pre-hack):
sub OpenThread {
my $ThreadFile = shift;
@forumfacts = &GetForumRecord($number);
$ThisRestrict = $forumfacts[6];
$ThisPassword = &decodeURL($forumfacts[7]);
if ($ThisRestrict eq "private") {
$ExactPath = "Forum$number/private-$ThisPassword";
} else {
$ExactPath = "Forum$number";
}
if ( ($ThreadFile =~ /^d{6}.(cgi|ubb)$/) || ($ThreadFile =~ /^d{6}-d{6}-d{6}-d{6}.(n|m|msg|nmsg)$/) ) {
open (MESSAGE, "$ForumsPath/$ExactPath/$ThreadFile");
my @mess = ;
close (MESSAGE);
my @threadguts = sort(@mess);
return(@threadguts);