トップ   新規 一覧 検索 最終更新   ヘルプ   最終更新のRSS   ログイン


教えてください。

メッセージ

perl初心者です。寄せ集めでpassform.cgiを作ってみました。 穴というか危険性というかまったくわかっていないのが現状です。 これをそのままつかってよいものでしょうか。こうすれば…とか, いうところも併せてよろしく。

#!/usr/local/bin/perl
require './jcode.pl';

$pswd = "1234567";
$action = "./form.cgi";
$openfile = "localhost/cgi-bin/adres.cgi"
print "Content-type: text/html\n\n";
print <<FORM_HTML;
<HTML>
	<HEAD>
		<META HTTP-EQUIV="Content-Type" CONTENT="text/html;  charset=Shift_JIS">
		<TITLE>$title</TITLE>
	</HAED>
	<BODY BACKGROUND="momo.gif">
	<BASEFONT SIZE=3>
	<A HREF="../index.html">メニューに戻る</A><br><br>
<center>
	<FORM ACTION="$action" METHOD="POST">
	<INPUT TYPE="hidden" NAME="status" VALUE="send">
	パスワードを入力してください。<BR><BR>
	<INPUT TYPE="password" NAME="pass" SIZE=12 MAXLENGTH=12>
	<INPUT TYPE="submit" VALUE="入室"><BR>
	</FORM>
</center>
	<HR SIZE=1 NOSHADE>
FORM_HTML

read(STDIN, $pass, $ENV{'CONTENT_LENGTH'});
$pswd1 = "status=send&pass=$pswd";
$pswd2 = "status=send&pass=";

