Function at 0x520e50
Capabilities:
Reference http user-agent string

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x6c0c85
mov eax, dword fs:[0]
push eax
sub esp, 0x22c
mov eax, dword [0x76a02c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x230], 0
cmp dword [ebp + 0xc], 0
jne 0x520eaf
push 0
mov ecx, dword [ebp + 8]
call fcn.0040f960
mov eax, dword [ebp - 0x230]
or eax, 1
mov dword [ebp - 0x230], eax
mov eax, dword [ebp + 8]
jmp 0x5211b0
push 0x744352
lea eax, [ebp - 0x14]
push eax
call fcn.0051ff70
add esp, 8
mov dword [ebp - 4], 0
mov eax, dword [ebp + 0x14]
push eax
lea ecx, [ebp - 0x14]
call fcn.00520200
mov ecx, eax
call fcn.00523a10
push 0
lea ecx, [ebp - 0x14]
call fcn.00520200
mov ecx, eax
call fcn.00523a30
push 0x104
push 0
lea eax, [ebp - 0x118]
push eax
call fcn.00530310
add esp, 0xc
mov dword [ebp - 0x11c], 0x104
lea eax, [ebp - 0x11c]
push eax
lea ecx, [ebp - 0x118]
push ecx
push 0x10000001
call sub.urlmon.dll_ObtainUserAgentString
lea eax, [ebp - 0x118]
push eax
lea ecx, [ebp - 0x134]
call fcn.0040f960
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x13c]
call fcn.0040e1d0
mov byte [ebp - 4], 2
cmp dword [ebp + 0x18], 0
je 0x520f7b
lea eax, [ebp + 0x18]
push eax
push str.User_Agent
lea ecx, [ebp - 0x1fc]
push ecx
call fcn.0051fee0
add esp, 0xc
push eax
lea edx, [ebp - 0x204]
push edx
lea ecx, [ebp - 0x13c]
call fcn.0051fe60
jmp 0x520fd4
lea eax, [ebp - 0x134]
push eax
push str.User_Agent
lea ecx, [ebp - 0x220]
push ecx
call fcn.0051ff20
add esp, 0xc
mov dword [ebp - 0x234], eax
mov edx, dword [ebp - 0x234]
mov dword [ebp - 0x238], edx
mov byte [ebp - 4], 3
mov eax, dword [ebp - 0x238]
push eax
lea ecx, [ebp - 0x228]
push ecx
lea ecx, [ebp - 0x13c]
call fcn.0051fea0
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x220]
call fcn.00520160
sub esp, 8
mov ecx, esp
mov dword [ebp - 0x22c], esp
lea eax, [ebp - 0x13c]
push eax
call fcn.00520060
lea ecx, [ebp - 0x14]
call fcn.00520200
mov ecx, eax
call fcn.00523840
call fcn.005211d0
movzx eax, al
test eax, eax
je 0x52103f
push str.127.0.0.1:8888
lea ecx, [ebp - 0x154]
call fcn.0040f960
mov byte [ebp - 4], 4
lea eax, [ebp - 0x154]
push eax
lea ecx, [ebp - 0x14]
call fcn.00520200
mov ecx, eax
call fcn.005238b0
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x154]
call fcn.00403420
lea ecx, [ebp - 0x16c]
call fcn.004109e0
mov byte [ebp - 4], 5
mov eax, dword [ebp + 0xc]
push eax
lea ecx, [ebp - 0x184]
call fcn.0040f960
mov byte [ebp - 4], 6
lea eax, [ebp - 0x184]
push eax
lea ecx, [ebp - 0x1b4]
push ecx
lea ecx, [ebp - 0x14]
call fcn.00520200
mov ecx, eax
call fcn.00523f90
mov byte [ebp - 4], 7
cmp dword [ebp + 0x10], 0
je 0x521093
mov eax, dword [ebp + 0x10]
mov ecx, dword [ebp - 0x1b4]
mov dword [eax], ecx
cmp dword [ebp - 0x1b4], 0xc8
je 0x521123
lea eax, [ebp - 0x16c]
push eax
mov ecx, dword [ebp + 8]
call fcn.0040f760
mov ecx, dword [ebp - 0x230]
or ecx, 1
mov dword [ebp - 0x230], ecx
mov byte [ebp - 4], 6
lea ecx, [ebp - 0x1b4]
call fcn.005201c0
mov byte [ebp - 4], 5
lea ecx, [ebp - 0x184]
call fcn.00403420
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x16c]
call fcn.00403420
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x13c]
call fcn.00410950
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x134]
call fcn.00403420
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call fcn.00520180
mov eax, dword [ebp + 8]
jmp 0x5211b0
lea eax, [ebp - 0x1b0]
push eax
lea ecx, [ebp - 0x16c]
call fcn.00410250
lea eax, [ebp - 0x16c]
push eax
mov ecx, dword [ebp + 8]
call fcn.0040f760
mov ecx, dword [ebp - 0x230]
or ecx, 1
mov dword [ebp - 0x230], ecx
mov byte [ebp - 4], 6
lea ecx, [ebp - 0x1b4]
call fcn.005201c0
mov byte [ebp - 4], 5
lea ecx, [ebp - 0x184]
call fcn.00403420
mov byte [ebp - 4], 2
lea ecx, [ebp - 0x16c]
call fcn.00403420
mov byte [ebp - 4], 1
lea ecx, [ebp - 0x13c]
call fcn.00410950
mov byte [ebp - 4], 0
lea ecx, [ebp - 0x134]
call fcn.00403420
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x14]
call fcn.00520180
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00468d3e
mov esp, ebp
pop ebp
ret