strangeworld-mirror/[1999-06-20 - 1999-07-12] REQUIEM (aka RECYCLE)/getlog.txt

304 lines
8.4 KiB
Plaintext
Raw Normal View History

new file: @hi-ho/bbs.cgi new file: @hi-ho/getlog.cgi new file: [1999-01-24 - 1999-04-09] REBIRTH (aka Haruna)/bbscgi.txt new file: [1999-01-24 - 1999-04-09] REBIRTH (aka Haruna)/getlogcgi.txt new file: [1999-01-24 - 1999-04-09] REBIRTH (aka Haruna)/locationcgi.txt new file: [1999-05-04 - present] REMIX/bbs.txt new file: [1999-05-04 - present] REMIX/getlog_m.txt new file: [1999-05-04 - present] REMIX/jcode.txt new file: [1999-05-04 - present] REMIX/location.txt new file: [1999-05-04 - present] REMIX/loveyou.dat new file: [1999-06-20 - 1999-07-12] REQUIEM (aka RECYCLE)/bbs.txt new file: [1999-06-20 - 1999-07-12] REQUIEM (aka RECYCLE)/count0.txt new file: [1999-06-20 - 1999-07-12] REQUIEM (aka RECYCLE)/delete.txt new file: [1999-06-20 - 1999-07-12] REQUIEM (aka RECYCLE)/getlog.txt new file: [1999-06-20 - 1999-07-12] REQUIEM (aka RECYCLE)/jcode.txt new file: [1999-06-20 - 1999-07-12] REQUIEM (aka RECYCLE)/location.txt new file: [1999-06-20 - 1999-07-12] REQUIEM (aka RECYCLE)/loveyou.dat new file: [1999-06-20 - 1999-07-12] REQUIEM (aka RECYCLE)/readme.html new file: [1999-06-20 - 1999-07-12] REQUIEM (aka RECYCLE)/update.html new file: [1999-11-03 - 2000-05-02] REFLEX (aka AGStar no Yabou)/bbs.cgi new file: [1999-11-03 - 2000-05-02] REFLEX (aka AGStar no Yabou)/getlog_m.cgi new file: [1999-11-03 - 2000-05-02] REFLEX (aka AGStar no Yabou)/jcode.pl new file: [1999-11-03 - 2000-05-02] REFLEX (aka AGStar no Yabou)/list.cgi new file: [1999-11-03 - 2000-05-02] REFLEX (aka AGStar no Yabou)/loveyou.dat new file: [1999-11-03 - 2000-05-02] REFLEX (aka AGStar no Yabou)/readme.txt new file: source.txt
2024-12-02 19:52:30 +00:00
#! /usr/local/bin/perl
#<23>͂<EFBFBD><CD82><EFBFBD><EFBFBD><EFBFBD>ӂ<EFBFBD><D382>݁[<5B><><EFBFBD>̃p<CC83>\<5C><><EFBFBD>^<5E><><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD>{<7B><><EFBFBD>ɂ<EFBFBD><C982><EFBFBD>Ƃ<EFBFBD>
#--------------------
$body = '<body bgcolor="#004040" text="#ffffff" link="#eeffee" vlink="#dddddd" alink="#ff0000">';
$bbstitle ="<22><><EFBFBD><EFBFBD><E282B5><EFBFBD><EFBFBD><EFBFBD>[<5B><><EFBFBD><EFBFBD>REQUIEM";
$logdir = './log/';
$cgiurl = 'getlog.cgi';
$action ='getlog';
$bbsurl = './bbs.cgi';
# <20><><EFBFBD>{<7B><><EFBFBD>R<EFBFBD>[<5B>h<EFBFBD>ϊ<EFBFBD><CF8A><EFBFBD><EFBFBD>C<EFBFBD>u<EFBFBD><75><EFBFBD><EFBFBD>jocde.pl<70>̃p<CC83>X
require './jcode.pl';
# <20>L<EFBFBD>[<5B><><EFBFBD>[<5B>h<EFBFBD>̍ő啶<C591><E595B6><EFBFBD><EFBFBD><EFBFBD>i<EFBFBD><69><EFBFBD>p<EFBFBD>j
$keylength = 64;
# <20><><EFBFBD><EFBFBD> <20>T<EFBFBD>[<5B>o<EFBFBD>̎<EFBFBD><CC8E>v<EFBFBD><76><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă鎞<C482><E98E9E><EFBFBD><EFBFBD><EFBFBD>{<7B><><EFBFBD>ԈȊO<C88A>ɂ<EFBFBD><C982><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ɏg<C98E><67>
$tim = 0;
$\ = "\n";
#--------------------
#if ($ENV{'REQUEST_METHOD'} eq "POST") { read(STDIN, $buffer, $ENV{'CONTENT_LENGTH'}); }
#else { $buffer = $ENV{'QUERY_STRING'}; }
$buffer = $ENV{'QUERY_STRING'};
@argv = split(/&/,$buffer);
foreach (@argv) {
($name, $value) = split(/=/);
$value =~ tr/+/ /;
$value =~ s/%([a-fA-F0-9][a-fA-F0-9])/pack("C", hex($1))/eg;
&jcode'convert(*value,'sjis');
$COMMAND{$name} = $value;
}
&error(2) if (length($COMMAND{'keyword'}) > $keylength);
&viewlog if ($COMMAND{'action'} eq "$action");
&list;
sub list {
&error(0) if(!opendir(DIR, $logdir));
@files=readdir(DIR);
closedir(DIR);
@files = sort by_number @files;
$end = @files;
$end--;
print "Content-type: text/html\n\n";
print "<html><head><title>$bbstitle <20>ߋ<EFBFBD><DF8B><EFBFBD><EFBFBD>O</title></head>\n";
print "<form method=get action=\"$cgiurl\">";
print "$body\n";
#&location;
print "<center><font size=+1><b>$bbstitle <20>ߋ<EFBFBD><DF8B><EFBFBD><EFBFBD>O<EFBFBD>ꗗ</b></font><br>\n";
print "<input type=hidden name=\"action\" value=\"$action\">";
print "<table>";
print "<tr><td></td><td><3E>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD></td><td align=right><3E>T<EFBFBD>C<EFBFBD>Y</td><td align=center><3E><><EFBFBD>t</td></tr>";
foreach (0 .. $end) {
if (!($files[$_] eq "." or $files[$_] eq "..")) {
($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime,$blksize,$blocks) = stat "$logdir$files[$_]";
($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = gmtime($mtime + 32400 + $tim);
$mon++;
$mon = "0$mon" if ($mon < 10);
if ($mday < 10) { $mday = "0$mday"; }
if ($min < 10) { $min = "0$min"; }
if ($hour < 10) { $hour = "0$hour"; }
$checked = ' checked' if ($_ == $end);
print "<tr><td><input type=\"radio\" name=\"logfile\" value=\"$files[$_]\"$checked></td>";
print "<td><a href=\"$logdir$files[$_]\">$files[$_]</a></td>";
print "<td align=right>$size</td><td align=center>$mon/$mday $hour:$min</td></tr>";
}
}
print "<tr><td></td></tr><tr><td colspan=4><3E><><EFBFBD><EFBFBD><EFBFBD>W<EFBFBD>I<EFBFBD>{<7B>^<5E><><EFBFBD>Ńt<C583>@<40>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>w<EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B</td></tr><tr><td></td></tr>\n";
print "<tr><td colspan=4><select name=\"hour1\">";
print "<option value=\"00\">0";
print "<option value=\"01\">1";
print "<option value=\"02\">2";
print "<option value=\"03\">3";
print "<option value=\"04\">4";
print "<option value=\"05\">5";
print "<option value=\"06\">6";
print "<option value=\"07\">7";
print "<option value=\"08\">8";
print "<option value=\"09\">9";
print "<option value=\"10\">10";
print "<option value=\"11\">11";
print "<option value=\"12\">12";
print "<option value=\"13\">13";
print "<option value=\"14\">14";
print "<option value=\"15\">15";
print "<option value=\"16\">16";
print "<option value=\"17\">17";
print "<option value=\"18\">18";
print "<option value=\"19\">19";
print "<option value=\"20\">20";
print "<option value=\"21\">21";
print "<option value=\"22\">22";
print "<option value=\"23\">23";
print "</select><3E><>";
print"<select name=\"min1\">";
print "<option value=\"00\">00";
print "<option value=\"05\">05";
print "<option value=\"10\">10";
print "<option value=\"15\">15";
print "<option value=\"20\">20";
print "<option value=\"25\">25";
print "<option value=\"30\">30";
print "<option value=\"35\">35";
print "<option value=\"40\">40";
print "<option value=\"45\">45";
print "<option value=\"50\">50";
print "<option value=\"55\">55";
print "</select><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>";
print "<select name=\"hour2\">";
print "<option value=\"24\">24";
print "<option value=\"00\">0";
print "<option value=\"01\">1";
print "<option value=\"02\">2";
print "<option value=\"03\">3";
print "<option value=\"04\">4";
print "<option value=\"05\">5";
print "<option value=\"06\">6";
print "<option value=\"07\">7";
print "<option value=\"08\">8";
print "<option value=\"09\">9";
print "<option value=\"10\">10";
print "<option value=\"11\">11";
print "<option value=\"12\">12";
print "<option value=\"13\">13";
print "<option value=\"14\">14";
print "<option value=\"15\">15";
print "<option value=\"16\">16";
print "<option value=\"17\">17";
print "<option value=\"18\">18";
print "<option value=\"19\">19";
print "<option value=\"20\">20";
print "<option value=\"21\">21";
print "<option value=\"22\">22";
print "<option value=\"23\">23";
print "</select><3E><>";
print"<select name=\"min2\">";
print "<option value=\"00\">00";
print "<option value=\"05\">05";
print "<option value=\"10\">10";
print "<option value=\"15\">15";
print "<option value=\"20\">20";
print "<option value=\"25\">25";
print "<option value=\"30\">30";
print "<option value=\"35\">35";
print "<option value=\"40\">40";
print "<option value=\"45\">45";
print "<option value=\"50\">50";
print "<option value=\"55\">55";
print "</select><3E><><EFBFBD>܂<EFBFBD>";
print "</td></tr><br>";
print " <tr><td colspan=4><3E><><EFBFBD><EFBFBD><EFBFBD>F";
print "<select name=\"searchmode\">";
print "<option value=\"keyword\"><3E>S<EFBFBD><53>";
print "<option value=\"name\"><3E><><EFBFBD>e<EFBFBD>Җ<EFBFBD>";
print "<option value=\"subject\"><3E>薼\n</select>";
print "<input type=text name=\"keyword\" size=\"24\" maxlength=$keylength></td></tr><tr><td colspan=4 align=center>";
print "<input type=submit value=\"Get / Search\"></form></td></tr>";
print "</table>";
print "<hr>";
#print "<22><><EFBFBD>݃x<DD83>[<5B>^<5E>e<EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>ł<EFBFBD><C582>B<EFBFBD>o<EFBFBD>O<EFBFBD><4F><EFBFBD><EFBFBD><EFBFBD>‚<EFBFBD><C282><EFBFBD><EFBFBD><EFBFBD><EFBFBD>f<EFBFBD><66><EFBFBD>‚ɏ<C282><C98F><EFBFBD><EFBFBD>Ă<EFBFBD>";
print "<p align=center><a href=\"$bbsurl\"><3E>f<EFBFBD><66><EFBFBD>‚<EFBFBD></a></p>";
print "<h4 align=right><a href=\"http://logshonin.virtualave.net/\">Getlog Ver0.3b4</a></h4>";
print "</body></html>";
}
sub viewlog {
if (!open(DB,"$logdir$COMMAND{'logfile'}")) { &error(1); }
@lines = <DB>;
close(DB);
$COMMAND{'last'} = $COMMAND{'first'} + 1 if ($COMMAND{'first'} >= $COMMAND{'last'});
$first = "$COMMAND{'hour1'}<7D><>$COMMAND{'min1'}<7D><>";
$last = "$COMMAND{'hour2'}<7D><>$COMMAND{'min2'}<7D><>";
if ($COMMAND{'searchmode'} eq 'name') { $keyword = "<22><><EFBFBD>e<EFBFBD>ҁF.*>${COMMAND{'keyword'}}<"; }
elsif ($COMMAND{'searchmode'} eq 'subject') { $keyword = "color=\"#ffffee\"><b>${COMMAND{'keyword'}}</b></font>"; }
else { $keyword = $COMMAND{'keyword'}; }
if ($keyword ne '') {
$keyword =~ s/\\/\\\\/;
$keyword =~ s/\[/\\[/;
}
print "Content-type: text/html\n";
print "<html><head><title>$bbstitle <20>ߋ<EFBFBD><DF8B><EFBFBD><EFBFBD>O $COMMAND{'logfile'}</title></head>";
print "$body";
print "<h1>$COMMAND{'logfile'} $first<73>`$last</h1>";
$end = @lines;
$end--;
foreach (0 .. $end) {
# MiniBBS7.5<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>[<5B><><EFBFBD>ǎd<C78E>l
if ($lines[$_] =~ /<font size=-1><3E>@<40><><EFBFBD>e<EFBFBD><65><EFBFBD>F/) {
$hour = substr( $lines[$_], 36, 8 );
# <09><><EFBFBD><EFBFBD><E282B5><EFBFBD><EFBFBD><EFBFBD>[<5B><><EFBFBD>ǁ<EFBFBD><C781>ӂ<EFBFBD><D382>݁[<5B><> <20>I<EFBFBD><49><EFBFBD>W<EFBFBD>i<EFBFBD><69><EFBFBD>f<EFBFBD><66><EFBFBD>ƒX<C283>N<EFBFBD><4E><EFBFBD>v<EFBFBD>g
# if ($lines[$_] =~ /<font size="-1"><3E>@<40><><EFBFBD>e<EFBFBD><65><EFBFBD>F/) {
# $hour = substr( $lines[$_], 40, 8 );
last if ($hour ge "$first");
}
$skip++;
}
$skip--;
#print"<hr>";
foreach ($skip .. $end) {
# MiniBBS7.5<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>[<5B><><EFBFBD>ǎd<C78E>l
if ($lines[$_] =~ /<font size=-1><3E>@<40><><EFBFBD>e<EFBFBD><65><EFBFBD>F/) {
$hour = substr( $lines[$_], 36, 8 );
# <09><><EFBFBD><EFBFBD><E282B5><EFBFBD><EFBFBD><EFBFBD>[<5B><><EFBFBD>ǁ<EFBFBD><C781>ӂ<EFBFBD><D382>݁[<5B><> <20>I<EFBFBD><49><EFBFBD>W<EFBFBD>i<EFBFBD><69><EFBFBD>f<EFBFBD><66><EFBFBD>ƒX<C283>N<EFBFBD><4E><EFBFBD>v<EFBFBD>g
# if ($lines[$_] =~ /<font size="-1"><3E>@<40><><EFBFBD>e<EFBFBD><65><EFBFBD>F/) {
# $hour = substr( $lines[$_], 40, 8 );
last if ($hour ge "$last");
}
if ($keyword ne '') {
if ($lines[$_] =~ /$keyword/) {
$flag = 1;
$hit++;
}
push( @article, $lines[$_] );
if ($lines[$_] =~ /<\/blockquote>/) {
print @article if ($flag > 0);
splice( @article, 0 );
$flag = 0;
}
}
else { print $lines[$_]; }
}
if ($COMMAND{'keyword'} ne '') {
print "<hr>";
if ( $hit > 0 ) { print "<h3><3E>u$COMMAND{'keyword'}<7D>v<EFBFBD><76> $hit<69><74><EFBFBD><EFBFBD><EFBFBD>‚<EFBFBD><C282><EFBFBD><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B</h3>"; }
else { print "<h3><3E>u$COMMAND{'keyword'}<7D>v<EFBFBD>͌<EFBFBD><CD8C>‚<EFBFBD><C282><EFBFBD><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>ł<EFBFBD><C582><EFBFBD><EFBFBD>B</h3>"; }
}
print "</body></html>";
exit;
}
sub error {
$error = $_[0];
if ($error == 0) { $errmsg = '<27>f<EFBFBD>B<EFBFBD><42><EFBFBD>N<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD>J<EFBFBD><4A><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>ł<EFBFBD><C582><EFBFBD><EFBFBD>B'; }
if ($error == 1) { $errmsg = '<27>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD>J<EFBFBD><4A><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>ł<EFBFBD><C582><EFBFBD><EFBFBD>B'; }
if ($error == 2) { $errmsg = '<27>L<EFBFBD>[<5B><><EFBFBD>[<5B>h<EFBFBD><68><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B'; }
print "Content-type: text/html\n";
print "<html><head><title><3E>G<EFBFBD><47><EFBFBD>[</title></head>";
print "$body";
print "<h1>$errmsg</h1>";
print "</body></html>";
exit;
}
sub by_number {
$a <=> $b;
}
sub location {
print <<"EOF";
<center>
<font size=+1><b>$bbstitle <20>ߋ<EFBFBD><DF8B><EFBFBD><EFBFBD>O<EFBFBD>ꗗ</b></font>
EOF
}