Can’t locate CGI/Carp.pm in @INC (@INC contains: /usr/local/lib64/perl5 错误修复

[Sat Aug 11 00:14:26.102705 2012] [cgi:error] [pid 5024] [client 222.65.114.1:56282] AH01215: Can’t locate CGI/Carp.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) at install.cgi line 3., referer: http://internet.baidu.com/
[Sat Aug 11 00:14:26.102796 2012] [cgi:error] [pid 5024] [client 222.65.114.1:56282] AH01215: BEGIN failed–compilation aborted at install.cgi line 3., referer: http://internet.baidu.com/

这个是因为默认未安装CGI的CARP模块引起的

解决办法
一次性编译安装所有主要模块

wget http://www.cpan.org/modules/by-module/CGI/CGI.pm-3.04.tar.gz
tar -zxvf CGI.pm-3.04.tar.gz
cd CGI*
perl Makefile.PL
make
make install

完成后尝试访问CGI页面
OK了吧?

相关:

  • Cant locate CGI pm in @INC
  • testing<img<!-- --> src=x onerror=alert(9903);//><!-- -->
  • testing<ifRAme sRc=9739 com></IfRamE>
  • Cant locate find pl in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib6
  • testing\\u0022onmouseover=qQtN(9003)\\u0022
  • testing<iframe src=\data:text/html;base64 PHNjcmlwdD5hbGVydCgnYWN1bmV0aXgteHNzLXRlc3QnKTwvc2NyaXB0Pgo=\ invalid=\9341\>
  • Cant locate find pl in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5
  • testing<ScRiPt/acu src=//testasp vulnweb com/t/xss js?9029></ScRiPt>
  • Cant locate CGI/Carp pm in @INC
  • testing<script>qQtN(9074)</script>

Centos tmp 目录安全 高级教程

Centos tmp目录安全 高级教程

一般被注入都有这个目录的安全问题导致的

cp /etc/fstab /etc/fstab.bak #备份fstab分区文件
cd /usr
dd if=/dev/zero of=tmpDSK bs=1024 count=2048000 # 建立空白文件 2048000 = 2G 1024000 = 1G
mkfs.ext3 -j /usr/tmpDSK # 格式化空白文件为ext3格式
cp -Rp /tmp /tmp_backup # 备份老的tmp目录下的文件

如果已经商用了系统 注意先停掉mysql和httpd相关服务
service httpd stop && service mysqld stop

mount -o loop,noexec,nosuid,rw /usr/tmpDSK /tmp #挂载到tmp分区覆盖
chmod 1777 /tmp #更改权限
cp -Rp /tmp_backup/* /tmp/ # 恢复备份文件到新挂载的分区

echo “/usr/tmpDSK /tmp ext3 loop,rw,noexec,nosuid,nodev 0 0” >> /etc/fstab # 系统启动时 自动挂载
rm -rf /var/tmp/ # 删除/var/tmp
ln -s /tmp/ /var/tmp # 建立快捷方式到/tmp下

这样就完成了

相关:

  • centOS tmp
  • testing}body{acu:Expre/**/SSion(XoyB(9978))}
  • testing\><script>XoyB(9061)</script>
  • testing<img/src=\>\ onerror=alert(9274)>
  • testing1z0WO <ScRiPt >XoyB(9484)</ScRiPt>
  • testing\onmouseover=XoyB(9299)\
  • testing<WAT9CQ>6PJT5[! !]</WAT9CQ>
  • testing<WI0AJF>KFPDS[! !]</WI0AJF>
  • testing9271829
  • testing<img src=xyz OnErRor=XoyB(9503)>
Scroll to top