2ch-master-mirror/bbs-entry.cgi

3455 lines
103 KiB
Plaintext
Raw Permalink Normal View History

use strict 'vars';
use File::stat;
use POSIX qw(:errno_h strftime);
use BBSD;
#########################################################
sub bbs_entry
{
use vars qw($BBSCGI) ; #<23>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>[
$BBSCGI = '2010/10/28' ; #<23>ŏI<C58F>X<EFBFBD>V<EFBFBD><56>
use vars qw($FOX) ; #<23>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>[
use vars qw(@FOX_K998) ; #<23>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>[ <20>Kc<4B><63><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>g(<28><>)
use vars qw(@FOX_K999) ; #<23>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>[ <20>K<EFBFBD><4B><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>g(ISP)
use vars qw(@FOX_Ro54) ; #<23>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>[ <20>K<EFBFBD><4B><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>g(Rock54)
use vars qw(@FOX_KABUU) ; #<23>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>[ <20><><EFBFBD>ʊ<EFBFBD><CA8A><EFBFBD><EFBFBD>D<EFBFBD>Җ<EFBFBD><D296><EFBFBD><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>g
use vars qw(@FOX_774) ; #<23>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>[ <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>g(vip)
#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>b<EFBFBD>N<EFBFBD>A<EFBFBD>b<EFBFBD>v
use vars qw(%FOX_KEN_ASAHI) ; #<23>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>[ asahi-net
use vars qw(%FOX_KEN_DION) ; #<23>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>[ dion
# <20>ŏ<EFBFBD><C58F><EFBFBD>umask(0)<29><><EFBFBD><EFBFBD><E98CBE><EFBFBD>Ă<EFBFBD><C482><EFBFBD>(<28>Ō<EFBFBD><C58C>܂ŗL<C597><4C>)
umask(0);
unless(defined($FOX))
{
# $FOX = 20 ;
$FOX = {} ;
@FOX_K998 = () ;
@FOX_K999 = () ;
@FOX_Ro54 = () ;
&initFOX ; #<23>L<EFBFBD><4C><EFBFBD>֌W<D68C>͍ŏ<CD8D><C58F>Ɉ<EFBFBD><C988><EFBFBD><EFBFBD>ǂݍ<C782><DD8D><EFBFBD><EFBFBD>ŁA
srand(time) ; #<23><><EFBFBD><EFBFBD>
@FOX_KABUU = () ;
&readKABUU() ;
}
&bbs_entryXXX ;
}
#############################################################################
#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>?
#############################################################################
sub IsSenmon
{
my ($GB) = @_ ;
if($ENV{'SERVER_NAME'} !~ /2ch.net/) {return 1;}
if($ENV{SERVER_NAME} =~ /hayabusa/) {return 0;}
if($GB->{FORM}->{bbs} =~ /plus$/) {return 0;}
if($GB->{FORM}->{bbs} =~ /saloon$/) {return 0;}
if($GB->{FORM}->{bbs} =~ /anime/) {return 0;}
if($GB->{FORM}->{bbs} eq 'morningcoffee') {return 0;}
if($GB->{FORM}->{bbs} eq 'news') {return 0;}
if($GB->{FORM}->{bbs} eq 'anime4vip') {return 0;}
if($GB->{FORM}->{bbs} eq 'news4vip') {return 0;}
if($GB->{FORM}->{bbs} eq 'news4viptasu') {return 0;}
if($GB->{FORM}->{bbs} eq 'campus') {return 0;}
if($GB->{FORM}->{bbs} eq 'ghard') {return 0;}
if($GB->{FORM}->{bbs} eq 'poverty') {return 0;}
if($GB->{FORM}->{bbs} eq 'wcomic') {return 0;}
if($GB->{FORM}->{bbs} eq 'soccer') {return 0;}
if($GB->{FORM}->{bbs} eq 'ms') {return 0;}
if($GB->{FORM}->{bbs} eq 'campus') {return 0;}
if($GB->{FORM}->{bbs} eq 'streaming') {return 0;}
if($GB->{FORM}->{bbs} eq 'mmo') {return 0;}
if($GB->{FORM}->{bbs} eq 'slot') {return 0;}
if($GB->{FORM}->{bbs} eq 'comic') {return 0;}
if($GB->{FORM}->{bbs} eq 'skate') {return 0;}
if($GB->{FORM}->{bbs} eq 'keiba') {return 0;}
if($GB->{FORM}->{bbs} eq 'giin') {return 0;}
if($GB->{FORM}->{bbs} eq 'seiji') {return 0;}
if($GB->{FORM}->{bbs} eq 'famicom') {return 0;}
if($GB->{FORM}->{bbs} eq 'shar') {return 0;}
if($GB->{FORM}->{bbs} eq 'mog2') {return 0;}
if($GB->{FORM}->{bbs} eq 'download') {return 0;}
if($GB->{FORM}->{bbs} eq 'livemarket2') {return 0;}
if($GB->{FORM}->{bbs} eq 'livemarket1') {return 0;}
if($GB->{FORM}->{bbs} eq 'base') {return 0;}
return 1 ;
}
#############################################################################
# IPv6<76>ڑ<EFBFBD><DA91><EFBFBD><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD><EFBFBD><EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD>
# <20>͂<EFBFBD><CD82>߂̂ق<CC82><D982>Ŏg<C58E><67><EFBFBD>̂ŁAbbs-entry.cgi <20>ɓ<EFBFBD><C993><EFBFBD><EFBFBD><EFBFBD>Ƃɂ<C682><C982><EFBFBD>
# $GB<47>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɌĂ΂<C482><CE82><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD>͂Ȃ<CD82>
#############################################################################
sub IsIPv6
{
my $saddr = $ENV{'SERVER_ADDR'};
use Net::IP qw(:PROC);
return ip_is_ipv6($saddr);
}
#########################################################
#
#########################################################
sub foxSamba24Init
{
my ($ita) = @_ ;
$FOX->{BOOK} = "." ;
if(-e "/md/tmp/book") {$FOX->{BOOK} = "/md/tmp" ;}
$FOX->{SambaOffset_KEITAI} = 10 ;
$FOX->{SambaOffset_P22CH} = 10 ;
# if($FOX->{$ita}->{"BBS_BE_TYPE2"}) {return 120;}
if($ita eq 'newsplus') {return 128;}
#return 10 ;
if($ita eq 'liveplus') {return 20;}
if($ita =~ /ogame/) {return 20;}
if($ita =~ /bgame/) {return 60;}
if($ita eq 'news') {return 20;}
if($ENV{SERVER_NAME} =~ /hayabusa/) {return 20;}
if($ENV{SERVER_NAME} !~ /2ch\.net/ && $ENV{SERVER_NAME} !~ /bbspink\.com/) { return 600; }
if($ENV{SERVER_NAME} =~ /bbspink\.com/) {return 20;}
return 40 ;
}
#######################################################################
#
#######################################################################
sub foxViva
{
my ($GB, $tane) = @_ ;
my $Samba = "VivaSamba24" ;
my $span = 180 ; #<23>K<EFBFBD><4B><EFBFBD>b<EFBFBD><62>
$tane =~ s/\./-/g;
$tane =~ s/\//~/g;
my $sFile = "$FOX->{BOOK}/book/$tane.cgi";
my $remo = $GB->{HOST29} ; #<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E9838A><EFBFBD>z
my $ipip = $ENV{REMOTE_ADDR} ;
my $isViva ;
# <20>g<EFBFBD>т͂<D182><CD82><EFBFBD><EFBFBD>[
if($GB->{KEITAI}) {return 0;}
# <20><EFBFBD><E182BE><EFBFBD>܂ł́A<CD81>ǂ<EFBFBD><C782><EFBFBD><ED82A9><EFBFBD>Ȃ<EFBFBD><C882>̂ō<CC82><C58D>̂Ƃ<CC82><C682><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>A<EFBFBD><41><EFBFBD>̌<EFBFBD><CC8C><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EB82B5>
# <20>@<40>@<40><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82><EFBFBD>
if(IsSnowmanServer)
{
my $errmsg = bbsd_db($GB->{FORM}{bbs}, 'chkid', 'vivaSamba', $tane, $span, 0xFFFF, 0xFFFF, 'dummy');
if (&bbsd_TimeoutCheck($GB, $errmsg)) {return 0;}
if ((split /,/, $errmsg)[0])
{
$errmsg = bbsd_db($GB->{FORM}{bbs}, 'peekid', 'vivaSambaIP', "$tane:$ipip", $span, 0xFFFF, 0xFFFF, 'dummy');
if (&bbsd_TimeoutCheck($GB, $errmsg)) {return 0;}
if (!(split /,/, $errmsg)[0]) {$isViva = 1;}
}
if (!$isViva)
{
bbsd_db($GB->{FORM}{bbs}, 'chkid', 'vivaSambaIP', "$tane:$ipip", $span, 0xFFFF, 0xFFFF, 'dummy');
}
}
else
{
if(-e $sFile)
{
my ($prsize, $prmtime) = (local $_=stat($sFile)) ? ($_->size, $_->mtime) : (0, 0);
my $ctime = time;
my $keika = $ctime - $prmtime;
#$GB->{FORM}->{'MESSAGE'} .= "<hr><3E><><EFBFBD><EFBFBD><EFBFBD>ڈȍ~<7E>A<EFBFBD>@<40><>=$ipip ";
if(open(SMB,"$sFile"))
{
my @mdx = <SMB> ;
close(SMB) ;
#$GB->{FORM}->{'MESSAGE'} .= "<22>O=$mdx[0] $keika sec<65>o<EFBFBD><6F><br>";
if($ipip ne $mdx[0] && $keika < $span) {$isViva = 1;}
}
}
if(!$isViva && open(LOG,"> $sFile")) {print LOG "$ipip";close(LOG) ;}
}
if($isViva)
{
print "Content-type: text/html; charset=shift_jis\n\n";
print <<EOF;
<html><head><title><3E>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I</title><meta http-equiv="Content-Type" content="text/html; charset=shift_jis"></head>
<body><!-- 2ch_X:error -->
<EFBFBD>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q - Viva Samba <20>J<EFBFBD>[<5B>j<EFBFBD>o<EFBFBD><6F> !<br>
<br>
<EFBFBD>Ƃ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><EFBFBD>B<br><br>
<br><hr><font color=green>FOX <20><></font></body>
</html>
EOF
exit;
}
return 0;
}
#################################################################################################
# <09>g<EFBFBD><67><EFBFBD>b<EFBFBD>N<EFBFBD>o<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>M
#################################################################################################
sub foxTrackBackIn
{
my ($GB) = @_ ;
if(!$ENV{PATH_INFO}) {return 0;} #PATH_INFO<46><4F><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD>TBACK<43><4B><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD>
if($ENV{REQUEST_METHOD} ne 'POST') {return 0;} #POST<53>̂ݎ󂯓<DD8E><F382AF93><EFBFBD>
use CGI ;
my $cgi = new CGI ;
my $ver = "0.11" ;
my $refer = $ENV{HTTP_REFERER} ;
my $who = $cgi->param('who') ;
my $mac = $cgi->param('themacallan') ;
my $raddr = $who || $ENV{REMOTE_ADDR} ;
#$ENV{'REMOTE_ADDR'}<>$GB->{MARU}<>$ENV{'HTTP_USER_AGENT'}
#my $rhost = gethostbyaddr(pack('C4',split(/\./, $raddr)), 2) || $raddr;
if($refer =~ m#^http://(?:[-\w]+\.)?(?:2ch\.net|bbspink\.com)/#)
{
if($who eq '') {&TBackEnd("<22><><EFBFBD>M<EFBFBD><4D><EFBFBD>s<EFBFBD><73>");}
if($mac ne "18") {&TBackEnd("<22><><EFBFBD>݂<EFBFBD><DD82><EFBFBD>");}
$ENV{'REMOTE_ADDR'} = $raddr ;
$ENV{'HTTP_USER_AGENT'} = $cgi->param('ua');
$GB->{FORM}->{sid} = $cgi->param('mm');
}
my ($d0,$bbs,$key,$d3) = split(/\//,$ENV{PATH_INFO}) ;
if($bbs eq '') {&TBackEnd("<22>–<EFBFBD><C296>Ȃ<EFBFBD>");}
if($bbs =~ /\W/) {&TBackEnd("<22>–<EFBFBD><C296><EFBFBD><EFBFBD><EFBFBD>");}
if($bbs eq 'sec2ch') {&TBackEnd("<22><><EFBFBD>̔‚͎󂯕t<F382AF95><74><EFBFBD>Ȃ<EFBFBD>");}
if($bbs eq 'saku') {&TBackEnd("<22><><EFBFBD>̔‚͎󂯕t<F382AF95><74><EFBFBD>Ȃ<EFBFBD>");}
if($bbs eq 'saku2ch') {&TBackEnd("<22><><EFBFBD>̔‚͎󂯕t<F382AF95><74><EFBFBD>Ȃ<EFBFBD>");}
if($bbs eq 'news4vip') {&TBackEnd("<22><><EFBFBD>̔‚͎󂯕t<F382AF95><74><EFBFBD>Ȃ<EFBFBD>");}
if($bbs eq 'maru') {&TBackEnd("<22><><EFBFBD>̔‚͎󂯕t<F382AF95><74><EFBFBD>Ȃ<EFBFBD>");}
if($key eq '') {&TBackEnd("key<65>Ȃ<EFBFBD>");}
if($key =~ /\D/) {&TBackEnd("key<65><79><EFBFBD><EFBFBD>");}
# 924 <20>̓g<CD83><67><EFBFBD>b<EFBFBD>N<EFBFBD>o<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>M<EFBFBD><4D><EFBFBD><EFBFBD>(<28>ɂ<EFBFBD><C982>Ȃ<EFBFBD><C882>Ă<EFBFBD><C482>Ƃ肠<C682><E882A0><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ł͖<C582><CD96><EFBFBD><EFBFBD>Ȃ<EFBFBD>)
#if($key =~ /^924/) {&TBackEnd("key<65><79><EFBFBD><EFBFBD>");}
my $url = $cgi->param('url') ;
#$url =~ tr/+/ / ;
$url =~ tr/\t/ / ;
$url =~ s/\r\n?|\n/<br>/g ;
# \x00 <20><> [[:cntrl:]]
$url =~ s/[[:cntrl:]]//g ;
if($url eq '') {&TBackgoThre("http://$ENV{SERVER_NAME}/test/read.cgi/$bbs/$key/l50");}
if($url !~ /^http\:\/\//) {&TBackgoThre("http://$ENV{SERVER_NAME}/test/read.cgi/$bbs/$key/l50");}
if($url =~ /\|| /) {&TBackgoThre("http://$ENV{SERVER_NAME}/test/read.cgi/$bbs/$key/l50");}
if($url =~ /<|>/) {&TBackgoThre("http://$ENV{SERVER_NAME}/test/read.cgi/$bbs/$key/l50");}
if($url =~ /<2F>@/) {&TBackgoThre("http://$ENV{SERVER_NAME}/test/read.cgi/$bbs/$key/l50");}
if(!TBackgoodUrl($url)) {&TBackgoThre("http://$ENV{SERVER_NAME}/test/read.cgi/$bbs/$key/l50");}
my $ttl = $cgi->param('title') ;
my $bnm = $cgi->param('blog_name') ;
my $exc = $cgi->param('excerpt') ;
# $exc = substr($exc, 0, 200) ;
if(!($refer =~ m#^http://(?:[-\w]+\.)?(?:2ch\.net|bbspink\.com)/#))
{
use Jcode ;
$ttl = Jcode::convert( $ttl, 'sjis' ) ;
$bnm = Jcode::convert( $bnm, 'sjis' ) ;
$exc = Jcode::convert( $exc, 'sjis' ) ;
}
# \r <20><><EFBFBD>J<EFBFBD>b<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD>K<EFBFBD>v<EFBFBD><76><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃɒ<C682><C992><EFBFBD>
foreach ($ttl, $bnm, $exc) {
# s/"/&quot;/g;
s/</&lt;/g;
s/>/&gt;/g;
tr/\t/ /;
# [\x00\n\r] <20><> [[:cntrl:]]
s/[[:cntrl:]]//g;
}
$exc =~ s/&lt;br&gt;/<br>/g;
my $tb = "<22>y<EFBFBD>g<EFBFBD><67><EFBFBD>b<EFBFBD>N<EFBFBD>o<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>z (ver. $ver) <br>" ;
if($ttl) {$tb .= "[<5B>^<5E>C<EFBFBD>g<EFBFBD><67>] $ttl <br>";}
if($bnm) {$tb .= "[<5B><><EFBFBD>u<EFBFBD><75><EFBFBD>O] $bnm <br>";}
$tb .= "$url<br>" ;
# if($refer) {$tb .= "( ref= $refer ) <br><br>";}
if($exc) {$tb .= "[<5B><><EFBFBD>v<EFBFBD><76><EFBFBD><EFBFBD>]<br>$exc <br><br> ";}
$GB->{FORM}->{'FROM'} = "TBACK <20><>" ;
$GB->{FORM}->{'mail'} = "sage" ;
$GB->{FORM}->{'MESSAGE'} = $tb ;
$GB->{FORM}->{'subject'} = "" ;
$GB->{FORM}->{'time'} = $GB->{NOWTIME} - 100;
$GB->{FORM}->{'bbs'} = $bbs ;
$GB->{FORM}->{'key'} = $key ;
$GB->{TBACK} = 1 ; # 1=TrackBack 0=<3D>ʏ<CA8F><ED8F88>
$GB->{CAP} = 1 ; # <20>g<EFBFBD><67><EFBFBD>b<EFBFBD>N<EFBFBD>o<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD><EFBFBD>O<EFBFBD>̍Ōオ<C58C><E382AA>
#&DispError2($GB,"FOX <20><>","<font color=green>FOX <20><></font>TBACK(201)<br><br>r=$raddr<br>r=$refer<br>");
return $raddr ;
}
##############################################################################
sub TBackgoodUrl
{
my $x = $_[0] ;
if($x =~ /unko\.2ch\.net/) {return 0;}
if($x =~ /ezbbs\.net\/01\/sample0/) {return 0;}
if($x =~ /news4vip/) {return 0;}
$x =~ /^http\:\/\/([\w|\:\!\#\$\%\=\&\-\^\`\\\|\@\~\[\{\]\}\;\+\*\,\.\?]+)\/([\w|\:\!\#\$\%\=\&\-\^\`\\\|\@\~\[\{\]\}\;\+\*\,\.\?\/]+)/ ;
my $u = $1 ;
my $v = $2 ;
if($u eq '') {return 0;}
if($v eq '') {return 0;}
if($u eq /ime.st$/) {return 0;}
if($u eq /ime.nu$/) {return 0;}
if($u eq /pinktower.com$/) {return 0;}
if($u =~ /\.2ch.net/) {return 1;}
if($u =~ /\.bbspink.com/) {return 1;}
if($u =~ /\.ddo.jp/) {return 1;}
if($u =~ /\.goo.ne.jp/) {return 1;}
if($u =~ /\.hatena.ne.jp/) {return 1;}
if($u =~ /\.livedoor.com/) {return 1;}
if($u =~ /\.livedoor.jp/) {return 1;}
if($u =~ /\.yahoo.co.jp/) {return 1;}
if($u =~ /\.cocolog-nifty.com/) {return 1;}
if($u =~ /yaplog.jp/) {return 1;}
if($u =~ /jugem.jp/) {return 1;}
if($u =~ /blogzine.jp/) {return 1;}
if($u =~ /\.kakiko.com/) {return 1;}
if($ENV{SERVER_NAME} =~ /qb6/) {return 1;}
return 0 ;
use LWP::UserAgent;
my $ua = LWP::UserAgent->new();
$ua->timeout(3);
my $request = HTTP::Request->new('GET', $x);
my $response = $ua->request($request) ;
my $response_body = $response->content();
my $response_code = $response->code();
my $db_content = $response->content();
if($response_code > 300) {return 0;}
return 0 ;
}
##############################################################################
sub TBackEnd
{
#&TBackerrEnd;
print "Content-type: text/html; charset=shift_jis\n\n";
print "<HTML lang=\"ja\">" ;
print "<HEAD>\n" ;
print "<META http-equiv=\"Content-Type\" content=\"text/html; charset=Shift_JIS\">\n";
print "</HEAD>\n" ;
print "<BODY>\n" ;
print "tb.cgi-----------<br>\n" ;
print "| $_[0]<br>\n" ;
print "tb.cgi-----------<br>\n" ;
print "<br><br><br><hr>\n";
print "PATH_INFO=[$ENV{PATH_INFO}]<br>\n" ;
print "</BODY>\n";
print "</HTML>\n";
exit;
}
##############################################################################
sub TBackgoThre
{
my $ttt = $_[0];
print "Content-type: text/html; charset=shift_jis\n\n";
print <<EOF;
<HTML lang="ja">
<HEAD>
<META http-equiv="Content-Type" content="text/html; charset=Shift_JIS">
<title><3E>g<EFBFBD><67><EFBFBD>b<EFBFBD>N<EFBFBD>o<EFBFBD>b<EFBFBD>N@<40>Q<EFBFBD><51><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˂<EFBFBD></title>
<META content=10;URL="$ttt" http-equiv=refresh>
</HEAD>
<BODY>
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
<a href="$ttt">$ttt</a>
</BODY>
</HTML>
EOF
exit;
}
##############################################################################
sub TBacksuperEnd
{
print "Content-type: text/xml\n\n" ;
print <<EOF;
<?xml version="1.0" encoding="utf-8"?>
<response>
<error>0</error>
</response>
EOF
exit;
}
##############################################################################
sub TBackerrEnd
{
print "Content-type: text/xml\n\n" ;
print <<EOF;
<?xml version="1.0" encoding="utf-8"?>
<response>
<error>1</error>
</response>
EOF
exit;
}
#################################################################################################
# <09>g<EFBFBD><67><EFBFBD>b<EFBFBD>N<EFBFBD>o<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>M
#################################################################################################
sub foxTrackBack
{
my ($GB) = @_ ;
# 924 <20>̓g<CD83><67><EFBFBD>b<EFBFBD>N<EFBFBD>o<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>M<EFBFBD><4D><EFBFBD><EFBFBD>(<28>ɂ͂Ƃ肠<C682><E882A0><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>ł<EFBFBD><C582><EFBFBD><EFBFBD><EFBFBD>)
#if($GB->{FORM}->{'key'} =~ /^924/) {return 0;}
if($GB->{TBACK}) {return 0;}
if($GB->{FORM}->{bbs} eq 'news4vip') {return 0;}
if($GB->{FORM}->{'MESSAGE'} !~ /<2F>g<EFBFBD><67><EFBFBD>b<EFBFBD>N<EFBFBD>o<EFBFBD>b<EFBFBD>N:http\:\/\/([\w|\:\!\#\$\%\=\&\-\^\`\\\|\@\~\[\{\]\}\;\+\*\,\.\?\/]+)/) {return 0;}
my $target = "http://$1" ;
if($target =~ /\.2ch\.net|\.bbspink\.com|\.kakiko\.com/)
{$target =~ s/read\.cgi/bbs\.cgi/;}
my $url = "http://$ENV{SERVER_NAME}/test/read.cgi/$GB->{FORM}->{bbs}/$GB->{FORM}->{'key'}/l50" ;
if($target =~ /$GB->{FORM}->{bbs}/ && $target =~ /$GB->{FORM}->{'key'}/)
{&DispError2($GB,"<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I","<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>F<EFBFBD><46><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD><58><EFBFBD>b<EFBFBD>h<EFBFBD>ɂ̓g<CD83><67><EFBFBD>b<EFBFBD>N<EFBFBD>o<EFBFBD>b<EFBFBD>N<EFBFBD>ł<EFBFBD><C582>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B");}
my $dattemp = "";
my $firstlog = "";
if(IsSnowmanServer == BBSD->{REMOTE})
{
# <20><EFBFBD><E182BE><EFBFBD>܂ł́AHTTP<54>o<EFBFBD>R<EFBFBD>œ<EFBFBD><C593><EFBFBD><E882B7>
use LWP::UserAgent;
my $ua = LWP::UserAgent->new(agent => 'bbs.cgi', timeout => 3, max_redirect => 0);
my $res = $ua->get("http://127.0.0.1/$GB->{FORM}{bbs}/dat/$GB->{FORM}{key}.dat", Host => $ENV{SERVER_NAME});
if ($res->is_error)
{
&DispError2($GB, '<27>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I', '<27>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>F>>1<>̎擾<CC8E>Ɏ<EFBFBD><C98E>s<EFBFBD><73><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B');
}
$firstlog = (split(/\n/, $res->content, 2))[0];
}
else
{
# <20>ʏ<EFBFBD><CA8F>T<EFBFBD>[<5B>o<EFBFBD>ł́A<CD81><41><EFBFBD><EFBFBD>dat<61><74><EFBFBD>ǂ<EFBFBD>
$dattemp = $GB->{DATPATH} . $GB->{FORM}->{'key'} . ".dat";
open(RDAT, $dattemp) ;
$firstlog = <RDAT> ;
close(RDAT) ;
chomp($firstlog) ;
}
my ($name,$mail,$time,$message,$subject) = split(/<>/,$firstlog);
use LWP::UserAgent;
use HTTP::Request::Common qw(POST);
my %formdata;
$formdata{'title'} = $subject;
$formdata{'excerpt'} = $message;
$formdata{'url'} = $url;
$formdata{'blog_name'} = $FOX->{$GB->{FORM}->{bbs}}->{BBS_TITLE};
if($target =~ /\.2ch\.net|\.bbspink\.com/)
{
$formdata{'who'} = $ENV{REMOTE_ADDR};
$formdata{'themacallan'} = "18";
$formdata{'mm'} = $GB->{FORM}->{sid} ;
$formdata{'ua'} = $ENV{'HTTP_USER_AGENT'} ;
}
my $request = POST "$target" , \%formdata;
$request->referer($url);
my $ua = LWP::UserAgent->new() ;
$ua->agent('TrackBack/1.0');
$ua->parse_head(0);
$ua->timeout(3) ;
my $response = $ua->request($request);
my $response_body = $response->content() ;#<23><><EFBFBD>ʂ͂<CA82><CD82><EFBFBD><EFBFBD>ɓ<EFBFBD><C993><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
my $response_code = $response->code() ;#<23><><EFBFBD>ʂ͂<CA82><CD82><EFBFBD><EFBFBD>ɓ<EFBFBD><C993><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
my $db_content = $response->content() ;
# <20>G<EFBFBD><47><EFBFBD>[<5B>`<60>F<EFBFBD>b<EFBFBD>N
if ($response->is_error)
{
&DispError2($GB, "<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I", "<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>F<EFBFBD>g<EFBFBD><67><EFBFBD>b<EFBFBD>N<EFBFBD>o<EFBFBD>b<EFBFBD>N<EFBFBD>̑<EFBFBD><CC91>M<EFBFBD>Ɏ<EFBFBD><C98E>s<EFBFBD><73><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B($response_code)");
}
# $db_content =~ s/"/&quot;/g;
$db_content =~ s/</&lt;/g;
$db_content =~ s/>/&gt;/g;
$db_content =~ tr/\n//d;
if($ENV{SERVER_NAME} !~ /qb6/) {return 1;}
$GB->{FORM}->{'MESSAGE'} .= "<hr><font color=orange><3E>g<EFBFBD><67><EFBFBD>b<EFBFBD>N<EFBFBD>o<EFBFBD>b<EFBFBD>N</font><br>";
$GB->{FORM}->{'MESSAGE'} .= "target=$target<br>";
$GB->{FORM}->{'MESSAGE'} .= "title=[$subject]<br>";
# $GB->{FORM}->{'MESSAGE'} .= "excerpt=[$message]<br>";
$GB->{FORM}->{'MESSAGE'} .= "URL=[ $url ]<br>";
$GB->{FORM}->{'MESSAGE'} .= "blog_name=$FOX->{$GB->{FORM}->{bbs}}->{BBS_TITLE}<br>";
$GB->{FORM}->{'MESSAGE'} .= "=====<br>[$db_content]";
return 1;
}
#########################################################
# index.html/subback.html <20><><EFBFBD><EFBFBD><EFBFBD>ڂ<EFBFBD><DA82>T<EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>ǂ<EFBFBD><C782><EFBFBD>
# <20><><EFBFBD>ڂ<EFBFBD>: 1<>A<EFBFBD><41><EFBFBD>ڂ<EFBFBD><DA82>Ȃ<EFBFBD>: 0
#########################################################
sub SaborinServer
{
my ($GB) = @_ ;
if($GB->{BBSCGI_FUNCTIONS}{SABORIN}) {return 1;}
# news21/news22: <20><><EFBFBD><EFBFBD><EFBFBD>p
#if($ENV{'SERVER_NAME'} =~ /news21/) {return 1;}
#if($ENV{'SERVER_NAME'} =~ /news22/) {return 1;}
# ex<65>n<EFBFBD>A<EFBFBD><41><EFBFBD>͊<EFBFBD><CD8A>ɂȂ<C982>
#if($ENV{'SERVER_NAME'} =~ /ex11/) {return 1;}
#if($ENV{'SERVER_NAME'} =~ /ex12/) {return 1;}
#if($ENV{'SERVER_NAME'} =~ /ex13/) {return 1;}
#if($ENV{'SERVER_NAME'} =~ /ex14/) {return 1;}
#if($ENV{'SERVER_NAME'} =~ /ex15/) {return 1;}
#if($ENV{'SERVER_NAME'} =~ /ex16/) {return 1;}
#if($ENV{'SERVER_NAME'} =~ /ex17/) {return 1;}
#if($ENV{'SERVER_NAME'} =~ /ex19/) {return 1;}
#if($ENV{'SERVER_NAME'} =~ /ex20/) {return 1;}
#if($ENV{'SERVER_NAME'} =~ /ex21/) {return 1;}
# live<76>n
#if($ENV{'SERVER_NAME'} =~ /live28/) {return 1;}
# live22/live23/live24<32>͂<EFBFBD><CD82><EFBFBD><EFBFBD>Ŏw<C58E><EFBFBD>Ă<EFBFBD><C482>Ӗ<EFBFBD><D396>Ȃ<EFBFBD>(<28><EFBFBD><E182BE><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD><EFBFBD>)
#if($ENV{'SERVER_NAME'} =~ /live22/) {return 1;}
#if($ENV{'SERVER_NAME'} =~ /live23/) {return 1;}
#if($ENV{'SERVER_NAME'} =~ /live24/) {return 1;}
# <20>•ʂŎw<C58E><EFBFBD><E882B7><EFBFBD>
if($GB->{FORM}->{'bbs'} =~ /live/) {return 1;}
if($GB->{FORM}->{'bbs'} eq "weekly") {return 1;}
return 0 ;
}
sub Saborin
{
my ($GB) = @_ ;
#$GB->{FORM}->{'MESSAGE'} .= "<hr><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>($ENV{'SERVER_NAME'},$GB->{FORM}->{'bbs'},$GB->{NEWTHREAD},$GB->{PID})" ;
# return 0 ;
# <20>V<EFBFBD>X<EFBFBD><58><EFBFBD>̎<EFBFBD><CC8E>͍X<CD8D>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>ڂ<EFBFBD><DA82>Ȃ<EFBFBD>
if($GB->{NEWTHREAD} ne 0) {return 0;}
# LA<4C><41><EFBFBD><EFBFBD>l<EFBFBD><6C>1.2<EFBFBD>{<7B>ɒB<C992><42><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD>̌<EFBFBD><CC8C>͍X<CD8D>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>ڂ<EFBFBD>
my $fact = 1.2 ;# LA<4C>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD>̍ۂ̊<CC8A>l<EFBFBD>ɑ΂<C991><CE82><EFBFBD><EFBFBD>{<7B><>
# anime<6D>T<EFBFBD>[<5B>o<EFBFBD><6F>1<EFBFBD>{
if($ENV{'SERVER_NAME'} =~ /anime/) { $fact = 1.0; }
# news<77>n<EFBFBD>T<EFBFBD>[<5B>o<EFBFBD><6F>1<EFBFBD>{
if($ENV{'SERVER_NAME'} =~ /news/) { $fact = 1.0; }
# ex<65>n<EFBFBD>T<EFBFBD>[<5B>o<EFBFBD><6F>1<EFBFBD>{
if($ENV{'SERVER_NAME'} =~ /ex/) { $fact = 1.0; }
# live<76>n<EFBFBD>T<EFBFBD>[<5B>o<EFBFBD><6F>1<EFBFBD>{
if($ENV{'SERVER_NAME'} =~ /live/) { $fact = 1.0; }
# LA<4C><41><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N
if(&mumumuMaxLACheck($GB->{LOADAVG}, $fact)) {return 1;}
# <20>B<EFBFBD><42><EFBFBD>Ă<EFBFBD><C482>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD>Y<EFBFBD><59><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>T<EFBFBD>[<5B>o<EFBFBD>ȊO<C88A>͍X<CD8D>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>ڂ<EFBFBD><DA82>Ȃ<EFBFBD>
elsif(!&SaborinServer($GB)) {return 0;}
# index.html <20><><EFBFBD><EFBFBD><EFBFBD>݂<EFBFBD><DD82>Ȃ<EFBFBD><C882><EFBFBD>͂<EFBFBD><CD82>ڂ<EFBFBD><DA82>Ȃ<EFBFBD>
# <20><><EFBFBD>݂<EFBFBD><DD82><EFBFBD><EFBFBD><EFBFBD>͎<EFBFBD><CD8E><EFBFBD><EFBFBD>ȍ~<7E>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>Ȃ<EFBFBD>
if (!$FOX->{ISINDEXHTML}{$GB->{FORM}{bbs}}) {
if (!-e "../$GB->{FORM}{bbs}/index.html") {return 0;}
$FOX->{ISINDEXHTML}{$GB->{FORM}{bbs}} = 1;
}
# <20>Y<EFBFBD><59><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>T<EFBFBD>[<5B>o<EFBFBD>ł<EFBFBD>PID<49><44>50<35>Ŋ<EFBFBD><C58A><EFBFBD><EFBFBD>ė]<5D><EFBFBD><E882AA><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD>̌<EFBFBD><CC8C>̍X<CC8D>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>ڂ<EFBFBD>
if($GB->{PID} % 50) {return 1;}
# mod_speedycgi<67><69>speedy_backend<6E>ł<EFBFBD>pid<69><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ɠ<EFBFBD><C693><EFBFBD><EFBFBD>ɂȂ<C982><C882>”\<5C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̂ŁA
# rand()<29><><EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD>ɕύX(1999/2000<30>̊m<CC8A><6D>)
# <20><><EFBFBD>΂炭<CE82><E782AD><EFBFBD>̂<EFBFBD><CC82>‚ŗl<C597>q<EFBFBD><71>
#if(rand(2000) > 1) {return 1;}
# <20><><EFBFBD>L<EFBFBD>̂<EFBFBD><CC82><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɂ<EFBFBD><C982>Y<EFBFBD><59><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD>(<28>X<EFBFBD>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>ڂ<EFBFBD><DA82>Ȃ<EFBFBD>)
return 0 ;
}
#######################################################################
# IsKoukoku<6B><75><EFBFBD>X<EFBFBD>L<EFBFBD>b<EFBFBD>v<EFBFBD><76><EFBFBD><EFBFBD><EFBFBD>T<EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD><EFBFBD><EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD>
#######################################################################
sub mumumuIsKoukokuSkipServer
{
my ($GB, $server) = @_;
if($GB->{BBSCGI_FUNCTIONS}{ISKOUKOKUSKIP}) {return 1;}
# if($server =~ /news21/) {return 1;}
# if($server =~ /news22/) {return 1;}
# if($server =~ /ex11/) {return 1;}
# if($server =~ /ex13/) {return 1;}
# if($server =~ /ex14/) {return 1;}
# if($server =~ /ex15/) {return 1;}
# if($server =~ /ex16/) {return 1;}
# if($server =~ /ex19/) {return 1;}
# if($server =~ /ex20/) {return 1;}
return 0;
}
#######################################################################
# IsKoukoku<6B><75><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD><EFBFBD><EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD>
#######################################################################
sub mumumuIsIsKoukoku
{
my ($GB) = @_;
# banana<6E>T<EFBFBD>[<5B>o<EFBFBD>ł͕K<CD95><4B><EFBFBD><EFBFBD><EFBFBD>s
if(&mumumuGetServerType() =~ /banana/) {return 1;}
# <20>Y<EFBFBD><59><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>T<EFBFBD>[<5B>o<EFBFBD>ł͎<C582><CD8E>s<EFBFBD><73><EFBFBD>Ȃ<EFBFBD>
if(&mumumuIsKoukokuSkipServer($GB, $ENV{SERVER_NAME})) {return 0;}
# <20><><EFBFBD><EFBFBD><EFBFBD>ȊO<C88A>͎<EFBFBD><CD8E>s
return 1;
}
#######################################################################
# 1/100<30>b<EFBFBD><62><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E888B5>(<28>\<5C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>)<29><><EFBFBD>ǂ<EFBFBD><C782><EFBFBD>
#######################################################################
sub IsCentiSec
{
my ($GB) = @_;
if($GB->{BBSCGI_FUNCTIONS}{CENTISEC}) {return 1;}
# <20><><EFBFBD>̂ւ<CC82><D682>̃T<CC83>[<5B>o<EFBFBD>ł͕\<5C><>
#if($ENV{'SERVER_NAME'} =~ /atlanta/) {return 1;}
#if($ENV{'SERVER_NAME'} =~ /live/) {return 1;}
if($ENV{'SERVER_NAME'} =~ /hayabusa/) {return 1;}
if($ENV{'SERVER_NAME'} =~ /snow/) {return 1;}
# <20><><EFBFBD>̂ւ<CC82><D682>̔‚ł͕\<5C><>
if($GB->{FORM}->{'bbs'} eq "news") {return 1;}
if($GB->{FORM}->{'bbs'} eq "news4vip") {return 1;}
if($GB->{FORM}->{'bbs'} eq "news4viptasu") {return 1;}
if($GB->{FORM}->{'bbs'} eq "morningcoffee") {return 1;}
if($GB->{FORM}->{'bbs'} eq "asaloon") {return 1;}
if($GB->{FORM}->{'bbs'} eq "operate2") {return 1;}
return 0;
}
#######################################################################
# <20>•ʃL<CA83><4C><EFBFBD>b<EFBFBD>v<EFBFBD><76><EFBFBD>ǂ<EFBFBD><C782><EFBFBD>
#######################################################################
sub IsItabetsuCap
{
my ($GB) = @_;
our %ItabetsuCapList;
BEGIN {
# <20>•ʃL<CA83><4C><EFBFBD>b<EFBFBD>v<EFBFBD>̔‚<CC94><C282>ς<EFBFBD><CF82><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ҏW<D28F><57><EFBFBD><EFBFBD>
%ItabetsuCapList = map +($_ => 1), (
# plus<75>n
"bizplus", "dqnplus", "femnewsplus", "liveplus",
"mnewsplus", "moeplus", "namazuplus", "news4plus",
"news5plus", "newsplus", "owabiplus", "scienceplus",
"ticketplus", "wildplus",
# plus<75>n<EFBFBD>ł͂Ȃ<CD82><C882><EFBFBD><EFBFBD><EFBFBD>
"comicnews", "gamenews",
"musicnews", "news",
"pcnews"
);
}
if($ItabetsuCapList{$GB->{FORM}->{'bbs'}})
{
return 1;
}
return 0;
}
#######################################################################
# <20>X<EFBFBD><58><EFBFBD>b<EFBFBD>h<EFBFBD><68><EFBFBD>𐧌<EFBFBD><F090A78C><EFBFBD><EFBFBD><EFBFBD><EFBFBD>‚<EFBFBD><C282>ǂ<EFBFBD><C782><EFBFBD>
#######################################################################
sub IsThreadLimitIta
{
my ($GB) = @_;
# <20>ΏۂƂȂ<C682><C882>‚<EFBFBD><C282><EFBFBD>
our %ThreadLimitItaList;
BEGIN {
%ThreadLimitItaList = map +($_ => 1), (
#<23><><EFBFBD><EFBFBD>ch
"dancesite", "dome", "endless", "festival",
#<23>ԑgch
"livenhk", "liveetv",
"liventv", "liveanb", "livetbs", "livetx", "livecx",
#<23><><EFBFBD><EFBFBD>ch(weekly<6C>n)
"livewkwest", "weekly",
#<23><EFBFBD>A<EFBFBD>T<EFBFBD>b<EFBFBD>J<EFBFBD>[
"livebase", "livefoot",
#BS<42>A<EFBFBD><41><EFBFBD>W<EFBFBD>I<EFBFBD>A<EFBFBD>X<EFBFBD>J<EFBFBD>p<EFBFBD>[(CS)<29>AWOWOW
"livebs", "liveradio",
"liveskyp", "livewowow",
#<23>Ȃ<EFBFBD><C882>ł<EFBFBD><C582><EFBFBD><EFBFBD><EFBFBD>J<EFBFBD>A<EFBFBD>Ȃ<EFBFBD><C882>ł<EFBFBD><C582><EFBFBD><EFBFBD><EFBFBD>S
"livejupiter", "livesaturn",
#<23>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD>
"oonna", "ootoko",
#<23>Ȃ<EFBFBD><C882>ł<EFBFBD><C582><EFBFBD><EFBFBD><EFBFBD>V
"livevenus",
#<23>e<EFBFBD>X<EFBFBD>g<EFBFBD>p
#"operate2",
#<23>n<EFBFBD>k
"eq", "eqplus"
);
}
if($ThreadLimitItaList{$GB->{FORM}->{'bbs'}})
{
return 1;
}
return 0;
}
#######################################################################
# JavaScript<70><74>read.html<6D><6C><EFBFBD>L<EFBFBD><4C><EFBFBD>ɂ<EFBFBD><C982><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD><EFBFBD><EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD>
#######################################################################
sub IsReadHtml
{
my ($GB) = @_;
# <20>Ƃ肠<C682><E882A0><EFBFBD><EFBFBD>dso, life7<65>T<EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD><EFBFBD><EFBFBD>L<EFBFBD><4C>
#if($ENV{'SERVER_NAME'} =~ /^(?:dso|life7)\./) {return 1;}
# read.html <20>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD>̑<EFBFBD><CC91>݂̗L<CC97><4C><EFBFBD>Ő؂<C590><D882>ւ<EFBFBD>
our $IsReadHtml;
BEGIN {
$IsReadHtml = -e 'read.html';
}
return $IsReadHtml;
}
=begin comment
bbsd <20>֘A<D698>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD> BBSD.pm <20>Ɉ<EFBFBD><C988>C<EFBFBD>̂<EFBFBD><CC82>߃R<DF83><52><EFBFBD><EFBFBD><EFBFBD>g<EFBFBD>A<EFBFBD>E<EFBFBD>g
#######################################################################
# <20><EFBFBD><E182BE><EFBFBD>܃T<DC83>[<5B>o<EFBFBD><6F><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD>
#######################################################################
sub IsSnowManServer
{
my ($server) = @_;
if($ENV{SSL_X_BBSD_SERVER}) {return 1;}
if($server =~ /live22/) {return 1;}
if($server =~ /live23/) {return 1;}
if($server =~ /live24/) {return 1;}
if($server =~ /news20/) {return 1;}
if($server =~ /snow/) {return 1;}
return 0;
}
#############################################################################
# <20><EFBFBD><E182BE><EFBFBD>܃T<DC83>[<5B>o<EFBFBD>p<EFBFBD><70><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>[<5B>`<60><>
# <20><><EFBFBD><EFBFBD>: <20>T<EFBFBD>[<5B>o<EFBFBD><6F>
# <20>E<EFBFBD>e<EFBFBD><65><EFBFBD>ϐ<EFBFBD>(<28><><EFBFBD><EFBFBD><EFBFBD>[<5B>΂<EFBFBD><CE82>[)<29>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD>
#############################################################################
sub InitSnow
{
my ($server) = @_;
# <20>‹<EFBFBD><C28B>ϐ<EFBFBD> SSL_X_BBSD_SERVER(, SSL_X_BBSD_DB_SERVER) <20><><EFBFBD><EFBFBD><EFBFBD>
# XXX: suExec <20><><EFBFBD>Ɠn<C693><6E><EFBFBD><EFBFBD><EFBFBD>‹<EFBFBD><C28B>ϐ<EFBFBD><CF90>ɐ<EFBFBD><C990><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E982BD> SSL_X_ <20><><EFBFBD>t<EFBFBD><74><EFBFBD><EFBFBD>
if ($ENV{SSL_X_BBSD_SERVER}) {
# bbsd(<28><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݁EID<49>̎<EFBFBD><CC8E>S<EFBFBD><53>)<29>̏<EFBFBD><CC8F><EFBFBD>
($FOX->{SNOWMAN}{BBSD}{HOST}, $FOX->{SNOWMAN}{BBSD}{PORT})
= $ENV{SSL_X_BBSD_SERVER} =~ /:/
? split(/:/, $ENV{SSL_X_BBSD_SERVER})
: ($ENV{SSL_X_BBSD_SERVER}, 2222);
$FOX->{SNOWMAN}{BBSD}{TIMEOUT} = 3;
# bbsd(Samba<62><61><EFBFBD><EFBFBD><EFBFBD><EFBFBD>DB<44>S<EFBFBD><53>)<29>̏<EFBFBD><CC8F><EFBFBD>
($FOX->{SNOWMAN}{DB}{HOST}, $FOX->{SNOWMAN}{DB}{PORT})
= $ENV{SSL_X_BBSD_DB_SERVER}
? $ENV{SSL_X_BBSD_DB_SERVER} =~ /:/
? split(/:/, $ENV{SSL_X_BBSD_DB_SERVER})
: ($ENV{SSL_X_BBSD_DB_SERVER}, 2222)
: ($FOX->{SNOWMAN}{BBSD}{HOST}, $FOX->{SNOWMAN}{BBSD}{PORT});
$FOX->{SNOWMAN}{DB}{TIMEOUT} = 1;
}
# <20><><EFBFBD>T<EFBFBD>[<5B>o<EFBFBD>ł͈Ⴄ<CD88>l<EFBFBD><6C><EFBFBD>ݒ<EFBFBD><DD92>ł<EFBFBD><C582><EFBFBD><EFBFBD><EFBFBD>ɂ<EFBFBD><C982>Ă<EFBFBD><C482><EFBFBD>
# live22<32>n<EFBFBD>̏ꍇ
elsif($server =~ /live22/)
{
# bbsd(<28><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݁EID<49>̎<EFBFBD><CC8E>S<EFBFBD><53>)<29>̏<EFBFBD><CC8F><EFBFBD>
$FOX->{SNOWMAN}->{BBSD}->{HOST} = '192.168.100.1';
$FOX->{SNOWMAN}->{BBSD}->{PORT} = 2222;
$FOX->{SNOWMAN}->{BBSD}->{TIMEOUT} = 3;
# bbsd(Samba<62><61><EFBFBD><EFBFBD><EFBFBD><EFBFBD>DB<44>S<EFBFBD><53>)<29>̏<EFBFBD><CC8F><EFBFBD>
$FOX->{SNOWMAN}->{DB}->{HOST} = '192.168.100.2';
$FOX->{SNOWMAN}->{DB}->{PORT} = 2222;
$FOX->{SNOWMAN}->{DB}->{TIMEOUT} = 1;
}
# live23<32>n<EFBFBD>̏ꍇ
elsif($server =~ /live23/)
{
# bbsd(<28><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݁EID<49>̎<EFBFBD><CC8E>S<EFBFBD><53>)<29>̏<EFBFBD><CC8F><EFBFBD>
$FOX->{SNOWMAN}->{BBSD}->{HOST} = '192.168.100.34';
$FOX->{SNOWMAN}->{BBSD}->{PORT} = 2222;
$FOX->{SNOWMAN}->{BBSD}->{TIMEOUT} = 3;
# bbsd(Samba<62><61><EFBFBD><EFBFBD><EFBFBD><EFBFBD>DB<44>S<EFBFBD><53>)<29>̏<EFBFBD><CC8F><EFBFBD>
$FOX->{SNOWMAN}->{DB}->{HOST} = '192.168.100.34';
$FOX->{SNOWMAN}->{DB}->{PORT} = 2222;
$FOX->{SNOWMAN}->{DB}->{TIMEOUT} = 1;
}
# live24<32>n<EFBFBD>̏ꍇ
elsif($server =~ /live24/)
{
# bbsd(<28><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݁EID<49>̎<EFBFBD><CC8E>S<EFBFBD><53>)<29>̏<EFBFBD><CC8F><EFBFBD>
$FOX->{SNOWMAN}->{BBSD}->{HOST} = '192.168.100.1';
$FOX->{SNOWMAN}->{BBSD}->{PORT} = 2223;
$FOX->{SNOWMAN}->{BBSD}->{TIMEOUT} = 3;
# bbsd(Samba<62><61><EFBFBD><EFBFBD><EFBFBD><EFBFBD>DB<44>S<EFBFBD><53>)<29>̏<EFBFBD><CC8F><EFBFBD>
$FOX->{SNOWMAN}->{DB}->{HOST} = '192.168.100.1';
$FOX->{SNOWMAN}->{DB}->{PORT} = 2223;
$FOX->{SNOWMAN}->{DB}->{TIMEOUT} = 1;
}
# news20<32>n<EFBFBD>̏ꍇ
elsif($server =~ /news20/)
{
# bbsd(<28><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݁EID<49>̎<EFBFBD><CC8E>S<EFBFBD><53>)<29>̏<EFBFBD><CC8F><EFBFBD>
$FOX->{SNOWMAN}->{BBSD}->{HOST} = '192.168.100.33';
$FOX->{SNOWMAN}->{BBSD}->{PORT} = 2222;
$FOX->{SNOWMAN}->{BBSD}->{TIMEOUT} = 3;
# bbsd(Samba<62><61><EFBFBD><EFBFBD><EFBFBD><EFBFBD>DB<44>S<EFBFBD><53>)<29>̏<EFBFBD><CC8F><EFBFBD>
$FOX->{SNOWMAN}->{DB}->{HOST} = '192.168.100.33';
$FOX->{SNOWMAN}->{DB}->{PORT} = 2222;
$FOX->{SNOWMAN}->{DB}->{TIMEOUT} = 1;
}
# snow<6F>T<EFBFBD>[<5B>o(<28><><EFBFBD>[<5B>J<EFBFBD><4A><EFBFBD><EFBFBD><E182BE><EFBFBD><EFBFBD>)
elsif($server =~ /snow/)
{
# bbsd(<28><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݁EID<49>̎<EFBFBD><CC8E>S<EFBFBD><53>)<29>̏<EFBFBD><CC8F><EFBFBD>
$FOX->{SNOWMAN}->{BBSD}->{HOST} = '127.0.0.1';
$FOX->{SNOWMAN}->{BBSD}->{PORT} = 2222;
$FOX->{SNOWMAN}->{BBSD}->{TIMEOUT} = 3;
# bbsd(Samba<62><61><EFBFBD><EFBFBD><EFBFBD><EFBFBD>DB<44>S<EFBFBD><53>)<29>̏<EFBFBD><CC8F><EFBFBD>
$FOX->{SNOWMAN}->{DB}->{HOST}
= $FOX->{SNOWMAN}->{BBSD}->{HOST};
$FOX->{SNOWMAN}->{DB}->{PORT}
= $FOX->{SNOWMAN}->{BBSD}->{PORT};
$FOX->{SNOWMAN}->{DB}->{TIMEOUT} = 1;
}
# <20>^<5E>C<EFBFBD><43><EFBFBD>A<EFBFBD>E<EFBFBD>g<EFBFBD><67><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W
$FOX->{SNOWMAN}->{TIMEOUTMSG} = "bbsd timed out";
return 0;
}
=end comment
=cut
#########################################################
sub bbs_entryXXX
{
# qb5 <20>ŋl<C58B>܂<EFBFBD><DC82><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̃f<CC83>o<EFBFBD>b<EFBFBD>O<EFBFBD>p
# our $bbs_entryXXX_cmds;
# BEGIN {
# $bbs_entryXXX_cmds = <<'__BBS_ENTRY_XXX_CMDS_END__';
use CGI::SpeedyCGI ;
my $sp = CGI::SpeedyCGI->new ;
my $spv = $sp->i_am_speedy ? 'SpeedyCGI' : '???';
$ENV{TZ} = 'Asia/Tokyo' ;#<23><><EFBFBD>{
#$ENV <20>͂<EFBFBD><CD82>̂܂܎g<DC8E><67>
#<23>Ή<EFBFBD><CE89>V<EFBFBD>O<EFBFBD>i<EFBFBD><69>
$SIG{PIPE} = $SIG{INT} = $SIG{HUP} = $SIG{QUIT} = $SIG{TERM} = \&SigExit;
my $GBX = {} ;
# bbs.cgi <20>̃o<CC83>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD>
$GBX->{version} = "<a href=\"http://www.2ch.net/\"><3E>Q<EFBFBD><51><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˂<EFBFBD></a> " ;
$GBX->{version} .= "BBS.CGI - $BBSCGI ($spv)" ;
# <20><><EFBFBD>ݎ<EFBFBD><DD8E><EFBFBD><EFBFBD><EFBFBD>$GB<47>ɓ<EFBFBD><C993><EFBFBD>
# <20>}<7D>C<EFBFBD>N<EFBFBD><4E><EFBFBD>b<EFBFBD><62><EFBFBD>Ƃ<EFBFBD><C682>A$GB->{NOWTIME}, $GB->{NOWMICROTIME} <20>ɂ<EFBFBD><C982><EFBFBD><EA82BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
&mumumuGetNowTime($GBX);
$GBX->{PID} = $$ ;#pid
$GBX->{FORM} = {} ;#
&foxSetDate($GBX) ;#<23>@<40><><EFBFBD>t<EFBFBD>E<EFBFBD><45><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݒ<EFBFBD><DD92>i$DATE<54>ɐݒ<C990>)
# foxTrackBackIn<49>̒<EFBFBD><CC92>ŃZ<C583>b<EFBFBD>g<EFBFBD><67><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD>̂ŁA<C581><41><EFBFBD><EFBFBD><EFBFBD>Œ<EFBFBD><C592>`<60>E<EFBFBD><45><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
$GBX->{CAP} = 0 ;# 0:<3A>L<EFBFBD><4C><EFBFBD>b<EFBFBD>v<EFBFBD><76><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD> 1:<3A>L<EFBFBD><4C><EFBFBD>b<EFBFBD>v
$GBX->{TBACK} = 0 ;# 1=TrackBack 0=<3D>ʏ<CA8F><ED8F88>
$GBX->{HOST} = &foxTrackBackIn($GBX) ;
# FORM <20>̓ǂݍ<C782><DD8D>݂<EFBFBD> foxIkinari <20>̑O<CC91>ł<EFBFBD><C582><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
&foxReadForm($GBX) ;#$FORM <20><><EFBFBD>ǂݍ<C782><DD8D><EFBFBD>
# <20><><EFBFBD>e<EFBFBD>m<EFBFBD>F<EFBFBD><46><EFBFBD>ʂ<EFBFBD><CA82>X<EFBFBD>L<EFBFBD>b<EFBFBD>v<EFBFBD><76><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(<28>X<EFBFBD>L<EFBFBD>b<EFBFBD>v<EFBFBD><76><EFBFBD><EFBFBD>)<29>ƃt<C683><74><EFBFBD>O
$GBX->{KPIN1} = "kihon" ;# <20>t<EFBFBD>H<EFBFBD>[<5B><><EFBFBD>̖<EFBFBD><CC96>O
$GBX->{KPIN2} = "suriashi" ;# <20>t<EFBFBD>H<EFBFBD>[<5B><><EFBFBD>̓<EFBFBD><CC93>e
$GBX->{KPASS} = 0 ;# 0:<3A>ʏ<CA8F><ED93AE> 1:<3A><><EFBFBD>e<EFBFBD>m<EFBFBD>F<EFBFBD><46><EFBFBD>ʂ<EFBFBD><CA82>p<EFBFBD>X
# <20>X<EFBFBD>L<EFBFBD>b<EFBFBD>v<EFBFBD><76><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N
$GBX->{KPASS} = &KPinCheck($GBX);
# <20><><EFBFBD><EFBFBD><EFBFBD>‚<EFBFBD><C282><EFBFBD> foxIkinari <20>ŃZ<C583>b<EFBFBD>g<EFBFBD><67><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD>̂ŁA<C581><41><EFBFBD><EFBFBD><EFBFBD>ŏ<EFBFBD><C58F><EFBFBD><EFBFBD><EFBFBD>
$GBX->{PON} = "PON" ;# <20>N<EFBFBD>b<EFBFBD>L<EFBFBD>[<5B>̑f
$GBX->{PONX} = "PONX" ;# <20>N<EFBFBD>b<EFBFBD>L<EFBFBD>[<5B>̑f
$GBX->{PONOK} = 0 ;# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> PON <20>𑗂<EFBFBD><F0919782>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD>?
$GBX->{HAP} = "HAP" ;# <20>N<EFBFBD>b<EFBFBD>L<EFBFBD>[<5B>̑f
$GBX->{HAPX} = "HAPX" ;# <20>N<EFBFBD>b<EFBFBD>L<EFBFBD>[<5B>̑f
$GBX->{HAPOK} = 0 ;# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> HAP <20>𑗂<EFBFBD><F0919782>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD>?
# <20>͂Ȃ<CD82><C882><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̎<EFBFBD><CC8E><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ς<EFBFBD><CF82><EFBFBD>́A<CD81><41><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E982B1>
# $GBX->{PIN1} = "hana" ;$GBX->{PIN2} = "mogera";
# $GBX->{PIN1} = "kiri" ;$GBX->{PIN2} = "tanpo" ;
# $GBX->{PIN1} = "suka" ;$GBX->{PIN2} = "pontan";
# $GBX->{PIN1} = "tepo" ;$GBX->{PIN2} = "don";
$GBX->{PIN1} = "kuno" ;$GBX->{PIN2} = "ichi";
$GBX->{PIN} = "$GBX->{PIN1}=$GBX->{PIN2}";# <20>N<EFBFBD>b<EFBFBD>L<EFBFBD>[<5B>Ŏg<C58E>p
if(!$GBX->{TBACK})
{
$GBX->{HOST} = &foxIkinari($GBX) ;
}
$GBX->{HOST2} = "HOST2" ;
$GBX->{HOST3} = "HOST3" ;
$GBX->{HOST4} = "HOST4" ;
$GBX->{HOST5} = "HOST5" ;
$GBX->{HOST999} = "HOST999" ;
$GBX->{HOST29} = "HOST29" ;
$GBX->{WHITECAP} = 0 ;# 0:<3A><><EFBFBD>L<EFBFBD><4C><EFBFBD>b<EFBFBD>v<EFBFBD><76><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD> 1:<3A><><EFBFBD>L<EFBFBD><4C><EFBFBD>b<EFBFBD>v
# (<28><><EFBFBD>̃t<CC83><74><EFBFBD>O<EFBFBD>͍<EFBFBD><CD8D><EFBFBD>bbs.cgi<67>ł͎g<CD8E>p<EFBFBD><70><EFBFBD><EFBFBD>)
$GBX->{STRONGCAP} = 0 ;# 0:<3A><><EFBFBD><EFBFBD><EFBFBD>L<EFBFBD><4C><EFBFBD>b<EFBFBD>v<EFBFBD><76><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD> 1:<3A><><EFBFBD><EFBFBD><EFBFBD>L<EFBFBD><4C><EFBFBD>b<EFBFBD>v
$GBX->{TRIPSTRING} = "" ;# <20>g<EFBFBD><67><EFBFBD>b<EFBFBD>v<EFBFBD><76><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E395B6><EFBFBD><EFBFBD>
$GBX->{MARU} = "" ;# <20><><EFBFBD>̃Z<CC83>b<EFBFBD>V<EFBFBD><56><EFBFBD><EFBFBD>ID(<28><><EFBFBD><EFBFBD><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>”\)
$GBX->{PATH} = "PATH" ;
$GBX->{WPATH} = "WPATH" ;
$GBX->{DATPATH} = "DATPATH" ;
$GBX->{LOGPATH} = "LOGPATH" ;
$GBX->{TEMPPATH} = "TEMPPATH" ;
$GBX->{IMODEPATH} = "IMODEPATH" ;
$GBX->{INDEXFILE} = "INDEXFILE" ;
$GBX->{SUBFILE} = "SUBFILE" ;
$GBX->{FILENUM} = "FILENUM" ;
$GBX->{SUBLINE} = "SUBLINE" ;
$GBX->{OUTDAT} = "OUTDAT" ;# <20>܂<EFBFBD><DC82>ɏ<EFBFBD><C98F><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682>Ă<EFBFBD><C482><EFBFBD>dat
$GBX->{LOGDAT} = "LOGDAT" ;# <20>܂<EFBFBD><DC82>ɏ<EFBFBD><C98F><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682>Ă<EFBFBD><C482><EFBFBD>dat<61>̃<EFBFBD><CC83>O
$GBX->{xID} = "xID" ;# <20>܂<EFBFBD><DC82>ɏ<EFBFBD><C98F><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682>Ă<EFBFBD><C482><EFBFBD>dat<61><74>ID
$GBX->{xBE} = "xBE" ;# <20>܂<EFBFBD><DC82>ɏ<EFBFBD><C98F><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682>Ă<EFBFBD><C482><EFBFBD>dat<61><74>BE
$GBX->{DAT1} = "DAT1" ;# <20><><EFBFBD><EFBFBD>dat<61><74>1
$GBX->{DATLAST} = () ;# <20><><EFBFBD><EFBFBD>dat<61>̂<EFBFBD><CC82>KBBS_CONTENTS_NUMBER<45>•<EFBFBD>
$GBX->{DATNUM} = 0 ;# <20><><EFBFBD><EFBFBD>dat<61>̒<EFBFBD><CC92><EFBFBD> = <20><><EFBFBD>X<EFBFBD><58>
$GBX->{NEWSUB} = () ;# subject.txt<78><74><EFBFBD>ێ<EFBFBD>
$GBX->{SABORIN} = 0 ;# Saborin<69>t<EFBFBD><74><EFBFBD>O
$GBX->{LOADAVG} = 0.0 ;# <20><><EFBFBD>݂̃<DD82><CC83>[<5B>h<EFBFBD>A<EFBFBD>x<EFBFBD><78><EFBFBD>[<5B>W(<28><><EFBFBD>ԍ<EFBFBD><D48D>̂<EFBFBD><CC82><EFBFBD>)
$GBX->{MAXLOADAVG} = 0.0 ;# <20><><EFBFBD>e<EFBFBD><65><EFBFBD>[<5B>h<EFBFBD>A<EFBFBD>x<EFBFBD><78><EFBFBD>[<5B>W(<28><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EA8F88>)
$GBX->{IDNOTANE} = "IDNOTANE" ;
$GBX->{KEITAI} = 0 ;# 0:<3A>g<EFBFBD>т<EFBFBD><D182><EFBFBD><EFBFBD>Ȃ<EFBFBD> 1:Docomo 2:au 3:SoftBank
;# 5:emobile
$GBX->{P22CH} = 0 ;# 0:p2.2ch.net<65>ȊO 1:p2.2ch.net
$GBX->{KEITAIBROWSER} = 0 ;# 0:<3A>g<EFBFBD>їp<D197>u<EFBFBD><75><EFBFBD>E<EFBFBD>U<EFBFBD>ȊO 1:<3A>g<EFBFBD>їp<D197>u<EFBFBD><75><EFBFBD>E<EFBFBD>U
$GBX->{V931} = "0" ;# 0:vip<69>L<EFBFBD><4C><EFBFBD>Ȃ<EFBFBD> 931:vip<69>L<EFBFBD><4C>
$GBX->{NEWTHREAD} = 0 ;
$GBX->{JIKAN} = "JIKAN" ;
$GBX->{base} = "base" ;
$GBX->{NEWTHREAD} = 0 ;# bby.2ch.net <20>V<EFBFBD>X<EFBFBD><58><EFBFBD>ʒm<CA92>@<40>\
$GBX->{BURNEDPROXY} = 0 ;# 1:BBQ <20>o<EFBFBD>^<5E>ς݁A<DD81>Ă<EFBFBD><C482>ς݂<CF82>proxy 0:<3A><><EFBFBD><EFBFBD><EFBFBD>ȊO
$GBX->{BURNEDKEITAI} = 0 ;# 1:BBM <20>o<EFBFBD>^<5E>ς݁A<DD81>Ă<EFBFBD><C482>ς݂̌g<CC8C><67> 0:<3A><><EFBFBD><EFBFBD><EFBFBD>ȊO
# IPv6<76>ڑ<EFBFBD><DA91><EFBFBD><EFBFBD>ǂ<EFBFBD><C782><EFBFBD>
$GBX->{IPv6} = 0 ;# 0:IPv6<76>ڑ<EFBFBD><DA91>ł͂Ȃ<CD82><C882>A1: IPv6<76>ڑ<EFBFBD>
# IPv6<76>ڑ<EFBFBD><DA91><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>AIPv6<76>t<EFBFBD><74><EFBFBD>O<EFBFBD>𗧂Ă<F097A782>
if(&IsIPv6())
{
$GBX->{IPv6} = 1 ;
}
$GBX->{DEBUG} = "<22>͂<EFBFBD><CD82>܂<EFBFBD><DC82>͂<EFBFBD><CD82>܂<EFBFBD><DC82>[<br>" ;
$GBX->{LOADAVG} = &mumumuGetLA() ;# <20><><EFBFBD>[<5B>h<EFBFBD>A<EFBFBD>x<EFBFBD><78><EFBFBD>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD><EFBFBD>̓<EFBFBD><CC93><EFBFBD>
my $maxspan = 600 ;
my $span = $GBX->{NOWTIME} - $FOX->{NOWTIME};
if($span > $maxspan) {$sp->shutdown_next_time;}
&foxSetPath($GBX) ;# <20>e<EFBFBD><65>PATH<54><48><EFBFBD><EFBFBD>
&foxReadSettings($GBX) ;# <20>ݒ<C290><DD92><EFBFBD><EFBFBD>݂<EFBFBD><DD82>݂Ƃ<DD82><C682>߂<EFBFBD><DF82><EFBFBD> SETTING.TXT
&foxSetDate2($GBX) ;# <20><><EFBFBD>t<EFBFBD>E<EFBFBD><45><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݒ<EFBFBD><DD92>i$DATE<54>ɐݒ<C990> !!<21>j<EFBFBD><6A>)
&foxBEset($GBX) ;# BE<42><45><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E282A2><EFBFBD>
#<23><><EFBFBD>֌W
&foxKabuInit($GBX) ;# <20><><EFBFBD>֌W
$FOX->{$GBX->{FORM}->{'bbs'}}->{MD5NUMBER} = &foxCheckMD5id(
$GBX->{FORM}->{'bbs'},
$GBX->{MD5DATE},
$FOX->{$GBX->{FORM}->{'bbs'}}->{MD5NUMBER},
$FOX->{MD5DATE},
$GBX->{WPATH});
$FOX->{MD5DATE} = $GBX->{MD5DATE} ;
#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
$FOX->{OTAMESHIMARU} = 'eGSfQMC3U3iZy7mL' ;
#Vip<69>N<EFBFBD>I<EFBFBD><49><EFBFBD>e<EFBFBD>B<EFBFBD>֌W
$GBX->{VIPQ2STOP} = 0 ;# 1:<3A>X<EFBFBD><58><EFBFBD>X<EFBFBD>g<EFBFBD>@0:<3A>p<EFBFBD><70>
require "../../test/bbs-main.cgi";
&bbs_main($GBX) ;
&DispError2($GBX,"FOX <20><>","<font color=green>FOX <20><><EFBFBD>@<40>ӂӂӂ<D382></font><br><br><3E><><EFBFBD><EFBFBD>\\<5C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ́E<CD81>E<EFBFBD>E<br><3E>{<7B><>require<72><65><EFBFBD><EFBFBD><EFBFBD>̂ɂ<CC82><C982><EFBFBD><EFBFBD><EFBFBD><EFBFBD>֍s<D68D><73><EFBFBD>Ȃ<EFBFBD><C882>ƁA<C681>A<EFBFBD>A");
print "Content-type: text/html; charset=shift_jis\n\nWOWOWOWOWOW-----\n";
return ;
#__BBS_ENTRY_XXX_CMDS_END__
# $bbs_entryXXX_cmds = join '', map {
# !/^\s*#/ && /;/ ? "${_}_bbs_entryXXX_debug(<<'__BBS_ENTRY_XXX_DEBUG_EOT__');\n${_}__BBS_ENTRY_XXX_DEBUG_EOT__\n" : $_;
# } split /^/, $bbs_entryXXX_cmds if ($ENV{SERVER_NAME} =~ /^qb\d*\./);
# }
# _bbs_entryXXX_debug();
# eval $bbs_entryXXX_cmds;
# print "Content-Type: text/plain\n\n$@" if ($@);
}
# qb5 <20>ŋl<C58B>܂<EFBFBD><DC82><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̃f<CC83>o<EFBFBD>b<EFBFBD>O<EFBFBD>p
sub _bbs_entryXXX_debug
{
our $ptime;
if (!defined $_[0]) {
$ptime = time;
}
else {
my ($time, $diff) = time;
if (($diff = $time - $ptime) > 7 && open(local *F, '>>', "/var/tmp/bbscgi.log.$ENV{SERVER_NAME}")) {
local ($_, $\) = ($_[0], "\n");
chomp;
print F strftime('[%F %T] ', localtime $time), "$_: took ${diff}s";
close F;
}
$ptime = $time;
}
}
#############################################################################
# <09><><EFBFBD>֌W
#############################################################################
sub IsUtai
{
my ($ne) = @_;
# 1% = 100
if($ne < 30) {return 300;}
if($ne < 50) {return 150;}
if($ne < 100) {return 75;}
if($ne < 500) {return 50;}
if($ne < 1000) {return 40;}
return 30 ;
}
sub IsSpecialKabuU
{
my ($GB,$mei) = @_ ;
#if($mei eq 'supplement') {return 0;}
#if($mei eq 'tanka') {return 0;}
#if($mei eq 'ranking') {return 0;}
#if($mei eq 'radio') {return 0;}
# <20><><EFBFBD><EFBFBD><EFBFBD>D<EFBFBD><44>
#<23><><EFBFBD><EFBFBD>
#http://2pix.2ch.se/test/kabuka.so?morningcoffee
my $host = "http://2pix.2ch.se/test/kabuka2.so?" ;
my $path = $mei ;
my $ua = LWP::UserAgent->new() ;
$ua->agent('Mozilla/5.0 FOX(2ch.se)') ;
$ua->timeout(3) ;
my $request = HTTP::Request->new('GET', $host . $path);
my $response = $ua->request($request) ;#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> GET <20><><EFBFBD><EFBFBD>
my $db_content = $response->content() ;
# <20>G<EFBFBD><47><EFBFBD>[<5B>`<60>F<EFBFBD>b<EFBFBD>N
if ($response->is_error)
{
# <20>‚̊<C282><CC8A><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>G<EFBFBD><47><EFBFBD>[(E)<29>Ƃ<EFBFBD><C682><EFBFBD>
return 0;
}
my ($name,$kabuka,$zenkabu,$ttttt) = split(/\:/,$db_content) ;
$kabuka = int($kabuka) ;
$zenkabu = int($zenkabu) ;
my $kabusu = &foxGetKabusu($GB,$mei) ;
if($zenkabu < 1) {return 0;}
if($kabusu > 0)
{
$GB->{KABUXP} = "$mei" ;
$GB->{KABUUP} = 1 ; #<23><><EFBFBD><EFBFBD><EFBFBD>D<EFBFBD>҂Ղ<D282>
}
my $rrr = int(10000 * $kabusu / $zenkabu);
my $rrx = int($rrr/100) ;
my $u4 = &IsUtai($kabuka) ;
if($rrr >= $u4)
{
$GB->{KABUX} .= "($mei)" ;
return 1 ;
}
return 0 ;
}
sub foxKabuInit
{
my ($GB) = @_;
#&DispError2($GB,"FOX <20><>","<font color=green>FOX <20><><EFBFBD>@<40>ӂӂӂ<D382></font><br><br>$FOX_KABUU[2]");
$GB->{KABU} = 0 ;
$GB->{KABUX} = "<22><><EFBFBD><EFBFBD><EFBFBD>D<EFBFBD><44>" ;
$GB->{KABUXP} = $GB->{FORM}->{'bbs'} ;
$GB->{KABUU} = 0 ;
$GB->{KABUUP} = 0 ; #<23><><EFBFBD><EFBFBD><EFBFBD>D<EFBFBD>҃v<D283>`
$GB->{NINNIN} = 0 ;
if($GB->{FORM}->{'FROM'} !~ /\!kab/) {return 0;}
$GB->{KABU} = 1 ;
$GB->{MEIGARA} = $GB->{FORM}->{'bbs'} ;
if($GB->{MEIGARA} eq 'operate2') {$GB->{MEIGARA} = 'news4vip';}
# if($GB->{MEIGARA} eq 'operate2') {$GB->{MEIGARA} = 'punk';}
$GB->{ZENKABU} = 0 ;
$GB->{KABUKA} = &foxGetKabuka($GB,$GB->{MEIGARA}) ;
# <20><><EFBFBD><EFBFBD><EFBFBD>D<EFBFBD><44>
my $kabuu = &foxGetKabusu($GB,$GB->{MEIGARA}) ;
my $rrr = 0 ;
if($GB->{ZENKABU} > 0) {$rrr = int(10000 * $kabuu / $GB->{ZENKABU});}
my $rrx = int($rrr/100) ;
$GB->{ZENKABU} = "$GB->{MEIGARA}:$kabuu/$GB->{ZENKABU}=$rrx(%)" ;
my $u4 = &IsUtai($GB->{KABUKA}) ;
if($kabuu > 4)
{
$GB->{KABUUP} = 1 ; #<23><><EFBFBD><EFBFBD><EFBFBD>D<EFBFBD>҂Ղ<D282>
}
if($rrr >= $u4)
{
$GB->{KABUU} = 1 ;
}
# else
{
if($GB->{FORM}->{'FROM'} =~ /\!88/)
{
my $abc = 0 ;
foreach(@FOX_KABUU)
{
if($abc >= 5) {last;}
if(&IsSpecialKabuU($GB,"$_"))
{
$GB->{KABUU} = 1;
last;
}
$abc ++ ;
}
if($GB->{FORM}->{'FROM'} =~ /\!88-/)
{
$GB->{FORM}->{'FROM'} =~ s/\!88\-//;
$GB->{KABUX} = "<22><><EFBFBD><EFBFBD><EFBFBD>D<EFBFBD><44>" ;
}
else
{
$GB->{FORM}->{'FROM'} =~ s/\!88//;
}
}
}
if($GB->{FORM}->{'FROM'} =~ /\!kab\-/)
{
$GB->{FORM}->{'FROM'} =~ s/\!kab\-//;
$GB->{NINNIN} = 1 ;
}
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>\<5C><>
if($GB->{FORM}->{'FROM'} =~ /\!kab\:([a-zA-Z0-9]+)/)
{
if($1 ne '') {$GB->{MEIGARA} = $1} ;
}
$GB->{KABUSU} = &foxGetKabusu($GB,$GB->{MEIGARA}) ;
if(!$GB->{KABUU} && $GB->{KABUUP})
{
$GB->{KABUX} = "<22><><EFBFBD>D<EFBFBD>v<EFBFBD>`($GB->{KABUXP})" ;
}
return 1;
}
#############################################################################
# <20><><EFBFBD>ݎ<EFBFBD><DD8E><EFBFBD><EFBFBD><EFBFBD>$GB<47>ɑ<EFBFBD><C991><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
# <20>}<7D>C<EFBFBD>N<EFBFBD><4E><EFBFBD>b<EFBFBD><62><EFBFBD>Ƃ<EFBFBD><C682>A$GB->{NOWTIME}, $GB->{NOWMICROTIME} <20>ɂ<EFBFBD><C982><EFBFBD><EA82BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
#############################################################################
sub mumumuGetNowTime
{
my ($GB) = @_;
#$GB->{NOWTIME} = time ; #<23><><EFBFBD>ݎ<EFBFBD><DD8E><EFBFBD>
# <20>}<7D>C<EFBFBD>N<EFBFBD><4E><EFBFBD>b<EFBFBD><62><EFBFBD>Ƃ<EFBFBD>
use Time::HiRes qw( gettimeofday );
($GB->{NOWTIME}, $GB->{NOWMICROTIME}) = gettimeofday;
# FreeBSD 5.2.1R<EFBFBD><EFBFBD>banana<EFBFBD>T<EFBFBD>[<5B>o<EFBFBD><6F>perl<72>ɂ<EFBFBD>
# Time::HiRes<65><73><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>Ȃ<EFBFBD><C882>̂ŁA
# <20>ւ<EFBFBD><D682><EFBFBD><EFBFBD><EFBFBD>syscall<6C><6C><EFBFBD>g<EFBFBD><67><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
#
#my $tv = pack("L!L!", ()); # 2<>‚<EFBFBD>pack<63><6B><EFBFBD><EFBFBD>long<6E>^<5E>ϐ<EFBFBD>
#
#require 'sys/syscall.ph';
#syscall(&main::SYS_gettimeofday, $tv, undef);
#
#($GB->{NOWTIME}, $GB->{NOWMICROTIME}) = unpack("L!L!", $tv);
return 0;
}
#######################################################################
# <20><><EFBFBD>݂̃<DD82><CC83>[<5B>h<EFBFBD>A<EFBFBD>x<EFBFBD><78><EFBFBD>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD><EFBFBD>𒲂ׂ<F092B282>
#######################################################################
sub mumumuGetLA
{
use Sys::CpuLoad;
return (Sys::CpuLoad::load())[0];
}
#######################################################################
# <20><EFBFBD><EE8F80><EFBFBD>[<5B>h<EFBFBD>A<EFBFBD>x<EFBFBD><78><EFBFBD>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD><EFBFBD>𒲂ׂ<F092B282>
#######################################################################
sub mumumuGetMaxLA
{
my $servertype = "";
$servertype = &mumumuGetServerType();
if($servertype =~ /cobra/) { return 12.0; } # cobra
elsif($servertype =~ /tiger/) { return 10.0; } # tiger
elsif($servertype =~ /banana/) { return 4.0; } # banana
else { return 4.0; } # unknown
}
#######################################################################
# <20>T<EFBFBD>[<5B>o<EFBFBD>̌^<5E>𒲂ׂ<F092B282> (cobra/tiger/banana/unknown)
#######################################################################
sub mumumuGetServerType
{
use Sys::Hostname;
my $hostname = "";
$hostname = hostname();
if($hostname =~ /cobra/ ||
$hostname =~ /oyster/) { return "cobra"; }
elsif($hostname =~ /tiger/) { return "tiger"; }
elsif($hostname =~ /banana/) { return "banana"; }
else { return "unknown"; }
}
#######################################################################
# <20><EFBFBD><EE8F80><EFBFBD>[<5B>h<EFBFBD>A<EFBFBD>x<EFBFBD><78><EFBFBD>[<5B>W<EFBFBD>ɒB<C992><42><EFBFBD>Ă<EFBFBD><C482><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD>𒲂ׂ<F092B282> (<28><><EFBFBD><EFBFBD>: LA, <20>{<7B><>)
#######################################################################
sub mumumuMaxLACheck
{
my ($loadavg, $fact) = @_;
if($loadavg >= $FOX->{MAXLOADAVG} * $fact) {return 1;}
else {return 0;}
}
#############################################################################
# BE<42>̃|<7C>C<EFBFBD><43><EFBFBD>g<EFBFBD>ɉ<EFBFBD><C989><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>N<EFBFBD>t<EFBFBD><74>
# <20><><EFBFBD><EFBFBD>: BE<42>̃|<7C>C<EFBFBD><43><EFBFBD>g
# <20>߂<EFBFBD><DF82>l: <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EA82BC><EFBFBD>ɉ<EFBFBD><C989><EFBFBD><EFBFBD><EFBFBD>3<EFBFBD><33><EFBFBD><EFBFBD><EFBFBD>̕<EFBFBD><CC95><EFBFBD><EFBFBD><EFBFBD>
#############################################################################
sub GetBERank
{
my ($user_points) = @_;
# 100000<30>|<7C>C<EFBFBD><43><EFBFBD>g<EFBFBD>ȏ<EFBFBD><C88F>́u<CD81>\<5C><><EFBFBD>e<EFBFBD>B<EFBFBD>A<EFBFBD>v
if($user_points >= 500000) { return "SOL"; }
# 30000<30>|<7C>C<EFBFBD><43><EFBFBD>g<EFBFBD>ȏ<EFBFBD><C88F>̓_<CD83>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
elsif($user_points >= 100000) { return "DIA"; }
# 10000<30>|<7C>C<EFBFBD><43><EFBFBD>g<EFBFBD>ȏ<EFBFBD><C88F>̓v<CD83><76><EFBFBD>`<60>i<EFBFBD><69><EFBFBD><EFBFBD>
elsif($user_points >= 12000) { return "PLT"; }
# 1000<30>|<7C>C<EFBFBD><43><EFBFBD>g<EFBFBD>ȏ<EFBFBD><C88F>̓u<CD83><75><EFBFBD><EFBFBD><EFBFBD>Y<EFBFBD><59><EFBFBD><EFBFBD>
elsif($user_points >= 10000) { return "BRZ"; }
# <20><><EFBFBD><EFBFBD><EA96A2><EFBFBD>͈<EFBFBD><CD88>ʉ<EFBFBD><CA89><EFBFBD>
else { return "2BP"; }
}
#############################################################################
# BE <20>ɂ<EFBFBD><C982><EFBFBD><EFBFBD>u<EFBFBD>|<7C>C<EFBFBD><43><EFBFBD>g<EFBFBD><67><EFBFBD>T(<28><><EFBFBD>b<EFBFBD>L<EFBFBD>[<5B><>)<29>v<EFBFBD><76><EFBFBD><EFBFBD>
# <20><><EFBFBD><EFBFBD>: $GB
# <20>߂<EFBFBD><DF82>l: 1: <20>|<7C>C<EFBFBD><43><EFBFBD>g<EFBFBD><67><EFBFBD>T<EFBFBD>A0: <20>͂<EFBFBD><CD82><EFBFBD>
#############################################################################
sub GetBELucky
{
my ($GB) = @_;
# SOL / DIA / PLT <20>͖<EFBFBD><CD96><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> 1
if($GB->{BEelite} eq "SOL") { return 1; }
if($GB->{BEelite} eq "DIA") { return 1; }
if($GB->{BEelite} eq "PLT") { return 1; }
# BRZ <20><> 1/2 <20>̊m<CC8A><6D><EFBFBD><EFBFBD> 1
if($GB->{BEelite} eq "BRZ")
{
if(rand(4) < 1) { return 1; }
return 0;
}
# <20><><EFBFBD><EFBFBD><EFBFBD>ȊO<C88A>͏<EFBFBD><CD8F><EFBFBD> 0
return 0;
}
#######################################################################
# <20><><EFBFBD>ʊ<EFBFBD><CA8A><EFBFBD><EFBFBD>D<EFBFBD>҂<EFBFBD><D282><EFBFBD><E693BE><EFBFBD><EFBFBD>
#######################################################################
sub readKABUU
{
#http://2pix.2ch.se/compan/moke.txt
my $host = "http://2pix.2ch.se/compan/moke.txt" ;
my $path = "" ;
my $ua = LWP::UserAgent->new();
$ua->agent('Mozilla/5.0 FOX(2ch.se)');
$ua->timeout(3);
my $request = HTTP::Request->new('GET', $host . $path);
my $response = $ua->request($request) ;#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> GET <20><><EFBFBD><EFBFBD>
my $db_content = $response->content();
# <20>G<EFBFBD><47><EFBFBD>[<5B>`<60>F<EFBFBD>b<EFBFBD>N
if ($response->is_error)
{
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD>0<EFBFBD><30><EFBFBD>Ƃ݂Ȃ<DD82>
return 0;
}
@FOX_KABUU = split(/\n/,$db_content) ;
return 0 ;
}
#######################################################################
# <20><><EFBFBD>݊<EFBFBD><DD8A><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E693BE><EFBFBD><EFBFBD>
#######################################################################
sub foxGetKabusu
{
my ($GB,$bn) = @_ ;
#&DispError2($GB,"FOX <20><>","<font color=green>FOX <20><><EFBFBD>@<40>ӂӂӂ<D382></font><br><br>DMDM[$GB->{FORM}->{'DMDM'}] ,MDMD[$GB->{FORM}->{'MDMD'}]");
# my $bn = $GB->{FORM}->{'bbs'} ;
# if($bn eq 'operate2') {$bn="giin";}
#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
#http://be.2ch.net/test/PXshowsecdetail.php?DMDM=onetop@gmail.com&MDMD=8d2888&BN=news
my $host = "http://be.2ch.net/test/PXshowsecdetail.php?" ;
my $path = "MDMD=$GB->{FORM}->{'MDMD'}&DMDM=$GB->{FORM}->{'DMDM'}&BN=$bn" ;
my $ua = LWP::UserAgent->new();
$ua->agent('Mozilla/5.0 FOX(2ch.se)');
$ua->timeout(3);
my $request = HTTP::Request->new('GET', $host . $path);
my $response = $ua->request($request) ;#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> GET <20><><EFBFBD><EFBFBD>
my $db_content = $response->content();
# <20>G<EFBFBD><47><EFBFBD>[<5B>`<60>F<EFBFBD>b<EFBFBD>N
if ($response->is_error)
{
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD>0<EFBFBD><30><EFBFBD>Ƃ݂Ȃ<DD82>
return 0;
# my $code = $response->code();
# &DispError2($GB, "<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I", "<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>F<EFBFBD><46><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̎擾<CC8E>Ɏ<EFBFBD><C98E>s<EFBFBD><73><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B($code)");
}
my ($name,$kabu,$tanka,$ttttt) = split(/<>/,$db_content) ;
my $kkk = int($kabu) ;
return $kkk ;
}
#######################################################################
# <20><><EFBFBD>݊<EFBFBD><DD8A><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E693BE><EFBFBD><EFBFBD>
#######################################################################
sub foxGetKabuka
{
my ($GB,$ita) = @_ ;
#<23><><EFBFBD><EFBFBD>
#http://2pix.2ch.se/test/kabuka.so?morningcoffee
my $host = "http://2pix.2ch.se/test/kabuka2.so?" ;
my $path = $ita ;
my $ua = LWP::UserAgent->new() ;
$ua->agent('Mozilla/5.0 FOX(2ch.se)') ;
$ua->timeout(3) ;
my $request = HTTP::Request->new('GET', $host . $path);
my $response = $ua->request($request) ;#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> GET <20><><EFBFBD><EFBFBD>
my $db_content = $response->content() ;
# <20>G<EFBFBD><47><EFBFBD>[<5B>`<60>F<EFBFBD>b<EFBFBD>N
if ($response->is_error)
{
# <20>‚̊<C282><CC8A><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>G<EFBFBD><47><EFBFBD>[(E)<29>Ƃ<EFBFBD><C682><EFBFBD>
return "E";
# my $code = $response->code();
# &DispError2($GB, "<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I", "<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>F<EFBFBD><46><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̎擾<CC8E>Ɏ<EFBFBD><C98E>s<EFBFBD><73><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B($code)");
}
my ($name,$kabuka,$zenkabu,$ttttt) = split(/\:/,$db_content) ;
$kabuka = int($kabuka) ;
my $ret = "---" ;
if($kabuka > 0) {$ret = $kabuka;}
$GB->{KABUKA} = $ret;
$GB->{ZENKABU} = int($zenkabu) ;
return $ret;
}
#######################################################################
# BE<42>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD>$GB<47>ɃZ<C983>b<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD>
#######################################################################
sub foxBEset
{
my ($GB) = @_ ;
$GB->{isBE} = 0 ;
$GB->{BEelite} = "" ;
$GB->{BELucky} = 0 ;
$GB->{icon} = "" ;
###2010/7/7 be<62>T<EFBFBD>[<5B>o<EFBFBD>ח<EFBFBD>
#return 1;
##############becheck
#&DispError2($GB,"FOX <20><>","<font color=green>FOX <20><><EFBFBD>@<40>ӂӂӂ<D382></font><br><br>DMDM[$GB->{FORM}->{'DMDM'}] ,MDMD[$GB->{FORM}->{'MDMD'}]");
if($GB->{FORM}->{'DMDM'} eq '') {return 0;}
# if($GB->{FORM}->{'bbs'} eq 'news'
# && $GB->{JIKAN} % 2
# )
# {
# if($GB->{FORM}->{'DMDM'} =~ /\@gmail.com/
# || $GB->{FORM}->{'DMDM'} =~ /\@yahoo.co.jp/
# || $GB->{FORM}->{'DMDM'} =~ /\@hotmail.co.jp/
# )
# {
# &DispError2($GB,"<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I","<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>F<EFBFBD><46><EFBFBD><EFBFBD>be<62>A<EFBFBD>J<EFBFBD>E<EFBFBD><45><EFBFBD>g<EFBFBD>͂<EFBFBD><CD82>̎<EFBFBD><CC8E>Ԏg<D48E><67><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B");
# }
# }
use LWP::UserAgent;
my $path = "d=$GB->{FORM}->{'DMDM'}&m=$GB->{FORM}->{'MDMD'}";
my $ua = LWP::UserAgent->new();
$ua->timeout(5);
my $request = HTTP::Request->new('GET', 'http://be.2ch.net/test/v.php?' . $path);
my $response = $ua->request($request) ;#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> GET <20><><EFBFBD><EFBFBD>
my $response_body = $response->content();#GET<45>̌<EFBFBD><CC8C>ʂ͂<CA82><CD82><EFBFBD><EFBFBD>ɓ<EFBFBD><C993><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
my $db_content = $response->content();
# <20>G<EFBFBD><47><EFBFBD>[<5B>`<60>F<EFBFBD>b<EFBFBD>N
if ($response->is_error)
{
my $code = $response->code();
&DispError2($GB, "<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I", "<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>FBe<42><65><EFBFBD>[<5B>U<EFBFBD>[<5B><><EFBFBD><EFBFBD><EFBFBD>̎擾<CC8E>Ɏ<EFBFBD><C98E>s<EFBFBD><73><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B($code)");
}
my ($user_points, $xxx, $icon_name) = split(/ /, $db_content);
# if($user_points =~ /\D/ || $xxx =~ /\D/){
# &DispError2($GB, "<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I", "<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>FBe<42><65><EFBFBD>[<5B>U<EFBFBD>[<5B><><EFBFBD><EFBFBD><EFBFBD>̎擾<CC8E>Ɏ<EFBFBD><C98E>s<EFBFBD><73><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B(Invalid response)");
# }
if($xxx eq ''){
&DispError2($GB,"<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I","<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>FBe<42><65><EFBFBD>[<5B>U<EFBFBD>[<5B><><EFBFBD><EFBFBD><EFBFBD>G<EFBFBD><47><EFBFBD>[<5B>B<EFBFBD><42><EFBFBD>O<EFBFBD>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(e)<29>B<a href=\"http://be.2ch.net/\">be.2ch.net</a>");
}
$GB->{isBE} = 1 ;
$GB->{BEpoints} = $user_points ;
$GB->{BExxx} = $xxx ;
$GB->{icon} = $icon_name ;
# BE<42>̓_<CC93><5F><EFBFBD>ɉ<EFBFBD><C989><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>N<EFBFBD>t<EFBFBD><74><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>A<EFBFBD><41><EFBFBD>ʂɉ<CA82><C989><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
$GB->{BEelite} = &GetBERank($GB->{BEpoints});
#&DispError2($GB,"root <20><>","BE<42><45><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>e<EFBFBD>[<5B>^<5E>X: $GB->{BEelite}");
# <20><><EFBFBD>b<EFBFBD>L<EFBFBD>[<5B>܂<EFBFBD><DC82>ǂ<EFBFBD><C782><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ׂ<EFBFBD>
$GB->{BELucky} = &GetBELucky($GB);
#&DispError2($GB,"root <20><>","BE<42><45><EFBFBD>b<EFBFBD>L<EFBFBD>[<5B><>: $GB->{BELucky}");
if($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_BE_TYPE2"})
{
#BBE<42>ُ펞<D98F>͂<EFBFBD><CD82><EFBFBD><EFBFBD>[
if(!$FOX->{BBE}) {return 1;}
#BBE<42>ɖ⍇<C996><E28D87>
my $addr = foxDNSquery2("$GB->{NOWTIME}.$GB->{PID}.$GB->{FORM}->{'MDMD'}.1.bbe.2ch.net") ;
#BBE<42><45><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD>Ȍ<EFBFBD><C88C>D<EFBFBD><44><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD>DNS<4E><EFBFBD><E282A2><EFBFBD><EFBFBD><ED82B9><EFBFBD><EFBFBD><EFBFBD>~
if($addr eq "127.0.0.0") { $FOX->{BBE} = 0; }
# <20>Ă<EFBFBD><C482><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD>
elsif($addr eq '127.0.0.2')
{
# &DispError2($GB,"<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I","<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>F<EFBFBD>Ă<EFBFBD><C482>ꂽ be <20>͎g<CD8E><67><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>I");
}
}
return 1;
}
#==================================================
#<23>@<40><><EFBFBD>t<EFBFBD>E<EFBFBD><45><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݒ<EFBFBD><DD92>i$DATE<54>ɐݒ<C990>)
#==================================================
sub foxSetDate
{
my ($GB) = @_ ;
my @wdays = ("<22><>", "<22><>", "<22><>", "<22><>", "<22><>", "<22><>", "<22>y");
my ($sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst);
#<23><><EFBFBD>t<EFBFBD>Ǝ<EFBFBD><C68E>Ԃ<EFBFBD><D482><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682><EFBFBD>
($sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst) = localtime($GB->{NOWTIME});
$GB->{DATE} = sprintf("%02d/%02d/%02d %02d:%02d:%02d",
$year % 100, $mon + 1, $mday, $hour, $min, $sec);
$GB->{MD5DATE} = sprintf("%04d_%02d_%02d",
$year + 1900, $mon + 1, $mday);
$GB->{JIKAN} = $hour;
$GB->{MON} = $mon+1;
$GB->{MDAY} = $mday;
}
#==================================================
#<23>@<40><><EFBFBD>t<EFBFBD>E<EFBFBD><45><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݒ<EFBFBD><DD92>i$DATE<54>ɐݒ<C990>)
#==================================================
sub foxSetDate2
{
my ($GB) = @_ ;
my @wdays = split(/\//,$FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_YMD_WEEKS'});
my ($sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst);
#<23><><EFBFBD>t<EFBFBD>Ǝ<EFBFBD><C68E>Ԃ<EFBFBD><D482><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682><EFBFBD>
($sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst) = localtime($GB->{NOWTIME});
my $nengo = $FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_YMD_NAME'} ;
my $offset = $FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_YMD_OFFSET'} ;
#2006/04/01 event
if($GB->{FORM}->{'bbs'} eq 'news4vip' && $year eq 107 && $mon eq 1 && $mday eq 14)
{
$mon = 1 ;
$mday = 15 ;
}
if($nengo)
{
$GB->{DATE} = sprintf("$nengo%d<>N,%04d/%02d/%02d(%s) %02d:%02d:%02d",
$year + 1900 + $offset,$year + 1900, $mon + 1, $mday,$wdays[$wday], $hour, $min, $sec);
}
else
{
$GB->{DATE} = sprintf("%04d/%02d/%02d(%s) %02d:%02d:%02d",
$year + 1900, $mon + 1, $mday,$wdays[$wday], $hour, $min, $sec);
}
}
#==================================================
#<23>@<40><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̎擾<CC8E>i<EFBFBD>ݒ<EFBFBD><DD92>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD>j
#==================================================
#<23>ݒ<EFBFBD><DD92>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD>ǂ<EFBFBD>
sub foxReadSettings
{
my ($GB) = @_ ;
my $ita = $GB->{FORM}->{'bbs'} ;
$GB->{DEBUG} .= "SETTING.TXT <20><><EFBFBD>݂<EFBFBD><DD82>݂<EFBFBD>? $ita<br>";
if(defined($FOX->{$ita}))
{
$GB->{DEBUG} .= "SETTING.TXT <20><><EFBFBD>ɓǂݍ<C782><DD8D>ݍς݁[(1)$ita<br>";
# $GB->{FORM}->{MESSAGE} .= "<hr>SETTING.TXT <20><><EFBFBD>ɓǂݍ<C782><DD8D>ݍς݁[<5B>B($GB->{PID})";
return 0;
}
$GB->{DEBUG} .= "SETTING.TXT <20><><EFBFBD>݂<EFBFBD><DD82>݁[$ita<br>";
my $m_pass = "../$GB->{FORM}->{'bbs'}/SETTING.TXT";
unless(-e $m_pass)
{
my $gogo5 = "../$GB->{FORM}->{'bbs'}/";
#<23>ݒ<EFBFBD><DD92>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>iERROR)
&DispError2($GB,"<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I","<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>F<EFBFBD><46><EFBFBD>[<5B>U<EFBFBD>[<5B>ݒ肪<DD92><E882AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>܂<EFBFBD><DC82>I3<br><a href=\"$gogo5\"><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɂ<EFBFBD><C982><EFBFBD><E982A9><EFBFBD>ł<EFBFBD></a>");
}
{
open(FILE,$m_pass);
local $_; while (<FILE>) {
chomp;
/^([^=]+)=(.*)$/ or next;
(my $m_name, $_) = ($1, $2);
#(my $m_name, $_) = split(/=/, $_, 2);
s/%([[:xdigit:]]{2})/pack('H2', $1)/eg;
$FOX->{$GB->{FORM}->{'bbs'}}->{$m_name} = $_;
}
close(FILE);
}
#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̕⊮
if($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_BG_PICTURE"} =~ /ba\.gif/){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_BG_PICTURE"} = "http://www2.2ch.net/ba.gif";
}
if($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_TITLE_PICTURE"} =~ /2ch\.gif/){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_TITLE_PICTURE"} = "http://www2.2ch.net/2ch.gif";
}
if($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_TITLE_LINK"} =~ /info\.html/){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_TITLE_LINK"} = "http://info.2ch.net/guide/";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_THREAD_NUMBER"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_THREAD_NUMBER"} = 20;
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_CONTENTS_NUMBER"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_CONTENTS_NUMBER"} = 10;
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_LINE_NUMBER"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_LINE_NUMBER"} = 30;
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_MAX_MENU_THREAD"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_MAX_MENU_THREAD"}=100;
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_BG_COLOR"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_BG_COLOR"}="#FFFFFF";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_MENU_COLOR"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_MENU_COLOR"}="#CCFFCC";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_MAKETHREAD_COLOR"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_MAKETHREAD_COLOR"}="#CCFFCC";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_THREAD_COLOR"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_THREAD_COLOR"}="#EFEFEF";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_SUBJECT_COLOR"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_SUBJECT_COLOR"}="#FF0000";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_TEXT_COLOR"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_TEXT_COLOR"}="#000000";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_NAME_COLOR"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_NAME_COLOR"}="#008800";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_LINK_COLOR"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_LINK_COLOR"}="#0000FF";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_ALINK_COLOR"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_ALINK_COLOR"}="#FF0000";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_VLINK_COLOR"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_VLINK_COLOR"}="#660099";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_UNICODE'}){
$FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_UNICODE'}="change";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_TITLE_COLOR"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_TITLE_COLOR"}="#000000";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_SUBJECT_COUNT"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_SUBJECT_COUNT"}=64;
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_NAME_COUNT"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_NAME_COUNT"}=64;
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_MAIL_COUNT"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_MAIL_COUNT"}=64;
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_MESSAGE_COUNT"}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_MESSAGE_COUNT"}=4096;
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{'timecount'}){
$FOX->{$GB->{FORM}->{'bbs'}}->{'timecount'} = 15;
}
if($FOX->{$GB->{FORM}->{'bbs'}}->{'timecount'} < 1){
$FOX->{$GB->{FORM}->{'bbs'}}->{"timecount"} = 1;
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{'timeclose'}){
$FOX->{$GB->{FORM}->{'bbs'}}->{'timeclose'} = 12;
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_NONAME_NAME'}){
$FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_NONAME_NAME'} = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_DISP_IP'}){
$FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_DISP_IP'} = "";
}
unless($FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_YMD_WEEKS'}){
$FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_YMD_WEEKS'} = "<22><>/<2F><>/<2F><>/<2F><>/<2F><>/<2F><>/<2F>y";
}
# unless($FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_YMD_NAME'}){
# $FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_YMD_NAME'} = "<22>c<EFBFBD>I";
# }
# unless($FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_YMD_OFFSET'}){
# $FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_YMD_OFFSET'} = 660;
# }
# <20>I<EFBFBD><49><EFBFBD>p
#$FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_NONAME_NAME'} = "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>񁗂<EFBFBD><F1819782><EFBFBD><EFBFBD><EFBFBD><EFBFBD>I<EFBFBD><49><EFBFBD>ɍs<C98D><73><EFBFBD><EFBFBD>";
#$FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_SLIP'} = "checked";
if($FOX->{$GB->{FORM}->{'bbs'}}->{'timeclose'} > $FOX->{$GB->{FORM}->{'bbs'}}->{'timecount'}){
$FOX->{$GB->{FORM}->{'bbs'}}->{"timeclose"} = $FOX->{$GB->{FORM}->{'bbs'}}->{"timecount"};
}
$GB->{DEBUG} .= "SETTING.TXT <20><><EFBFBD>݂<EFBFBD><DD82>݁[$ita<74><61><EFBFBD><EFBFBD>!!<br>";
# $GB->{FORM}->{MESSAGE} .= "<hr>SETTING.TXT<58>ǂ񂾁B($GB->{PID})";
$FOX->{$GB->{FORM}->{'bbs'}}->{MD5NUMBER} = &foxInitMD5id($GB->{FORM}->{'bbs'},$GB->{MD5DATE},$GB->{WPATH});
$FOX->{MD5DATE} = $GB->{MD5DATE} ;
$FOX->{$GB->{FORM}->{'bbs'}}->{SAMBA24} = &foxSamba24Init($GB->{FORM}->{'bbs'});
#bbspink<6E>́ABBS_MAIL_COUNT=16
if($ENV{SERVER_NAME} =~ /bbspink.com/)
{
$FOX->{$GB->{FORM}->{'bbs'}}->{"BBS_MAIL_COUNT"}=16;
}
#if($GB->{FORM}->{'bbs'} eq 'operate2' || $GB->{FORM}->{'bbs'} eq 'news4vip' || $GB->{FORM}->{'bbs'} eq 'news4viptasu')
#{
# my ($sec, $min, $hour, $mday, $mon, $year, $wday, $yday, $isdst) = localtime(time);
# if($mday <= 11)
# {
# my $ato = (11*24 + 6)*60*60 ;
# $ato -= ((($mday*24 + $hour)*60 + $min)*60 + $sec) ;
# if($ato < 1000000) {$ato =~ s/(\d)(\d\d\d)(?!\d)/$1,$2/g;}
# else {$ato =~ s/(\d)(\d\d\d)(\d\d\d)(?!\d)/$1,$2,$3/g;}
# $FOX->{$GB->{FORM}->{'bbs'}}->{'BBS_NONAME_NAME'} .= "<22><><EFBFBD><EFBFBD>$ato<74>b";
# }
#}
return 1 ;
}
#######################################################################
#
#######################################################################
sub foxSamba24
{
my ($GB, $tane, $spanspan) = @_ ;
my $Samba = "Samba24-2.13" ;
#my $spanspan = 20 ; #<23>K<EFBFBD><4B><EFBFBD>b<EFBFBD><62>
my $kanpeki = 3 ; #<23><><EFBFBD>e<EFBFBD><65><EFBFBD><EFBFBD> ERR593 Nsec <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>܂<EFBFBD><DC82><EFBFBD>
my $saidai = 5 ; #<23><><EFBFBD>E<EFBFBD><45><EFBFBD><EFBFBD> ERR599 <20>R<EFBFBD>[<5B>q<EFBFBD>[<5B>u<EFBFBD><75><EFBFBD>C<EFBFBD>N<EFBFBD>A<EFBFBD>ȍ~<7E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B
# my $yakinFile = "./book/$tane.cgi";
my $yakinFile = "$FOX->{BOOK}/book/$tane.cgi";
my $memomemo = "($Samba)";
my ($prsize,$prmtime)= ();
my $ctime = 0;
my $keika = 0;
my $errmsg = ""; # bbsd<73>ɕ<EFBFBD><C995><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
my $statnum = 0; # Samba DB<44><42><EFBFBD><EFBFBD><EFBFBD>Ԃ<EFBFBD><D482>Ă<EFBFBD><C482><EFBFBD><EFBFBD>X<EFBFBD>e<EFBFBD>[<5B>^<5E>X
# <20><EFBFBD><E182BE><EFBFBD>܂ł́Abbsd<73>ɖ₢<C996><E282A2><EFBFBD><EFBFBD><ED82B9>
if(IsSnowmanServer)
{
# live22x[123] <20>Ƃ<EFBFBD><C682><EFBFBD><EFBFBD><EFBFBD><EFBFBD>O<EFBFBD>ŗ<EFBFBD><C597><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ASamba120<32>b
if($ENV{SERVER_NAME} =~ /live22x[123]/)
{
$spanspan = 120;
}
# Samba24 DB <20>ւ̖₢<CC96><E282A2><EFBFBD>
my $cmd = 'chkid';
$errmsg = bbsd_db($GB->{FORM}->{'bbs'}, $cmd, 'samba24', $tane, $spanspan, $kanpeki, $saidai, 'dummy');
# <20>^<5E>C<EFBFBD><43><EFBFBD>A<EFBFBD>E<EFBFBD>g<EFBFBD><67><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N
# <20>^<5E>C<EFBFBD><43><EFBFBD>A<EFBFBD>E<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Samba24<32>̓X<CD83><58><EFBFBD>[<5B><><EFBFBD><EFBFBD>
if(&bbsd_TimeoutCheck($GB, $errmsg))
{
return 0;
}
# <20><><EFBFBD>ʂ<EFBFBD><CA82>؂<EFBFBD><D882>o<EFBFBD><6F>
($statnum, $prsize, $keika) = split(/,/, $errmsg);
# <20>X<EFBFBD>e<EFBFBD>[<5B>^<5E>X<EFBFBD><58>0<EFBFBD>Ȃ疳<C882><E796B3><EFBFBD><EFBFBD>
if($statnum == 0) {return 0;}
# <20>u<EFBFBD>A<EFBFBD><41><EFBFBD>񐔁v<F1909481>𐔂<EFBFBD><F0909482><EFBFBD><EFBFBD>̂ŁA<C581><41><EFBFBD>Œ<EFBFBD><C28C><EFBFBD>K<EFBFBD>v<EFBFBD><76><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
$prsize--;
}
else
{
($prsize, $prmtime) = (local $_=stat($yakinFile)) ? ($_->size, $_->mtime) : (0, 0);
$ctime = time;
$keika = $ctime - $prmtime;
}
# <20>K<EFBFBD><4B><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
if($prsize > $saidai)
{
my $houhou = '<a href=\"http://etc6.2ch.net/event/\"><3E>C<EFBFBD>x<EFBFBD><78><EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD></a><3E>‚ňꎞ<C588>Ԉȏ<D488><C88F>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>ʔ<EFBFBD><CA94><EFBFBD><EFBFBD>C<EFBFBD>x<EFBFBD><78><EFBFBD>g<EFBFBD>l<EFBFBD><6C><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B';
print "Content-type: text/html; charset=shift_jis\n\n";
print <<EOF;
<html><head><title><3E>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I</title><meta http-equiv="Content-Type" content="text/html; charset=shift_jis"></head>
<body><!-- 2ch_X:error -->
<EFBFBD>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q - 594 <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ə<EFBFBD><C68F><EFBFBD><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B<br>
<br>
<EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><EFBFBD>́A<EFBFBD>K<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>g<EFBFBD>ɒlj<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><EFBFBD><EFBFBD><EFBFBD>B<br><br>
<EFBFBD>y<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>@<40>z<br>
$houhou<br>
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ȊO<EFBFBD>ɉ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>̕<EFBFBD><EFBFBD>@<40>͂<EFBFBD><CD82><EFBFBD><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B<br>
<br><hr>$memomemo</body>
</html>
EOF
if(!IsSnowmanServer)
{
open(YAN1,">>$yakinFile");print YAN1 "1";close(YAN1);
}
exit;
}
# <20>x<EFBFBD><78><EFBFBD>\<5C><>
if($prsize && $keika < $spanspan)
{
if(!IsSnowmanServer)
{
open(YAN1,">>$yakinFile");print YAN1 "1";close(YAN1);
}
# <20>d<EFBFBD><64><EFBFBD><EFBFBD><EFBFBD>΂<EFBFBD>
if($prsize > $kanpeki)
{
my ($fsec,$fmin,$fhour,$fmday,$fmon,$fyear,$fwday,$fyday,$fisdst) = localtime($ctime); $fmon ++ ;$fyear += 1900 ;
print "Content-type: text/html; charset=shift_jis\n\n";
print <<EOF;
<html><head><title><3E>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I</title><meta http-equiv="Content-Type" content="text/html; charset=shift_jis"></head>
<body><!-- 2ch_X:error -->
599 <20>A<EFBFBD>ł<EFBFBD><C582>Ȃ<EFBFBD><C882>ł<EFBFBD><C582><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B<EFBFBD><42><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EB82BB><EFBFBD>K<EFBFBD><4B><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>g<EFBFBD>ɓ<EFBFBD><C993><EFBFBD><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B<EFBFBD>B(<28>P<EFBFBD>[<5B>P)<29>j<EFBFBD><6A><EFBFBD><EFBFBD><EFBFBD>b<br>
<br><hr>$memomemo</body>
</html>
EOF
exit;
}
# <20>y<EFBFBD><79><EFBFBD><EFBFBD><EFBFBD>΂<EFBFBD>/<2F><><EFBFBD><EFBFBD>
print "Content-type: text/html; charset=shift_jis\n\n";
print <<EOF;
<html><head><title><3E>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I</title><meta http-equiv="Content-Type" content="text/html; charset=shift_jis"></head>
<body><!-- 2ch_X:error -->
<EFBFBD>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q - 593 $spanspan sec <20><><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>Ə<EFBFBD><C68F><EFBFBD><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B($prsize<7A><65><EFBFBD>ځA$keika sec <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ĂȂ<C482>)<br>
<br>
120sec<EFBFBD>K<EFBFBD><EFBFBD><EFBFBD>̏ꍇ Be <20>Ƀ<EFBFBD><C983>O<EFBFBD>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ɖ<EFBFBD><C689><EFBFBD><EFBFBD>ł<EFBFBD><C582>܂<EFBFBD>(newsplus<75><73><EFBFBD><EFBFBD><EFBFBD><EFBFBD>)<29>B<a href="http://be.2ch.net/">be.2ch.net</a>
<br><hr>$memomemo</body>
</html>
EOF
exit;
}
if(!IsSnowmanServer)
{
if($prsize) {unlink("$yakinFile");}
open(YAN1,">>$yakinFile");print YAN1 "1";close(YAN1);
# <20>ŏ<EFBFBD><C58F><EFBFBD>umask(0)<29><><EFBFBD><EFBFBD><E98CBE><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD>̂ŕs<C595>v
#umask(0);
#chmod(0666, $yakinFile);
}
return 0;
}
#######################################################################
# <20><><EFBFBD>ł̒P<CC92>ʎ<EFBFBD><CA8E>ԓ<EFBFBD><D493><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̃X<CC83><58><EFBFBD><EFBFBD><EFBFBD>Đ<EFBFBD><C490><EFBFBD><EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD>
# <20><EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD>̏ꏊ<CC8F><EA8F8A>Samba24<32>Ɠ<EFBFBD><C693><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682><EFBFBD><EFBFBD>𗬗p<F097AC97><70><EFBFBD><EFBFBD>
# <20><EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD>̐擪<CC90><E693AA> "." <20><><EFBFBD>‚<EFBFBD><C282><EFBFBD>ƂŁAf22<32>ɂ<EFBFBD><C982><EFBFBD>IP<49><50><EFBFBD>̃J<CC83>E<EFBFBD><45><EFBFBD>g<EFBFBD><67>
# <20>e<EFBFBD><65><EFBFBD><EFBFBD><EFBFBD>o<EFBFBD>Ȃ<EFBFBD><C882><EFBFBD>ɂ<EFBFBD><C982><EFBFBD>
#######################################################################
sub mumumuKuromaruSuretateCount
{
my ($GB, $tcountmax) = @_;
my $FilenoTane = $GB->{MARU};
# <20><><EFBFBD>̓J<CD83>E<EFBFBD><45><EFBFBD>g<EFBFBD>A<EFBFBD>b<EFBFBD>v<EFBFBD>Ȃ<EFBFBD>
if($GB->{CAP}) {return 0;}
# <20><><EFBFBD>̒<EFBFBD><CC92>g<EFBFBD><67><EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682>Ďg<C48E>p<EFBFBD>”\<5C>Ȃ<EFBFBD><C882>̂ɂ<CC82><C982><EFBFBD>(/<2F><>_<EFBFBD>ɕϊ<C995>)
$FilenoTane =~ s/\//_/g;
# <20><EFBFBD><E182BE><EFBFBD>܂ł<DC82>bbsd<73>ɖ₢<C996><E282A2><EFBFBD><EFBFBD><ED82B9>
if(IsSnowmanServer)
{
my $errmsg = "";
my $statnum = 0;
my $cmd = 'chkid';
$errmsg = bbsd_db($GB->{FORM}->{'bbs'}, $cmd, 'kuromarusuretate', $FilenoTane, 1800, $tcountmax, $tcountmax, 'dummy');
# <20>^<5E>C<EFBFBD><43><EFBFBD>A<EFBFBD>E<EFBFBD>g<EFBFBD><67><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N
# <20>^<5E>C<EFBFBD><43><EFBFBD>A<EFBFBD>E<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD><58><EFBFBD>[<5B><><EFBFBD><EFBFBD>
if(&bbsd_TimeoutCheck($GB, $errmsg))
{
return 0;
}
# <20><><EFBFBD>ʂ<EFBFBD><CA82>؂<EFBFBD><D882>o<EFBFBD><6F>
$statnum = (split(/,/, $errmsg))[0];
# $tcountmax<61>𒴂<EFBFBD><F092B482>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
if($statnum == 3) {return 1;}
# <20>X<EFBFBD><58><EFBFBD>[<5B><><EFBFBD><EFBFBD>
return 0;
}
else
{
# <20>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD>u<EFBFBD><75><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Samba24<32>̏ꏊ<CC8F><EA8F8A><EFBFBD>ؗp<D897><70><EFBFBD><EFBFBD>
my $KuromaruFile = "./book/.$FilenoTane.cgi";
# <20><><EFBFBD>ł̃X<CC83><58><EFBFBD><EFBFBD><EFBFBD>ĉ<EFBFBD><C489><EFBFBD>
my $tcount = 0;
# <20>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ׂāA<C481>A<EFBFBD>A
if(-e $KuromaruFile)
{
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>g<EFBFBD><67><EFBFBD>ǂ<EFBFBD><C782>ŕϐ<C595><CF90>ɓ<EFBFBD><C993><EFBFBD><EFBFBD>A<EFBFBD>J<EFBFBD>E<EFBFBD><45><EFBFBD>g<EFBFBD>A<EFBFBD>b<EFBFBD>v<EFBFBD><76><EFBFBD>ď<EFBFBD><C48F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɓ<EFBFBD><C993><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ł̃X<CC83><58><EFBFBD><EFBFBD><EFBFBD>Ă͂Ȃ<CD82><C882>Ɖ<EFBFBD><C689><EFBFBD>A<EFBFBD>r<EFBFBD><72><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>͂<EFBFBD><CD82>Ȃ<EFBFBD>
open(KURO,"+<$KuromaruFile");
$tcount = <KURO>;
$tcount++;
truncate(KURO, 0);
seek(KURO, 0, 0);
print KURO $tcount;
close(KURO);
}
else
{
# <20>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD>V<EFBFBD>K<EFBFBD>ɍ<EFBFBD><C98D><EFBFBD><EFBFBD>āA1<41><31><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
$tcount = 1;
open(KURO,">$KuromaruFile");
print KURO $tcount;
close(KURO);
}
# <20>ő<EFBFBD><C591>񐔂ɒB<C992><42><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD>ُ<EFBFBD><D98F><EFBFBD><EFBFBD>Ԃ<EFBFBD>
if($tcount >= $tcountmax) {return 1;}
# <20>X<EFBFBD><58><EFBFBD>[<5B><><EFBFBD><EFBFBD>
return 0;
}
}
#########################################################
#
#########################################################
sub foxCheckMD5id
{
my ($bbs,$md5date,$num,$dateFox,$wpath) = @_ ;
my $md5datefile = "";
if($dateFox eq $md5date)
{
return $num ;
}
# <20><EFBFBD><E182BE><EFBFBD>܂<EFBFBD>/md<6D>̉<EFBFBD><CC89><EFBFBD><EFBFBD>ǂ<EFBFBD>
if(IsSnowmanServer == BBSD->{REMOTE})
{
$md5datefile = $wpath . '/md5.cgi';
}
else
{
$md5datefile = "../$bbs/md5.cgi";
}
if(open(MD5FILE, $md5datefile))
{
my $md5line = <MD5FILE>;
close(MD5FILE);
my ($a, $b) = split(/<>/, $md5line, 2);
if ($a eq $md5date) {return $b;}
}
return &foxCreateMD5id($bbs,$md5date,$wpath) ;
}
#########################################################
#
#########################################################
sub foxGetMD5id
{
my ($bbs,$md5date,$num,$tane) = @_ ;
my $id = "FOX" ;
use Digest::MD5 ;
use Digest::MD5 qw(md5_hex) ;
my $idnum = md5_hex($tane) ;
my $md5 = Digest::MD5->new ;
$md5->add(substr($idnum,-4)) ;
$md5->add($bbs) ;
$md5->add($num) ;
$id = substr($md5->b64digest, 0, 8);
return $id ;
}
#########################################################
#
#########################################################
sub foxInitMD5id
{
my ($bbs,$md5date,$wpath) = @_ ;
my $md5datefile = "";
# <20><EFBFBD><E182BE><EFBFBD>܂<EFBFBD>/md<6D>̉<EFBFBD><CC89><EFBFBD><EFBFBD>ǂ<EFBFBD>
if(IsSnowmanServer == BBSD->{REMOTE})
{
$md5datefile = $wpath . '/md5.cgi';
}
else
{
$md5datefile = "../$bbs/md5.cgi";
}
if(open(MD5FILE, $md5datefile))
{
my $md5line = <MD5FILE> ;
close(MD5FILE) ;
my ($a, $b) = split(/<>/, $md5line, 2);
if($a eq $md5date) {return $b;}
}
return &foxCreateMD5id($bbs,$md5date,$wpath) ;
}
#########################################################
#
#########################################################
sub foxCreateMD5id
{
use Fcntl;
my ($bbs,$md5date,$wpath) = @_ ;
my $md5datefile = "";
# <20><EFBFBD><E182BE><EFBFBD>܂<EFBFBD>/md<6D>̉<EFBFBD><CC89>ɍ<EFBFBD><C98D><EFBFBD>
if(IsSnowmanServer == BBSD->{REMOTE})
{
if(!(-e $wpath)) { mkdir($wpath, 0777); }
$md5datefile = $wpath . '/md5.cgi';
}
else
{
$md5datefile = "../$bbs/md5.cgi";
}
my $data = "ABCD";
my $md5line = "";
# <20><EFBFBD><E182BE><EFBFBD>܂ł́Abbsd<73>Ɏ<EFBFBD><C98E><EFBFBD><EFBFBD><EFBFBD><E282A2><EFBFBD><EFBFBD><ED82B9>
if(IsSnowmanServer == BBSD->{REMOTE})
{
my $cmd = 'getmd5seed';
$md5line = bbsd($bbs, $cmd, 'dummy');
# <20>^<5E>C<EFBFBD><43><EFBFBD>A<EFBFBD>E<EFBFBD>g<EFBFBD><67><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>$GB<47><42><EFBFBD>Ȃ<EFBFBD><C882>̂ŁA<C581>K<EFBFBD><4B><EFBFBD>ɍ<EFBFBD><C98D><EFBFBD>
my $TMPGB = {};
$TMPGB->{FORM}->{'bbs'} = $bbs;
if(&bbsd_TimeoutCheck($TMPGB, $md5line))
{
&bbsd_TimeoutError($TMPGB, $cmd);
}
}
# <20>ʏ<EFBFBD><CA8F>T<EFBFBD>[<5B>o<EFBFBD>ł́A<CD81><41><EFBFBD><EFBFBD><EFBFBD>Ŏ<EFBFBD><C58E><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
else
{
sysopen(RANDOM, '/dev/urandom', O_RDONLY) || die "cannot open /dev/urandom $!\n";
sysread(RANDOM, $data, 16) ;
close(RANDOM) ;
}
open(MD5FILE, ">$md5datefile") ;
# <20><EFBFBD><E182BE><EFBFBD>܂ł́A<CD81><41><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̂܂܂̌`<60>ŏ<EFBFBD><C58F><EFBFBD>
if(IsSnowmanServer == BBSD->{REMOTE})
{
print MD5FILE $md5line;
$data = (split(/<>/,$md5line))[1];
}
else
{
print MD5FILE "$md5date<>$data" ;
}
close(MD5FILE) ;
# <20>ŏ<EFBFBD><C58F><EFBFBD>umask(0)<29><><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD>̂ŕs<C595>v
#chmod(0777, $md5datefile) ;
return $data ;
}
########################################################################
# <20>‚<EFBFBD><C282>Ƃ̃X<CC83><58><EFBFBD>b<EFBFBD>h<EFBFBD>ێ<EFBFBD><DB8E><EFBFBD><EFBFBD>𒲂ׂ<F092B282>(initFOX<4F><58><EFBFBD><EFBFBD><EFBFBD>D<EFBFBD>o<EFBFBD>q<EFBFBD><71><EFBFBD>Ɉ<EFBFBD><C988>x<EFBFBD><78><EFBFBD><EFBFBD><EFBFBD>Ă΂<C482><CE82><EFBFBD>)
# <20>߂<EFBFBD><DF82>l: f22<32>ɂ<EFBFBD><C982><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ێ<EFBFBD><DB8E><EFBFBD>(<28><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>f<EFBFBD>t<EFBFBD>H<EFBFBD><48><EFBFBD>g(1000))
########################################################################
#sub mumumuGetHojisuu
#{
# # <20>f<EFBFBD>t<EFBFBD>H<EFBFBD><48><EFBFBD>g<EFBFBD>l<EFBFBD>A/_bg/f22.cgi<67><69><EFBFBD>Q<EFBFBD><51>
# my $resNumMax = 1000;
# my @f22 = ();
# my @f22r = ();
#
# # f22<32>̐ݒ<CC90><DD92>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD>ǂ݁A<DD81>l<EFBFBD>𒲂ׂ<F092B282>
# if (-e '../_bg/f22info.cgi')
# {
# open(F22FILE,"../_bg/f22info.cgi");
# @f22 = <F22FILE>;
# close(F22FILE);
#
# # $resNumMax <20>̍s<CC8D>𒲂ׁA<D781>A<EFBFBD>A
# @f22r = grep(/\$resNumMax /, @f22);
#
# # <20>Y<EFBFBD><59><EFBFBD>s<EFBFBD><73><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>΁A<CE81><41><EFBFBD>΂<EFBFBD>
# # <20><><EFBFBD><EFBFBD><EFBFBD>ɂ<EFBFBD><C982><EFBFBD>$resNumMax<61><78><EFBFBD>X<EFBFBD>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
# if ($f22r[0] ne '')
# {
# eval $f22r[0];
# }
# }
#
# return $resNumMax;
#}
#########################################################
#
#########################################################
sub initFOX
{
$FOX->{NOWTIME} = time ;
# BBx<42><78>DNS<4E>T<EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD>t<EFBFBD><74><EFBFBD>O
$FOX->{BBM} = 1 ;
$FOX->{BBM2} = 1 ;
$FOX->{BBQ} = 1 ;
$FOX->{BBX} = 1 ;
$FOX->{BBN} = 1 ;
$FOX->{BBY} = 1 ;
$FOX->{BBS} = 1 ;
$FOX->{BBR} = 1 ;
$FOX->{BBE} = 1 ;
# BBY/BBS/BBR<42>pDNS<4E>T<EFBFBD>[<5B>oIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X
# <20>T<EFBFBD>[<5B>o<EFBFBD>ړ]<5D><><EFBFBD>͗v<CD97>ύX
# BBR<42><52>rock54.2ch.net<65>Ɠ<EFBFBD><C693><EFBFBD><EFBFBD>T<EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD><EFBFBD><EFBFBD><EFBFBD>IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>ƂȂ邱<C882>Ƃɒ<C682><C992><EFBFBD>
# (BBQ/BBM/BBX/BBN/BBE<42>͒ʏ<CD92><CA8F><EFBFBD>DNS<4E><53><EFBFBD><EFBFBD><EFBFBD>̂<EFBFBD><CC82>߁AIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD>ߍ<EFBFBD><DF8D>݂͂Ȃ<CD82>)
$FOX->{DNSSERVER}->{BBY} = "206.223.152.130" ;# a.ns.bby.2ch.net
$FOX->{DNSSERVER}->{BBYP} = "206.223.153.130" ;# a.ns.bby.bbspink.com
$FOX->{DNSSERVER}->{BBS} = "207.29.247.145" ;# a.ns.bbs.2ch.net
$FOX->{DNSSERVER}->{BBR} = "206.223.151.68" ;# a.ns.bbr.2ch.net
=begin comment
bbsd <20>֘A<D698>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD> BBSD.pm <20>Ɉ<EFBFBD><C988>C<EFBFBD>̂<EFBFBD><CC82>߃R<DF83><52><EFBFBD><EFBFBD><EFBFBD>g<EFBFBD>A<EFBFBD>E<EFBFBD>g
# <20><EFBFBD><E182BE><EFBFBD>܃T<DC83>[<5B>o<EFBFBD><6F><EFBFBD>ǂ<EFBFBD><C782><EFBFBD>(<28><EFBFBD><E182BE><EFBFBD>܂Ȃ<DC82>1<EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD>łȂ<C582><C882><EFBFBD><EFBFBD><EFBFBD>0)
$FOX->{SNOWMAN}->{FLAG} = &IsSnowManServer($ENV{'SERVER_NAME'});
# <20><EFBFBD><E182BE><EFBFBD>܃T<DC83>[<5B>o<EFBFBD><6F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>[<5B>`<60><><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD>
if($FOX->{SNOWMAN}->{FLAG})
{
&InitSnow($ENV{'SERVER_NAME'});
}
=end comment
=cut
# <20><><EFBFBD><EFBFBD><EFBFBD>@<40>\ (Saborin, IsKoukokuSkip, CentiSec <20><>)
%{$FOX->{BBSCGI_FUNCTIONS}} = map +($_ => 1), split /,/, uc($ENV{SSL_X_BBSCGI_FUNCTIONS} || '');
# Set-Cookie <20>L<EFBFBD><4C><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
$FOX->{COOKIEEXPIRES} = strftime '%A, %d-%b-%Y %T GMT', gmtime 86400 * (int($FOX->{NOWTIME} / 86400) + 2 * 365);
$FOX->{MAXLOADAVG} = &mumumuGetMaxLA();# <20>T<EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>̋<EFBFBD><CC8B>e<EFBFBD><65><EFBFBD>[<5B>h<EFBFBD>A<EFBFBD>x<EFBFBD><78><EFBFBD>[<5B>W
$FOX->{ISKOUKOKU} = 1 ;# IsKoukoku<6B><75><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD><EFBFBD>ǂ<EFBFBD><C782><EFBFBD>
# $FOX->{KUROMARUTCOUNT} = 6 ;# <20><><EFBFBD>ňꎞ<C588>Ԃ<EFBFBD><D482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɗ<EFBFBD><C997>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD>
$FOX->{KUROMARUTCOUNT} = 100 ;# by FOX
#$FOX->{HOJISUU} = &mumumuGetHojisuu();# <20>T<EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>Ƃ̃X<CC83><58><EFBFBD>b<EFBFBD>h<EFBFBD>ێ<EFBFBD><DB8E><EFBFBD>
# <20>L<EFBFBD><4C><EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD>(public_html/test <20><><EFBFBD><EFBFBD><EFBFBD>̑<EFBFBD><CC91>΃p<CE83>X)
# <20><EFBFBD><E182BE><EFBFBD>܂ł<DC82>bbsd<73>ɓn<C993><6E>
if($ENV{'SERVER_NAME'} =~ /bbspink\.com/)
{
$FOX->{headadfile} = '../SAKURA.txt' ;#<23><><EFBFBD>̏<EFBFBD>
$FOX->{putadfile} = '' ;#<23><><EFBFBD>̉<EFBFBD>
$FOX->{maido3adfile} = sub { '../BANANA.txt'; } ;#<23>^<5E><><EFBFBD><EFBFBD>
}
else
{
$FOX->{headadfile} = 'headad.txt' ;#<23><><EFBFBD>̏<EFBFBD>
$FOX->{putadfile} = 'putad.txt' ;#<23><><EFBFBD>̉<EFBFBD>
$FOX->{maido3adfile} = sub { "maido3ad/$_[0]"; } ;#<23>^<5E><><EFBFBD><EFBFBD>
}
################################################################
# <20>g<EFBFBD><67>/PHS<48>pIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>֘A
################################################################
# <20>g<EFBFBD>p<EFBFBD><70><EFBFBD>W<EFBFBD><57><EFBFBD>[<5B><><EFBFBD>̓ǂݍ<C782><DD8D><EFBFBD>
use Net::CIDR::Lite;
################################################################
# i<><69><EFBFBD>[<5B>h<EFBFBD>pIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>֘A
################################################################
$FOX->{IMODECIDR} = Net::CIDR::Lite->new;
# IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>ꗗ(CIDR<44>`<60><>)
# <20>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>W<EFBFBD><57><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD>ɉ<EFBFBD><C989><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# http://www.nttdocomo.co.jp/service/imode/make/content/ip/
my @imodecidr = (
"210.153.84.0/24",
"210.136.161.0/24",
"210.153.86.0/24",
"124.146.174.0/24",
"124.146.175.0/24",
"202.229.176.0/24",
"202.229.177.0/24",
"202.229.178.0/24"
);
# CIDR<44><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E782A9><EFBFBD>ߓo<DF93>^<5E><><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƂŁA<C581>d<EFBFBD><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>bbs.cgi<67>o<EFBFBD>q<EFBFBD><71><EFBFBD><EFBFBD>1<EFBFBD><31><EFBFBD>ōς<C58D>
foreach (@imodecidr) {
$FOX->{IMODECIDR}->add($_);
}
################################################################
# i<><69><EFBFBD>[<5B>h<EFBFBD>t<EFBFBD><74><EFBFBD>u<EFBFBD><75><EFBFBD>E<EFBFBD>U<EFBFBD>pIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>֘A
################################################################
$FOX->{IMODEFULLBROWSERCIDR} = Net::CIDR::Lite->new;
# IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>ꗗ(CIDR<44>`<60><>)
# <20>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>W<EFBFBD><57><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD>ɉ<EFBFBD><C989><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# http://www.nttdocomo.co.jp/service/imode/make/content/ip/
my @imodefullbrowsercidr = (
"210.153.87.0/24"
);
# CIDR<44><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E782A9><EFBFBD>ߓo<DF93>^<5E><><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƂŁA<C581>d<EFBFBD><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>bbs.cgi<67>o<EFBFBD>q<EFBFBD><71><EFBFBD><EFBFBD>1<EFBFBD><31><EFBFBD>ōς<C58D>
foreach (@imodefullbrowsercidr) {
$FOX->{IMODEFULLBROWSERCIDR}->add($_);
}
################################################################
# EZweb<65>pIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>֘A
################################################################
$FOX->{EZWEBCIDR} = Net::CIDR::Lite->new;
# IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>ꗗ(CIDR<44>`<60><>)
# <20>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>W<EFBFBD><57><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD>ɉ<EFBFBD><C989><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# http://www.au.kddi.com/ezfactory/tec/spec/ezsava_ip.html
my @ezwebcidr = (
"210.230.128.224/28",
"121.111.227.160/27",
"61.117.1.0/28",
"219.108.158.0/27",
"219.125.146.0/28",
"61.117.2.32/29",
"61.117.2.40/29",
"219.108.158.40/29",
"219.125.148.0/25",
"222.5.63.0/25",
"222.5.63.128/25",
"222.5.62.128/25",
"59.135.38.128/25",
"219.108.157.0/25",
"219.125.145.0/25",
"121.111.231.0/25",
"121.111.227.0/25",
"118.152.214.192/26",
"118.159.131.0/25",
"118.159.133.0/25",
"118.159.132.160/27",
"111.86.142.0/26",
"111.86.141.64/26",
"111.86.141.128/26",
"111.86.141.192/26",
"118.159.133.192/26",
"111.86.143.192/27",
"111.86.143.224/27",
"111.86.147.0/27",
"111.86.142.128/26",
"111.86.142.192/26",
"111.86.143.0/26"
);
# CIDR<44><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E782A9><EFBFBD>ߓo<DF93>^<5E><><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƂŁA<C581>d<EFBFBD><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>bbs.cgi<67>o<EFBFBD>q<EFBFBD><71><EFBFBD><EFBFBD>1<EFBFBD><31><EFBFBD>ōς<C58D>
foreach (@ezwebcidr) {
$FOX->{EZWEBCIDR}->add($_);
}
################################################################
# au PC<50>T<EFBFBD>C<EFBFBD>g<EFBFBD>r<EFBFBD><72><EFBFBD>[<5B>A<EFBFBD>[(PCSV)<29>pIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>֘A
################################################################
$FOX->{PCSITEVIEWERCIDR} = Net::CIDR::Lite->new;
# IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>ꗗ(CIDR<44>`<60><>)
# <20>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>W<EFBFBD><57><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD>ɉ<EFBFBD><C989><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# http://www.au.kddi.com/ezfactory/tec/spec/pcsv.html
my @pcsiteviewercidr = (
"222.15.68.192/26",
"59.135.39.128/27",
"118.152.214.160/27",
"118.152.214.128/27",
"222.1.136.96/27",
"222.1.136.64/27",
"59.128.128.0/20"
);
# CIDR<44><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E782A9><EFBFBD>ߓo<DF93>^<5E><><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƂŁA<C581>d<EFBFBD><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>bbs.cgi<67>o<EFBFBD>q<EFBFBD><71><EFBFBD><EFBFBD>1<EFBFBD><31><EFBFBD>ōς<C58D>
foreach (@pcsiteviewercidr) {
$FOX->{PCSITEVIEWERCIDR}->add($_);
}
################################################################
# Y!<21>P<EFBFBD>[<5B>^<5E>C<EFBFBD>pIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>֘A
################################################################
$FOX->{SOFTBANKCIDR} = Net::CIDR::Lite->new;
# IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>ꗗ(CIDR<44>`<60><>)
# <20>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>W<EFBFBD><57><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD>ɉ<EFBFBD><C989><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# http://developers.vodafone.jp/dp/tech_svc/web/ip.php
#
# <20>\<5C>t<EFBFBD>g<EFBFBD>o<EFBFBD><6F><EFBFBD>N<EFBFBD><4E><EFBFBD>o<EFBFBD>C<EFBFBD><43><EFBFBD>ɂȂ<C982><C882>āAURI <20><><EFBFBD>ύX<CF8D><58><EFBFBD><EFBFBD>͗l
# -- 10/30/2006 by <20><>
# http://developers.softbankmobile.co.jp/dp/tech_svc/web/ip.php
#
# <20>ēx<C493>ύX<CF8D><58><EFBFBD><EFBFBD>͗l
# -- 4/28/2008 by <20><>
# http://creation.mb.softbank.jp/web/web_ip.html
my @softbankcidr = (
"123.108.237.0/27",
"202.253.96.224/27",
"210.146.7.192/26",
"210.175.1.128/25"
);
# CIDR<44><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E782A9><EFBFBD>ߓo<DF93>^<5E><><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƂŁA<C581>d<EFBFBD><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>bbs.cgi<67>o<EFBFBD>q<EFBFBD><71><EFBFBD><EFBFBD>1<EFBFBD><31><EFBFBD>ōς<C58D>
foreach (@softbankcidr) {
$FOX->{SOFTBANKCIDR}->add($_);
}
################################################################
# <20>\<5C>t<EFBFBD>g<EFBFBD>o<EFBFBD><6F><EFBFBD>N<EFBFBD><4E><EFBFBD>o<EFBFBD>C<EFBFBD><43> PC<50>T<EFBFBD>C<EFBFBD>g<EFBFBD>u<EFBFBD><75><EFBFBD>E<EFBFBD>U<EFBFBD>pIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>֘A
################################################################
$FOX->{PCSITEBROWSERCIDR} = Net::CIDR::Lite->new;
# PC<50>T<EFBFBD>C<EFBFBD>g<EFBFBD>u<EFBFBD><75><EFBFBD>E<EFBFBD>U<EFBFBD>ɂė<C982><C497>p<EFBFBD><70><EFBFBD><EFBFBD>IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>ш<EFBFBD>
# <20>\<5C>t<EFBFBD>g<EFBFBD>o<EFBFBD><6F><EFBFBD>N<EFBFBD>g<EFBFBD>ѓd<D193>b<EFBFBD><62>PC<50>T<EFBFBD>C<EFBFBD>g<EFBFBD>u<EFBFBD><75><EFBFBD>E<EFBFBD>U<EFBFBD>ɂ<EFBFBD>
# <20>E<EFBFBD>F<EFBFBD>u<EFBFBD>T<EFBFBD>[<5B>o<EFBFBD>փA<D683>N<EFBFBD>Z<EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>ہA<DB81>E<EFBFBD>F<EFBFBD>u<EFBFBD>T<EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>ɒʒm<CA92><6D><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
# <20><><EFBFBD>M<EFBFBD><4D><EFBFBD><EFBFBD>IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>͉<EFBFBD><CD89>L<EFBFBD>̑ш<CC91><D188><EFBFBD><EFBFBD>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>ƂȂ<C682><C882>܂<EFBFBD><DC82>B
my @pcsitebrowsercidr = (
"123.108.237.224/27",
"202.253.96.0/28"
);
# CIDR<44><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E782A9><EFBFBD>ߓo<DF93>^<5E><><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƂŁA<C581>d<EFBFBD><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>bbs.cgi<67>o<EFBFBD>q<EFBFBD><71><EFBFBD><EFBFBD>1<EFBFBD><31><EFBFBD>ōς<C58D>
foreach (@pcsitebrowsercidr) {
$FOX->{PCSITEBROWSERCIDR}->add($_);
}
################################################################
# emobile EMnet<65>pIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>֘A
################################################################
$FOX->{EMNETCIDR} = Net::CIDR::Lite->new;
# IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>ꗗ(CIDR<44>`<60><>)
# <20>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>W<EFBFBD><57><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD>ɉ<EFBFBD><C989><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# http://developer.emnet.ne.jp/ipaddress.html
# eM60-254-209-99.emobile.ad.jp = 60.254.209.99 <20><> EMnet <20>Ȃ<EFBFBD><C882>Ƃɒ<C682><C992><EFBFBD>
# http://takagi-hiromitsu.jp/diary/20080722.html
my @emnetcidr = (
"60.254.209.99/32",
"117.55.1.224/27"
);
# CIDR<44><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E782A9><EFBFBD>ߓo<DF93>^<5E><><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƂŁA<C581>d<EFBFBD><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>bbs.cgi<67>o<EFBFBD>q<EFBFBD><71><EFBFBD><EFBFBD>1<EFBFBD><31><EFBFBD>ōς<C58D>
foreach (@emnetcidr) {
$FOX->{EMNETCIDR}->add($_);
}
################################################################
# AIR-EDGE PHONE<4E>pIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>֘A
################################################################
$FOX->{AIREDGECIDR} = Net::CIDR::Lite->new;
# IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>ꗗ(CIDR<44>`<60><>)
# <20>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>W<EFBFBD><57><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD>ɉ<EFBFBD><C989><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# http://www.willcom-inc.com/ja/service/contents_service/create/center_info/index.html
my @airedgecidr = (
"61.198.128.0/24", "61.198.129.0/24", "61.198.130.0/24", "61.198.131.0/24",
"61.198.132.0/24", "61.198.133.0/24", "61.198.134.0/24", "61.198.135.0/24",
"61.198.136.0/24", "61.198.137.0/24", "61.198.138.100/32", "61.198.138.101/32",
"61.198.138.102/32", "61.198.138.103/32", "61.198.139.0/29", "61.198.139.128/27",
"61.198.139.160/28", "61.198.140.0/24", "61.198.141.0/24", "61.198.142.0/24",
"61.198.143.0/24", "61.198.160.0/24", "61.198.161.0/24", "61.198.162.0/24",
"61.198.163.0/24", "61.198.164.0/24", "61.198.165.0/24", "61.198.166.0/24",
"61.198.168.0/24", "61.198.169.0/24", "61.198.170.0/24", "61.198.171.0/24",
"61.198.172.0/24", "61.198.173.0/24", "61.198.174.0/24", "61.198.175.0/24",
"61.198.248.0/24", "61.198.249.0/24", "61.198.250.0/24", "61.198.251.0/24",
"61.198.252.0/24", "61.198.253.0/24", "61.198.254.0/24", "61.198.255.0/24",
"61.204.0.0/24", "61.204.2.0/24", "61.204.3.0/25", "61.204.3.128/25",
"61.204.4.0/24", "61.204.5.0/24", "61.204.6.0/25", "61.204.6.128/25",
"61.204.7.0/25", "61.204.92.0/24", "61.204.93.0/24", "61.204.94.0/24",
"61.204.95.0/24", "114.20.49.0/24", "114.20.50.0/24", "114.20.51.0/24",
"114.20.52.0/24", "114.20.53.0/24", "114.20.54.0/24", "114.20.55.0/24",
"114.20.56.0/24", "114.20.57.0/24", "114.20.58.0/24", "114.20.59.0/24",
"114.20.60.0/24", "114.20.61.0/24", "114.20.62.0/24", "114.20.63.0/24",
"114.20.64.0/24", "114.20.65.0/24", "114.20.66.0/24", "114.20.67.0/24",
"125.28.0.0/24", "125.28.1.0/24", "125.28.15.0/24", "125.28.16.0/24",
"125.28.17.0/24", "125.28.2.0/24", "125.28.3.0/24", "125.28.4.0/24",
"125.28.5.0/24", "125.28.8.0/24", "210.168.246.0/24", "210.168.247.0/24",
"210.169.92.0/24", "210.169.93.0/24", "210.169.94.0/24", "210.169.95.0/24",
"210.169.96.0/24", "210.169.97.0/24", "210.169.98.0/24", "210.169.99.0/24",
"211.126.192.128/25", "211.18.232.0/24", "211.18.233.0/24", "211.18.234.0/24",
"211.18.235.0/24", "211.18.236.0/24", "211.18.237.0/24", "219.108.10.0/24",
"219.108.11.0/24", "219.108.12.0/24", "219.108.13.0/24", "219.108.14.0/24",
"219.108.15.0/24", "219.108.7.0/24", "219.108.8.0/24", "219.108.9.0/24",
"221.119.0.0/24", "221.119.1.0/24", "221.119.2.0/24", "221.119.3.0/24",
"221.119.4.0/24", "221.119.6.0/24", "221.119.7.0/24", "221.119.8.0/24",
"221.119.9.0/24"
);
# CIDR<44><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E782A9><EFBFBD>ߓo<DF93>^<5E><><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƂŁA<C581>d<EFBFBD><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>bbs.cgi<67>o<EFBFBD>q<EFBFBD><71><EFBFBD><EFBFBD>1<EFBFBD><31><EFBFBD>ōς<C58D>
foreach (@airedgecidr) {
$FOX->{AIREDGECIDR}->add($_);
}
################################################################
# AIR-EDGE MEGAPLUS<55>pIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>֘A
################################################################
$FOX->{MEGAPLUSCIDR} = Net::CIDR::Lite->new;
# IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>ꗗ(CIDR<44>`<60><>)
# <20>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>W<EFBFBD><57><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD>ɉ<EFBFBD><C989><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
#
# <20>yBBQ 7<>{<7B>ځz<DA81><7A><EFBFBD>J<EFBFBD><4A><EFBFBD>o<EFBFBD>^<5E><> <20>y<EFBFBD>s<EFBFBD><73><EFBFBD>|<7C>C<EFBFBD><43><EFBFBD>g<EFBFBD>K<EFBFBD><4B><EFBFBD>z
# http://qb5.2ch.net/test/read.cgi/sec2chd/1123932393/908-918
# <20>ɂ<EFBFBD><C982><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD>݂<EFBFBD>222.13.35.0/24<32><34><EFBFBD>o<EFBFBD>^
#
# <20><><EFBFBD><EFBFBD><EFBFBD>[<5B>gIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>̃<EFBFBD><CC83><EFBFBD><EFBFBD>W<EFBFBD><57><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>AfoxSetHost <20>ŁA
# Client_IP <20>w<EFBFBD>b<EFBFBD>_<EFBFBD><5F><EFBFBD>ǂ݁A<DD81><41><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>R<EFBFBD><52><EFBFBD><EFBFBD><EFBFBD>̓<EFBFBD><CC93><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
my @megapluscidr = (
"222.13.35.0/24"
);
# CIDR<44><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E782A9><EFBFBD>ߓo<DF93>^<5E><><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƂŁA<C581>d<EFBFBD><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>bbs.cgi<67>o<EFBFBD>q<EFBFBD><71><EFBFBD><EFBFBD>1<EFBFBD><31><EFBFBD>ōς<C58D>
foreach (@megapluscidr) {
$FOX->{MEGAPLUSCIDR}->add($_);
}
################################################################
# ibisBrowser<65>pIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>֘A
################################################################
$FOX->{IBISBROWSERCIDR} = Net::CIDR::Lite->new;
# IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>ꗗ(CIDR<44>`<60><>)
# <20>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>W<EFBFBD><57><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD>ɉ<EFBFBD><C989><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# http://ibis.ne.jp/support/browserIP.jsp
my @ibisbrowsercidr = (
"59.106.88.0/24"
);
# CIDR<44><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E782A9><EFBFBD>ߓo<DF93>^<5E><><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƂŁA<C581>d<EFBFBD><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>bbs.cgi<67>o<EFBFBD>q<EFBFBD><71><EFBFBD><EFBFBD>1<EFBFBD><31><EFBFBD>ōς<C58D>
foreach (@ibisbrowsercidr) {
$FOX->{IBISBROWSERCIDR}->add($_);
}
################################################################
# jig Browser<65>pIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>֘A
################################################################
$FOX->{JIGBROWSERCIDR} = Net::CIDR::Lite->new;
# IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>ꗗ(CIDR<44>`<60><>)
# <20>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>W<EFBFBD><57><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD>ɉ<EFBFBD><C989><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# http://br.jig.jp/pc/ip_br.html
my @jigbrowsercidr = (
"59.106.23.169/32", "59.106.23.170/31", "59.106.23.172/31",
"82.48.6.10/31", "82.48.6.12/30",
"112.78.114.208/32",
"112.78.207.6/31", "112.78.207.8/29", "112.78.207.16/29",
"112.78.207.24/31", "112.78.207.38/31", "112.78.207.40/29",
"112.78.207.48/29", "112.78.207.56/31",
"112.78.215.70/31", "112.78.215.72/29", "112.78.215.80/29",
"112.78.215.88/31",
"112.78.215.166/31", "112.78.215.168/29", "112.78.215.176/29",
"112.78.215.184/31", "112.78.215.198/31", "112.78.215.200/29",
"112.78.215.208/29", "112.78.215.216/31", "112.78.215.230/31",
"112.78.215.232/29", "112.78.215.240/29", "112.78.215.248/31",
"182.48.5.134/31", "182.48.5.136/29", "182.48.5.144/29",
"182.48.5.152/31", "182.48.5.166/31", "182.48.5.168/29",
"182.48.5.176/29", "182.48.5.184/31", "182.48.5.198/31",
"182.48.5.200/29", "182.48.5.208/29", "182.48.5.216/31",
"182.48.5.230/31", "182.48.5.232/29",
"182.48.6.6/31", "182.48.6.8/29",
"202.181.98.160/32", "202.181.98.179/32", "202.181.98.196/32",
"210.188.205.81/32", "210.188.205.83/32",
"219.94.177.6/31", "219.94.177.8/29", "219.94.177.16/29",
"219.94.177.24/31",
"219.94.182.230/31", "219.94.182.232/29", "219.94.182.240/29",
"219.94.182.248/31",
"219.94.183.102/31", "219.94.183.104/29", "219.94.183.112/29",
"219.94.183.120/31",
"219.94.184.70/31", "219.94.184.72/30", "219.94.184.76/32"
);
# CIDR<44><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E782A9><EFBFBD>ߓo<DF93>^<5E><><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƂŁA<C581>d<EFBFBD><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>bbs.cgi<67>o<EFBFBD>q<EFBFBD><71><EFBFBD><EFBFBD>1<EFBFBD><31><EFBFBD>ōς<C58D>
foreach (@jigbrowsercidr) {
$FOX->{JIGBROWSERCIDR}->add($_);
}
################################################################
# <20>\<5C>t<EFBFBD>g<EFBFBD>o<EFBFBD><6F><EFBFBD>N<EFBFBD><4E><EFBFBD>o<EFBFBD>C<EFBFBD><43> iPhone<6E>pIP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>u<EFBFBD><75><EFBFBD>b<EFBFBD>N<EFBFBD>֘A
################################################################
# 2ch<63><68><EFBFBD><EFBFBD><EFBFBD>^<5E>T<EFBFBD>[<5B>o<EFBFBD>E<EFBFBD><45><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>\<5C>z<EFBFBD><7A><EFBFBD><EFBFBD> Part29
# http://qb5.2ch.net/test/read.cgi/operate/1212665493/850-852
# <20>Ƃ肠<C682><E882A0><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ή<EFBFBD> -- 2008/7/15 by <20><>
# http://qb5.2ch.net/test/read.cgi/operate/1267711917/639
# 126.230.0.0/15 <20><> 126.232.0.0/13 <20><><EFBFBD>lj<EFBFBD> -- 2010/4/10 by <20><>
$FOX->{IPHONECIDR} = Net::CIDR::Lite->new;
my @iphonecidr = (
"126.230.0.0/15",
"126.232.0.0/13",
"126.240.0.0/12"
);
# CIDR<44><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E782A9><EFBFBD>ߓo<DF93>^<5E><><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ƂŁA<C581>d<EFBFBD><64><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>bbs.cgi<67>o<EFBFBD>q<EFBFBD><71><EFBFBD><EFBFBD>1<EFBFBD><31><EFBFBD>ōς<C58D>
foreach (@iphonecidr) {
$FOX->{IPHONECIDR}->add($_);
}
#<23><EFBFBD><E182BE><EFBFBD>܃T<DC83>[<5B>o<EFBFBD>ł́A<CD81><41><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̍L<CC8D><4C><EFBFBD>͓ǂ܂Ȃ<DC82><C882>Ă<EFBFBD><C482><EFBFBD>
if(!IsSnowmanServer)
{
local $/;
if (open(ADFILE, $FOX->{headadfile})) {
$FOX->{headad} = <ADFILE>;
close(ADFILE);
}
if($ENV{'SERVER_NAME'} =~ /2ch\.net/)
{
if (open(ADFILE, $FOX->{putadfile})) {
$FOX->{putad} = <ADFILE>;
close(ADFILE);
}
}
}
#<23>t<EFBFBD>b<EFBFBD>^<5E>[<5B>i<EFBFBD><69><EFBFBD>̍L<CC8D><4C><EFBFBD>j
$FOX->{footad} = '' ;
$FOX->{topad} = '' ;
$FOX->{lastad} = ' <20>y<EFBFBD>[<5B>W<EFBFBD>̂<EFBFBD><CC82><EFBFBD><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B<EFBFBD>B<EFBFBD><42>';
#<23>f<EFBFBD><66><EFBFBD>ˆ<C288>\<5C>̕\<5C><>
#<23><EFBFBD><E182BE><EFBFBD>܂ł͂<C582><CD82><EFBFBD><EFBFBD>ł͂Ȃ<CD82><C882>Abbsd<73><64><EFBFBD>\<5C><><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD>̂Œ<CC82><C592><EFBFBD>
$FOX->{links} = '<Center><a href="http://menu.2ch.net/bbstable.html" Target=_blank><3E><><b><3E>f<EFBFBD><66><EFBFBD>ˆꗗ</b><3E><></a></Center>';
#<23>Q<EFBFBD><51><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˂<EFBFBD><CB82><EFBFBD><EFBFBD>ʃ<EFBFBD><CA83><EFBFBD><EFBFBD>N
#<23><EFBFBD><E182BE><EFBFBD>܂ł͂<C582><CD82><EFBFBD><EFBFBD>ł͂Ȃ<CD82><C882>Abbsd<73><64><EFBFBD>\<5C><><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD>̂Œ<CC82><C592><EFBFBD>
$FOX->{specialad} = ' | <a href="http://irc.2ch.net"><3E>`<60><><EFBFBD>b<EFBFBD>g</a>';
# <20>ȉ<EFBFBD><C889>̂<EFBFBD><CC82>̂͐Ⴞ<CD90><E182BE><EFBFBD>܂ł<DC82><C582>ǂ܂Ȃ<DC82><C882>Ƃ<EFBFBD><C682><EFBFBD>
#<23>K<EFBFBD><4B><EFBFBD>p<EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43>(<28><>)
if(open(ADFILE, 'proxy998.cgi'))
{
@FOX_K998 = <ADFILE> ;
close(ADFILE) ;
}
#<23>K<EFBFBD><4B><EFBFBD>p<EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43>(<28>v<EFBFBD><76><EFBFBD>o<EFBFBD>C<EFBFBD>_)
if(open(ADFILE, 'proxy999.cgi'))
{
@FOX_K999 = <ADFILE> ;
close(ADFILE) ;
}
#<23>K<EFBFBD><4B><EFBFBD>p<EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43>(Rock54)
if(open(ADFILE, '../_bg/Rock54.txt'))
{
# @FOX_Ro54 = <ADFILE> ;
@FOX_Ro54 = map { eval {
no warnings;
my @a = (split /<>/)[5..7];
[qr/$a[0]/, @a[1..2]];
}; } <ADFILE>;
close(ADFILE) ;
}
local $_;
#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>g(4vip)
if(open(ADFILE, '/md/tmp/nanashi.txt')
||open(ADFILE, 'nanashi.txt'))
{
while (<ADFILE>)
{
chomp ;
push(@FOX_774, $_); # <20>Ō<EFBFBD><C58C>ɗv<C997>f<EFBFBD><66><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD><EFBFBD>
}
close(ADFILE) ;
}
# <20>I<EFBFBD><49><EFBFBD>p
#@FOX_774 = (
# "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>񁗂<EFBFBD><F1819782><EFBFBD><EFBFBD><EFBFBD><EFBFBD>I<EFBFBD><49><EFBFBD>ɍs<C98D><73><EFBFBD><EFBFBD>(a)",
# "<22><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>񁗂<EFBFBD><F1819782><EFBFBD><EFBFBD><EFBFBD><EFBFBD>I<EFBFBD><49><EFBFBD>ɍs<C98D><73><EFBFBD><EFBFBD>(a)"
#);
#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>b<EFBFBD>N<EFBFBD>A<EFBFBD>b<EFBFBD>v asahi-net
%FOX_KEN_ASAHI = () ;
if(open(ADFILE,"./_KEN-ASAHI.txt"))
{
while (<ADFILE>)
{
chomp ;
my ($p,$r,$x) = split(/ /) ;
#if(open(LX,">> HOST29.000")){print LX "(READ asahi) $p = $r\n";close(LX);}
next if ($r =~ /\D/) ;
$FOX_KEN_ASAHI{$p} = int($r) ;
}
close(ADFILE) ;
}
#if(open(LX,">> HOST29.000")){print LX "(READ asahi) v116 = $FOX_KEN_ASAHI{v116}\n";close(LX);}
#<23><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>b<EFBFBD>N<EFBFBD>A<EFBFBD>b<EFBFBD>v dion
%FOX_KEN_DION = () ;
if(open(ADFILE,"./_KEN-DION.txt"))
{
while (<ADFILE>)
{
chomp ;
my ($p,$r,$x) = split(/\t/) ;
if ($r !~ /\D/ && $r > 0)
{
#if(open(LX,">> HOST29.000")){print LX "(READ dion) $p = $r\n";close(LX);}
$FOX_KEN_DION{$p} = int($r) ;
}
}
close(ADFILE) ;
}
return 1 ;
}
#==================================================
#<23>V<EFBFBD>O<EFBFBD>i<EFBFBD><69><EFBFBD>Ώ<EFBFBD><CE8F>֐<EFBFBD>
#==================================================
sub SigExit
{
exit(0);
}
#==================================================
#<23>@<40><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>i<EFBFBD>o<EFBFBD>n<EFBFBD>r<EFBFBD>s<EFBFBD>j
#==================================================
sub foxReadForm
{
my ($GB) = @_;
my $FORM = $GB->{FORM};
# UTF-8 -> Shift JIS -- for POST by XMLHttpRequest
use Jcode;
my $jcode = $#ARGV >= 0 && $ARGV[0] eq 'UTF-8' ? new Jcode : undef;
# to avoid "Use of uninitialized value" warnings (except key)
$FORM->{$_} = '' foreach (qw/subject FROM mail bbs time MESSAGE submit/);
#<23>‹<EFBFBD><C28B>ϐ<EFBFBD><CF90><EFBFBD><EFBFBD><EFBFBD><EFBFBD>o<EFBFBD>n<EFBFBD>r<EFBFBD>s<EFBFBD>̂Ł[<5B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>`
if(!$GB->{TBACK} && $ENV{REQUEST_METHOD} eq 'POST') #TBACK <20><><EFBFBD>͓ǂ܂Ȃ<DC82>
{
use Fcntl qw(F_GETFL F_SETFL O_NONBLOCK);
local $/;
$ENV{CONTENT_LENGTH} > 65535
and &DispError2($GB,'<27>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I','<27>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>F<EFBFBD><46><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>I');
# POST <20>f<EFBFBD>[<5B>^<5E><><EFBFBD>M<EFBFBD>Ɏ<EFBFBD><C98E>Ԃ<EFBFBD><D482><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> DoS <20>U<EFBFBD><55><EFBFBD>ɑ΂<C991> robust <20><>
my ($timeout, $len, $fdset, $stdin, $ptime) = (8, $ENV{CONTENT_LENGTH}, '', '', time);
vec($fdset, fileno STDIN, 1) = 1;
fcntl(STDIN, F_SETFL, O_NONBLOCK | fcntl(STDIN, F_GETFL, 0));
while ($len && $timeout > 0) {
my ($l, $s, $t);
select($fdset, undef, undef, $timeout)
# sysread() <20>̕<EFBFBD><CC95><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> SpeedyCGI <20><><EFBFBD>ƃ_<C683><5F>
and $l = read(STDIN, $s, $len)
or last;
$len -= $l;
$stdin .= $s;
$timeout -= ($t = time) - $ptime;
$ptime = $t;
}
# DoS <20>Ǝv<C68E><76><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>͂Ƃ肠<C682><E882A0><EFBFBD><EFBFBD><EFBFBD>L<EFBFBD>^
if (!vec($fdset, fileno STDIN, 1) && open(local *F, '>>', "/var/tmp/dos.post.$ENV{SERVER_NAME}")) {
local $\ = "\n";
print F strftime('[%F %T] ', localtime $ptime), $ENV{REMOTE_ADDR},
' <> ', map "$_=$ENV{$_}, ", grep /^HTTP_/, keys %ENV;
close F;
&DispError2($GB,'<27>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I','<27>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>F<EFBFBD><46><EFBFBD>e<EFBFBD><65><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>I');
}
foreach (split(/&/, $stdin)) {
(my $name, $_) = split(/=/, $_, 2);
next unless (defined $_);
$_ = $jcode->set(\$_, 'utf8')->sjis if (ref $jcode);
tr/+/ /;
s/%([[:xdigit:]]{2})/pack('H2', $1)/eg;
# <20>g<EFBFBD><67><EFBFBD>b<EFBFBD>v<EFBFBD>L<EFBFBD>[<5B><> "as is" <20><>
if ($name eq 'FROM') {
require "jcode.pl";
&jcode::tr(\$_, '<27><>', '#');
($_, $GB->{TRIPKEY}) = split(/#/, $_, 2);
}
# s/"/&quot;/g;
s/</&lt;/g;
s/>/&gt;/g;
tr/\t/ /;
s/\r\n?|\n/<br>/g;
# <20>]<5D>v<EFBFBD>ȋ󔒒lj<F3949292><C789><EFBFBD><EFBFBD>}<7D><>......<2E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>@<40><><EFBFBD>ɉe<C989><65><EFBFBD>H
# s/(?<=[\x80-\xFF])<br>/ <br>/g;
s/<br>/ <br> /g;
# \x00 <20><> [[:cntrl:]]
s/[[:cntrl:]]//g;
$FORM->{$name} = $_;
}
}
#<23>P<EFBFBD>s<EFBFBD>f<EFBFBD>[<5B>^<5E><><EFBFBD><EFBFBD><EFBFBD>͉<EFBFBD><CD89>s<EFBFBD><73><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ă^<5E>O<EFBFBD><4F><EFBFBD>‚<EFBFBD><C282>܂<EFBFBD>
$FORM->{'subject'} =~ s/ ?<br> ?//g;
$FORM->{'subject'} =~ s/&(?!(?:quo|[lg])t;)/&amp;/g;
$FORM->{'FROM'} =~ s/ ?<br> ?//g;
$FORM->{'mail'} =~ s/ ?<br> ?//g;
$FORM->{'mail'} =~ s/"/&quot;/g;
$FORM->{'bbs'} =~ s/\W//g;
$FORM->{'key'} =~ s/\D//g if (defined $FORM->{'key'});
$FORM->{'time'} =~ s/\D//g;
$FORM->{'FROM'} =~ s/&r/&amp;r/g;
# BadTripCheck <20>ŎE<C58E><45><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD>̂ŕs<C595>v
# $FORM->{'FROM'} =~ s/usubon//g;
$FORM->{'mail'} =~ s/&r/&amp;r/g;
# foxIkinari<72>̏<EFBFBD><CC8F><EFBFBD><EFBFBD>ƌ݊<C68C><DD8A>ɂ<EFBFBD><C982><EFBFBD> (<28>Z<EFBFBD>L<EFBFBD><4C><EFBFBD><EFBFBD><EFBFBD>e<EFBFBD>B<EFBFBD><42><EFBFBD><EFBFBD><EFBFBD>{<7B><><EFBFBD><EFBFBD> " <20>͊댯)
# $FORM->{'MESSAGE'} =~ s/"/&quot;/g; <- foreach <20><><EFBFBD>[<5B>v<EFBFBD><76><EFBFBD>ɓ<EFBFBD><C993><EFBFBD>
####cookie
{
#// <20>N<EFBFBD>b<EFBFBD>L<EFBFBD>[<5B>
foreach (split(/[&,;]\s*/, $ENV{HTTP_COOKIE} || '')) {
(my $key, $_) = split(/=/, $_, 2);
$GB->{COOKIES}{$key} = $_ if (defined $_ && !exists $GB->{COOKIES}{$key});
}
$FORM->{'DMDM'} = $GB->{COOKIES}{DMDM} || '';
$FORM->{'MDMD'} = $GB->{COOKIES}{MDMD} || '';
#&DispError2($GB,"FOX <20><>","<font color=green>FOX <20><><EFBFBD>@<40>ӂӂӂ<D382></font><br><br>DMDM[$FORM->{'DMDM'}] ,MDMD[$FORM->{'MDMD'}]");
}
#<23>ł<EFBFBD><C582>@<40><><EFBFBD>ڎw<DA8E><EFBFBD><E882AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E38F91>
if($FORM->{'BEmailad'} && $FORM->{'BEcode32'})
{
$FORM->{'DMDM'} = $FORM->{'BEmailad'};
$FORM->{'MDMD'} = $FORM->{'BEcode32'};
}
#####
#<23><><EFBFBD><EFBFBD><EFBFBD>΍<EFBFBD>
if($ENV{HTTP_USER_AGENT} =~ /<2F>ޏ<EFBFBD>/)
{
$FORM->{'FROM'} = "fusianasan $FORM->{'FROM'}";
}
if($ENV{HTTP_USER_AGENT} =~ /Sirangana/)
{
$FORM->{'FROM'} = "fusianasan $FORM->{'FROM'}";
}
if($ENV{HTTP_USER_AGENT} =~ /Mirage\.Core/)
{
$FORM->{'FROM'} = "fusianasan $FORM->{'FROM'}";
}
if($ENV{HTTP_USER_AGENT} eq '')
{
$FORM->{'FROM'} = "fusianasan $FORM->{'FROM'}";
}
if($ENV{HTTP_USER_AGENT} eq '.')
{
$FORM->{'FROM'} = "fusianasan $FORM->{'FROM'}";
}
#####
}
#==================================================
#<23>@<40>G<EFBFBD><47><EFBFBD>[<5B><><EFBFBD>ʁi<CA81>G<EFBFBD><47><EFBFBD>[<5B><><EFBFBD><EFBFBD><EFBFBD>j
#==================================================
sub DispError2
{
my ($GB, $title, $topic) = @_;
if($GB->{TBACK} && $ENV{SERVER_NAME} !~ /qb6/){&TBackerrEnd;} #TBACK <20><> XML
print "Content-type: text/html; charset=shift_jis\n\n";
#-----------------------------------------------------------------------
print <<EOF;
<html>
<head>
<title>$title</title>
<meta http-equiv="Content-Type" content="text/html; charset=Shift_JIS">
</head>
<body bgcolor="#FFFFFF"><!-- 2ch_X:error -->
<font size=+1 color=#FF0000><b>$topic</b></font>
<ul>
<br><3E>z<EFBFBD>X<EFBFBD>g<b>$GB->{HOST}</B><br><b>$GB->{FORM}->{'subject'} </b><br>
<EFBFBD><EFBFBD><EFBFBD>O<EFBFBD>F <b>$GB->{FORM}->{'FROM'}</b><br>E-mail<69>F $GB->{FORM}->{'mail'}<br>
<EFBFBD><EFBFBD><EFBFBD>e<EFBFBD>F<br>$GB->{FORM}->{'MESSAGE'}<br><br>
</ul>
<a href="http://ula.cc/2ch/sec2ch.html"><3E><> <20>A<EFBFBD>N<EFBFBD>Z<EFBFBD>X<EFBFBD>K<EFBFBD><4B><EFBFBD><EFBFBD><EFBFBD>ł<EFBFBD><C582><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>‚<EFBFBD><C282><EFBFBD> <20><></a><br><br>
<hr>
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ń<EFBFBD><EFBFBD><EFBFBD><EFBFBD>[<5B>h<EFBFBD><68><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B<a href="../$GB->{FORM}->{'bbs'}/index.html"> GO! </a><br>
<EFBFBD>A<EFBFBD>N<EFBFBD>Z<EFBFBD>X<EFBFBD>K<EFBFBD><EFBFBD><EFBFBD>E<EFBFBD>v<EFBFBD><EFBFBD><EFBFBD>L<EFBFBD>V<EFBFBD>[<5B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>K<EFBFBD><4B><EFBFBD>́A<a href="http://2ch.tora3.net/"><3E>Q<EFBFBD><51><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˂<EFBFBD><CB82>r<EFBFBD><72><EFBFBD>[<5B>A</a>
<EFBFBD><EFBFBD><EFBFBD>g<EFBFBD><EFBFBD><EFBFBD>Ɖ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>ł<EFBFBD><EFBFBD>܂<EFBFBD><EFBFBD>B<p>
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʼn<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă݂悤! <a href="http://www.2ch.net/help.html"><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>߂Ȃ<DF82><C882><EFBFBD><EFBFBD>̑<EFBFBD><CC91><EFBFBD><EFBFBD>\\</a><br>
<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><a href="http://info.2ch.net/guide/"><3E>Q<EFBFBD><51><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˂<EFBFBD><CB82>K<EFBFBD>C<EFBFBD>h</a><3E>ցB<D681>B<EFBFBD>B<br><br>
<p>
</body>
</html>
EOF
#<font color=red><3E>r<EFBFBD><72><EFBFBD>o<EFBFBD><6F></font><br>
#$GB->{DEBUG}
#----------------------------------------<br>
#PATH =[$GB->{PATH}]<br>
#DATPATH =[$GB->{DATPATH}]<br>
#TEMPPATH =[$GB->{TEMPPATH}]<br>
#IMODEPATH =[$GB->{IMODEPATH}]<br>
#INDEXFILE =[$GB->{INDEXFILE}]<br>
#SUBFILE =[$GB->{SUBFILE}]<br>
#----------------------------------------<br>
#PID=$GB->{PID}<br>
#time=$GB->{NOWTIME}<br>
#$GB->{version}#sid=$GB->{FORM}->{sid}<br>
#maru=$GB->{MARU}<br>
#-----------------------------------------------------------------------
exit;
}
#==================================================
#<23>@<40>g<EFBFBD>їp<D197>K<EFBFBD><4B><EFBFBD>\<5C><>&<26>G<EFBFBD><47><EFBFBD>[<5B><><EFBFBD>ʁi<CA81>G<EFBFBD><47><EFBFBD>[<5B><><EFBFBD><EFBFBD><EFBFBD>j
#==================================================
sub DispError3
{
my ($GB, $title, $topic) = @_;
if (defined $GB->{TRIPKEY}) {
$_ = $GB->{TRIPKEY};
s/&/&amp;/g;
s/</&lt;/g;
s/>/&gt;/g;
s/[[:cntrl:]]/'&#' . ord($&) . ';'/eg;
$GB->{FORM}{FROM} .= "#$_";
}
$GB->{FORM}{FROM} =~ s/"/&quot;/g;
print "Content-type: text/html; charset=shift_jis\n\n";
#-----------------------------------------------------------------------
print <<EOF;
<html>
<head>
<title>$title</title>
<meta http-equiv="Content-Type" content="text/html; charset=Shift_JIS">
</head>
<body bgcolor=white><!-- 2ch_X:error -->
<a href="http://2ch.net/"><3E>Q<EFBFBD><51><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>˂<EFBFBD></a><br>
<font color=red>$topic</font><br>
<hr>
<font color=red><3E><><EFBFBD>e<EFBFBD>m<EFBFBD>F</font><br>
<EFBFBD>E<EFBFBD><EFBFBD><EFBFBD>e<EFBFBD>҂́A<EFBFBD><EFBFBD><EFBFBD>e<EFBFBD>Ɋւ<EFBFBD><EFBFBD>Ĕ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ӔC<EFBFBD><EFBFBD><EFBFBD>S<EFBFBD>ē<EFBFBD><EFBFBD>e<EFBFBD>҂ɋA<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><EFBFBD>B<br>
<EFBFBD>E<EFBFBD><EFBFBD><EFBFBD>e<EFBFBD>҂́A<EFBFBD>b<EFBFBD><EFBFBD><EFBFBD>Ɩ<EFBFBD><EFBFBD>֌W<EFBFBD>ȍL<EFBFBD><EFBFBD><EFBFBD>̓<EFBFBD><EFBFBD>e<EFBFBD>Ɋւ<EFBFBD><EFBFBD>āA<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̔<EFBFBD><EFBFBD>p<EFBFBD><EFBFBD><EFBFBD>x<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><br>
<EFBFBD>E<EFBFBD><EFBFBD><EFBFBD>e<EFBFBD>҂́A<EFBFBD><EFBFBD><EFBFBD>e<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>e<EFBFBD>y<EFBFBD>т<EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ɋ܂܂<EFBFBD><EFBFBD><EFBFBD><EFBFBD>m<EFBFBD>I<EFBFBD><EFBFBD><EFBFBD>Y<EFBFBD><EFBFBD><EFBFBD>A<EFBFBD>i<EFBFBD><EFBFBD><EFBFBD><EFBFBD>@<40><>21<32><31><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD>28<32><38><EFBFBD>ɋK<C98B><EFBFBD><E882B3><EFBFBD><EFBFBD><E98CA0><EFBFBD><EFBFBD><EFBFBD>܂ށj <20><><EFBFBD>̑<EFBFBD><CC91>̌<EFBFBD><CC8C><EFBFBD><EFBFBD>ɂ‚<C982><C282>i<EFBFBD><69><EFBFBD>O<EFBFBD>҂ɑ΂<C991><CE82>čċ<C48D><C48B><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E98CA0><EFBFBD><EFBFBD><EFBFBD>܂݂܂<DD82><DC82>B<EFBFBD>j<EFBFBD>A<EFBFBD>f<EFBFBD><66><EFBFBD>‰^<5E>c<EFBFBD>҂ɑ΂<C991><CE82>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD>ŏ<EFBFBD><C58F>n<EFBFBD><6E><EFBFBD><EFBFBD>Ƃ<EFBFBD> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B<EFBFBD><42><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD>e<EFBFBD><65><EFBFBD>ʂɒ<CA82><C992>߂<EFBFBD><DF82><EFBFBD>K<EFBFBD>C<EFBFBD>h<EFBFBD><68><EFBFBD>C<EFBFBD><43><EFBFBD>ɊY<C98A><59><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD>e<EFBFBD>Ɋւ<C98A><D682><EFBFBD><EFBFBD>m<EFBFBD>I<EFBFBD><49><EFBFBD>Y<EFBFBD><59><EFBFBD><EFBFBD><EFBFBD>̑<EFBFBD><CC91>̌<EFBFBD><CC8C><EFBFBD><EFBFBD>A <20>`<60><><EFBFBD>͈<EFBFBD><CD88><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ԓ<EFBFBD><D493>e<EFBFBD>҂ɗ<D282><C997>ۂ<EFBFBD><DB82><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B<br>
<EFBFBD>E<EFBFBD>f<EFBFBD><EFBFBD><EFBFBD>‰^<5E>c<EFBFBD>҂́A<CD81><41><EFBFBD>e<EFBFBD>҂ɑ΂<C991><CE82>ē<EFBFBD><C493>{<7B><><EFBFBD><EFBFBD><EFBFBD>O<EFBFBD>ɂ<EFBFBD><C982><EFBFBD><EFBFBD>Ė<EFBFBD><C496><EFBFBD><EFBFBD>Ŕ<EFBFBD><C594>Ɛ<EFBFBD><C690>I<EFBFBD>ɕ<EFBFBD><C995><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD><4F><EFBFBD>M<EFBFBD>A <20>Еz<D095>y<EFBFBD>і|<7C>󂷂錠<F382B782><E98CA0><EFBFBD>𓊍e<F0938A8D>҂ɋ<D282><C98B><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B<EFBFBD>܂<EFBFBD><DC82>A<EFBFBD><41><EFBFBD>e<EFBFBD>҂͌f<CD8C><66><EFBFBD>‰^<5E>c<EFBFBD>҂<EFBFBD><D282>w<EFBFBD><EFBFBD><E882B7><EFBFBD><EFBFBD><EFBFBD>O<EFBFBD>҂ɑ΂<C991><CE82>āA<C481><41><EFBFBD>؂̌<D882><CC8C><EFBFBD><EFBFBD>i<EFBFBD><69><EFBFBD>O<EFBFBD>҂ɑ΂<C991><CE82>čċ<C48D><C48B><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E98CA0><EFBFBD><EFBFBD><EFBFBD>܂݂܂<DD82><DC82>j<EFBFBD><6A><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B<br>
<EFBFBD>E<EFBFBD><EFBFBD><EFBFBD>e<EFBFBD>҂́A<EFBFBD>f<EFBFBD><EFBFBD><EFBFBD>‰^<5E>c<EFBFBD>҂<EFBFBD><D282><EFBFBD>͂<EFBFBD><CD82>̎w<CC8E><EFBFBD><E882B7><EFBFBD>҂ɑ΂<C991><CE82>āA<C481><41><EFBFBD><EFBFBD><EFBFBD>Ґl<D290>i<EFBFBD><69><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>؍s<D88D>g<EFBFBD><67><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B<br>
<hr>
<EFBFBD><EFBFBD><EFBFBD>ӂ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD>߂<EFBFBD><EFBFBD>čē<EFBFBD><EFBFBD>e<EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B(<28><>)<br><hr>
<EFBFBD>J<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><br>
<input type=checkbox ><3E><><EFBFBD>ӂ<EFBFBD><D382><EFBFBD><br>
<EFBFBD><EFBFBD><EFBFBD>O<EFBFBD>F<input type=text size=15 name="FROM" value="$GB->{FORM}->{'FROM'}"><br>
E-ma<6D>F<input type=text size=15 name="mail" value="$GB->{FORM}->{'mail'}"><br>
<textarea name="MESSAGE" rows=5>
$GB->{FORM}->{'MESSAGE'}
</textarea>
</body>
</html>
EOF
#<font color=red><3E>r<EFBFBD><72><EFBFBD>o<EFBFBD><6F></font><br>
#$GB->{DEBUG}
#----------------------------------------<br>
#PATH =[$GB->{PATH}]<br>
#DATPATH =[$GB->{DATPATH}]<br>
#TEMPPATH =[$GB->{TEMPPATH}]<br>
#IMODEPATH =[$GB->{IMODEPATH}]<br>
#INDEXFILE =[$GB->{INDEXFILE}]<br>
#SUBFILE =[$GB->{SUBFILE}]<br>
#----------------------------------------<br>
#PID=$GB->{PID}<br>
#time=$GB->{NOWTIME}<br>
#$GB->{version}#sid=$GB->{FORM}->{sid}<br>
#maru=$GB->{MARU}<br>
#-----------------------------------------------------------------------
exit;
}
#############################################################################
# <20><><EFBFBD>e<EFBFBD>m<EFBFBD>F<EFBFBD><46><EFBFBD>ʂ<EFBFBD><CA82>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ׂ<EFBFBD>
# <20><><EFBFBD>̎<EFBFBD><CC8E><EFBFBD><EFBFBD><EFBFBD> namazuplus <20>Ŏg<C58E>p<EFBFBD><70><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
# <20><><EFBFBD><EFBFBD>: $GB
# <20>߂<EFBFBD><DF82>l: 0: <20><><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>Ȃ<EFBFBD>(<28>ʏ<EFBFBD>)<29>A1: <20><><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
#############################################################################
sub KPinCheck
{
my ($GB) = @_;
# <20>u<EFBFBD><75><EFBFBD>{<7B>͂<EFBFBD><CD82><EFBFBD>v<EFBFBD>̎<EFBFBD><CC8E><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
if(($GB->{FORM}->{$GB->{KPIN1}} || '') eq $GB->{KPIN2}) {return 1;}
# <20><><EFBFBD><EFBFBD><EFBFBD>ȊO
return 0;
}
#############################################################################
# <20>u<EFBFBD><75><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>v<EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD>[<5B>`<60><>
# <20><><EFBFBD>j<EFBFBD>I<EFBFBD><49><EFBFBD><EFBFBD><EE82AA><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>񂠂<EFBFBD><F182A082><EFBFBD>Ȃ̂ŁA<C581>X<EFBFBD>V<EFBFBD><56><EFBFBD>ɂ͒<C982><CD92>ӂ<EFBFBD><D382><EFBFBD><E982B1>
#############################################################################
sub foxIkinari
{
my ($GB) = @_;
if($ENV{PATH_INFO}) {return "127.0.0.101";}
# <20>ŋ߂̑f<CC91><66>IE8<45><38>UA<55><41><EFBFBD>ƂĂ<C682><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̂ŁA256<35>ł͂<C582><CD82>‚<EFBFBD><C282><EFBFBD>
if(length($ENV{'HTTP_USER_AGENT'}) > 384)
{
print "Content-type: text/html; charset=shift_jis\n\n";
print <<EOF;
<html><head><title><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݂܂<DD82><DC82><EFBFBD><EFBFBD>B</title><meta http-equiv="Content-Type" content="text/html; charset=Shift_JIS"></head><body><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݂<EFBFBD><DD82>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B<br><br><3E><><EFBFBD>ʂ<EFBFBD><CA82>؂<EFBFBD><D882>ւ<EFBFBD><D682><EFBFBD><EFBFBD>܂ł<DC82><C582>΂炭<CE82><E782AD><EFBFBD>҂<EFBFBD><D282><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}</body></html>
EOF
exit;
}
if($ENV{'HTTP_USER_AGENT'} =~ />>/)
{
print "Content-type: text/html; charset=shift_jis\n\n";
print <<EOF;
<html><head><title><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݂܂<DD82><DC82><EFBFBD><EFBFBD>B</title><meta http-equiv="Content-Type" content="text/html; charset=Shift_JIS"></head><body><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݂<EFBFBD><DD82>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B<br><br><3E><><EFBFBD>ʂ<EFBFBD><CA82>؂<EFBFBD><D882>ւ<EFBFBD><D682><EFBFBD><EFBFBD>܂ł<DC82><C582>΂炭<CE82><E782AD><EFBFBD>҂<EFBFBD><D282><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}<br><br>$ENV{'HTTP_USER_AGENT'}</body></html>
EOF
exit;
}
my $HOST = gethostbyaddr(pack('C4',split(/\./, $ENV{'REMOTE_ADDR'})), 2) || $ENV{'REMOTE_ADDR'};
if($ENV{'HTTP_VIA'} || $ENV{'HTTP_X_FORWARDED_FOR'} || $ENV{'HTTP_FORWARDED'})
{
unless($HOST =~/jp$/ || $HOST =~/edu$/)
{
print "Content-type: text/html; charset=shift_jis\n\n";
print <<EOF;
<html><head><title><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݂܂<DD82><DC82><EFBFBD><EFBFBD>B</title><meta http-equiv="Content-Type" content="text/html; charset=Shift_JIS"></head><body><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݂<EFBFBD><DD82>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B<br><br><3E><><EFBFBD>ʂ<EFBFBD><CA82>؂<EFBFBD><D882>ւ<EFBFBD><D682><EFBFBD><EFBFBD>܂ł<DC82><C582>΂炭<CE82><E782AD><EFBFBD>҂<EFBFBD><D282><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B</body></html>
EOF
exit;
}
}
# <20>g<EFBFBD>т<EFBFBD><D182><EFBFBD><EFBFBD>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݂̓X<CD83><58><EFBFBD>[
# <20>܂<EFBFBD><DC82><EFBFBD><EFBFBD>̎<EFBFBD><CC8E>_<EFBFBD>ł<EFBFBD>IsIP4Mobile<6C>͎g<CD8E><67><EFBFBD>Ȃ<EFBFBD>
# <20><><EFBFBD>Ƃ<EFBFBD><C682>Ƃ<EFBFBD><C682><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><ED82AF><EFBFBD><EFBFBD><EFBFBD>ǁAUA<55>ł͂<C582><CD82><EFBFBD><E882BD><EFBFBD>Ȃ<EFBFBD><C882>Ȃ<EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD>‚<EFBFBD><C282>̓<EFBFBD><CD83>t<EFBFBD>@<40><><EFBFBD><EFBFBD><EFBFBD>N<EFBFBD>b<EFBFBD>L<EFBFBD>[<5B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD>Ƃɂ<C682><C982>Ă<EFBFBD><C482><EFBFBD>
if($ENV{'HTTP_USER_AGENT'} =~ /DoCoMo|J-PHONE|Vodafone|SoftBank|UP.Browser|KDDI/) {
return $HOST;
}
# <20><><EFBFBD>ۂ<EFBFBD>4<EFBFBD>@<40><><EFBFBD>̓<EFBFBD><CD83>t<EFBFBD>@<40><><EFBFBD>͓f<CD93><66><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD>ǁA<C781>N<EFBFBD>b<EFBFBD>L<EFBFBD>[<5B>͐H<CD90>ׂ<EFBFBD>
if($ENV{'HTTP_USER_AGENT'} !~ /AH-J3001V|AH-J3002V|AH-J3003S|WX220J/)
{
# <20><><EFBFBD>t<EFBFBD>@<40><><EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N(<28><><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD>)
#if($ENV{'HTTP_REFERER'} !~ /^http:\/\/$ENV{'HTTP_HOST'}\//)
if($ENV{'HTTP_REFERER'} !~ m#^http://(?:[-\w]+\.)?(?:2ch\.net|bbspink\.com|ula\.cc|u\.la|s2ch\.net|orz\.2ch\.io)/#)
{
print "Content-type: text/html; charset=shift_jis\n\n";
print <<EOF;
<html><head><title><3E>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I</title><meta http-equiv="Content-Type" content="text/html; charset=Shift_JIS"></head><body><3E>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>Freferer<65><72><EFBFBD>񂪕ςł<CF82><C582>B(ref1)$ENV{'HTTP_REFERER'}</body></html>
EOF
exit;
}
}
my $hap = time ;
$hap /= 60 ;
$hap /= 60 ;
$hap /= 24 ;
$hap = int($hap) ;
$hap += (($hap % 12000) * 1000) ;
# PON <20><> HAP <20><><EFBFBD>ێ<EFBFBD><DB8E><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
$GB->{PON} = $HOST;
$GB->{PONX} = "PON=$HOST";
$GB->{HAP} = $hap;
$GB->{HAPX} = "HAP=$hap";
# PON <20><><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD>΁A<CE81>Ƃ肠<C682><E882A0><EFBFBD><EFBFBD><EFBFBD>Ĕ<EFBFBD><C494>s<EFBFBD><73><EFBFBD><EFBFBD>
if(($GB->{COOKIES}{PON} || '') ne $GB->{PON})
{
# PON <20>𔭍s<F094AD8D><73><EFBFBD><EFBFBD>(<28><><EFBFBD><EFBFBD><EFBFBD>ɗL<C997><4C><EFBFBD>ɂȂ<C982>)
print "Set-Cookie: $GB->{PONX}; expires=$FOX->{COOKIEEXPIRES}; path=/\n";
}
else
{
# PON <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
$GB->{PONOK} = 1;
}
# Mozilla/4.0 <20>ł͂Ȃ<CD82><C882><EFBFBD>AHAP <20>͗L<CD97><4C><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ݂Ȃ<DD82>
# (<28><><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>Ă<EFBFBD><C482><EFBFBD>)
if($ENV{'HTTP_USER_AGENT'} !~ /Mozilla\/4\.0/)
{
$GB->{HAPOK} = 1;
}
# HAP <20><><EFBFBD>Ȃ<EFBFBD><C882>ꍇ or <20>ς<EFBFBD><CF82><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ĕ<EFBFBD><C494>s<EFBFBD><73><EFBFBD><EFBFBD>
if(($GB->{COOKIES}{HAP} || '') ne $GB->{HAP})
{
# <20>V<EFBFBD><56><EFBFBD><EFBFBD> HAP <20>𔭍s<F094AD8D><73><EFBFBD><EFBFBD>(<28><><EFBFBD><EFBFBD><EFBFBD>ɗL<C997><4C><EFBFBD>ɂȂ<C982>)
print "Set-Cookie: $GB->{HAPX}; expires=$FOX->{COOKIEEXPIRES}; path=/\n";
}
else
{
# HAP <20>͗L<CD97><4C><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(<28>O<EFBFBD><4F> HAP <20>ƈ<EFBFBD><C688>v<EFBFBD><76><EFBFBD><EFBFBD>)
$GB->{HAPOK} = 1;
}
# <20>@<40>I<EFBFBD>ȓ<EFBFBD><C893>e<EFBFBD>m<EFBFBD>F<EFBFBD><46><EFBFBD>ʂ̕\<5C><> & exit;
&HoutekiToukouKakunin($GB);
# <20><><EFBFBD><EFBFBD><EFBFBD>P<EFBFBD>[<5B>X(<28>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>͂悭<CD82><EFBFBD><ED82A9><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD>)
if($GB->{FORM}->{'bbs'} =~ /style\=/){exit;}
return $HOST;
}
#############################################################################
# <20>@<40>I<EFBFBD>ȓ<EFBFBD><C893>e<EFBFBD>m<EFBFBD>F<EFBFBD><46><EFBFBD>ʂ̕\<5C><>
#############################################################################
sub HoutekiToukouKakunin
{
my ($GB) = @_;
# <20>X<EFBFBD>L<EFBFBD>b<EFBFBD>v<EFBFBD>̎<EFBFBD><CC8E><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD>̓X<CD83><58><EFBFBD>[
if($GB->{KPASS}) {return 0;}
# <20>V<EFBFBD>K<EFBFBD>X<EFBFBD><58><EFBFBD>b<EFBFBD>h<EFBFBD><EFBFBD><EC90AC><EFBFBD><EFBFBD>(BBS_PASSWORD_CHECK)<29>̍ۂ̑΍<CC91>
# foxReadSettings <20>̑O<CC91>Ȃ̂ŁASETTING.TXT <20>̓<EFBFBD><CC93>e<EFBFBD><65>
# <20>܂<EFBFBD><DC82><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ł͎Q<CD8E>Ƃł<C682><C582>Ȃ<EFBFBD>
# <20>X<EFBFBD><58><EFBFBD>^<5E>C<EFBFBD><43><EFBFBD>Ȃ<EFBFBD><C882>āA
if(!($GB->{FORM}->{'subject'} ne ""))
{
# <20><><EFBFBD>A<C281>L<EFBFBD>[<5B><><EFBFBD>񂪒<EFBFBD><F182AA92>`<60><><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>Ȃ<EFBFBD><C882><EFBFBD>ɂ́A
if(!defined($GB->{FORM}->{'key'}))
{
# <20><><EFBFBD><EFBFBD><EFBFBD>͑f<CD91>ʂ肳<CA82><E882B3><EFBFBD>AfoxSetInformation <20>Ń`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD>
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> &newbbs <20><><EFBFBD>Ă΂<C482><CE82><EFBFBD> or
# <20>u<EFBFBD>T<EFBFBD>u<EFBFBD>W<EFBFBD>F<EFBFBD>N<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD>݂<EFBFBD><DD82>܂<EFBFBD><DC82><EFBFBD><EFBFBD>v<EFBFBD>G<EFBFBD><47><EFBFBD>[<5B>ɂȂ邱<C882>ƂɂȂ<C982>
return 0;
}
}
# <20>͂Ȃ<CD82><C882><EFBFBD><EFBFBD><EFBFBD> Cookie <20><><EFBFBD>L<EFBFBD><4C><EFBFBD><EFBFBD><EFBFBD>ǂ<EFBFBD><C782><EFBFBD>
my $isvalidPIN = ($GB->{COOKIES}{$GB->{PIN1}} || '') eq $GB->{PIN2};
# PON <20><> HAP <20><><EFBFBD>L<EFBFBD><4C><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>Ƃ<EFBFBD><C682><EFBFBD>(<28>K<EFBFBD>{)
if($GB->{PONOK} && $GB->{HAPOK})
{
# <20>͂Ȃ<CD82><C882><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̎<EFBFBD><CC8E><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>
if(($GB->{FORM}{$GB->{PIN1}} || '') eq $GB->{PIN2}) {return 0;}
# <20>͂Ȃ<CD82><C882><EFBFBD><EFBFBD><EFBFBD><EFBFBD>N<EFBFBD>b<EFBFBD>L<EFBFBD>[<5B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD>(<28><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ԓ<EFBFBD><D493>ɓ<EFBFBD><C993>e<EFBFBD><65><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682><EFBFBD><EFBFBD><EFBFBD>)
if($isvalidPIN) {return 0;}
}
# <20>t<EFBFBD>H<EFBFBD>[<5B><><EFBFBD>̎<EFBFBD><CC8E>Ԃ<EFBFBD><D482>Z<EFBFBD>b<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD>(<28>\<5C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ŏg<C58E>p<EFBFBD><70><EFBFBD>Ă<EFBFBD><C482><EFBFBD>)
$GB->{FORM}->{'time'} = time;
# <br> <20>Ƃ<EFBFBD><C682><EFBFBD><EFBFBD>o<EFBFBD>Ȃ<EFBFBD><C882><EFBFBD>ɁA<C981><EFBFBD>I<EFBFBD><49> foxReadForm <20>ʼn<EFBFBD><C589>H<EFBFBD><48><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>‚<EFBFBD><C282>߂<EFBFBD>
my %form;
foreach (qw/subject FROM mail MESSAGE/) {
$form{$_} = $GB->{FORM}{$_};
$form{$_} =~ s/&(?!(?:quo|[lg])t;)/&amp;/g if ($_ ne 'subject');
$form{$_} =~ s/"/&quot;/g;
}
if (defined $GB->{TRIPKEY}) {
$_ = $GB->{TRIPKEY};
s/&/&amp;/g;
s/</&lt;/g;
s/>/&gt;/g;
s/[[:cntrl:]]/'&#' . ord($&) . ';'/eg;
$GB->{FORM}{FROM} .= "#$_";
s/"/&quot;/g;
$form{FROM} .= "#$_";
}
$form{MESSAGE} =~ s/ ?<br> ?/&#10;/g;
# <20>w<EFBFBD>b<EFBFBD>_<EFBFBD><5F><EFBFBD>\<5C><><EFBFBD><EFBFBD><EFBFBD>āA<C481>A<EFBFBD>A
print "Content-type: text/html; charset=shift_jis\n\n";
# <20><><EFBFBD>e<EFBFBD>m<EFBFBD>F<EFBFBD><46><EFBFBD>ʂ<EFBFBD><CA82>\<5C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
my @kakuningamen0 = (
qq|<html><!-- 2ch_X:cookie -->|,
qq|<head>|
);
&PutLines(*STDOUT, @kakuningamen0);
# <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD>(DoS)<29>Ή<EFBFBD>(comic6<63><36><EFBFBD><EFBFBD><EFBFBD>^<5E>C<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD>ς<EFBFBD><CF82>Ă݂<C482>)
my $kakunintitle = qq|<title><3E><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݊m<DD8A>F <20><></title>|;
if($ENV{SERVER_NAME} =~ /comic6/)
{
$kakunintitle = qq|<title><3E><> <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݂̊m<CC8A>F <20><></title>|;
}
&Put1Line(*STDOUT, $kakunintitle);
my $submitButton = $isvalidPIN ? '<27>m<EFBFBD>F<EFBFBD><46><EFBFBD>ď<EFBFBD><C48F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>' : '<27><><EFBFBD>L<EFBFBD>S<EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ď<EFBFBD><C48F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>';
my @kakuningamen = (
qq|<META http-equiv="Content-Type" content="text/html; charset=x-sjis">|,
qq|<meta name="viewport" content="width=device-width,initial-scale=1.0,minimum-scale=1.0,maximum-scale=1.6,user-scalable=yes" />|,
qq|</head>|,
qq|<body bgcolor=#EEEEEE>|,
qq|<font size=+1 color=#FF0000><b><3E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݁<EFBFBD><DD81>N<EFBFBD>b<EFBFBD>L<EFBFBD>[<5B>m<EFBFBD>F</b></font>|,
qq|<ul><br><br>|,
qq|<b>$GB->{FORM}->{'subject'} </b><br>|,
qq|<7C><><EFBFBD>O<EFBFBD>F $GB->{FORM}->{'FROM'}<br>|,
qq|E-mail<69>F $GB->{FORM}->{'mail'}<br>|,
qq|<7C><><EFBFBD>e<EFBFBD>F<br>$GB->{FORM}->{'MESSAGE'}<br><br></ul>|,
# <20><><EFBFBD>̕<EFBFBD><CC95>ʂ͂͂Ȃ<CD82><C882><EFBFBD><EFBFBD><EFBFBD> Cookie <20><><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>o<EFBFBD><6F>
!$isvalidPIN ? (
qq|<b>|,
qq|<7C><><EFBFBD>e<EFBFBD>m<EFBFBD>F<br>|,
qq|<7C>E<EFBFBD><45><EFBFBD>e<EFBFBD>҂́A<CD81><41><EFBFBD>e<EFBFBD>Ɋւ<C98A><D682>Ĕ<EFBFBD><C494><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ӔC<D394><43><EFBFBD>S<EFBFBD>ē<EFBFBD><C493>e<EFBFBD>҂ɋA<C98B><41><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B<br>|,
qq|<7C>E<EFBFBD><45><EFBFBD>e<EFBFBD>҂́A<CD81>b<EFBFBD><62><EFBFBD>Ɩ<EFBFBD><C696>֌W<D68C>ȍL<C88D><4C><EFBFBD>̓<EFBFBD><CC93>e<EFBFBD>Ɋւ<C98A><D682>āA<C481><41><EFBFBD><EFBFBD><EFBFBD>̔<EFBFBD><CC94>p<EFBFBD><70><EFBFBD>x<EFBFBD><78><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><br>|,
qq|<7C>E<EFBFBD><45><EFBFBD>e<EFBFBD>҂́A<CD81><41><EFBFBD>e<EFBFBD><65><EFBFBD><EFBFBD><EA82BD><EFBFBD>e<EFBFBD>y<EFBFBD>т<EFBFBD><D182><EFBFBD><EFBFBD>Ɋ܂܂<DC82><DC82><EFBFBD><EFBFBD>m<EFBFBD>I<EFBFBD><49><EFBFBD>Y<EFBFBD><59><EFBFBD>A<EFBFBD>i<EFBFBD><69><EFBFBD><EFBFBD>@<40><>21<32><31><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD>28<32><38><EFBFBD>ɋK<C98B><EFBFBD><E882B3><EFBFBD><EFBFBD><E98CA0><EFBFBD><EFBFBD><EFBFBD>܂ށj|,
qq|<7C><><EFBFBD>̑<EFBFBD><CC91>̌<EFBFBD><CC8C><EFBFBD><EFBFBD>ɂ‚<C982><C282>i<EFBFBD><69><EFBFBD>O<EFBFBD>҂ɑ΂<C991><CE82>čċ<C48D><C48B><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E98CA0><EFBFBD><EFBFBD><EFBFBD>܂݂܂<DD82><DC82>B<EFBFBD>j<EFBFBD>A<EFBFBD>f<EFBFBD><66><EFBFBD>‰^<5E>c<EFBFBD>҂ɑ΂<C991><CE82>A<EFBFBD><41><EFBFBD><EFBFBD><EFBFBD>ŏ<EFBFBD><C58F>n<EFBFBD><6E><EFBFBD><EFBFBD>Ƃ<EFBFBD>|,
qq|<7C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B<EFBFBD><42><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD>e<EFBFBD><65><EFBFBD>ʂɒ<CA82><C992>߂<EFBFBD><DF82><EFBFBD>K<EFBFBD>C<EFBFBD>h<EFBFBD><68><EFBFBD>C<EFBFBD><43><EFBFBD>ɊY<C98A><59><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD>e<EFBFBD>Ɋւ<C98A><D682><EFBFBD><EFBFBD>m<EFBFBD>I<EFBFBD><49><EFBFBD>Y<EFBFBD><59><EFBFBD><EFBFBD><EFBFBD>̑<EFBFBD><CC91>̌<EFBFBD><CC8C><EFBFBD><EFBFBD>A|,
qq|<7C>`<60><><EFBFBD>͈<EFBFBD><CD88><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ԓ<EFBFBD><D493>e<EFBFBD>҂ɗ<D282><C997>ۂ<EFBFBD><DB82><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B<br>|,
qq|<7C>E<EFBFBD>f<EFBFBD><66><EFBFBD>‰^<5E>c<EFBFBD>҂́A<CD81><41><EFBFBD>e<EFBFBD>҂ɑ΂<C991><CE82>ē<EFBFBD><C493>{<7B><><EFBFBD><EFBFBD><EFBFBD>O<EFBFBD>ɂ<EFBFBD><C982><EFBFBD><EFBFBD>Ė<EFBFBD><C496><EFBFBD><EFBFBD>Ŕ<EFBFBD><C594>Ɛ<EFBFBD><C690>I<EFBFBD>ɕ<EFBFBD><C995><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD><4F><EFBFBD>M<EFBFBD>A|,
qq#<23>Еz<D095>y<EFBFBD>і|<7C>󂷂錠<F382B782><E98CA0><EFBFBD>𓊍e<F0938A8D>҂ɋ<D282><C98B><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B<EFBFBD>܂<EFBFBD><DC82>A<EFBFBD><41><EFBFBD>e<EFBFBD>҂͌f<CD8C><66><EFBFBD>‰^<5E>c<EFBFBD>҂<EFBFBD><D282>w<EFBFBD><EFBFBD><E882B7><EFBFBD><EFBFBD><EFBFBD>O<EFBFBD>҂ɑ΂<C991><CE82>āA<C481><41><EFBFBD>؂̌<D882><CC8C><EFBFBD><EFBFBD>i<EFBFBD><69><EFBFBD>O<EFBFBD>҂ɑ΂<C991><CE82>čċ<C48D><C48B><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E98CA0><EFBFBD><EFBFBD><EFBFBD>܂݂܂<DD82><DC82>j<EFBFBD><6A><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B<br>#,
qq|<7C>E<EFBFBD><45><EFBFBD>e<EFBFBD>҂́A<CD81>f<EFBFBD><66><EFBFBD>‰^<5E>c<EFBFBD>҂<EFBFBD><D282><EFBFBD>͂<EFBFBD><CD82>̎w<CC8E><EFBFBD><E882B7><EFBFBD>҂ɑ΂<C991><CE82>āA<C481><41><EFBFBD><EFBFBD><EFBFBD>Ґl<D290>i<EFBFBD><69><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>؍s<D88D>g<EFBFBD><67><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B<br>|,
qq|<br>|,
qq|</b>|
) : (),
# "<pre>Cookie:\n", join("\n", map("$_=$GB->{COOKIES}{$_}", keys %{$GB->{COOKIES}})), "\n</pre>",
qq|<form method=POST action="../test/bbs.cgi?guid=ON">|,
qq|<input type=hidden name=subject value="$form{subject}">|,
qq|<input TYPE=hidden NAME=FROM value="$form{FROM}">|,
qq|<input TYPE=hidden NAME=mail value="$form{mail}">|,
qq|<input type=hidden name=MESSAGE value="$form{MESSAGE}">|,
qq|<input type=hidden name=bbs value=$GB->{FORM}->{'bbs'}>|,
qq|<input type=hidden name=time value=$GB->{FORM}->{'time'}>|,
defined $GB->{FORM}{key} ? qq|<input type=hidden name=key value=$GB->{FORM}{key}>| : qq||,
!$isvalidPIN ? qq|<input type=hidden name="$GB->{PIN1}" value="$GB->{PIN2}">| : qq||,
qq|<br>|,
qq|<input type=submit value="$submitButton" name="submit"><br>|,
qq|</form>|,
qq|<7C>ύX<CF8D><58><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EA8D87>|, $#ARGV >= 0 && $ARGV[0] eq 'UTF-8' ? qq|<7C>L<EFBFBD><4C><EFBFBD><EFBFBD><EFBFBD>Z<EFBFBD><5A><EFBFBD><EFBFBD><EFBFBD><EFBFBD>| : qq|<7C>߂<EFBFBD><DF82>{<7B>^<5E><><EFBFBD>Ŗ߂<C596><DF82><EFBFBD>|, qq|<7C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ĉ<EFBFBD><C489><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B<br><br>|,
qq|<7C><><EFBFBD>݁A<DD81>r<EFBFBD><EFBFBD>΍<EFBFBD><CE8D>ŃN<C583>b<EFBFBD>L<EFBFBD>[<5B><><EFBFBD>ݒ肵<DD92>Ă<EFBFBD><C482>Ȃ<EFBFBD><C882>Ə<EFBFBD><C68F><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݂ł<DD82><C582>Ȃ<EFBFBD><C882><EFBFBD>ɂ<EFBFBD><C982>Ă<EFBFBD><C482>܂<EFBFBD><DC82>B<br>|,
qq|<font size=-1>(cookie<69><65><EFBFBD>ݒ肷<DD92><E882B7><EFBFBD>Ƃ<EFBFBD><C682>̉<EFBFBD><CC89>ʂ͂łȂ<C582><C882>Ȃ<EFBFBD><C882>܂<EFBFBD><DC82>B)</font><br>|,
qq|</body>|,
qq|</html>|,
#qq|<!-- $ENV{'HTTP_COOKIE'} ++ SPID=$CSPID -->|
);
&PutLines(*STDOUT, @kakuningamen);
# <20><><EFBFBD>ʏo<CA8F><6F><EFBFBD><EFBFBD><EFBFBD><EFBFBD> exit <20><><EFBFBD>Ă<EFBFBD><C482>܂<EFBFBD>
exit;
# return <20>͂<EFBFBD><CD82>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD>ǁA<C781>
return 0;
}
#############################################################################
# BBY/BBS/BBR
#############################################################################
sub foxDNSquery
{
my ($host, $nameserver) = @_ ;
# $host .= "bbs.timeout.peko.2ch.net.";
use Net::DNS;
my $res = Net::DNS::Resolver->new(recurse => 0,
nameservers => [$nameserver]);
$res->bgsend($host) ;
return 1 ;
}
#############################################################################
# BBQ/BBM/BBX/BBN/BBE
#############################################################################
sub foxDNSquery2
{
my ($host) = @_ ;
# $host .= "bbs.timeout.peko.2ch.net.";
use Net::DNS;
my $res = Net::DNS::Resolver->new;
$res->tcp_timeout(3);
$res->udp_timeout(3);
$res->retry(4);
my $query = $res->query($host) ;
if($query)
{
my @ans = $query->answer;
foreach(@ans)
{
return $_->address ;
}
}
if($res->errorstring eq 'query timed out') {return "127.0.0.0";}
return "127.0.0.1";
}
##########################################################################
# IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>Y<EFBFBD><59><EFBFBD><EFBFBD><EFBFBD><EFBFBD><E9838A><EFBFBD>[<5B>g<EFBFBD>z<EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>𓾂<EFBFBD>
# <20>t<EFBFBD><74><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD>IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD>̂܂ܕԂ<DC95>
# IPv4/IPv6<76><36><EFBFBD>ʂŎg<C58E><67><EFBFBD><EFBFBD><EFBFBD>͂<EFBFBD>
#
# <20><><EFBFBD><EFBFBD>: IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD><EFBFBD>(REMOTE_ADDR<44>Ƃ<EFBFBD><C682><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>)
# <20>߂<EFBFBD><DF82>l: <20><><EFBFBD><EFBFBD><EFBFBD>[<5B>g<EFBFBD>z<EFBFBD>X<EFBFBD>g<EFBFBD><67>(<28>t<EFBFBD><74><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݂<EFBFBD><DD82>Ȃ<EFBFBD><C882><EFBFBD><EA8D87>IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X)
##########################################################################
sub GetRemoteHostName
{
my ($ipaddr) = @_;
use Net::IP;
use Net::DNS;
# <20>z<EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ϐ<EFBFBD>
my $hostname = undef;
my $ip = new Net::IP($ipaddr);
my $res = Net::DNS::Resolver->new;
# <20>t<EFBFBD><74><EFBFBD><EFBFBD><EFBFBD>Ɏg<C98E><67><EFBFBD><EFBFBD><EFBFBD>`<60>ɂ<EFBFBD><C982><EFBFBD>
my $rev = $ip->reverse_ip();
$res->tcp_timeout(2);
$res->udp_timeout(2);
$res->retry(3);
# PTR<54><52><EFBFBD>R<EFBFBD>[<5B>h<EFBFBD><68><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
my $ans = $res->search($rev, 'PTR');
if ($ans)
{
foreach my $rr ($ans->answer)
{
if ($rr->type eq 'PTR')
{
$hostname = $rr->ptrdname;
last;
}
}
}
if ($hostname eq undef)
{
$hostname = $ipaddr;
}
return $hostname;
}
#############################################################################
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̐ݒ<CC90>
# <20>e<EFBFBD><65>PATH<54><48><EFBFBD><EFBFBD>
#############################################################################
sub foxSetPath
{
my ($GB) = @_ ;
$GB->{PATH} = "../$GB->{FORM}{bbs}/";
# <20><EFBFBD><E182BE><EFBFBD>܃T<DC83>[<5B>o<EFBFBD><6F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>[<5B>N<EFBFBD>G<EFBFBD><47><EFBFBD>A<EFBFBD><41><EFBFBD>ʂɂƂ<C982>
if(IsSnowmanServer == BBSD->{REMOTE})
{
# <20><><EFBFBD>[<5B>U<EFBFBD><55><EFBFBD><EFBFBD>getpwuid<69>łƂ<C582><C682>Ă<EFBFBD><C482><EFBFBD>
my $name = getpwuid($>);
$GB->{WPATH} = "/md/$name/$GB->{FORM}{bbs}/";
}
else
{
$GB->{WPATH} = $GB->{PATH};
}
$GB->{DATPATH} = "$GB->{PATH}dat/";
$GB->{LOGPATH} = "../../test/ggg/$GB->{FORM}{bbs}dat/";
$GB->{TEMPPATH} = "$GB->{PATH}html/";
$GB->{IMODEPATH} = "$GB->{PATH}i/";
$GB->{INDEXFILE} = "$GB->{PATH}index.html";
$GB->{SUBFILE} = "$GB->{PATH}subback.html";
# <20><EFBFBD><E182BE><EFBFBD>܃T<DC83>[<5B>o<EFBFBD>ł͈<C582><CD88>̃f<CC83>B<EFBFBD><42><EFBFBD>N<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD>
if(IsSnowmanServer != BBSD->{REMOTE})
{
my $ggg = "../../test/ggg/";
unless(-e $ggg){
# <20>ŏ<EFBFBD><C58F><EFBFBD>umask(0)<29><><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD>̂ŕs<C595>v
#umask(0);
mkdir($ggg,0777);
}
}
$GB->{DEBUG} .= "<22>e<EFBFBD><65><EFBFBD>o<EFBFBD>`<60>s<EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD> PATH=$GB->{PATH}<br>";
}
=begin comment
bbsd <20>֘A<D698>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD> BBSD.pm <20>Ɉ<EFBFBD><C988>C<EFBFBD>̂<EFBFBD><CC82>߃R<DF83><52><EFBFBD><EFBFBD><EFBFBD>g<EFBFBD>A<EFBFBD>E<EFBFBD>g
#############################################################################
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݁EID<49>̎폈<CC8E><ED8F88><EFBFBD>p<EFBFBD><70>bbsd<73><64><EFBFBD>Ăяo<D18F><6F>
#############################################################################
sub bbsd
{
# my (@Argv) = @_;
# return &bbsd_main(0, @Argv);
return &bbsd_main(0, @_);
}
#############################################################################
# DB<44><42><EFBFBD><EFBFBD><EFBFBD>p<EFBFBD><70>bbsd<73><64><EFBFBD>Ăяo<D18F><6F>
#############################################################################
sub bbsd_db
{
# my (@Argv) = @_;
# return &bbsd_main(1, @Argv);
return &bbsd_main(1, @_);
}
#############################################################################
# bbsd<73>Ƃ̊Ԃ̒ʐM<CA90><4D><EFBFBD>s<EFBFBD><73>
# <20>t<EFBFBD><74><EFBFBD>O: 0: <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݁EID<49>̎<EFBFBD><CC8E>̏<EFBFBD><CC8F><EFBFBD><EFBFBD>A1: DB<44><42><EFBFBD><EFBFBD>
#############################################################################
sub bbsd_main
{
# my ($flag, @Argv) = @_;
my $flag = shift;
use Socket;
# <20><EFBFBD><E282A2><EFBFBD><EFBFBD><ED82B9>IP<49>A<EFBFBD>h<EFBFBD><68><EFBFBD>X<EFBFBD>A<EFBFBD>|<7C>[<5B>g<EFBFBD>ԍ<EFBFBD><D48D>A<EFBFBD>^<5E>C<EFBFBD><43><EFBFBD>A<EFBFBD>E<EFBFBD>g<EFBFBD>l
my $BBSD_HOST = undef;
my $BBSD_PORT = undef;
my $BBSD_TIMEOUT = undef;
# <20>t<EFBFBD><74><EFBFBD>O<EFBFBD>ɂ<EFBFBD><C982><EFBFBD><EFBFBD>Ăԃz<D483>X<EFBFBD>g<EFBFBD>̃p<CC83><70><EFBFBD><EFBFBD><EFBFBD>[<5B>^<5E><><EFBFBD>ύX<CF8D><58><EFBFBD><EFBFBD>
if (!$flag)
{
$BBSD_HOST = inet_aton($FOX->{SNOWMAN}->{BBSD}->{HOST});
$BBSD_PORT = $FOX->{SNOWMAN}->{BBSD}->{PORT};
$BBSD_TIMEOUT = $FOX->{SNOWMAN}->{BBSD}->{TIMEOUT};
}
else
{
$BBSD_HOST = inet_aton($FOX->{SNOWMAN}->{DB}->{HOST});
$BBSD_PORT = $FOX->{SNOWMAN}->{DB}->{PORT};
$BBSD_TIMEOUT = $FOX->{SNOWMAN}->{DB}->{TIMEOUT};
}
my ($rfd, $str) = ('', '');
my $sin = sockaddr_in($BBSD_PORT, $BBSD_HOST);
socket(SOCK, AF_INET, SOCK_DGRAM, 0) || return "$!";
# send(SOCK, join("\x8", @Argv), 0, $sin) || (close(SOCK), return "$!");
send(SOCK, join("\x8", @_), 0, $sin) || (close(SOCK), return "$!");
vec($rfd, fileno(SOCK), 1) = 1;
if (select($rfd, undef, undef, $BBSD_TIMEOUT))
{
recv(SOCK, $str, 16384, 0) || (close(SOCK), return "$!");
}
else
{
$str = $FOX->{SNOWMAN}->{TIMEOUTMSG};
}
close(SOCK);
return $str;
}
=end comment
=cut
#############################################################################
# bbsd<73>̃^<5E>C<EFBFBD><43><EFBFBD>A<EFBFBD>E<EFBFBD>g<EFBFBD><67><EFBFBD>ǂ<EFBFBD><C782><EFBFBD><EFBFBD>`<60>F<EFBFBD>b<EFBFBD>N
# <20><><EFBFBD><EFBFBD>: $GB, bbsd<73>̖߂<CC96><DF82>l
#############################################################################
sub bbsd_TimeoutCheck
{
my ($GB, $errmsg) = @_;
if($errmsg eq (local $! = ETIMEDOUT))
{
return 1;
}
# <20><><EFBFBD><EFBFBD><EFBFBD>ȊO<C88A>͖߂<CD96>
return 0;
}
#############################################################################
# bbsd<73>̃^<5E>C<EFBFBD><43><EFBFBD>A<EFBFBD>E<EFBFBD>g<EFBFBD>G<EFBFBD><47><EFBFBD>[<5B>̏<EFBFBD><CC8F><EFBFBD>
# <20><><EFBFBD><EFBFBD>: $GB, <20><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD>ɏo<C98F>͂<EFBFBD><CD82><EFBFBD>߂̃R<CC83>}<7D><><EFBFBD>h<EFBFBD><68>
#############################################################################
sub bbsd_TimeoutError
{
my ($GB, $cmd) = @_;
&DispError2($GB, '<27>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>I', "<22>d<EFBFBD>q<EFBFBD>q<EFBFBD>n<EFBFBD>q<EFBFBD>F<EFBFBD>o<EFBFBD>b<EFBFBD>N<EFBFBD>G<EFBFBD><47><EFBFBD>h<EFBFBD>T<EFBFBD>[<5B>o<EFBFBD>Ƃ̒ʐM<CA90><4D><EFBFBD>^<5E>C<EFBFBD><43><EFBFBD>A<EFBFBD>E<EFBFBD>g<EFBFBD><67><EFBFBD>܂<EFBFBD><DC82><EFBFBD>($cmd)<29>B<EFBFBD><42><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>݂<EFBFBD><DD82><EFBFBD><EFBFBD>f<EFBFBD><66><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82><EFBFBD><EFBFBD>B");
# <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>߂邱<DF82>Ƃ͂Ȃ<CD82>(<28><><EFBFBD>A<EFBFBD>ꉞ)
return 0;
}
#############################################################################
# <20>w<EFBFBD><EFBFBD><E882B5><EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68><EFBFBD><EFBFBD>1<EFBFBD>s<EFBFBD>o<EFBFBD>͂<EFBFBD><CD82><EFBFBD>
# <20>g<EFBFBD><67><EFBFBD><EFBFBD>: &Put1Line(*FILE, $str);
#############################################################################
sub Put1Line
{
local (*FD) = shift;
print FD @_;
return 0;
}
#############################################################################
# <20>w<EFBFBD><EFBFBD><E882B5><EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68><EFBFBD>ɕ<EFBFBD><C995><EFBFBD><EFBFBD>s<EFBFBD>o<EFBFBD>͂<EFBFBD><CD82><EFBFBD>
# <20>g<EFBFBD><67><EFBFBD><EFBFBD>: &PutLines(*FILE, @str);
#############################################################################
sub PutLines
{
local (*FD) = shift;
print FD @_;
return 0;
}
#############################################################################
# end of bbs.entry.cgi
#############################################################################
1;