Function at 0x47c610
Capabilities:
Get system information on windows
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x4c
mov ecx, dword [ebp + 0x18]
xor eax, eax
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x38], eax
mov eax, dword [ebp + 0x14]
push ebx
push edi
mov edi, dword [esi + 0x18]
mov edx, eax
or eax, ecx
mov dword [ebp - 0x18], 1
mov dword [ebp - 0x14], edi
mov dword [ebp - 0x2c], edx
mov dword [ebp - 0x28], ecx
jne 0x47c66e
push ecx
mov eax, esp
mov dword [ebp + 0xc], esp
push str.AddFile:_adding_0_bytes_file
push eax
call fcn.00464a80
add esp, 8
call fcn.0047c360
mov eax, 1
pop edi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
mov ecx, dword [esi + 8]
mov eax, dword [ebp + 0xc]
mov dword [eax], ecx
mov ecx, dword [esi + 0xc]
mov dword [eax + 4], ecx
lea esp, [esp]
xor eax, eax
cmp eax, dword [ebp - 0x28]
jg 0x47c692
jl 0x47c68d
cmp edi, edx
jae 0x47c692
mov dword [ebp - 8], edi
jmp 0x47c695
mov dword [ebp - 8], edx
mov eax, dword [ebp - 8]
add eax, 0x2000
xor edx, edx
mov dword [ebp - 0xc], eax
add eax, dword [esi + 8]
push 0
adc edx, dword [esi + 0xc]
lea ecx, [ebp - 0x40]
push ecx
mov dword [ebp - 0x40], edx
mov edx, dword [esi]
push eax
push edx
mov dword [ebp - 0x44], eax
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [esi]
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov ecx, dword [esi]
push 0
push 0
push 0
push 4
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov dword [ebp - 0x10], eax
test eax, eax
je 0x47c801
cmp dword [0x518be8], 0
mov edi, dword [esi + 8]
mov edx, dword [ebp - 0xc]
mov ebx, dword [esi + 0xc]
mov dword [ebp - 0x4c], edi
mov dword [ebp - 0x20], edx
jne 0x47c708
push 0x518bcc
call dword [sym.imp.KERNEL32.dll_GetSystemInfo]
mov eax, dword [0x518be8]
push 0
push eax
push ebx
push edi
call fcn.004ba680
mov ecx, dword [ebp - 0x10]
sub edi, eax
mov eax, dword [ebp - 0x20]
sbb ebx, edx
sub eax, edi
add eax, dword [ebp - 0x4c]
push eax
push edi
push ebx
push 6
push ecx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebp - 0x20], eax
test eax, eax
je 0x47c745
mov ebx, eax
sub ebx, edi
add ebx, dword [ebp - 0x4c]
mov dword [ebp - 0x1c], ebx
jmp 0x47c748
mov ebx, dword [ebp - 0x1c]
test ebx, ebx
je 0x47c82f
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 0x34]
mov ecx, dword [ebp - 0x30]
push edx
mov edx, dword [ebp + 8]
push eax
push ecx
push 4
push edx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov edi, eax
test edi, edi
je 0x47c843
mov ecx, dword [esi + 0x10]
mov eax, dword [ecx]
mov eax, dword [eax]
lea edx, [ebp - 0xc]
push edx
mov edx, dword [ebp - 8]
push edx
mov edx, dword [esi + 0xc]
push edx
mov edx, dword [esi + 8]
push edx
push ebx
push edi
call eax
mov eax, dword [ebp - 0xc]
xor ecx, ecx
add dword [esi + 8], eax
adc dword [esi + 0xc], ecx
xor edx, edx
cmp dword [ebp - 0x28], edx
jl 0x47c7b4
jg 0x47c7a9
mov ebx, dword [ebp - 0x2c]
cmp ebx, dword [ebp - 0x14]
jbe 0x47c7b4
mov ebx, dword [ebp - 0x14]
sub dword [ebp - 0x2c], ebx
sbb dword [ebp - 0x28], edx
jmp 0x47c7bc
xor edx, edx
mov dword [ebp - 0x2c], edx
mov dword [ebp - 0x28], edx
mov edx, dword [ebp - 8]
add dword [ebp - 0x34], edx
push edi
mov edi, dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
adc dword [ebp - 0x30], ecx
add dword [ebp - 0x3c], eax
adc dword [ebp - 0x38], ecx
call edi
mov eax, dword [ebp - 0x20]
push eax
call edi
mov ecx, dword [ebp - 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x28], 0
jl 0x47c874
jg 0x47c7f6
cmp dword [ebp - 0x2c], 0
jbe 0x47c874
mov edi, dword [ebp - 0x14]
mov edx, dword [ebp - 0x2c]
jmp 0x47c680
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ecx
mov edx, esp
mov dword [ebp + 0xc], esp
push eax
mov eax, dword [ebp - 0xc]
push eax
push str.AddFile:_error_extending_VFC_file_by__d_bytes__LE_d
push edx
call fcn.00464a80
add esp, 0x10
call fcn.0047c360
xor eax, eax
pop edi
pop ebx
mov esp, ebp
pop ebp
ret 0x14
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ecx
mov ecx, esp
mov dword [ebp + 8], esp
push eax
push str._AddFile:_Dest_mapping_failed__LE_d
jmp 0x47c855
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ecx
mov ecx, esp
mov dword [ebp + 8], esp
push eax
push str._AddFile:_Src_mapping_failed__LE_d
push ecx
call fcn.00464a80
add esp, 0xc
call fcn.0047c360
mov edx, dword [ebp - 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x18], 0
mov ecx, dword [esi + 8]
mov eax, dword [ebp + 0xc]
sub ecx, dword [eax]
mov edx, dword [esi + 0xc]
sbb edx, dword [eax + 4]
mov eax, dword [ebp + 0x10]
pop edi
mov dword [eax], ecx
mov dword [eax + 4], edx
mov eax, dword [ebp - 0x18]
pop ebx
mov esp, ebp
pop ebp
ret 0x14