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

Disassembly:
sub esp, 0x28
push ebx
push ebp
push esi
push edi
push 0x400
push 0x40
mov dword [esp + 0x18], 0x400
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
mov edx, dword [esp + 0x48]
mov ebx, eax
lea eax, [esp + 0x10]
mov edi, edx
push eax
or ecx, 0xffffffff
xor eax, eax
push ebx
repne scasb al, byte es:[edi]
not ecx
dec ecx
push ecx
push edx
call fcn.00401d60
mov ebp, dword [esp + 0x54]
or ecx, 0xffffffff
mov edi, ebp
xor eax, eax
repne scasb al, byte es:[edi]
mov edx, dword [esp + 0x20]
not ecx
dec ecx
lea eax, [ecx + edx + 0x1e]
push eax
call fcn.004039b0
mov esi, eax
mov edi, ebp
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
mov edx, dword [esp + 0x24]
mov edi, esi
not ecx
dec ecx
lea ecx, [ecx + edx + 0x1e]
mov edx, ecx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
xor edx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov ax, word [0x40b368]
mov word [esp + 0x32], dx
mov word [esp + 0x40], ax
xor ecx, ecx
mov word [esp + 0x30], ax
push edx
lea eax, [esp + 0x44]
mov dword [esp + 0x46], ecx
push 9
push eax
mov dword [esp + 0x52], ecx
mov byte [esp + 0x40], dl
call fcn.00401e70
push 2
lea ecx, [esp + 0x40]
push 4
push ecx
call fcn.00401e70
lea edx, [esp + 0x48]
lea eax, [esp + 0x58]
push edx
push ebx
push eax
push ebp
push str._s_c_stitle_sid_s
push esi
call fcn.0040395e
add esp, 0x44
push ebx
call dword [sym.imp.KERNEL32.dll_LocalFree]
push 0
push 0
push 0
push 0
push str.Mozilla_5.0__Windows_NT_6.1__rv:30.0__Gecko_20100101_Firefox_30.0
call dword [0x40b1e0]
mov ebp, eax
test ebp, ebp
je 0x4020fd
mov ecx, dword [esp + 0x40]
mov edx, dword [esp + 0x3c]
push 0
push 0
push 3
push 0
push 0
push ecx
push edx
push ebp
call dword [0x40b1dc]
mov edi, eax
test edi, edi
mov dword [esp + 0x48], edi
je 0x4020f6
push 0
lea eax, [esp + 0x28]
push 0x84c01100
push eax
push 0
push str.HTTP_1.1
push esi
push 0x40a128
push edi
mov dword [esp + 0x44], str.text_html_application_xhtmlxml_application_xml_q0.9___q0.8
mov dword [esp + 0x48], 0
call dword [0x40b1d8]
mov ebx, eax
test ebx, ebx
jne 0x4020bd
push edi
call dword [0x40b1cc]
push ebp
call dword [0x40b1cc]
push esi
call fcn.00403953
add esp, 4
xor al, al
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x28
ret
lea ecx, [esp + 0x18]
push 4
push ecx
push 6
push ebx
mov dword [esp + 0x28], 0x2710
call dword [0x40b1c8]
push 0
push 0
push 0
push 0
push ebx
call dword [0x40b1d4]
test eax, eax
jne 0x402110
push ebx
call dword [0x40b1cc]
push edi
call dword [0x40b1cc]
push ebp
call dword [0x40b1cc]
push esi
call fcn.00403953
add esp, 4
xor al, al
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x28
ret
push esi
call fcn.00403953
mov esi, dword [esp + 0x50]
add esp, 4
lea edx, [esp + 0x14]
xor edi, edi
push edx
push 0x400
push esi
push ebx
mov dword [esp + 0x24], edi
call dword [0x40b1d0]
test eax, eax
je 0x40215b
mov eax, dword [esp + 0x14]
test eax, eax
je 0x40215b
add esi, eax
add edi, eax
lea eax, [esp + 0x14]
push eax
push 0x400
push esi
push ebx
call dword [0x40b1d0]
test eax, eax
jne 0x402139
mov ecx, dword [esp + 0x50]
push ebx
mov dword [ecx], edi
call dword [0x40b1cc]
mov edx, dword [esp + 0x48]
push edx
call dword [0x40b1cc]
push ebp
call dword [0x40b1cc]
pop edi
pop esi
pop ebp
mov al, 1
pop ebx
add esp, 0x28
ret