Function at 0x407f40
Capabilities:
Read .ini file

Disassembly:
mov eax, dword [esp + 4]
sub esp, 0x60
push ebx
lea edx, [eax*4 + 0x40f3b0]
mov ecx, dword [esp + 0x6c]
push esi
push edi
mov eax, dword [edx]
mov dword [esp + 0xc], edx
push ebp
lea edx, [esp + 0x1c]
push ecx
mov dword [eax + 0x3b5], 0x12d687
push 0x40f800
push edx
call dword [sym.imp.USER32.dll_wsprintfA]
mov edx, dword [esp + 0x1c]
add esp, 0xc
push 0x4011a0
mov eax, dword [edx]
push 0x32
add eax, 0x3b9
lea ecx, [esp + 0x24]
push eax
push 0x401198
push 0x4011c8
push ecx
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov edx, dword [esp + 0x10]
mov ecx, 0x401198
mov eax, dword [edx]
add eax, 0x3b9
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x407fd2
or dl, dl
je 0x407fce
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x407fd2
add eax, 2
add ecx, 2
or dl, dl
jne 0x407fb2
xor eax, eax
jmp 0x407fd7
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x407fe5
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x60
ret
push 0xc44
call fcn.00405390
add esp, 4
mov edi, eax
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov edx, dword [esp + 0x10]
shr ecx, 2
mov esi, edi
mov edi, dword [edx]
add edi, 0x3eb
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov edx, dword [esp + 0x10]
xor ecx, ecx
mov eax, dword [edx]
xor edx, edx
mov cl, byte [eax + 0x14]
mov dl, byte [eax + 0x13]
sub ecx, edx
mov edx, dword [esp + 0x10]
inc ecx
mov dword [eax + 0x3a5], ecx
mov eax, dword [edx]
xor esi, esi
xor ebp, ebp
cmp dword [eax + 0x3a5], esi
jle 0x4080bd
lea ebx, [esi + 1]
lea eax, [esp + 0x3c]
push ebx
push 0x4011b0
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0xc
push 0x30
call fcn.00405d90
lea ecx, [esp + 0x40]
add esp, 4
mov edi, eax
push 0x4011a0
push 0x28
lea eax, [edi + 8]
push eax
push ecx
lea ecx, [esp + 0x4c]
lea eax, [esp + 0x2c]
push ecx
push eax
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov dword [edi + 4], esi
test ebp, ebp
mov dword [edi], 0
jne 0x4080a8
mov ebp, edi
mov edx, dword [esp + 0x10]
mov eax, dword [edx]
mov dword [eax + 0x399], edi
jmp 0x4080ad
mov dword [ebp], edi
mov ebp, edi
mov esi, ebx
mov edx, dword [esp + 0x10]
mov eax, dword [edx]
cmp dword [eax + 0x3a5], ebx
jg 0x408048
push 0xc44
call fcn.00405390
add esp, 4
mov edi, eax
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov edx, dword [esp + 0x10]
shr ecx, 2
mov esi, edi
mov edi, dword [edx]
add edi, 0x3eb
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
push 0x4011a0
and ecx, 3
push 0x32
rep movsb byte es:[edi], byte [esi]
lea eax, [esp + 0x44]
lea ecx, [esp + 0x24]
push eax
push 0x401198
push 0x4011b8
push ecx
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [esp + 0x3c]
mov ecx, 0x401198
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x40813f
or dl, dl
je 0x40813b
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x40813f
add eax, 2
add ecx, 2
or dl, dl
jne 0x40811f
xor eax, eax
jmp 0x408144
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x4082c4
lea eax, [esp + 0x3c]
mov ecx, 0x40fa40
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x408175
or dl, dl
je 0x408171
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x408175
add eax, 2
add ecx, 2
or dl, dl
jne 0x408155
xor eax, eax
jmp 0x40817a
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x4082c4
xor ebx, ebx
push 0x2000
call fcn.00405d90
mov dword [esp + 0x1c], eax
add esp, 4
lea ecx, [esp + 0x1c]
push 0x4011a0
push 0x2000
mov edi, 0x401108
push eax
push 0x401198
push 0x4011b8
push ecx
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov ecx, 0xffffffff
mov edi, dword [esp + 0x18]
sub eax, eax
repne scasb al, byte es:[edi]
dec edi
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x18]
xor edi, edi
cmp byte [esi], bl
je 0x408289
lea eax, [esp + 0x14]
push eax
push 0x40f810
push esi
call sub.CRTDLL.dll_sscanf
add esp, 0xc
cmp eax, 1
jne 0x408289
mov edx, dword [esp + 0x10]
dec dword [esp + 0x14]
mov ecx, dword [esp + 0x14]
mov eax, dword [edx]
mov eax, dword [eax + 0x3a5]
dec eax
test ecx, ecx
jg 0x408228
xor ecx, ecx
cmp eax, ecx
jl 0x40822e
mov eax, ecx
mov dword [esp + 0x14], eax
push 0x14
call fcn.00405d90
mov ecx, dword [esp + 0x18]
add esp, 4
mov dword [eax + 8], ecx
test edi, edi
mov dword [eax + 0xc], 0
mov dword [eax + 0x10], 0
mov dword [eax], edi
mov dword [eax + 4], 0
jne 0x40826c
mov edx, dword [esp + 0x10]
mov ecx, dword [edx]
mov dword [ecx + 0x3a1], eax
jmp 0x40826f
mov dword [edi + 4], eax
mov edi, eax
push 0x20
push esi
inc ebx
call sub.CRTDLL.dll_strchr
add esp, 8
lea esi, [eax + 1]
cmp byte [esi], 0
jne 0x4081f5
test ebx, ebx
je 0x4082aa
mov edx, dword [esp + 0x10]
mov esi, dword [edx]
mov eax, dword [esi + 0x3a1]
push eax
call fcn.00407c80
add esp, 4
mov dword [esi + 0x39d], eax
jmp 0x4082b7
mov eax, dword [esp + 0x74]
push eax
call fcn.00407cd0
add esp, 4
mov eax, dword [esp + 0x18]
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
jmp 0x4082d1
mov eax, dword [esp + 0x74]
push eax
call fcn.00407cd0
add esp, 4
mov eax, 1
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x60
ret