Function at 0x407150
Capabilities:
Get socket status
Receive data
Receive data on socket
Send data
Send data on socket
Send http request
Send http request with host header

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x658
mov eax, dword [0x51df40]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 0x644], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x648], eax
mov dword [ebp - 0x62c], 0
mov dword [ebp - 0x634], 0xffffffff
mov dword [ebp - 0x63c], 0
push edi
mov edi, 0x400
mov dword [ebp - 0x610], edi
test esi, esi
jne 0x4071ca
pop edi
mov dword [0x5203bc], esi
or eax, 0xffffffff
mov dword [0x5203c0], 2
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004d3ed5
mov esp, ebp
pop ebp
ret
mov ecx, esi
lea edx, [ecx + 1]
nop
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4071d0
sub ecx, edx
push ebx
lea eax, [ecx + 1]
push eax
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov ebx, eax
add esp, 4
mov dword [ebp - 0x620], ebx
test ebx, ebx
je 0x408189
mov ecx, esi
lea edx, [ecx + 1]
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407200
sub ecx, edx
lea eax, [ecx + 1]
push eax
push esi
push ebx
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncpy]
add esp, 0xc
push 5
push str.https
push ebx
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__strnicmp]
test eax, eax
push 0x4dd0f0
push ebx
sete byte [ebp - 0x640]
call sub.VCRUNTIME140.dll_strstr
test eax, eax
push 0x2f
lea ecx, [eax + 3]
cmove ecx, ebx
push ecx
mov dword [ebp - 0x630], ecx
call sub.VCRUNTIME140.dll_strchr
push edi
mov esi, eax
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov ebx, eax
add esp, 0x20
mov dword [ebp - 0x628], ebx
test ebx, ebx
je 0x40817a
mov byte [ebx], 0
test esi, esi
jne 0x4072e1
mov ecx, ebx
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407278
sub ecx, edx
mov eax, edi
sub eax, ecx
dec eax
cmp eax, 0xf
jg 0x4072ac
mov eax, dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
add edi, 0x10
push edi
push ebx
mov dword [ebp - 0x610], edi
call eax
add esp, 8
test eax, eax
je 0x4072c8
mov ebx, eax
mov dword [ebp - 0x628], eax
push str.HTTP_1.0
push str.GET____s_r_n
push edi
push ebx
call fcn.00408360
add esp, 0x10
test eax, eax
jns 0x407350
push dword [ebp - 0x620]
mov esi, dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
call esi
push ebx
call esi
add esp, 8
jmp 0x408189
mov ecx, esi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4072e6
sub ecx, edx
lea edx, [ecx + 0x10]
mov ecx, ebx
lea edi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x4072f7
sub ecx, edi
mov edi, dword [ebp - 0x610]
mov eax, edi
sub eax, ecx
dec eax
cmp eax, edx
jg 0x407330
mov eax, dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
inc edi
add edi, edx
push edi
push ebx
mov dword [ebp - 0x610], edi
call eax
add esp, 8
test eax, eax
je 0x4072c8
mov ebx, eax
mov dword [ebp - 0x628], eax
push str.HTTP_1.0
push esi
push str.GET__s__s_r_n
push edi
push ebx
call fcn.00408360
add esp, 0x14
test eax, eax
js 0x4072c8
mov byte [esi], 0
mov ecx, dword [ebp - 0x630]
lea edx, [ecx + 1]
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407360
sub ecx, edx
lea edx, [ecx + 0x89]
mov ecx, ebx
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407374
sub ecx, esi
mov eax, edi
sub eax, ecx
dec eax
cmp eax, edx
jg 0x4073aa
inc edx
add edi, edx
push edi
push ebx
mov dword [ebp - 0x610], edi
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
add esp, 8
test eax, eax
je 0x4072c8
mov ebx, eax
mov dword [ebp - 0x628], ebx
lea ecx, [ebx - 1]
nop dword [eax]
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x4073b0
mov eax, dword [str.Host:]
mov edx, dword [ebp - 0x630]
mov esi, edx
mov dword [ecx], eax
mov ax, word [0x4dd11c]
mov word [ecx + 4], ax
mov al, byte [0x4dd11e]
mov byte [ecx + 6], al
nop dword [eax + eax]
mov al, byte [edx]
inc edx
test al, al
jne 0x4073e0
sub edx, esi
lea edi, [ebx - 1]
nop dword [eax]
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4073f0
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [ebx - 1]
nop dword [eax]
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x407410
mov ax, word [0x4dd120]
mov word [ecx], ax
mov al, byte [0x4dd122]
mov byte [ecx + 2], al
cmp dword [0x51c0b8], 0
jne 0x40751b
mov ecx, dword [0x5203b4]
test ecx, ecx
je 0x40751b
lea edx, [ecx + 1]
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407450
sub ecx, edx
lea edx, [ecx + 0xc]
mov ecx, ebx
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407461
sub ecx, esi
mov esi, dword [ebp - 0x610]
mov eax, esi
sub eax, ecx
dec eax
cmp eax, edx
jg 0x40749d
inc esi
add esi, edx
push esi
push ebx
mov dword [ebp - 0x610], esi
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
add esp, 8
test eax, eax
je 0x4072c8
mov ebx, eax
mov dword [ebp - 0x628], ebx
lea ecx, [ebx - 1]
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x4074a0
mov eax, dword [str.Referer:]
mov dword [ecx], eax
mov eax, dword [0x4dd128]
mov dword [ecx + 4], eax
mov ax, word [0x4dd12c]
mov word [ecx + 8], ax
mov edx, dword [0x5203b4]
mov esi, edx
nop dword [eax + eax]
mov al, byte [edx]
inc edx
test al, al
jne 0x4074d0
sub edx, esi
lea edi, [ebx - 1]
nop dword [eax]
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4074e0
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [ebx - 1]
nop dword [eax]
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x407500
mov ax, word [0x4dd120]
mov word [ecx], ax
mov al, byte [0x4dd122]
mov byte [ecx + 2], al
cmp dword [0x5203b8], 0
jne 0x4076fb
mov ecx, dword [0x5203b0]
test ecx, ecx
jne 0x407634
mov ecx, ebx
lea edx, [ecx + 1]
nop dword [eax + eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407540
mov esi, dword [ebp - 0x610]
sub ecx, edx
mov eax, esi
sub eax, ecx
dec eax
cmp eax, 0x21
jg 0x40757d
add esi, 0x22
push esi
push ebx
mov dword [ebp - 0x610], esi
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
add esp, 8
test eax, eax
je 0x4072c8
mov ebx, eax
mov dword [ebp - 0x628], ebx
lea ecx, [ebx - 1]
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x407580
mov eax, dword [str.User_Agent:]
mov dword [ecx], eax
mov eax, dword [0x4dd134]
mov dword [ecx + 4], eax
mov eax, dword [0x4dd138]
mov dword [ecx + 8], eax
mov al, byte [0x4dd13c]
mov byte [ecx + 0xc], al
lea ecx, [ebx - 1]
nop dword [eax]
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x4075b0
mov eax, dword [str.HTTP_Fetcher]
lea edi, [ebx - 1]
mov dword [ecx], eax
mov eax, dword [0x4dd144]
mov dword [ecx + 4], eax
mov eax, dword [0x4dd148]
mov dword [ecx + 8], eax
mov al, byte [0x4dd14c]
mov byte [ecx + 0xc], al
nop dword [eax]
mov al, byte [edi + 1]
lea edi, [edi + 1]
test al, al
jne 0x4075e0
mov ax, word [0x4dd150]
lea ecx, [ebx - 1]
mov word [edi], ax
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x4075f6
mov eax, dword [str.1.1.0]
mov dword [ecx], eax
mov ax, word [0x4dd158]
mov word [ecx + 4], ax
lea ecx, [ebx - 1]
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x407614
mov ax, word [0x4dd120]
mov word [ecx], ax
mov al, byte [0x4dd122]
mov byte [ecx + 2], al
jmp 0x407701
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407637
sub ecx, edx
lea edx, [ecx + 0xf]
mov ecx, ebx
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407648
sub ecx, esi
mov esi, dword [ebp - 0x610]
mov eax, esi
sub eax, ecx
dec eax
cmp eax, edx
jg 0x407684
inc esi
add esi, edx
push esi
push ebx
mov dword [ebp - 0x610], esi
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
add esp, 8
test eax, eax
je 0x4072c8
mov ebx, eax
mov dword [ebp - 0x628], ebx
lea ecx, [ebx - 1]
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x407687
mov eax, dword [str.User_Agent:]
mov dword [ecx], eax
mov eax, dword [0x4dd134]
mov dword [ecx + 4], eax
mov eax, dword [0x4dd138]
mov dword [ecx + 8], eax
mov al, byte [0x4dd13c]
mov byte [ecx + 0xc], al
mov edx, dword [0x5203b0]
mov esi, edx
mov al, byte [edx]
inc edx
test al, al
jne 0x4076b8
sub edx, esi
lea edi, [ebx - 1]
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x4076c4
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [ebx - 1]
nop dword [eax]
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x4076e0
mov ax, word [0x4dd120]
mov word [ecx], ax
mov al, byte [0x4dd122]
mov byte [ecx + 2], al
mov esi, dword [ebp - 0x610]
mov ecx, ebx
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407706
sub ecx, edx
mov eax, esi
sub eax, ecx
dec eax
cmp eax, 0x15
jg 0x407741
add esi, 0x16
push esi
mov dword [ebp - 0x610], esi
mov esi, dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
push ebx
call esi
add esp, 8
test eax, eax
je 0x4072c8
mov ebx, eax
mov dword [ebp - 0x628], ebx
jmp 0x407747
mov esi, dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
lea ecx, [ebx - 1]
nop word [eax + eax]
mov al, byte [ecx + 1]
lea ecx, [ecx + 1]
test al, al
jne 0x407750
mov eax, dword [str.Connection:_Close_r_n_r_n]
mov dword [ecx], eax
mov eax, dword [0x4dd160]
mov dword [ecx + 4], eax
mov eax, dword [0x4dd164]
mov dword [ecx + 8], eax
mov eax, dword [0x4dd168]
mov dword [ecx + 0xc], eax
mov eax, dword [0x4dd16c]
mov dword [ecx + 0x10], eax
mov ax, word [0x4dd170]
mov word [ecx + 0x14], ax
mov ecx, ebx
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407790
sub ecx, edx
lea eax, [ecx + 1]
push eax
push ebx
call esi
mov ebx, eax
add esp, 8
mov dword [ebp - 0x624], ebx
test ebx, ebx
je 0x40815f
push dword [ebp - 0x640]
lea eax, [ebp - 0x61c]
push eax
push dword [ebp - 0x630]
call fcn.004081b0
add esp, 0xc
mov dword [ebp - 0x61c], eax
push dword [ebp - 0x620]
cmp eax, 0xffffffff
je 0x40813d
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov edi, ebx
add esp, 4
lea ecx, [edi + 1]
mov al, byte [edi]
inc edi
test al, al
jne 0x4077f1
mov esi, dword [ebp - 0x618]
sub edi, ecx
test esi, esi
jne 0x407818
push esi
push edi
mov edi, dword [ebp - 0x61c]
push ebx
push edi
call dword [sym.imp.WS2_32.dll_send]
mov ebx, eax
jmp 0x407867
call fcn.00405910
push edi
push ebx
push esi
call fcn.00405c70
mov ebx, eax
add esp, 0xc
test ebx, ebx
jns 0x407870
nop
push ebx
push esi
call fcn.00405c20
add esp, 8
cmp eax, 2
je 0x407844
cmp eax, 3
jne 0x407861
call fcn.00405910
push edi
push dword [ebp - 0x624]
push esi
call fcn.00405c70
mov ebx, eax
add esp, 0xc
test ebx, ebx
js 0x407830
jmp 0x407870
mov edi, dword [ebp - 0x61c]
cmp ebx, 0xffffffff
je 0x407b08
push dword [ebp - 0x624]
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
lea ebx, [ebp - 0x404]
xor edx, edx
mov dword [ebp - 0x624], edx
mov dword [ebp - 0x630], edx
cmp edx, 0x400
je 0x40796d
mov edi, dword [ebp - 0x61c]
mov eax, dword [0x51c0b4]
mov dword [ebp - 0x504], edi
mov dword [ebp - 0x508], 1
mov dword [ebp - 0x650], eax
lea ecx, [edi + 1]
mov dword [ebp - 0x64c], 0
test eax, eax
js 0x4078da
lea eax, [ebp - 0x650]
push eax
jmp 0x4078dc
push 0
push 0
push 0
lea eax, [ebp - 0x508]
push eax
push ecx
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
je 0x407b81
cmp eax, 0xffffffff
je 0x407b38
test esi, esi
jne 0x407912
push esi
push 1
push ebx
push edi
call dword [sym.imp.WS2_32.dll_recv]
mov edi, eax
jmp 0x407933
push 1
push ebx
push esi
call fcn.00405c40
mov edi, eax
add esp, 0xc
test edi, edi
jg 0x407933
push edi
push esi
call fcn.00405c20
add esp, 8
cmp eax, 6
je 0x40793c
cmp edi, 0xffffffff
je 0x407b38
mov edx, dword [ebp - 0x624]
mov al, byte [ebx]
inc edx
mov ecx, dword [ebp - 0x630]
mov dword [ebp - 0x624], edx
cmp al, 0xd
je 0x407963
inc ecx
xor edi, edi
cmp al, 0xa
cmovne ecx, edi
mov dword [ebp - 0x630], ecx
inc ebx
cmp ecx, 2
jne 0x407893
mov byte [ebx - 2], 0
test edx, edx
js 0x407b42
lea eax, [ebp - 0x404]
push str.HTTP_
push eax
call sub.VCRUNTIME140.dll_strstr
add esp, 8
test eax, eax
je 0x4080ea
cmp byte [eax], 0x20
je 0x4079a6
nop word [eax + eax]
inc eax
cmp byte [eax], 0x20
jne 0x4079a0
lea ecx, [ebp - 0x638]
inc eax
push ecx
push 0x4dd17c
push eax
call fcn.004056d0
mov ebx, eax
add esp, 0xc
mov dword [ebp - 0x624], ebx
cmp ebx, 1
jne 0x408097
mov eax, dword [ebp - 0x638]
cmp eax, 0xc8
jl 0x408039
cmp eax, 0x133
jg 0x408039
cmp eax, 0x12c
jl 0x407c1f
inc dword [ebp - 0x63c]
lea eax, [ebp - 0x404]
push str.Location:
push eax
call sub.VCRUNTIME140.dll_strstr
mov edi, eax
add esp, 8
test edi, edi
je 0x407a39
mov al, byte [edi + 9]
add edi, 9
test al, al
je 0x407a39
nop
movsx eax, al
push eax
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_isspace]
add esp, 4
test eax, eax
je 0x407a97
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x407a20
test esi, esi
je 0x407a57
push esi
call fcn.00405c60
push esi
call fcn.00405c10
push dword [ebp - 0x614]
call fcn.00405ba0
add esp, 0xc
mov edi, dword [ebp - 0x61c]
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [ebp - 0x638]
pop ebx
pop edi
mov dword [0x5203c4], eax
or eax, 0xffffffff
mov dword [0x5203bc], 0
mov dword [0x5203c0], 0xa
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004d3ed5
mov esp, ebp
pop ebp
ret
cmp byte [edi], 0
je 0x407a39
push 0x4dd18c
push edi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strcspn]
add esp, 8
mov dword [ebp - 0x638], eax
test eax, eax
jle 0x407c1f
inc eax
push eax
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
push dword [ebp - 0x638]
mov ebx, eax
push edi
push ebx
mov dword [ebp - 0x620], ebx
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncpy]
mov eax, dword [ebp - 0x638]
add esp, 0x10
mov edi, dword [ebp - 0x610]
mov byte [eax + ebx], 0
mov eax, dword [0x51c0bc]
test eax, eax
js 0x407218
cmp dword [ebp - 0x63c], eax
jg 0x407ba1
jmp 0x407218
test esi, esi
je 0x407b26
push esi
call fcn.00405c60
push esi
call fcn.00405c10
push dword [ebp - 0x614]
call fcn.00405ba0
add esp, 0xc
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
push dword [ebp - 0x624]
jmp 0x408180
mov dword [0x5203bc], 1
test esi, esi
je 0x407b60
push esi
call fcn.00405c60
push esi
call fcn.00405c10
push dword [ebp - 0x614]
call fcn.00405ba0
add esp, 0xc
mov edi, dword [ebp - 0x61c]
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
pop ebx
pop edi
or eax, 0xffffffff
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004d3ed5
mov esp, ebp
pop ebp
ret
mov eax, dword [0x51c0b4]
mov dword [0x5203bc], 0
mov dword [0x5203c0], 3
mov dword [0x5203c4], eax
jmp 0x407b42
test ebx, ebx
je 0x407bb4
push ebx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov eax, dword [0x51c0bc]
add esp, 4
xor ecx, ecx
cmp dword [ebp - 0x63c], eax
jl 0x407c2b
test ecx, ecx
jne 0x407c2b
test esi, esi
je 0x407be0
push esi
call fcn.00405c60
push esi
call fcn.00405c10
push dword [ebp - 0x614]
call fcn.00405ba0
add esp, 0xc
mov edi, dword [ebp - 0x61c]
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [0x51c0bc]
pop ebx
pop edi
mov dword [0x5203c4], eax
or eax, 0xffffffff
mov dword [0x5203bc], 0
mov dword [0x5203c0], 0xb
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004d3ed5
mov esp, ebp
pop ebp
ret
mov eax, dword [0x51c0bc]
mov ecx, 1
jmp 0x407bb6
lea eax, [ebp - 0x404]
push str.Content_Type:
push eax
call sub.VCRUNTIME140.dll_strstr
mov edi, eax
add esp, 8
test edi, edi
jne 0x407c63
lea eax, [ebp - 0x404]
push str.Content_type:
push eax
call sub.VCRUNTIME140.dll_strstr
mov edi, eax
add esp, 8
test edi, edi
je 0x407ce4
push 0x4dd120
push edi
call sub.VCRUNTIME140.dll_strstr
mov byte [eax], 0
lea eax, [edi + 0xd]
push eax
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll__strdup]
mov edi, eax
add esp, 0xc
mov eax, dword [ebp - 0x644]
mov ecx, edi
mov dword [eax], edi
mov al, byte [ecx]
test al, al
je 0x407c9c
cmp al, 0x20
jne 0x407c9c
mov al, byte [ecx + 1]
inc ecx
test al, al
jne 0x407c90
mov edx, ecx
lea ebx, [edx + 1]
mov al, byte [edx]
inc edx
test al, al
jne 0x407ca1
sub edx, ebx
lea eax, [edx + 1]
push eax
push ecx
push edi
call sub.VCRUNTIME140.dll_memmove
mov ebx, dword [ebp - 0x644]
add esp, 0xc
mov edx, dword [ebx]
mov ecx, edx
lea edi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x407cc5
sub ecx, edi
lea eax, [edx - 1]
add eax, ecx
cmp eax, edx
jbe 0x407ce4
cmp byte [eax], 0x20
jne 0x407ce4
mov byte [eax], 0
dec eax
cmp eax, dword [ebx]
ja 0x407cd7
lea eax, [ebp - 0x404]
push 0x4dd1b0
push eax
call sub.VCRUNTIME140.dll_strstr
add esp, 8
test eax, eax
jne 0x407d14
lea eax, [ebp - 0x404]
push str.Content_length:
push eax
call sub.VCRUNTIME140.dll_strstr
add esp, 8
test eax, eax
je 0x407d8a
lea ecx, [ebp - 0x634]
add eax, 0x10
push ecx
push 0x4dd17c
push eax
call fcn.004056d0
add esp, 0xc
mov dword [ebp - 0x624], eax
cmp eax, 1
jge 0x407d8a
test esi, esi
je 0x407d55
push esi
call fcn.00405c60
push esi
call fcn.00405c10
push dword [ebp - 0x614]
call fcn.00405ba0
add esp, 0xc
mov edi, dword [ebp - 0x61c]
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
pop ebx
pop edi
mov dword [0x5203bc], 0
or eax, 0xffffffff
mov dword [0x5203c0], 8
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004d3ed5
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x634]
mov edi, eax
mov dword [ebp - 0x640], edi
cmp edi, 0xffffffff
jne 0x407da8
mov eax, 0x32000
mov dword [ebp - 0x634], eax
push eax
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov ebx, eax
add esp, 4
test ebx, ebx
jne 0x407de8
test esi, esi
je 0x407dd6
push esi
call fcn.00405c60
push esi
call fcn.00405c10
push dword [ebp - 0x614]
call fcn.00405ba0
add esp, 0xc
mov edi, dword [ebp - 0x61c]
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
jmp 0x408189
cmp dword [ebp - 0x624], 0
jbe 0x407f94
cmp edi, 0xffffffff
je 0x407e08
mov ecx, dword [ebp - 0x62c]
cmp ecx, edi
jge 0x407f96
mov edi, dword [ebp - 0x61c]
mov eax, dword [0x51c0b4]
mov dword [ebp - 0x608], edi
mov dword [ebp - 0x60c], 1
mov dword [ebp - 0x658], eax
lea ecx, [edi + 1]
mov dword [ebp - 0x654], 0
test eax, eax
js 0x407e43
lea eax, [ebp - 0x658]
push eax
jmp 0x407e45
push 0
push 0
push 0
lea eax, [ebp - 0x60c]
push eax
push ecx
call dword [sym.imp.WS2_32.dll_select]
test eax, eax
je 0x407f33
cmp eax, 0xffffffff
je 0x407f04
mov eax, dword [ebp - 0x62c]
add eax, ebx
test esi, esi
jne 0x407e87
push esi
push dword [ebp - 0x634]
push eax
push edi
call dword [sym.imp.WS2_32.dll_recv]
mov edi, eax
jmp 0x407eac
push dword [ebp - 0x634]
push eax
push esi
call fcn.00405c40
mov edi, eax
add esp, 0xc
test edi, edi
jg 0x407eac
push edi
push esi
call fcn.00405c20
add esp, 8
cmp eax, 6
je 0x407ef3
cmp edi, 0xffffffff
je 0x407fa8
mov ecx, dword [ebp - 0x62c]
add ecx, edi
mov dword [ebp - 0x62c], ecx
test edi, edi
jle 0x407f96
mov eax, dword [ebp - 0x634]
add eax, ecx
push eax
push ebx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
add esp, 8
test eax, eax
je 0x407fa8
mov edi, dword [ebp - 0x640]
mov ebx, eax
jmp 0x407df5
mov ecx, dword [ebp - 0x62c]
mov dword [ebp - 0x62c], ecx
jmp 0x407f96
test esi, esi
je 0x407fcc
push esi
call fcn.00405c60
push esi
call fcn.00405c10
push dword [ebp - 0x614]
call fcn.00405ba0
add esp, 0xc
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
push ebx
jmp 0x408180
mov eax, dword [0x51c0b4]
mov dword [0x5203bc], 0
mov dword [0x5203c0], 4
mov dword [0x5203c4], eax
test esi, esi
je 0x407f6f
push esi
call fcn.00405c60
push esi
call fcn.00405c10
push dword [ebp - 0x614]
call fcn.00405ba0
add esp, 0xc
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
push ebx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
or eax, 0xffffffff
pop ebx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004d3ed5
mov esp, ebp
pop ebp
ret
xor ecx, ecx
lea eax, [ecx + 1]
push eax
push ebx
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_realloc]
add esp, 8
test eax, eax
jne 0x407fd9
test esi, esi
je 0x407fc6
push esi
call fcn.00405c60
push esi
call fcn.00405c10
push dword [ebp - 0x614]
call fcn.00405ba0
add esp, 0xc
mov edi, dword [ebp - 0x61c]
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
push ebx
jmp 0x408180
mov ebx, dword [ebp - 0x62c]
mov ecx, dword [ebp - 0x648]
mov byte [eax + ebx], 0
test ecx, ecx
jne 0x407ff9
push eax
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
jmp 0x407ffb
mov dword [ecx], eax
test esi, esi
je 0x408019
push esi
call fcn.00405c60
push esi
call fcn.00405c10
push dword [ebp - 0x614]
call fcn.00405ba0
add esp, 0xc
mov edi, dword [ebp - 0x61c]
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, ebx
pop ebx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004d3ed5
mov esp, ebp
pop ebp
ret
test esi, esi
je 0x408057
push esi
call fcn.00405c60
push esi
call fcn.00405c10
push dword [ebp - 0x614]
call fcn.00405ba0
add esp, 0xc
mov edi, dword [ebp - 0x61c]
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
mov eax, dword [ebp - 0x638]
pop ebx
pop edi
mov dword [0x5203c4], eax
or eax, 0xffffffff
mov dword [0x5203bc], 0
mov dword [0x5203c0], 7
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004d3ed5
mov esp, ebp
pop ebp
ret
test esi, esi
je 0x4080b5
push esi
call fcn.00405c60
push esi
call fcn.00405c10
push dword [ebp - 0x614]
call fcn.00405ba0
add esp, 0xc
mov edi, dword [ebp - 0x61c]
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
pop ebx
pop edi
mov dword [0x5203bc], 0
or eax, 0xffffffff
mov dword [0x5203c0], 6
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004d3ed5
mov esp, ebp
pop ebp
ret
test esi, esi
je 0x408108
push esi
call fcn.00405c60
push esi
call fcn.00405c10
push dword [ebp - 0x614]
call fcn.00405ba0
add esp, 0xc
mov edi, dword [ebp - 0x61c]
push edi
call dword [sym.imp.WS2_32.dll_closesocket]
pop ebx
pop edi
mov dword [0x5203bc], 0
or eax, 0xffffffff
mov dword [0x5203c0], 5
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004d3ed5
mov esp, ebp
pop ebp
ret
mov esi, dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
call esi
push ebx
call esi
add esp, 8
or eax, 0xffffffff
pop ebx
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004d3ed5
mov esp, ebp
pop ebp
ret
push dword [ebp - 0x620]
mov ebx, dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
call ebx
push dword [ebp - 0x628]
call ebx
add esp, 8
jmp 0x408189
push dword [ebp - 0x620]
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
add esp, 4
mov ecx, dword [ebp - 4]
or eax, 0xffffffff
pop ebx
pop edi
xor ecx, ebp
mov dword [0x5203bc], 1
pop esi
call fcn.004d3ed5
mov esp, ebp
pop ebp
ret