1

Immunity Debugger でマルウェアの一部をリバース エンジニアリングし、Python を使用してセットアップしたサーバーに接続しようとしているSimpleHTTPServerので、そこに置いたファイルをダウンロードできます。

への呼び出しHttpSendRequestAが失敗し続け、エラーが発生します: ERROR_SXS_KEY_NOT_FOUND (00002EE7)。「サーバー名またはアドレスを解決できませんでした」という意味だと理解しています。ただし、ブラウザからサーバーにアクセスでき (サーバーに置いたファイルが表示され、クリックして読み取ることができます)、サイトにアクセスすると要求を確認できます (以下を参照)。私は ping127.0.0.1と pingを使用127.0.0.1:8000しました。結果は以下のとおりです (最初は機能しますが、後者は機能しません)。127.0.0.1Immunity Debugger で、127.0.0.1:8000、を介してアクセスしようとしましたがhttps://127.0.0.1:8000/、すべて同じ結果が得られました。

HttpSendRequestAいくつかの API 呼び出し (リストと順序はこちら) の一部であることは認識しており、それらはすべてそこにあります。エラーがあると思われる場所にあるため、事前に3つの関数呼び出しを追加しました。

ping:

C:\Users\Daniel>ping 127.0.0.1

Pinging 127.0.0.1 with 32 bytes of data:
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128
Reply from 127.0.0.1: bytes=32 time<1ms TTL=128

Ping statistics for 127.0.0.1:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 0ms, Average = 0ms

C:\Users\Daniel>ping 127.0.0.1:8000
Ping request could not find host 127.0.0.1:8000. Please check the name and try a
gain. 

シンプルHTTPサーバー:

C:\Users\Daniel>cd Documents/
C:\Users\Daniel\Documents>cd tempServer
C:\Users\Daniel\Documents\tempServer>dir
Volume in drive C has no label.
Volume Serial Number is 9C0B-05CE

Directory of C:\Users\Daniel\Documents\tempServer

02/21/2014  12:48 PM    <DIR>          .
02/21/2014  12:48 PM    <DIR>          ..
02/21/2014  12:48 PM                11 data.txt
           1 File(s)             11 bytes
           2 Dir(s)  31,708,946,432 bytes free

C:\Users\Daniel\Documents\tempServer>python -m SimpleHTTPServer
Serving HTTP on 0.0.0.0 port 8000 ...
WIN-NATUEANO3LL - - [23/Feb/2014 17:16:56] "GET / HTTP/1.1" 200 -
WIN-NATUEANO3LL - - [23/Feb/2014 17:20:10] "GET /data.txt HTTP/1.1" 200 -
WIN-NATUEANO3LL - - [23/Feb/2014 17:32:28] "GET / HTTP/1.1" 200 -
WIN-NATUEANO3LL - - [23/Feb/2014 17:32:56] "GET / HTTP/1.1" 200 -

コード:

push    ebx             ; dwFlags          //0
push    ebx             ; lpszProxyBypass  //0
push    ebx             ; lpszProxy        //0
push    ebx             ; dwAccessType     //0
push    offset szAgent  ; "Windows+NT+5.1"
call    ds:Internet

push    ebx             ; dwContext        //0
push    400000h         ; dwFlags
mov     eax, offset szUserName
push    3               ; dwService
push    eax             ; lpszPassword     //0040B130
push    eax             ; lpszUserName     //0040B130
lea     eax, [ebp+szServerName]               
push    ebx             ; nServerPort      //000008000
push    eax             ; lpszServerName   //127.0.0.1
push    esi             ; hInternet        //handle to previous call
call    ds:InternetConnectA 

push    ebx                                         //0
push    4000000h        ; dwFlags
push    offset lpszAcceptTypes ; lplpszAcceptTypes
push    ebx             ; lpszReferrer              //0
lea     ecx, [ebp+fileToDownload] 
push    offset szPassword ; "HTTP/1.1"
push    ecx             ; lpszObjectName            //"/data.txt"
push    offset szVerb   ; "GET"                     
push    eax             ; hConnect                  //handle to previous call
call    ds:HttpOpenRequestA 
4

0 に答える 0