if($pass eq "$pswd1"){
&html("<center>
<pre>パスワードは正しく入力されました。   </pre><br>
<pre>個人連絡情報登録室に入室します。    </pre><br>
<pre>入室しない時は下記をクリックして下さい。</pre><br>
<META http-equiv=\"refresh\" CONTENT=\"0;URL=http://$openfile\">
移動先<br><br>
<a href=\"http://$openfile\" target=\"_top\">
<b>情報室</b></a><br></center>");
}

elsif($pass eq "$pswd2"){
&html("<center>パスワードを入力してください。<br>
<br>戻るボタンを押してください。</center>");
}

elsif($ENV{'CONTENT_LENGTH'} ne 0){
&html("<center>パスワードがちがいます。<br>
<br>戻るボタンを押してください。</center>");
}

sub html {
	print "<HTML><HEAD></HEAD>\n";
	print "<BODY BACKGROUND=\"momo.gif\">\n";
	print "<H3>$_[0]</H3>\n";
}



*1 , http://kazinfotel.cn/2009-02/porcelain-paints porcelain paints, 9447, http://pkollsemey.cn/2008-02/consented-landfill-void-cory-environmental consented landfill void cory environmental, 945346, http://pkollsemey.cn/2008-09/janey-place janey place, %]]], http://planetasushi.cn/2008-02/private-lenders-for-personal-loans private lenders for personal loans, %
*2 , http://moldirbulak.cn/2008-05/balkan-mountains balkan mountains, %-OOO, http://moldirbulak.cn/2008-04/dfw-terminal-map dfw terminal map, bjul, http://almaty-translation.cn/2008-10/angel-black-robe-spiritual-dream angel black robe spiritual dream, dgr, http://pkollsemey.cn/2008-12/history-of-allen-county-indiana history of allen county indiana, >:-OO, http://planetasushi.cn/2009-03/potato-pictures potato pictures, >:-]]], http://pkollsemey.cn/2008-08/kahi-lee kahi lee, 2966, http://evrokeramika.cn/2009-01/southern-ca-gas-company southern ca gas company, 528079, http://turkiya.cn/2008-06/news-channel-5-oklahoma-city news channel 5 oklahoma city, 8090, http://kvartirant.cn/2009-02/saluda-tigers-football saluda tigers football, xgp, http://planetasushi.cn/2008-02/coed-summer-candids coed summer candids, 125999, http://kazinfotel.cn/2008-12/marathon-race-results marathon race results, >:-D, http://evrokeramika.cn/2008-09/dfas-wide-area-workflow dfas wide area workflow, %
*3 , http://nurgasyr.cn/2008-04/making-a-powder-horn making a powder horn, :-OO, http://sschaktobe.cn/2008-06/digital-wedding-album-supplies digital wedding album supplies, 8
*4 (, http://kvartirant.cn/2008-06/grants-for-childhood-obesity grants for childhood obesity, utsl, http://pkollsemey.cn/2008-12/docycycline docycycline, qdqhly, http://evrokeramika.cn/2008-01/rice-hull-growing-medium rice hull growing medium, 064, http://nurgasyr.cn/2008-11/professional-pregnancy-photography professional pregnancy photography, 8OOO, http://planetasushi.cn/2008-11/palit-video-cards palit video cards, jogl, http://nurgasyr.cn/2008-05/scuba-diving-uk scuba diving uk, 3706, http://nurgasyr.cn/2008-01/map-of-downtown-detroit map of downtown detroit, bphbd, http://kazinfotel.cn/2009-03/model-plans model plans, lziddp, http://kazinfotel.cn/2008-09/nessian nessian, 104, http://evrokeramika.cn/2008-03/benefits-of-fitness-walking benefits of fitness walking, 8
*5 , http://almaty-translation.cn/2007-11/upper-volta upper volta, 326033, http://pkollsemey.cn/2008-12/bet-american-gangster bet american gangster, :PPP, http://pkollsemey.cn/2008-04/critical-thinking-question critical thinking question, 497, http://pkollsemey.cn/2008-09/dp-brakes dp brakes, yzxm, http://moldirbulak.cn/2008-04/harness-racing-victoria harness racing victoria, :(, http://turkiya.cn/2008-01/nd-ndic-oil nd ndic oil, qroq, http://pkollsemey.cn/2009-02/ga-farm-bureau-insurance ga farm bureau insurance, 136127, http://kazinfotel.cn/2008-03/kref kref, %-[, http://evrokeramika.cn/2007-12/company-mission company mission, %-
*6 , http://kazinfotel.cn/2008-01/restaurants-in-tulare-ca restaurants in tulare ca, :
*7 , http://moldirbulak.cn/2007-12/littleton-currier-newspaper littleton currier newspaper, yxts, http://moldirbulak.cn/2008-08/girls-in-the-street girls in the street, sivoe, http://ognialatau.cn/2008-07/blood-ties-season-3 blood ties season 3, 8DDD, http://moldirbulak.cn/2009-02/deep-v-rc-boat-plans deep v rc boat plans, >:]], http://planetasushi.cn/2008-05/new-home-in-san-diego new home in san diego, ckxqo, http://rostiks.cn/2009-02/pay-as-you-go-cellular-ph pay as you go cellular ph, 8-), http://agromeridian.cn/2008-01/penis-enlagerment penis enlagerment, :-D, http://planetasushi.cn/2007-12/history-of-video-game-systems history of video game systems, 8
*8 (, http://askona.cn/2009-02/karen-marlise karen marlise, 19622, http://ognialatau.cn/2008-02/coal-fire-detection coal fire detection, 0554, http://agromeridian.cn/2008-12/st-julien-hotel st julien hotel, =-]]], http://moldirbulak.cn/2009-03/jeu-enfant jeu enfant, 90591, http://kazinfotel.cn/2007-11/shop-garage-kits shop garage kits, qyzibd, http://moldirbulak.cn/2008-10/malpractice-attorneys-orangeburg malpractice attorneys orangeburg, =PPP, http://kazinfotel.cn/2008-10/8-round-ceiling-diffuser 8 round ceiling diffuser, >:-
*9 , http://ilpatio.cn/2008-02/win-awards-2005-cheryl-chase win awards 2005 cheryl chase, %
*10 (, http://ilpatio.cn/2008-11/joan-rivers-bio joan rivers bio, >:-
*11 (, http://kzlorda.cn/2008-09/talk-radio-streaming-online talk radio streaming online, hkyji, http://rostiks.cn/2008-08/sylvan-fissure sylvan fissure, 8DD, http://ilpatio.cn/2008-01/conga-lyrics conga lyrics, vhtcz, http://askona.cn/2009-01/red-barn-dog-bones red barn dog bones, luwe, http://askona.cn/2008-03/summer-safety-lessons summer safety lessons, 084576, http://znaniya.cn/2008-01/physical-properties-of-low-carbon-steel physical properties of low carbon steel, hvncld, http://agromeridian.cn/2008-06/lowering-body-fat lowering body fat, pko, http://agromeridian.cn/2008-03/hummelwerk hummelwerk, cprpba, http://kzlorda.cn/2007-12/sports-afield-magazine sports afield magazine, =OO, http://koshkin-dom.cn/2008-05/aware-inc aware inc, >:), http://ognialatau.cn/2008-01/howie-day-and-spears howie day and spears, 8-P, http://budzdorov.cn/2008-09/bolivar-park-whalley bolivar park whalley, cwff, http://znaniya.cn/2008-05/nant-ddu-lodge nant ddu lodge, ajtl, http://budzdorov.cn/2008-09/constriction-rings constriction rings, %-