Function at 0x41e380
Capabilities:
Read file on windows
Read pipe

Disassembly:
sub esp, 0x2a8
mov eax, dword [0x4a206c]
xor eax, esp
mov dword [esp + 0x2a4], eax
push ebx
mov ebx, edx
push ebp
mov ebp, ecx
push esi
and dword [ebx + 0x2c], 0xfffdffff
mov ecx, dword [ebx + 0xa0]
mov esi, dword [esp + 0x2b8]
mov dword [esp + 0x10], ebp
push edi
test ecx, ecx
je 0x41e3bd
call fcn.0041c2c0
mov eax, dword [esi + 0x20]
test eax, eax
jns 0x41e3f4
test dword [ebx + 0x2c], 0x100
je 0x41e617
push dword [0x4972b4]
push dword [0x4972b0]
push eax
call dword [0x4b0818]
push eax
mov edx, ebx
call fcn.0041e2d0
add esp, 0xc
jmp 0x41e617
test dword [ebx + 0x2c], 0x100
je 0x41e5ff
mov ebp, dword [sym.imp.KERNEL32.dll_ReadFile]
push 0
lea eax, [esp + 0x1c]
push eax
push 0
push 0
push 0
push dword [ebx + 0x94]
call dword [sym.imp.KERNEL32.dll_PeekNamedPipe]
test eax, eax
je 0x41e5de
mov ecx, dword [esp + 0x18]
test ecx, ecx
je 0x41e5fb
cmp dword [ebx + 0x90], 0
je 0x41e533
mov eax, dword [ebx + 0x108]
or eax, dword [ebx + 0x10c]
jne 0x41e524
push eax
lea eax, [esp + 0x20]
push eax
push 0x10
lea eax, [esp + 0x34]
push eax
push dword [ebx + 0x94]
call ebp
test eax, eax
je 0x41e5de
mov eax, dword [esp + 0x28]
test al, 2
je 0x41e501
push 0
lea eax, [esp + 0x20]
push eax
push 0x278
lea eax, [esp + 0x44]
push eax
push dword [ebx + 0x94]
call ebp
test eax, eax
je 0x41e5de
mov ebp, dword [esp + 0x28]
push 0x284
and ebp, 4
call dword [0x4a2e1c]
mov edx, eax
add esp, 4
test edx, edx
je 0x41e655
mov ecx, 0x9e
lea esi, [esp + 0x38]
mov edi, edx
lea eax, [ebx + 0x110]
rep movsd dword es:[edi], dword [esi]
mov dword [edx + 0x280], ebp
lea ecx, [edx + 0x278]
mov ebp, dword [sym.imp.KERNEL32.dll_ReadFile]
mov dword [ecx], eax
mov eax, dword [ebx + 0x114]
mov dword [edx + 0x27c], eax
mov dword [eax], ecx
mov eax, dword [esp + 0x28]
mov dword [ebx + 0x114], ecx
inc dword [ebx + 0x118]
test al, 1
je 0x41e51e
mov eax, dword [esp + 0x30]
mov dword [ebx + 0x108], eax
mov eax, dword [esp + 0x34]
mov dword [ebx + 0x10c], eax
jmp 0x41e5b3
mov ecx, dword [esp + 0x18]
jmp 0x41e533
mov eax, dword [ebx + 0x108]
cmp ecx, eax
cmovae ecx, eax
mov dword [esp + 0x18], ecx
lea eax, [esp + 0x20]
mov dword [esp + 0x20], 0
push eax
mov eax, dword [ebx + 0x34]
push ecx
push ebx
mov dword [esp + 0x30], 0
call eax
mov edx, dword [esp + 0x30]
add esp, 0xc
test edx, edx
je 0x41e5cc
mov ecx, dword [esp + 0x20]
test ecx, ecx
je 0x41e5cc
push 0
lea eax, [esp + 0x20]
push eax
mov eax, dword [esp + 0x20]
cmp ecx, eax
cmovb eax, ecx
push eax
push edx
push dword [ebx + 0x94]
call ebp
test eax, eax
je 0x41e5c2
cmp dword [ebx + 0x90], 0
mov eax, dword [esp + 0x1c]
je 0x41e59a
sub dword [ebx + 0x108], eax
sbb dword [ebx + 0x10c], 0
lea ecx, [esp + 0x20]
push ecx
push eax
mov eax, dword [ebx + 0x38]
push ebx
call eax
mov eax, dword [esp + 0x28]
add esp, 0xc
cmp eax, dword [esp + 0x20]
jbe 0x41e5fb
test dword [ebx + 0x2c], 0x100
jne 0x41e407
jmp 0x41e5fb
push dword [esp + 0x24]
push dword [esp + 0x24]
jmp 0x41e5ea
lea eax, [esp + 0x20]
push eax
mov eax, dword [ebx + 0x38]
push 0xfffff024
push ebx
call eax
jmp 0x41e5f8
push dword [0x4972b4]
push dword [0x4972b0]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
mov edx, ebx
call fcn.0041e2d0
add esp, 0xc
mov ebp, dword [esp + 0x14]
mov eax, dword [ebx + 0x2c]
and eax, 0x20100
cmp eax, 0x100
jne 0x41e617
mov edx, ebx
mov ecx, ebp
call fcn.0041e100
mov ecx, dword [ebx + 0x3c]
mov eax, dword [ebx + 0x2c]
dec ecx
mov dword [ebx + 0x3c], ecx
test al, 1
je 0x41e63c
test ecx, ecx
jne 0x41e63c
test al, 8
jne 0x41e63c
or eax, 8
mov dword [ebx + 0x2c], eax
mov eax, dword [ebp + 0x2c]
mov dword [ebx + 0x28], eax
mov dword [ebp + 0x2c], ebx
mov ecx, dword [esp + 0x2b4]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.0042b571
add esp, 0x2a8
ret
mov edx, str.uv__malloc
mov ecx, 0xe
call fcn.0041c6e0
int3