Function at 0x474a80
Capabilities:
Get process image filename
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x57d0d8
mov eax, dword fs:[0]
push eax
sub esp, 0x60
mov eax, dword [0x5f6ea4]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edi, ecx
mov dword [ebp - 0x64], edi
xorps xmm0, xmm0
movlpd qword [ebp - 0x24], xmm0
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x20], 0
call fcn.004789d0
mov dword [ebp - 0x24], eax
mov dword [ebp - 4], 0
mov ecx, edi
cmp dword [edi + 0x14], 8
jb 0x474adf
mov ecx, dword [edi]
lea edx, [ebp - 0x24]
call fcn.00478a40
test eax, eax
jne 0x474b08
cmp dword [edi + 0x14], 8
mov ecx, edi
jb 0x474af5
mov ecx, dword [edi]
lea edx, [ebp - 0x24]
call fcn.00478f50
test eax, eax
jne 0x474b08
xor esi, esi
jmp 0x474e94
mov eax, dword [ebp - 0x24]
mov esi, dword [eax]
cmp esi, eax
je 0x474e88
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
nop dword [eax + eax]
push dword [esi + 0x10]
push 0
push 0x1fffff
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov edi, eax
mov dword [ebp - 0x28], edi
xor eax, eax
mov byte [ebp - 4], 1
push eax
push 0x104
lea ecx, [ebp - 0x40]
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x2c], 7
mov word [ebp - 0x40], ax
call fcn.00469ab0
mov byte [ebp - 4], 2
lea eax, [ebp - 0x40]
cmp dword [ebp - 0x2c], 8
push 0
push dword [ebp - 0x30]
cmovae eax, dword [ebp - 0x40]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_K32GetProcessImageFileNameW]
push eax
lea ecx, [ebp - 0x40]
call fcn.00456720
lea ecx, [ebp - 0x40]
call fcn.00473ab0
mov eax, dword [ebp - 0x64]
mov edx, eax
cmp dword [eax + 0x14], 8
jb 0x474b95
mov edx, dword [eax]
mov ecx, edi
call fcn.00474190
test eax, eax
je 0x474d52
mov eax, dword [esi + 0x28]
mov ecx, dword [esi + 0x34]
mov dword [ebp - 0x60], eax
mov eax, dword [esi + 0x34]
add eax, dword [esi + 0x38]
mov dword [ebp - 0x18], ecx
cmp ecx, eax
je 0x474d52
mov dword [ebp - 0x1c], 0
mov byte [ebp - 4], 3
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov edx, eax
mov eax, dword [ebp - 0x60]
test eax, eax
je 0x474bda
mov eax, dword [eax]
mov ecx, dword [ebp - 0x18]
mov ebx, dword [ebp - 0x18]
shr ecx, 2
mov dword [ebp - 0x5c], ecx
mov ecx, dword [eax + 8]
mov eax, dword [eax + 4]
dec ecx
and ecx, dword [ebp - 0x5c]
push 2
push 0
push 0
mov eax, dword [eax + ecx*4]
lea ecx, [ebp - 0x1c]
push ecx
mov dword [ebp - 0x14], ebx
and dword [ebp - 0x14], 3
shl dword [ebp - 0x14], 2
mov ecx, dword [ebp - 0x14]
push edx
push dword [ecx + eax]
push edi
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
mov ebx, dword [sym.imp.KERNEL32.dll_CloseHandle]
test eax, eax
je 0x474d30
push 1
push 0
push 0
push 4
push dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebp - 0x68], eax
test eax, eax
je 0x474d30
mov eax, dword [ebp - 0x64]
mov dword [ebp - 0x6c], eax
cmp dword [eax + 0x14], 8
jb 0x474c51
mov eax, dword [eax]
mov dword [ebp - 0x6c], eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov edx, dword [ebp - 0x6c]
mov ecx, eax
call fcn.00474190
test eax, eax
je 0x474d47
xor eax, eax
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x44], 7
mov word [ebp - 0x58], ax
mov byte [ebp - 4], 4
lea edx, [ebp - 0x58]
mov ecx, dword [ebp - 0x1c]
call fcn.00473cf0
mov eax, dword [ebp - 0x60]
test eax, eax
je 0x474c95
mov eax, dword [eax]
mov ecx, dword [eax + 8]
mov eax, dword [eax + 4]
dec ecx
and ecx, dword [ebp - 0x5c]
push dword [esi + 0x10]
push 0
mov eax, dword [eax + ecx*4]
mov ecx, dword [ebp - 0x14]
push 0x40
mov eax, dword [ecx + eax]
mov dword [ebp - 0x5c], eax
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov edi, eax
test edi, edi
je 0x474cef
mov dword [ebp - 0x14], 0
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push 1
push 0
push 2
lea ecx, [ebp - 0x14]
push ecx
push eax
push dword [ebp - 0x5c]
push edi
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
test eax, eax
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x474cec
push eax
call ebx
push edi
call ebx
mov byte [ebp - 4], 3
mov edx, dword [ebp - 0x44]
cmp edx, 8
jb 0x474d2d
mov ecx, dword [ebp - 0x58]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x474d23
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x474ec7
push edx
push ecx
call fcn.00537216
add esp, 8
mov edi, dword [ebp - 0x28]
mov byte [ebp - 4], 2
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x474d3e
push eax
call ebx
mov ecx, dword [ebp - 0x18]
inc ecx
jmp 0x474bad
push dword [ebp - 0x68]
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
jmp 0x474d30
mov edx, dword [esi + 0x14]
mov ecx, dword [esi + 0x20]
mov dword [ebp - 0x60], edx
mov eax, dword [esi + 0x24]
add eax, dword [esi + 0x20]
mov dword [ebp - 0x5c], ecx
cmp ecx, eax
je 0x474dd9
test edx, edx
jne 0x474d70
xor edi, edi
jmp 0x474d72
mov edi, dword [edx]
mov edx, dword [edi + 8]
mov eax, ecx
push dword [esi + 0x10]
shr eax, 2
dec edx
and edx, eax
and ecx, 3
mov eax, dword [edi + 4]
push 0
push 0x40
mov eax, dword [eax + edx*4]
mov eax, dword [eax + ecx*4]
mov dword [ebp - 0x68], eax
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov edi, eax
test edi, edi
je 0x474dd0
mov dword [ebp - 0x18], 0
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push 1
push 0
push 2
lea ecx, [ebp - 0x18]
push ecx
push eax
push dword [ebp - 0x68]
push edi
call dword [sym.imp.KERNEL32.dll_DuplicateHandle]
test eax, eax
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x474dcd
push eax
call ebx
push edi
call ebx
mov ecx, dword [ebp - 0x5c]
mov edx, dword [ebp - 0x60]
inc ecx
jmp 0x474d5b
mov byte [ebp - 4], 1
mov edx, dword [ebp - 0x2c]
cmp edx, 8
jb 0x474e17
mov ecx, dword [ebp - 0x40]
lea edx, [edx*2 + 2]
mov eax, ecx
cmp edx, 0x1000
jb 0x474e0d
mov ecx, dword [ecx - 4]
add edx, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x474ec7
push edx
push ecx
call fcn.00537216
add esp, 8
xor eax, eax
mov dword [ebp - 0x30], 0
mov byte [ebp - 4], al
mov edi, dword [ebp - 0x28]
mov dword [ebp - 0x2c], 7
mov word [ebp - 0x40], ax
test edi, edi
je 0x474e38
push edi
call ebx
mov eax, dword [esi + 8]
cmp byte [eax + 0xd], 0
je 0x474e64
mov eax, dword [esi + 4]
cmp byte [eax + 0xd], 0
jne 0x474e60
nop word [eax + eax]
cmp esi, dword [eax + 8]
jne 0x474e60
mov esi, eax
mov eax, dword [eax + 4]
cmp byte [eax + 0xd], 0
je 0x474e50
mov esi, eax
jmp 0x474e7c
mov esi, eax
mov ecx, dword [esi]
cmp byte [ecx + 0xd], 0
jne 0x474e7c
nop
mov eax, dword [ecx]
mov esi, ecx
mov ecx, eax
cmp byte [eax + 0xd], 0
je 0x474e70
cmp esi, dword [ebp - 0x24]
jne 0x474b20
mov edi, dword [ebp - 0x64]
mov ecx, edi
call fcn.00474600
mov esi, 1
lea ecx, [ebp - 0x24]
call fcn.00478930
push 0x3c
push dword [ebp - 0x24]
call fcn.00537216
add esp, 8
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00536fd5
mov esp, ebp
pop ebp
ret
call fcn.00552cb1
int3