Function at 0x43c9a3
Capabilities:
Get common file path
Get file size
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x13c8
call fcn.00612c90
mov eax, dword [0x6ffe74]
xor eax, ebp
mov dword [ebp - 8], eax
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
push esi
mov dword [ebp - 0x13c4], ecx
call fcn.00643470
xor ebx, ebx
pop ecx
cmp eax, 1
jae 0x43c9f7
lea eax, [ebp - 0x13ac]
push eax
push ebx
push ebx
push 0x1a
push ebx
call dword [sym.imp.SHELL32.dll_SHGetFolderPathA]
test eax, eax
js 0x43ca47
mov eax, str._sMikrotikWinbox_settings.cfg.viw
lea esi, [ebp - 0x13ac]
jmp 0x43c9fc
mov eax, str._s_settings.cfg.viw
push esi
push eax
lea eax, [ebp - 0x7f4]
push 0x3e8
push eax
call fcn.00402e0a
add esp, 0x10
lea ecx, [ebp - 0x7f4]
call fcn.00405670
test eax, eax
je 0x43ca47
push ebx
push ebx
push 3
push ebx
push 1
push SysReAllocString
lea eax, [ebp - 0x7f4]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
jne 0x43ca5a
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor eax, eax
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.006122f0
leave
ret 4
push ebx
push ebx
push ebx
push 2
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileMappingA]
mov esi, eax
test esi, esi
jne 0x43ca7c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x43ca47
push ebx
push ebx
push ebx
push 4
push esi
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov ebx, eax
mov dword [ebp - 0x13b0], ebx
test ebx, ebx
jne 0x43ca9d
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
jmp 0x43ca74
and dword [ebp - 0x13bc], 0
lea eax, [ebp - 0x13bc]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
cmp dword [ebp - 0x13bc], 0
mov dword [ebp - 0x13c0], eax
jne 0x43ca47
xor ecx, ecx
mov dword [ebp - 0x18], 0x64610400
mov byte [ebp - 0x40c], cl
mov edx, eax
mov byte [ebp - 0xbdc], cl
mov byte [ebp - 0xfc4], cl
lea ecx, [ebp - 0x18]
push 6
push ecx
mov ecx, ebx
mov word [ebp - 0x14], 0x7264
mov dword [ebp - 0x20], 0x6f6c0500
mov word [ebp - 0x1c], 0x6967
mov byte [ebp - 0x1a], 0x6e
mov dword [ebp - 0x10], 0x77700300
mov byte [ebp - 0xc], 0x64
call fcn.00417191
pop ecx
pop ecx
test eax, eax
je 0x43cb52
add eax, 6
xor ecx, ecx
mov dl, byte [eax]
test dl, dl
je 0x43cb52
lea ebx, [ebp - 0xfc4]
mov dword [ebp - 0x13b4], ecx
add ebx, ecx
inc ecx
inc eax
mov byte [ebx], dl
mov dl, byte [eax]
test dl, dl
jne 0x43cb1e
test ecx, ecx
je 0x43cb4c
cmp dword [ebp - 0x13b4], 0x3e8
jae 0x43cc66
mov byte [ebx], dl
mov ebx, dword [ebp - 0x13b0]
mov edx, dword [ebp - 0x13c0]
lea eax, [ebp - 0x20]
push 7
push eax
mov ecx, ebx
call fcn.00417191
pop ecx
pop ecx
test eax, eax
je 0x43cbb6
add eax, 7
xor ecx, ecx
mov dl, byte [eax]
test dl, dl
je 0x43cbb6
lea ebx, [ebp - 0xbdc]
mov dword [ebp - 0x13b4], ecx
add ebx, ecx
inc ecx
inc eax
mov dword [ebp - 0x13b8], ebx
mov byte [ebx], dl
mov dl, byte [eax]
test dl, dl
jne 0x43cb76
mov ebx, dword [ebp - 0x13b0]
test ecx, ecx
je 0x43cbb6
cmp dword [ebp - 0x13b4], 0x3e8
jae 0x43cc66
mov eax, dword [ebp - 0x13b8]
mov byte [eax], dl
mov edx, dword [ebp - 0x13c0]
lea eax, [ebp - 0x10]
push 5
push eax
mov ecx, ebx
call fcn.00417191
pop ecx
pop ecx
test eax, eax
je 0x43cc0a
add eax, 5
xor ecx, ecx
mov dl, byte [eax]
test dl, dl
je 0x43cc0a
lea ebx, [ebp - 0x40c]
mov dword [ebp - 0x13b8], ecx
add ebx, ecx
inc ecx
inc eax
mov byte [ebx], dl
mov dl, byte [eax]
test dl, dl
jne 0x43cbda
test ecx, ecx
je 0x43cc04
cmp dword [ebp - 0x13b8], 0x3e8
jae 0x43cc66
mov byte [ebx], dl
mov ebx, dword [ebp - 0x13b0]
lea eax, [ebp - 0x40c]
push eax
call fcn.00643470
pop ecx
test eax, eax
je 0x43cc4b
push 0xffffffffffffffff
mov ecx, 0x6c5bb9
lea eax, [ebp - 0x40c]
push ecx
push eax
lea eax, [ebp - 0xbdc]
push eax
lea eax, [ebp - 0xfc4]
push eax
push ecx
mov ecx, dword [ebp - 0x13c4]
push 0x2c7
push 7
call fcn.0043ee6b
push ebx
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
push esi
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
call esi
push edi
call esi
xor eax, eax
inc eax
jmp 0x43ca49
call fcn.00612782
int3