Function at 0x404830
Capabilities:
Read file via mapping

Disassembly:
sub esp, 0x54
mov eax, dword [0x7079d0]
xor eax, esp
mov dword [esp + 0x50], eax
mov eax, dword [esp + 0x58]
mov ecx, dword [esp + 0x5c]
push ebx
xor ebx, ebx
push ebp
mov ebp, dword [eax + 0x34c]
mov dword [esp + 0x3c], eax
push esi
mov eax, ebp
mov dword [esp + 0x3c], ecx
push edi
mov dword [esp + 0x34], ebx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x28], ebx
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x38], ebx
mov dword [esp + 0x20], ebx
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x10], ebx
mov dword [esp + 0x18], ebx
lea ecx, [eax + 1]
jmp 0x404890
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x404890
sub eax, ecx
add eax, 0x20
push 8
push eax
call fcn.0040ce60
mov esi, eax
add esp, 8
cmp esi, ebx
je 0x404c77
mov dword [esp + 0x14], ebx
jmp 0x4048c0
mov edx, dword [esp + 0x14]
mov ebx, dword [edx + 0x49a114]
push 0
push 0x486040
push ebp
push ebx
push esi
call fcn.00412730
mov edi, eax
push str.CONNECT_REQUEST
push edi
call fcn.004090b0
add esp, 0x1c
push esi
push 0
push 0x100002
call dword [sym.imp.KERNEL32.dll_OpenEventA]
mov dword [esp + 0x34], eax
test eax, eax
jne 0x4049b8
mov eax, dword [esp + 0x14]
add eax, 4
mov dword [esp + 0x14], eax
cmp eax, 8
jb 0x4048c0
mov dword [esp + 0x10], 0x7f6
xor ebx, ebx
push esi
call sub.MSVCR90.dll_free
mov esi, dword [esp + 0x14]
add esp, 4
cmp esi, ebx
je 0x404938
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x34]
mov ebp, dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp eax, ebx
je 0x404949
push eax
call ebp
mov eax, dword [esp + 0x24]
cmp eax, ebx
je 0x404954
push eax
call ebp
mov eax, dword [esp + 0x28]
cmp eax, ebx
je 0x404963
push eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov eax, dword [esp + 0x3c]
cmp eax, ebx
je 0x40496e
push eax
call ebp
cmp esi, ebx
je 0x404cca
cmp esi, 0x7fc
jne 0x404c80
mov edx, dword [esp + 0x18]
mov eax, dword [str.Cant_open_shared_memory__client_could_not_create__s_event___lu_]
mov ecx, dword [esp + 0x44]
push edx
push edi
push eax
mov eax, dword [str.HY000]
push eax
push esi
push ecx
call fcn.004045c0
add esp, 0x18
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
mov ecx, dword [esp + 0x50]
xor ecx, esp
call fcn.00466e0a
add esp, 0x54
ret
push str.CONNECT_ANSWER
push edi
call fcn.004090b0
add esp, 8
push esi
push 0
push 0x100002
call dword [sym.imp.KERNEL32.dll_OpenEventA]
mov dword [esp + 0x24], eax
test eax, eax
jne 0x4049e9
mov dword [esp + 0x10], 0x7f7
jmp 0x40491b
push str.CONNECT_DATA
push edi
call fcn.004090b0
add esp, 8
push esi
push 0
push 2
call dword [sym.imp.KERNEL32.dll_OpenFileMappingA]
mov dword [esp + 0x3c], eax
test eax, eax
jne 0x404a17
mov dword [esp + 0x10], 0x7f8
jmp 0x40491b
push 4
push 0
push 0
push 2
push eax
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [esp + 0x28], eax
test eax, eax
jne 0x404a3b
mov dword [esp + 0x10], 0x7f9
jmp 0x40491b
mov eax, dword [esp + 0x34]
push eax
call dword [sym.imp.KERNEL32.dll_SetEvent]
test eax, eax
jne 0x404a57
mov dword [esp + 0x10], 0x7fe
jmp 0x40491b
mov ecx, dword [esp + 0x70]
mov edx, dword [esp + 0x24]
imul ecx, ecx, 0x3e8
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
test eax, eax
je 0x404a7e
mov dword [esp + 0x10], 0x7fd
jmp 0x40491b
mov ecx, dword [esp + 0x28]
mov edx, dword [ecx]
push 0xa
lea eax, [esp + 0x4c]
push eax
push edx
call fcn.004194c0
push 0
push 0x486040
lea eax, [esp + 0x5c]
push eax
push 0x486040
push ebp
push ebx
push esi
call fcn.00412730
mov edi, eax
push str.DATA
push edi
call fcn.004090b0
add esp, 0x30
push esi
push 0
push 2
call dword [sym.imp.KERNEL32.dll_OpenFileMappingA]
mov dword [esp + 0x14], eax
test eax, eax
jne 0x404b38
mov dword [esp + 0x10], 0x7fa
mov ebx, dword [esp + 0x38]
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [esp + 0x18], eax
test ebx, ebx
je 0x404aee
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x30]
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
je 0x404aff
push eax
call ebx
mov eax, dword [esp + 0x2c]
test eax, eax
je 0x404b0a
push eax
call ebx
mov eax, dword [esp + 0x20]
test eax, eax
je 0x404b15
push eax
call ebx
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x404b24
push eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov eax, dword [esp + 0x14]
test eax, eax
je 0x40491b
push eax
call ebx
jmp 0x40491b
push 0x3e84
push 0
push 0
push 2
push eax
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [esp + 0x1c], eax
test eax, eax
jne 0x404b5f
mov dword [esp + 0x10], 0x7fb
jmp 0x404ad5
push str.SERVER_WROTE
push edi
call fcn.004090b0
mov ebp, dword [sym.imp.KERNEL32.dll_OpenEventA]
add esp, 8
push esi
push 0
push 0x100002
call ebp
mov dword [esp + 0x30], eax
test eax, eax
jne 0x404b92
mov dword [esp + 0x10], 0x7fc
jmp 0x404ad5
push str.SERVER_READ
push edi
call fcn.004090b0
add esp, 8
push esi
push 0
push 0x100002
call ebp
mov ebx, eax
test ebx, ebx
jne 0x404bbd
mov dword [esp + 0x10], 0x7fc
jmp 0x404ad9
push str.CLIENT_WROTE
push edi
call fcn.004090b0
add esp, 8
push esi
push 0
push 0x100002
call ebp
mov dword [esp + 0x20], eax
test eax, eax
jne 0x404bea
mov dword [esp + 0x10], 0x7fc
jmp 0x404ad9
push str.CLIENT_READ
push edi
call fcn.004090b0
add esp, 8
push esi
push 0
push 0x100002
call ebp
mov dword [esp + 0x2c], eax
test eax, eax
jne 0x404c17
mov dword [esp + 0x10], 0x7fc
jmp 0x404ad9
push str.CONNECTION_CLOSED
push edi
call fcn.004090b0
add esp, 8
push esi
push 0
push 0x100002
call ebp
mov ebp, eax
test ebp, ebp
jne 0x404c42
mov dword [esp + 0x10], 0x7fc
jmp 0x404ad9
push ebx
call dword [sym.imp.KERNEL32.dll_SetEvent]
mov ecx, dword [esp + 0x2c]
mov edx, dword [esp + 0x20]
mov eax, dword [esp + 0x30]
push ebp
push ecx
mov ecx, dword [esp + 0x24]
push edx
mov edx, dword [esp + 0x20]
push ebx
push eax
push ecx
push edx
call fcn.00419f20
mov ecx, dword [esp + 0x5c]
add esp, 0x1c
mov dword [ecx], eax
jmp 0x40491b
mov edi, dword [esp + 0x40]
jmp 0x40491d
lea edx, [esi - 0x7d0]
cmp edx, 0x3b
ja 0x404c94
mov eax, dword [esi*4 + 0x4fbba0]
jmp 0x404c99
mov eax, dword [0x4ffa20]
mov ecx, dword [esp + 0x18]
mov edx, dword [str.HY000]
push ecx
push eax
mov eax, dword [esp + 0x4c]
push edx
push esi
push eax
call fcn.004045c0
add esp, 0x14
pop edi
pop esi
pop ebp
or eax, 0xffffffff
pop ebx
mov ecx, dword [esp + 0x50]
xor ecx, esp
call fcn.00466e0a
add esp, 0x54
ret
mov ecx, dword [esp + 0x60]
mov eax, dword [esp + 0x1c]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.00466e0a
add esp, 0x54
ret