Function at 0x4a8a37
Capabilities:
Check if file exists

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x98
mov eax, dword [0x52fe80]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov ebx, ecx
push str.Selfportect_start_r_n
push 0x55b31c
mov dword [ebp - 0x8c], ebx
call fcn.004a9913
pop ecx
pop ecx
call fcn.00420bd2
push eax
lea ecx, [ebp - 0x80]
call fcn.00423e41
lea eax, [ebx + 0x20]
push eax
lea ecx, [ebp - 0x80]
call fcn.00425c4a
lea eax, [ebp - 0x80]
push eax
call fcn.0049dfdb
mov esi, str.Local_State
push esi
call fcn.004241d7
pop ecx
pop ecx
push eax
push esi
lea ecx, [ebp - 0x80]
call fcn.0043be5f
push dword [ebp - 0x80]
lea ecx, [ebp - 0x1c]
call fcn.00406c40
cmp dword [ebp - 8], 8
lea eax, [ebp - 0x1c]
cmovae eax, dword [ebp - 0x1c]
push eax
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
push 0xf
xor ebx, ebx
pop esi
test eax, eax
jne 0x4a8b89
push 0x10
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x24], ebx
mov byte [ebp - 0x34], bl
call fcn.00481836
pop ecx
test eax, eax
je 0x4a8ae8
mov ecx, eax
call fcn.0040e900
mov ebx, eax
lea eax, [ebp - 0x34]
push eax
push ebx
call fcn.004124e0
cmp dword [ebp - 8], 8
lea eax, [ebp - 0x1c]
pop ecx
cmovae eax, dword [ebp - 0x1c]
pop ecx
push eax
lea ecx, [ebp - 0x4c]
call fcn.00406c40
cmp dword [ebp - 0x20], 0x10
lea eax, [ebp - 0x34]
push dword [ebp - 0x24]
cmovae eax, dword [ebp - 0x34]
lea ecx, [ebp - 0x7c]
push eax
lea eax, [ebp - 0x4c]
push eax
call fcn.004086d0
push eax
call fcn.0040ad70
add esp, 0xc
lea ecx, [ebp - 0x7c]
mov esi, eax
call fcn.00408720
push 0
push 1
lea ecx, [ebp - 0x4c]
call fcn.00403650
cmp esi, 0xffffffff
jne 0x4a8b6d
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
sub esp, 0x18
lea esi, [ebp - 0x1c]
push 6
pop ecx
mov edi, esp
push str.WriteFile__ws_errcode_d_r_n
rep movsd dword es:[edi], dword [esi]
push 0x55b31c
call fcn.004a9913
add esp, 0x24
test ebx, ebx
je 0x4a8b79
mov eax, dword [ebx]
mov ecx, ebx
push 1
call dword [eax]
xor ebx, ebx
lea ecx, [ebp - 0x34]
push ebx
push 1
call fcn.00403580
push 0xf
pop esi
cmp dword [ebp - 8], 8
lea eax, [ebp - 0x1c]
lea ecx, [ebp - 0x4c]
mov dword [ebp - 0x50], esi
cmovae eax, dword [ebp - 0x1c]
push eax
mov dword [ebp - 0x54], ebx
mov byte [ebp - 0x64], bl
call fcn.00406c40
lea eax, [ebp - 0x64]
push eax
lea eax, [ebp - 0x4c]
push eax
lea ecx, [ebp - 0x7c]
call fcn.004086d0
push eax
call fcn.00412200
pop ecx
pop ecx
lea ecx, [ebp - 0x7c]
mov bl, al
call fcn.00408720
push 0
push 1
lea ecx, [ebp - 0x4c]
call fcn.00403650
test bl, bl
je 0x4a8d9d
cmp dword [ebp - 0x50], 0x10
lea eax, [ebp - 0x64]
cmovae eax, dword [ebp - 0x64]
mov dword [ebp - 0x94], eax
mov eax, dword [ebp - 0x54]
mov dword [ebp - 0x90], eax
lea eax, [ebp - 0x94]
push eax
call fcn.004124a0
mov edi, eax
mov dword [ebp - 0x88], edi
pop ecx
test edi, edi
je 0x4a8dc3
mov edx, dword [edi]
lea eax, [ebp - 0x84]
and dword [ebp - 0x84], 0
mov ecx, edi
push eax
call dword [edx + 0x28]
push str.safe.selfprotect
lea ecx, [ebp - 0x4c]
call fcn.00402570
mov ecx, dword [ebp - 0x84]
lea eax, [ebp - 0x98]
push eax
lea eax, [ebp - 0x4c]
push eax
call fcn.0040f010
mov bl, al
lea ecx, [ebp - 0x4c]
push 0
neg bl
push 1
sbb bl, bl
call fcn.00403580
inc bl
je 0x4a8d6e
xor eax, eax
cmp byte [ebp + 8], al
setne al
push eax
push str.dict_formentry__Get_no_exists_bool___d_r_n
push 0x55b31c
call fcn.004a9913
add esp, 0xc
lea ecx, [ebp - 0x4c]
push str.safe.selfprotect
call fcn.00402570
push dword [ebp + 8]
mov ecx, dword [ebp - 0x84]
lea eax, [ebp - 0x4c]
push eax
call fcn.0040eca0
xor ebx, ebx
lea ecx, [ebp - 0x4c]
push ebx
push 1
call fcn.00403580
lea eax, [ebp - 0x34]
mov dword [ebp - 0x20], esi
push eax
push edi
mov dword [ebp - 0x24], ebx
mov byte [ebp - 0x34], bl
call fcn.004124e0
cmp dword [ebp - 8], 8
lea eax, [ebp - 0x1c]
pop ecx
cmovae eax, dword [ebp - 0x1c]
pop ecx
push eax
lea ecx, [ebp - 0x4c]
call fcn.00406c40
cmp dword [ebp - 0x20], 0x10
lea eax, [ebp - 0x34]
push dword [ebp - 0x24]
cmovae eax, dword [ebp - 0x34]
lea ecx, [ebp - 0x7c]
push eax
lea eax, [ebp - 0x4c]
push eax
call fcn.004086d0
push eax
call fcn.0040ad70
add esp, 0xc
lea ecx, [ebp - 0x7c]
mov esi, eax
call fcn.00408720
push ebx
push 1
lea ecx, [ebp - 0x4c]
call fcn.00403650
cmp esi, 0xffffffff
jne 0x4a8d3f
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
sub esp, 0x18
lea esi, [ebp - 0x1c]
push 6
pop ecx
mov edi, esp
push str.WriteFile__ws_errcode_d_r_n
rep movsd dword es:[edi], dword [esi]
push 0x55b31c
call fcn.004a9913
mov edi, dword [ebp - 0x88]
add esp, 0x24
mov ecx, dword [ebp - 0x8c]
lea eax, [ebp - 0x88]
push eax
add ecx, 0xd8
mov dword [ebp - 0x88], 1
call fcn.0041ed40
push ebx
push 1
lea ecx, [ebp - 0x34]
call fcn.00403580
jmp 0x4a8d93
cmp dword [ebp - 8], 8
lea esi, [ebp - 0x1c]
cmovae esi, dword [ebp - 0x1c]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push esi
push str.ReadFileToString__ws_errcode_r_n
push 0x55b31c
call fcn.004a9913
add esp, 0x10
mov eax, dword [edi]
mov ecx, edi
push 1
call dword [eax]
jmp 0x4a8dc3
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
sub esp, 0x18
lea esi, [ebp - 0x1c]
push 6
pop ecx
mov edi, esp
push str.WriteFile__ws_errcode_d_r_n
rep movsd dword es:[edi], dword [esi]
push 0x55b31c
call fcn.004a9913
add esp, 0x24
push str.Selfportect_end_r_n
push 0x55b31c
call fcn.004a9913
pop ecx
pop ecx
push 0
push 1
lea ecx, [ebp - 0x64]
call fcn.00403580
push 0
push 1
lea ecx, [ebp - 0x1c]
call fcn.00403650
mov ecx, dword [ebp - 0x80]
lea ecx, [ecx - 0x10]
call fcn.004206ab
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.004bc1bd
mov esp, ebp
pop ebp
ret 4