Function at 0x40c850
Capabilities:
Read .ini file
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x3a0
mov eax, dword [0x4350b8]
mov dword [esp + 0x20], ecx
mov ecx, dword [esp + 0x3a4]
mov dword [esp], eax
push ebx
push ebp
mov eax, dword [ecx + 0x410]
mov ebp, dword [sym.imp.KERNEL32.dll_lstrlenA]
push esi
push edi
mov ebx, dword [eax]
cmp ebx, eax
je 0x40c90e
mov edx, dword [ebx + 8]
or ecx, 0xffffffff
xor eax, eax
push str..exe
lea esi, [edx + 0x241]
mov edi, esi
repne scasb al, byte es:[edi]
not ecx
dec ecx
lea edx, [ecx + edx + 0x23d]
push edx
call fcn.00427e70
add esp, 8
test eax, eax
jne 0x40c8f9
push 0x43a5d2
push esi
call fcn.00427e70
add esp, 8
test eax, eax
je 0x40c8f9
test esi, esi
jne 0x40c8cc
xor eax, eax
jmp 0x40c8cf
push esi
call ebp
push esi
push eax
lea ecx, [esp + 0x18]
call fcn.00404650
mov eax, 0x4356d4
test eax, eax
je 0x40c8ea
push 0x4356d4
call ebp
push 0x4356d4
push eax
lea ecx, [esp + 0x18]
call fcn.00404650
mov ecx, dword [esp + 0x3b4]
mov ebx, dword [ebx]
cmp ebx, dword [ecx + 0x410]
jne 0x40c884
mov edx, dword [esp + 0x10]
mov eax, dword [edx - 0xc]
lea esi, [edx - 0xc]
cmp eax, 1
jle 0x40c950
lea ecx, [esp + 0x10]
call fcn.00401e30
mov eax, dword [esi + 4]
lea ecx, [esp + 0x10]
push eax
call fcn.00401dd0
test eax, eax
je 0x40c950
mov ecx, dword [esi + 4]
mov edi, dword [esp + 0x10]
inc ecx
add esi, 0xc
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.USER32.dll_CharUpperA]
mov ecx, str.RAVXP.EXE
test ecx, ecx
je 0x40cb11
push ecx
call ebp
mov ebx, eax
test ebx, ebx
je 0x40cb11
mov edx, 0x43965c
test edx, edx
jne 0x40c984
mov dword [esp + 0x14], edx
jmp 0x40c98f
push 0x43965c
call ebp
mov dword [esp + 0x14], eax
mov esi, dword [esp + 0x10]
xor edi, edi
mov ebp, dword [esi - 8]
add ebp, esi
cmp esi, ebp
jae 0x40cb15
push str.RAVXP.EXE
push esi
call fcn.00427aec
add esp, 8
test eax, eax
je 0x40c9ca
lea esi, [eax + ebx]
push str.RAVXP.EXE
push esi
inc edi
call fcn.00427aec
add esp, 8
test eax, eax
jne 0x40c9b4
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea esi, [esi + eax + 1]
cmp esi, ebp
jb 0x40c9a2
test edi, edi
jle 0x40cb11
lea ecx, [esp + 0x10]
call fcn.004094c0
mov ebp, dword [esp + 0x14]
mov esi, dword [esp + 0x10]
sub ebp, ebx
imul ebp, edi
mov eax, dword [esi - 8]
mov dword [esp + 0x18], eax
add ebp, eax
mov eax, dword [esi - 4]
mov dword [esp + 0x28], ebp
cmp eax, ebp
jl 0x40ca11
cmp dword [esi - 0xc], 1
jle 0x40ca67
lea eax, [esi - 0xc]
push ebp
lea ecx, [esp + 0x14]
mov dword [esp + 0x24], eax
call fcn.00401dd0
test eax, eax
je 0x40cb11
mov eax, dword [esp + 0x20]
mov edi, dword [esp + 0x10]
mov ecx, dword [eax + 4]
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
cmp eax, dword [0x4350bc]
je 0x40ca63
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x40ca63
mov ecx, dword [esp + 0x20]
push ecx
call fcn.00426ac0
add esp, 4
mov esi, dword [esp + 0x10]
mov eax, dword [esi - 8]
add eax, esi
cmp esi, eax
mov dword [esp + 0x1c], eax
jae 0x40cb0e
push str.RAVXP.EXE
push esi
call fcn.00427aec
mov edi, eax
add esp, 8
test edi, edi
je 0x40caf3
mov ebp, dword [esp + 0x18]
mov esi, dword [esp + 0x10]
sub ebp, edi
lea edx, [edi + ebx]
sub ebp, ebx
add ebp, esi
mov esi, dword [esp + 0x14]
push ebp
push edx
lea eax, [edi + esi]
push eax
mov dword [esp + 0x2c], eax
call fcn.00427720
mov ecx, esi
mov esi, 0x43965c
mov eax, ecx
push str.RAVXP.EXE
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x30]
mov ecx, eax
sub ecx, ebx
push esi
mov byte [esi + ebp], 0
mov ebp, dword [esp + 0x2c]
add ebp, ecx
mov dword [esp + 0x2c], ebp
call fcn.00427aec
mov edi, eax
add esp, 0x14
test edi, edi
jne 0x40ca8c
mov ebp, dword [esp + 0x28]
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea esi, [esi + eax + 1]
mov eax, dword [esp + 0x1c]
cmp esi, eax
jb 0x40ca78
mov esi, dword [esp + 0x10]
mov dword [esi - 8], ebp
mov esi, dword [esp + 0x10]
mov edx, str.RAVSTUB.EXE
test edx, edx
je 0x40ccbb
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenA]
push edx
call esi
mov ebx, eax
test ebx, ebx
je 0x40ccb7
mov eax, 0x43965c
test eax, eax
jne 0x40cb44
mov dword [esp + 0x14], eax
jmp 0x40cb4f
push 0x43965c
call esi
mov dword [esp + 0x14], eax
mov esi, dword [esp + 0x10]
xor edi, edi
mov ebp, dword [esi - 8]
add ebp, esi
cmp esi, ebp
jae 0x40ccbb
push str.RAVSTUB.EXE
push esi
call fcn.00427aec
add esp, 8
test eax, eax
je 0x40cb8a
lea esi, [eax + ebx]
push str.RAVSTUB.EXE
push esi
inc edi
call fcn.00427aec
add esp, 8
test eax, eax
jne 0x40cb74
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea esi, [esi + eax + 1]
cmp esi, ebp
jb 0x40cb62
test edi, edi
jle 0x40ccb7
lea ecx, [esp + 0x10]
call fcn.004094c0
mov ebp, dword [esp + 0x14]
mov esi, dword [esp + 0x10]
sub ebp, ebx
imul ebp, edi
mov eax, dword [esi - 8]
mov dword [esp + 0x18], eax
add ebp, eax
mov eax, dword [esi - 4]
mov dword [esp + 0x28], ebp
cmp eax, ebp
jl 0x40cbd1
cmp dword [esi - 0xc], 1
jle 0x40cc0d
lea ecx, [esi - 0xc]
push ebp
mov dword [esp + 0x20], ecx
lea ecx, [esp + 0x14]
call fcn.00401dd0
test eax, eax
je 0x40ccb7
mov eax, dword [esp + 0x1c]
mov edi, dword [esp + 0x10]
push eax
mov ecx, dword [eax + 4]
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call fcn.00409490
mov esi, dword [esp + 0x10]
mov eax, dword [esi - 8]
add eax, esi
cmp esi, eax
mov dword [esp + 0x20], eax
jae 0x40ccb4
push str.RAVSTUB.EXE
push esi
call fcn.00427aec
mov edi, eax
add esp, 8
test edi, edi
je 0x40cc99
mov ebp, dword [esp + 0x18]
mov edx, dword [esp + 0x10]
mov esi, dword [esp + 0x14]
sub ebp, edi
sub ebp, ebx
lea ecx, [edi + ebx]
add ebp, edx
lea eax, [edi + esi]
push ebp
push ecx
push eax
mov dword [esp + 0x28], eax
call fcn.00427720
mov ecx, esi
mov esi, 0x43965c
mov edx, ecx
push str.RAVSTUB.EXE
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
mov eax, edx
and ecx, 3
sub eax, ebx
rep movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x2c]
push esi
mov byte [esi + ebp], 0
mov ebp, dword [esp + 0x2c]
add ebp, eax
mov dword [esp + 0x2c], ebp
call fcn.00427aec
mov edi, eax
add esp, 0x14
test edi, edi
jne 0x40cc32
mov ebp, dword [esp + 0x28]
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea esi, [esi + eax + 1]
mov eax, dword [esp + 0x20]
cmp esi, eax
jb 0x40cc1e
mov esi, dword [esp + 0x10]
mov dword [esi - 8], ebp
mov esi, dword [esp + 0x10]
mov ecx, str.RAVMOND.EXE
test ecx, ecx
je 0x40ce61
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenA]
push ecx
call esi
mov ebx, eax
test ebx, ebx
je 0x40ce5d
mov edx, 0x43965c
test edx, edx
jne 0x40ccea
mov dword [esp + 0x14], edx
jmp 0x40ccf5
push 0x43965c
call esi
mov dword [esp + 0x14], eax
mov esi, dword [esp + 0x10]
xor edi, edi
mov ebp, dword [esi - 8]
add ebp, esi
cmp esi, ebp
jae 0x40ce61
push str.RAVMOND.EXE
push esi
call fcn.00427aec
add esp, 8
test eax, eax
je 0x40cd30
lea esi, [eax + ebx]
push str.RAVMOND.EXE
push esi
inc edi
call fcn.00427aec
add esp, 8
test eax, eax
jne 0x40cd1a
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea esi, [esi + eax + 1]
cmp esi, ebp
jb 0x40cd08
test edi, edi
jle 0x40ce5d
lea ecx, [esp + 0x10]
call fcn.004094c0
mov ebp, dword [esp + 0x14]
mov esi, dword [esp + 0x10]
sub ebp, ebx
imul ebp, edi
mov eax, dword [esi - 8]
mov dword [esp + 0x18], eax
add ebp, eax
mov eax, dword [esi - 4]
mov dword [esp + 0x28], ebp
cmp eax, ebp
jl 0x40cd77
cmp dword [esi - 0xc], 1
jle 0x40cdb3
lea eax, [esi - 0xc]
push ebp
lea ecx, [esp + 0x14]
mov dword [esp + 0x20], eax
call fcn.00401dd0
test eax, eax
je 0x40ce5d
mov eax, dword [esp + 0x1c]
mov edi, dword [esp + 0x10]
push eax
mov ecx, dword [eax + 4]
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
call fcn.00409490
mov esi, dword [esp + 0x10]
mov eax, dword [esi - 8]
add eax, esi
cmp esi, eax
mov dword [esp + 0x20], eax
jae 0x40ce5a
push str.RAVMOND.EXE
push esi
call fcn.00427aec
mov edi, eax
add esp, 8
test edi, edi
je 0x40ce3f
mov ebp, dword [esp + 0x18]
mov edx, dword [esp + 0x10]
mov esi, dword [esp + 0x14]
sub ebp, edi
sub ebp, ebx
lea ecx, [edi + ebx]
add ebp, edx
lea eax, [edi + esi]
push ebp
push ecx
push eax
mov dword [esp + 0x28], eax
call fcn.00427720
mov ecx, esi
mov esi, 0x43965c
mov edx, ecx
push str.RAVMOND.EXE
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
mov eax, edx
and ecx, 3
sub eax, ebx
rep movsb byte es:[edi], byte [esi]
mov esi, dword [esp + 0x2c]
push esi
mov byte [esi + ebp], 0
mov ebp, dword [esp + 0x2c]
add ebp, eax
mov dword [esp + 0x2c], ebp
call fcn.00427aec
mov edi, eax
add esp, 0x14
test edi, edi
jne 0x40cdd8
mov ebp, dword [esp + 0x28]
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea esi, [esi + eax + 1]
mov eax, dword [esp + 0x20]
cmp esi, eax
jb 0x40cdc4
mov esi, dword [esp + 0x10]
mov dword [esi - 8], ebp
mov esi, dword [esp + 0x10]
mov eax, dword [esi - 8]
xor edi, edi
cmp eax, edi
jne 0x40cea9
mov eax, dword [0x4350bc]
lea ecx, [esi - 0xc]
cmp ecx, eax
je 0x40d1f5
add esi, 0xfffffff4
push esi
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x40d1f5
mov edx, dword [esp + 0x10]
add edx, 0xfffffff4
push edx
call fcn.00426ac0
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x3a0
ret 8
mov eax, dword [esp + 0x30]
lea ecx, [esp + 0x24]
lea edx, [esp + 0x2c]
push ecx
mov ebx, dword [eax + 0x240]
push edx
mov ecx, ebx
mov dword [esp + 0x2c], edi
mov dword [esp + 0x34], edi
mov dword [esp + 0x20], ebx
call fcn.00401a30
cmp dword [esp + 0x2c], edi
je 0x40d1ec
mov eax, dword [esp + 0x24]
cmp eax, 1
jl 0x40d1ec
inc eax
push eax
call fcn.00426d08
mov ecx, dword [esp + 0x28]
mov ebp, eax
mov edx, ecx
xor eax, eax
mov edi, ebp
mov dword [esp + 0x20], ebp
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x30]
push eax
push ecx
push ebp
call fcn.00427d70
mov edi, 0x4356d4
or ecx, 0xffffffff
xor eax, eax
add esp, 0x10
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edx, ecx
mov edi, ebp
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 0x2c]
and ecx, 3
push eax
rep movsb byte es:[edi], byte [esi]
mov ecx, ebx
call fcn.00401a50
test ebp, ebp
mov esi, ebp
je 0x40d1e3
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x40d1e3
push 0x3b
push esi
call fcn.00427a55
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x40cf87
mov ecx, dword [esp + 0x24]
lea ebx, [ecx + ebp]
mov ecx, 0xd
xor eax, eax
lea edi, [esp + 0x35]
mov byte [esp + 0x34], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov edx, ebx
sub edx, esi
stosb byte es:[edi], al
push edx
lea eax, [esp + 0x38]
push esi
push eax
call fcn.00427d70
mov ecx, 0xd
xor eax, eax
lea edi, [esp + 0x79]
mov byte [esp + 0x78], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
lea ecx, [esp + 0x40]
push 0x2b
push ecx
stosb byte es:[edi], al
call fcn.00427a55
add esp, 0x14
test eax, eax
je 0x40cffb
lea edx, [esp + 0x34]
push 0x2b
push edx
call fcn.00427a55
lea ecx, [esp + 0x3c]
lea edx, [esp + 0x3c]
sub eax, ecx
push eax
lea eax, [esp + 0x78]
push edx
push eax
call fcn.00427d70
add esp, 0x14
jmp 0x40d00f
lea ecx, [esp + 0x34]
push 0x38
lea edx, [esp + 0x70]
push ecx
push edx
call fcn.00427d70
add esp, 0xc
lea eax, [esp + 0x6c]
push 0
push eax
lea ecx, [esp + 0x18]
call fcn.00409560
test eax, eax
je 0x40d038
jle 0x40d1d8
mov ecx, dword [esp + 0x10]
cmp byte [eax + ecx - 1], 0x3b
jne 0x40d1d8
mov ecx, 0x40
xor eax, eax
lea edi, [esp + 0xa5]
mov byte [esp + 0xa4], 0
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
push 0x439fba
lea edx, [esp + 0xa8]
push str._sRAVXP.EXE
push edx
stosb byte es:[edi], al
call fcn.00426b7c
mov eax, dword [0x43b3b8]
add esp, 0xc
cmp eax, 6
je 0x40d0ab
lea edi, [esp + 0xa4]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
lea eax, [esp + 0xa4]
push ecx
push eax
lea ecx, [esp + 0x3c]
push 0
push ecx
mov ecx, dword [esp + 0x28]
call fcn.004019d0
push 0x1f4
call dword [sym.imp.KERNEL32.dll_Sleep]
mov ecx, dword [esp + 0x18]
push 0
push 0x43965c
lea edx, [esp + 0x3c]
push 0x64
push edx
call fcn.004019d0
test eax, eax
jne 0x40d1b6
mov ecx, 0x81
lea edi, [esp + 0x1a9]
mov byte [esp + 0x1a8], al
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov eax, dword [esp + 0x30]
lea ecx, [esp + 0x1a8]
lea ebp, [eax + 0x50]
push ebp
push 0x208
push ecx
push 0x43965c
push str.Closed
push str.Update
call dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea edx, [esp + 0x34]
lea eax, [esp + 0x1a8]
push edx
push eax
call fcn.00426bd0
add esp, 8
test eax, eax
jne 0x40d19b
lea edi, [esp + 0x34]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x1a8]
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea edx, [esp + 0x1a8]
and ecx, 3
push ebp
rep movsb byte es:[edi], byte [esi]
mov edi, 0x4356d4
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
lea eax, [esp + 0x1ac]
and ecx, 3
push eax
push str.Closed
push str.Update
rep movsb byte es:[edi], byte [esi]
call dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringA]
push 0x1f4
call dword [sym.imp.KERNEL32.dll_Sleep]
mov ecx, dword [esp + 0x3b8]
mov ebp, dword [esp + 0x1c]
mov byte [ecx], 1
jmp 0x40d1d8
mov edx, dword [esp + 0x3b8]
push eax
lea eax, [esp + 0x38]
push eax
push str.CallProcess__s_EXIT_return__d
push 0x4396a0
mov byte [edx], 0
call fcn.00404420
add esp, 0x10
lea esi, [ebx + 1]
test esi, esi
jne 0x40cf5d
push ebp
call fcn.00426ac0
add esp, 4
lea ecx, [esp + 0x10]
call fcn.00401f10
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x3a0
ret 8