Function at 0x4cace0
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x27c
mov eax, dword [0x5bc324]
xor eax, esp
mov dword [esp + 0x278], eax
push ebx
mov ebx, dword [ebp + 8]
mov eax, edx
mov dword [esp + 0x30], ecx
xorps xmm0, xmm0
mov ecx, dword [ebp + 0x10]
mov dword [esp + 0x2c], eax
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x34], ecx
mov dword [esp + 8], 0
movlpd qword [esp + 0x10], xmm0
mov dword [esp + 0x20], 0
mov dword [eax], 0
push esi
mov esi, dword [ebp + 0xc]
push edi
test ebx, ebx
je 0x4cb32d
call fcn.004cb520
mov edi, eax
mov dword [esp + 0x14], edi
test edi, edi
jne 0x4cad66
lea eax, [edi + 0x1b]
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x278]
xor ecx, esp
call fcn.00523a6a
mov esp, ebp
pop ebp
ret
push edi
test esi, esi
mov eax, str.Content_Type:_multipart_form_data
cmovne eax, esi
push eax
push str._s__boundary_s_r_n
lea eax, [esp + 0x1c]
push 0
push eax
call fcn.004ca760
mov esi, eax
add esp, 0x14
test esi, esi
je 0x4cadad
push edi
call dword [0x5bcc7c]
mov eax, esi
add esp, 4
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x278]
xor ecx, esp
call fcn.00523a6a
mov esp, ebp
pop ebp
ret
mov eax, dword [esp + 0x10]
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
nop dword [eax]
mov eax, dword [esp + 0x18]
or eax, dword [esp + 0x1c]
je 0x4cadef
push 0x590e74
lea eax, [esp + 0x1c]
push eax
lea eax, [esp + 0x18]
push eax
call fcn.004ca760
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x4cb294
mov edi, dword [esp + 0x14]
push edi
push str.___s_r_n
lea eax, [esp + 0x20]
push eax
lea eax, [esp + 0x1c]
push eax
call fcn.004ca760
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x4cb294
push str.Content_Disposition:_form_data__name_
lea eax, [esp + 0x1c]
push eax
lea eax, [esp + 0x18]
push eax
call fcn.004ca760
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x4cb294
lea eax, [esp + 0x18]
xor edx, edx
push eax
push dword [ebx + 8]
lea ecx, [esp + 0x18]
push dword [ebx + 4]
call fcn.004ca600
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x4cb294
push 0x59451c
lea eax, [esp + 0x1c]
push eax
lea eax, [esp + 0x18]
push eax
call fcn.004ca760
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x4cb294
cmp dword [ebx + 0x24], eax
je 0x4caec0
mov eax, dword [esp + 0x28]
test eax, eax
je 0x4cae8d
push eax
call dword [0x5bcc7c]
add esp, 4
call fcn.004cb520
mov dword [esp + 0x28], eax
test eax, eax
je 0x4cb28f
push eax
push str._r_nContent_Type:_multipart_mixed__boundary_s_r_n
lea eax, [esp + 0x20]
push eax
lea eax, [esp + 0x1c]
push eax
call fcn.004ca760
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x4cb294
mov esi, ebx
mov dword [esp + 0x2c], esi
cmp dword [ebx + 0x24], 0
je 0x4caef5
push dword [esp + 0x28]
lea eax, [esp + 0x1c]
push str._r_n___s_r_nContent_Disposition:_attachment
push eax
lea eax, [esp + 0x1c]
push eax
call fcn.004ca760
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x4cb294
mov ecx, esi
jmp 0x4caf08
mov eax, dword [ebx + 0x28]
test al, 0x51
je 0x4caf23
cmp dword [ebx + 0x2c], 0
jne 0x4caf06
test al, 1
je 0x4caf1b
mov ecx, ebx
lea eax, [esp + 0x18]
push eax
lea edx, [esp + 0x14]
call fcn.004cab90
mov edi, eax
add esp, 4
test edi, edi
jne 0x4cb294
mov eax, dword [esi + 0x1c]
test eax, eax
je 0x4caf4c
push eax
push str._r_nContent_Type:__s
lea eax, [esp + 0x20]
push eax
lea eax, [esp + 0x1c]
push eax
call fcn.004ca760
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x4cb294
mov esi, dword [esi + 0x20]
test esi, esi
je 0x4caf7f
push dword [esi]
lea eax, [esp + 0x1c]
push str._r_n_s
push eax
lea eax, [esp + 0x1c]
push eax
call fcn.004ca760
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x4cb294
mov esi, dword [esi + 4]
test esi, esi
jne 0x4caf53
jmp 0x4caf87
test edi, edi
jne 0x4cb294
push str._r_n_r_n
lea eax, [esp + 0x1c]
push eax
lea eax, [esp + 0x18]
push eax
call fcn.004ca760
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x4cb294
mov eax, dword [ebx + 0x28]
test al, 3
jne 0x4cb034
test al, 0x10
je 0x4cafc4
lea eax, [esp + 0x18]
push eax
push dword [ebx + 0x18]
push dword [ebx + 0x14]
jmp 0x4cb01c
mov esi, dword [ebx + 0x10]
test al, 0x40
je 0x4cb013
mov edi, dword [ebx + 0x30]
push 0x10
call dword [0x5bcc74]
add esp, 4
test eax, eax
jne 0x4cafe5
lea edi, [eax + 0x1b]
jmp 0x4cb23c
mov ecx, dword [esp + 0x10]
mov dword [eax], 0
mov dword [eax + 8], edi
mov dword [eax + 4], 2
test ecx, ecx
je 0x4cafff
mov dword [ecx], eax
add dword [esp + 0x18], esi
mov dword [esp + 0x10], eax
adc dword [esp + 0x1c], 0
xor edi, edi
jmp 0x4cb23c
lea eax, [esp + 0x18]
push eax
push esi
push dword [ebx + 0xc]
mov edx, 1
lea ecx, [esp + 0x1c]
call fcn.004ca600
add esp, 0xc
mov edi, eax
jmp 0x4cb23c
mov esi, dword [esp + 0x2c]
push dword [esi + 0xc]
push 0x593810
call sub.api_ms_win_crt_string_l1_1_0.dll__stricmp
add esp, 8
test eax, eax
jne 0x4cb05e
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
mov ebx, eax
add esp, 4
mov dword [esp + 0x30], ebx
jmp 0x4cb075
push 0x59c49c
push dword [esi + 0xc]
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen]
add esp, 8
mov dword [esp + 0x30], eax
mov ebx, eax
test ebx, ebx
je 0x4cb210
push 0
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push ebx
cmp ebx, eax
je 0x4cb131
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
mov edi, dword [esi + 0xc]
add esp, 4
push 0x10
call dword [0x5bcc74]
mov esi, eax
add esp, 4
test esi, esi
jne 0x4cb0b8
mov edi, 0x1b
jmp 0x4cb238
mov eax, dword [esp + 0x10]
mov dword [esi], 0
mov dword [esi + 8], edi
mov dword [esi + 4], 3
test eax, eax
je 0x4cb0d5
mov dword [eax], esi
mov edi, dword [esi + 8]
push edi
push 0x593810
mov dword [esp + 0x18], esi
call sub.api_ms_win_crt_string_l1_1_0.dll__stricmp
add esp, 8
test eax, eax
je 0x4cb120
lea eax, [esp + 0x48]
push eax
push dword [esi + 8]
call dword [sym.imp.api_ms_win_crt_filesystem_l1_1_0.dll__stat64]
add esp, 8
test eax, eax
jne 0x4cb127
mov eax, dword [esp + 0x4e]
and eax, 0xf000
cmp eax, 0x4000
je 0x4cb127
mov eax, dword [esp + 0x60]
add dword [esp + 0x18], eax
mov eax, dword [esp + 0x64]
adc dword [esp + 0x1c], eax
xor edi, edi
jmp 0x4cb238
mov edi, 0x2b
jmp 0x4cb238
push 0x200
lea eax, [esp + 0x88]
push 1
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
mov esi, eax
add esp, 0x10
test esi, esi
je 0x4cb238
mov ebx, dword [esp + 0x10]
push 0x10
call dword [0x5bcc74]
mov edi, eax
add esp, 4
test edi, edi
je 0x4cb0ae
mov dword [edi], 0
test esi, esi
jne 0x4cb189
lea esi, [esp + 0x80]
lea ecx, [esi + 1]
mov al, byte [esi]
inc esi
test al, al
jne 0x4cb180
sub esi, ecx
lea eax, [esi + 1]
push eax
call dword [0x5bcc74]
add esp, 4
mov dword [edi + 8], eax
test eax, eax
je 0x4cb1ff
push esi
lea ecx, [esp + 0x84]
push ecx
push eax
call sub.VCRUNTIME140.dll_memcpy
mov eax, dword [edi + 8]
add esp, 0xc
mov dword [edi + 0xc], esi
mov byte [esi + eax], 0
mov dword [edi + 4], 1
test ebx, ebx
je 0x4cb1c6
mov dword [ebx], edi
push dword [esp + 0x30]
add dword [esp + 0x1c], esi
lea eax, [esp + 0x84]
push 0x200
adc dword [esp + 0x24], 0
mov ebx, edi
push 1
push eax
mov dword [esp + 0x20], ebx
xor edi, edi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
mov esi, eax
add esp, 0x10
test esi, esi
jne 0x4cb157
jmp 0x4cb238
push edi
call dword [0x5bcc7c]
add esp, 4
mov edi, 0x1b
jmp 0x4cb238
mov eax, dword [esp + 0x38]
test eax, eax
je 0x4cb229
push dword [esi + 0xc]
push str.couldnt_open_file___s_
push eax
call fcn.004909c0
add esp, 0xc
mov eax, dword [esp + 0x34]
mov edi, 0x1a
mov dword [eax], 0
mov ebx, dword [esp + 0x24]
mov eax, dword [esp + 0x2c]
mov eax, dword [eax + 0x24]
mov dword [esp + 0x2c], eax
test edi, edi
jne 0x4cb294
mov esi, eax
test eax, eax
jne 0x4caec6
mov esi, dword [esp + 0x28]
cmp dword [ebx + 0x24], edi
je 0x4cb27c
push esi
push str._r_n___s__
lea eax, [esp + 0x20]
push eax
lea eax, [esp + 0x1c]
push eax
call fcn.004ca760
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x4cb294
mov ebx, dword [ebx]
mov dword [esp + 0x24], ebx
test ebx, ebx
je 0x4cb2d4
mov edi, dword [esp + 0x14]
jmp 0x4cadc0
mov edi, 0x1b
mov ebx, dword [esp + 0x14]
lea ecx, [esp + 0x44]
call fcn.004ca800
mov eax, dword [esp + 0x28]
test eax, eax
je 0x4cb2b3
push eax
call dword [0x5bcc7c]
add esp, 4
push ebx
call dword [0x5bcc7c]
mov eax, edi
add esp, 4
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x278]
xor ecx, esp
call fcn.00523a6a
mov esp, ebp
pop ebp
ret
test edi, edi
jne 0x4cb294
mov ebx, dword [esp + 0x14]
lea eax, [esp + 0x18]
push ebx
push str._r_n___s___r_n
push eax
lea eax, [esp + 0x1c]
push eax
call fcn.004ca760
mov edi, eax
add esp, 0x10
test edi, edi
jne 0x4cb298
mov ecx, dword [esp + 0x3c]
mov eax, dword [esp + 0x18]
mov dword [ecx], eax
mov eax, dword [esp + 0x1c]
mov dword [ecx + 4], eax
test esi, esi
je 0x4cb319
push esi
call dword [0x5bcc7c]
add esp, 4
push ebx
call dword [0x5bcc7c]
mov eax, dword [esp + 0x38]
add esp, 4
mov ecx, dword [esp + 0x40]
mov dword [eax], ecx
mov ecx, dword [esp + 0x284]
xor eax, eax
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.00523a6a
mov esp, ebp
pop ebp
ret