Function at 0x511280
Capabilities:
Read file on windows

Disassembly:
push ebp
push edi
mov eax, 0x143c
push esi
push ebx
call fcn.004ce940
mov edi, str.ftp:
sub esp, eax
mov ebx, ecx
mov ecx, 4
mov ebp, dword [esp + 0x1450]
mov esi, ebp
repe cmpsb byte [esi], byte es:[edi]
je 0x5112bd
mov edi, str.http:
mov ecx, 5
mov esi, ebp
repe cmpsb byte [esi], byte es:[edi]
jne 0x5114f4
lea edi, [esp + 0xc30]
mov dword [esp + 8], 0x800
mov dword [esp], ebp
mov dword [esp + 4], edi
call fcn.004e0330
test eax, eax
jne 0x5114e5
cmp ebx, dword [0x61fe40]
je 0x511820
lea esi, [esp + 0x430]
mov dword [esp + 8], 0x800
mov dword [esp + 4], ebp
mov dword [esp], esi
call fcn.00609ab0
mov dword [esp + 4], 0x23
mov dword [esp], esi
call sub.msvcrt.dll_strrchr
test eax, eax
je 0x51131e
mov byte [eax], 0
mov eax, dword [ebx + 0x944]
test eax, eax
je 0x511339
mov dword [esp + 4], esi
mov dword [esp], ebx
call eax
test eax, eax
je 0x5114e5
mov ecx, ebx
call fcn.00517980
lea eax, [ebx + 0x1160]
mov dword [esp + 4], esi
mov dword [esp + 8], 0x800
mov dword [esp], eax
call fcn.00609ab0
lea eax, [ebx + 0x960]
mov dword [esp + 4], esi
mov dword [esp + 8], 0x800
mov esi, eax
mov dword [esp], eax
mov dword [esp + 0x2c], eax
call fcn.00609ab0
mov dword [esp + 4], 0x2f
mov dword [esp], esi
call sub.msvcrt.dll_strrchr
test eax, eax
je 0x511810
cmp dword [esp + 0x2c], eax
jb 0x5117e0
lea esi, [esp + 0x30]
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], ebp
mov dword [esp + 8], str._HTML__HEAD__TITLE_Error__TITLE___HEAD__BODY__H1_Error__H1__P_Unable_to_follow_the_link___s_____s.__P___BODY_
mov dword [esp + 4], 0x400
mov dword [esp], esi
call fcn.0060b840
cmp ebx, dword [0x61fe40]
je 0x511880
mov ecx, ebx
call fcn.00517980
or dword [ebx + 0x40], 0x80
mov dword [esp], esi
call dword [sym.imp.msvcrt.dll__strdup]
mov ecx, ebx
mov dword [ebx + 0x480], eax
mov byte [0x61dc44], 1
call fcn.00511b50
mov edi, dword [ebx + 0x480]
mov byte [0x61dc44], 0
test edi, edi
je 0x5114e5
mov eax, dword [ebx + 0x1970]
test eax, eax
je 0x511800
mov edi, dword [ebx + 0x1c]
mov edx, dword [ebx + 0x1968]
sub edi, eax
cmp edx, edi
mov eax, edi
jl 0x5117c0
mov ecx, edx
mov esi, edx
shr ecx, 0x1f
test cl, cl
je 0x5117c0
lea ecx, [ebx + 0x1978]
mov dword [esp + 0xc], edx
mov dword [ebx + 0x1960], esi
mov dword [esp], esi
mov dword [esp + 8], 0
mov dword [esp + 4], eax
call fcn.0054f9f0
mov eax, dword [ebx + 0xc]
sub esp, 0x10
mov ecx, ebx
mov dword [esp], ebx
mov dword [esp + 4], eax
call fcn.00551980
mov ecx, ebx
sub esp, 8
call fcn.00552630
mov esi, dword [ebx + 0x480]
test esi, esi
je 0x5114e5
mov eax, dword [ebx + 0x1970]
test eax, eax
je 0x5117f2
mov edx, dword [ebx + 0x18]
sub edx, eax
mov eax, edx
mov edx, dword [ebx + 0x196c]
test edx, edx
jns 0x5117d0
cmp edx, eax
mov esi, edx
jl 0x5117d0
lea ecx, [ebx + 0x1a10]
mov dword [ebx + 0x1964], esi
mov dword [esp + 0xc], edx
mov dword [esp + 8], 0
mov dword [esp + 4], eax
mov dword [esp], esi
call fcn.0054f9f0
mov ecx, ebx
sub esp, 0x10
call fcn.00552630
add esp, 0x143c
xor eax, eax
pop ebx
pop esi
pop edi
pop ebp
ret 4
mov edi, str.https:
mov ecx, 6
mov esi, ebp
repe cmpsb byte [esi], byte es:[edi]
je 0x5112bd
mov edi, str.ipp:
mov ecx, 4
mov esi, ebp
repe cmpsb byte [esi], byte es:[edi]
je 0x5112bd
mov edi, 0x665a8c
mov ecx, 7
mov esi, ebp
repe cmpsb byte [esi], byte es:[edi]
je 0x5112bd
mov edi, str.news:
mov ecx, 5
mov esi, ebp
repe cmpsb byte [esi], byte es:[edi]
je 0x5112bd
cmp ebx, dword [0x61fe40]
je 0x51194a
lea esi, [esp + 0x430]
mov dword [esp + 8], 0x800
mov dword [esp + 4], ebp
mov dword [esp], esi
call fcn.00609ab0
mov dword [esp + 4], 0x23
mov dword [esp], esi
call sub.msvcrt.dll_strrchr
test eax, eax
je 0x5118e9
lea edi, [eax + 1]
mov byte [eax], 0
mov dword [esp + 0x2c], edi
mov eax, dword [ebx + 0x944]
test eax, eax
je 0x5118dc
mov dword [esp + 4], esi
mov dword [esp], ebx
lea edi, [ebx + 0x1160]
call eax
test eax, eax
mov ebp, eax
je 0x5114e5
mov ecx, ebx
call fcn.00517980
mov dword [esp], edi
lea edi, [ebx + 0x960]
mov dword [esp + 8], 0x800
mov dword [esp + 4], esi
call fcn.00609ab0
mov dword [esp + 8], 0x800
mov dword [esp + 4], esi
mov dword [esp], edi
call fcn.00609ab0
mov dword [esp + 4], 0x2f
mov dword [esp], edi
call sub.msvcrt.dll_strrchr
test eax, eax
je 0x5118f6
cmp edi, eax
jae 0x51160e
cmp byte [eax - 1], 0x2f
je 0x51160e
mov byte [eax], 0
mov esi, ebp
mov ecx, 5
mov edi, str.file:
repe cmpsb byte [esi], byte es:[edi]
lea eax, [ebp + 5]
mov dword [esp + 4], 0x665b0a
seta cl
setb dl
cmp cl, dl
cmove ebp, eax
mov dword [esp], ebp
call fcn.00608a20
test eax, eax
mov esi, eax
je 0x511902
mov dword [esp + 8], 2
mov dword [esp + 4], 0
mov dword [esp], eax
call sub.msvcrt.dll_fseek
mov dword [esp], esi
call sub.msvcrt.dll_ftell
mov dword [esp], esi
mov edi, eax
call sub.msvcrt.dll_rewind
lea eax, [edi + 1]
mov dword [esp + 4], 1
mov dword [esp], eax
call sub.msvcrt.dll_calloc
mov dword [esp + 0xc], esi
mov dword [ebx + 0x480], eax
mov dword [esp + 8], edi
mov dword [esp + 4], 1
mov dword [esp], eax
call sub.msvcrt.dll_fread
mov dword [esp], esi
call sub.msvcrt.dll_fclose
mov ecx, ebx
mov byte [0x61dc44], 1
call fcn.00511b50
mov ecx, dword [esp + 0x2c]
mov byte [0x61dc44], 0
test ecx, ecx
je 0x511956
mov edx, dword [ebx + 0x954]
test edx, edx
je 0x5114e5
mov eax, dword [esp + 0x2c]
lea esi, [esp + 0xc30]
mov dword [esp + 8], 0x20
mov dword [esp], esi
mov dword [esp + 4], eax
call fcn.00609ab0
mov eax, dword [ebx + 0x954]
mov dword [esp + 0x10], 0x50de70
mov dword [esp + 0xc], 0x24
mov dword [esp], esi
mov dword [esp + 8], eax
mov eax, dword [ebx + 0x95c]
mov dword [esp + 4], eax
call sub.msvcrt.dll_bsearch
test eax, eax
je 0x5114e5
mov esi, dword [eax + 0x20]
mov eax, dword [ebx + 0x480]
test eax, eax
je 0x5114e5
mov eax, dword [ebx + 0x1970]
test eax, eax
je 0x51196c
mov edi, dword [ebx + 0x1c]
mov ecx, esi
mov edx, dword [ebx + 0x1968]
shr ecx, 0x1f
sub edi, eax
test cl, cl
mov eax, edi
jne 0x511976
cmp edx, edi
jl 0x511976
cmp esi, edx
cmovg esi, edx
lea ecx, [ebx + 0x1978]
mov dword [esp + 0xc], edx
mov dword [ebx + 0x1960], esi
mov dword [esp], esi
mov dword [esp + 8], 0
mov dword [esp + 4], eax
call fcn.0054f9f0
mov eax, dword [ebx + 0xc]
sub esp, 0x10
mov ecx, ebx
mov dword [esp], ebx
mov dword [esp + 4], eax
call fcn.00551980
mov ecx, ebx
sub esp, 8
call fcn.00552630
jmp 0x5114e5
xor esi, esi
jmp 0x51143e
xor esi, esi
jmp 0x5114b7
cmp byte [eax - 1], 0x2f
je 0x51139c
mov byte [eax], 0
jmp 0x51139c
call fcn.0053ad80
jmp 0x511498
call fcn.0053ad80
jmp 0x51141a
mov byte [ebx + 0x960], 0
jmp 0x51139c
mov eax, dword [0x61fe6c]
test eax, eax
je 0x511830
mov ecx, ebx
call fcn.00552630
mov dword [0x61fe54], 0
mov dword [0x61fe5c], 0
mov dword [0x61fe50], 0
mov dword [0x61fe58], 0
mov dword [0x61fe44], 0
mov dword [0x61fe48], 0
mov dword [0x61fe6c], 0
jmp 0x5112ec
mov ebp, dword [0x61fe6c]
test ebp, ebp
je 0x511891
mov ecx, ebx
call fcn.00552630
mov dword [0x61fe54], 0
mov dword [0x61fe5c], 0
mov dword [0x61fe50], 0
mov dword [0x61fe58], 0
mov dword [0x61fe44], 0
mov dword [0x61fe48], 0
mov dword [0x61fe6c], 0
jmp 0x5113cc
lea ebp, [ebx + 0x1160]
mov edi, ebp
jmp 0x5115b4
mov dword [esp + 0x2c], 0
jmp 0x51158d
mov byte [ebx + 0x960], 0
jmp 0x51160e
call dword [sym.imp.msvcrt.dll__errno]
mov eax, dword [eax]
lea esi, [esp + 0x30]
mov dword [esp], eax
call sub.msvcrt.dll_strerror
mov dword [esp + 0xc], ebp
mov dword [esp + 0x10], eax
mov dword [esp + 8], str._HTML__HEAD__TITLE_Error__TITLE___HEAD__BODY__H1_Error__H1__P_Unable_to_follow_the_link___s_____s.__P___BODY_
mov dword [esp + 4], 0x400
mov dword [esp], esi
call fcn.0060b840
mov dword [esp], esi
call dword [sym.imp.msvcrt.dll__strdup]
mov dword [ebx + 0x480], eax
jmp 0x5116a7
mov ecx, ebx
call fcn.0050e000
jmp 0x511550
mov dword [esp], 0
mov ecx, ebx
call fcn.005172f0
sub esp, 4
jmp 0x5114e5
call fcn.0053ad80
jmp 0x511748
xor esi, esi
jmp 0x51176f