Function at 0x40b740
Capabilities:
Get common file path
Read .ini file

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x144
push ebx
xor ebx, ebx
cmp byte [0x417900], bl
push esi
push edi
je 0x40b9d9
push 0x414f44
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov edi, eax
cmp edi, ebx
je 0x40b7d1
push 0x414f30
push edi
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov esi, eax
cmp esi, ebx
je 0x40b7ca
mov ecx, dword [0x41785c]
mov edx, 0x414f14
cmp ecx, ebx
jne 0x40b791
mov edx, 0x414efc
xor eax, eax
cmp ecx, ebx
sete al
push eax
push edx
push 0x417b00
push 0x414ef8
push 0x417a80
push 0x417a00
push 0x417980
push 0x417900
call esi
test eax, eax
je 0x40b7ca
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
jmp 0x40b9d9
push edi
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
lea eax, [ebp - 0x144]
push 0x100
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
lea eax, [ebp - 0x144]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
cmp byte [ebp + eax - 0x145], 0x5c
mov esi, dword [sym.imp.KERNEL32.dll_lstrcatA]
je 0x40b80e
lea eax, [ebp - 0x144]
push 0x41410c
push eax
call esi
lea eax, [ebp - 0x144]
push 0x417900
push eax
call esi
lea eax, [ebp - 0x144]
push ebx
push eax
call dword [sym.imp.KERNEL32.dll__lcreat]
cmp eax, 0xffffffff
mov dword [ebp - 4], eax
je 0x40b9d9
push dword [0x417bdc]
push 0x4000
push dword [0x417c38]
push 0x41485c
push 0x414ef0
push 0x414850
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov ecx, dword [0x417c38]
cmp byte [ecx], 0x7f
jne 0x40b8d2
cmp eax, 1
jne 0x40b8d2
push 0x414908
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpyA]
lea eax, [ebp - 0x44]
push eax
call fcn.0040b9de
mov esi, dword [0x417c38]
pop ecx
mov al, byte [esi]
cmp al, bl
je 0x40b9b4
mov edi, dword [ebp - 4]
cmp al, 0x25
jne 0x40b9a8
mov al, byte [esi + 1]
cmp al, 0x31
jl 0x40b9a8
cmp al, 0x38
jg 0x40b9a8
cmp byte [esi + 2], 0x25
jne 0x40b9a8
cmp al, 0x34
jg 0x40b908
movsx edi, al
sub edi, 0x30
shl edi, 7
add edi, 0x417900
jmp 0x40b95b
push 0x5e
push ecx
call fcn.0040c3d7
pop ecx
cmp eax, ebx
pop ecx
je 0x40b878
cmp byte [eax], bl
mov ecx, eax
je 0x40b8ef
inc ecx
cmp byte [ecx], bl
jne 0x40b8e6
cmp ecx, eax
jb 0x40b8f7
mov dl, byte [ecx]
mov byte [ecx + 1], dl
dec ecx
jmp 0x40b8eb
push 0x5e
mov byte [eax], 0xd
mov byte [eax + 1], 0xa
push dword [0x417c38]
jmp 0x40b8d5
cmp al, 0x35
jne 0x40b922
cmp dword [0x4178a8], ebx
je 0x40b91b
mov edi, 0x4148fc
jmp 0x40b95b
mov edi, 0x4148f0
jmp 0x40b95b
cmp al, 0x36
jne 0x40b92b
lea edi, [ebp - 0x44]
jmp 0x40b95b
cmp al, 0x37
jne 0x40b945
cmp dword [0x41785c], ebx
je 0x40b93e
mov edi, 0x4148e8
jmp 0x40b95b
mov edi, 0x4148e0
jmp 0x40b95b
cmp al, 0x38
jne 0x40b95b
cmp dword [0x41785c], ebx
mov edi, 0x4148cc
jne 0x40b95b
mov edi, 0x4175f0
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
sub eax, 3
cmp eax, ebx
jle 0x40b987
lea edx, [esi + 3]
mov ecx, edx
cmp byte [ecx], bl
je 0x40b975
inc ecx
jmp 0x40b96e
cmp ecx, edx
jb 0x40b99b
mov bl, byte [ecx]
mov byte [ecx + eax], bl
dec ecx
cmp ecx, edx
jae 0x40b979
xor ebx, ebx
jmp 0x40b99b
jge 0x40b99b
lea ecx, [esi + 3]
mov dl, byte [ecx]
cmp dl, bl
je 0x40b998
mov byte [ecx + eax], dl
inc ecx
jmp 0x40b98c
mov byte [ecx + eax], bl
mov al, byte [edi]
cmp al, bl
je 0x40b9a7
mov byte [esi], al
inc esi
inc edi
jmp 0x40b99b
dec esi
mov al, byte [esi + 1]
inc esi
cmp al, bl
jne 0x40b895
push dword [0x417c38]
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
push dword [0x417c38]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll__lwrite]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll__lclose]
pop edi
pop esi
pop ebx
leave
ret