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

Disassembly:
sub esp, 0x3a0
mov eax, dword [0x437348]
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 0x40d0de
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.0042a9c0
add esp, 8
test eax, eax
jne 0x40d0c9
push 0x43ca32
push esi
call fcn.0042a9c0
add esp, 8
test eax, eax
je 0x40d0c9
test esi, esi
jne 0x40d09c
xor eax, eax
jmp 0x40d09f
push esi
call ebp
push esi
push eax
lea ecx, [esp + 0x18]
call fcn.00404520
mov eax, 0x437a2c
test eax, eax
je 0x40d0ba
push 0x437a2c
call ebp
push 0x437a2c
push eax
lea ecx, [esp + 0x18]
call fcn.00404520
mov ecx, dword [esp + 0x3b4]
mov ebx, dword [ebx]
cmp ebx, dword [ecx + 0x410]
jne 0x40d054
mov edx, dword [esp + 0x10]
mov eax, dword [edx - 0xc]
lea esi, [edx - 0xc]
cmp eax, 1
jle 0x40d120
lea ecx, [esp + 0x10]
call fcn.00402400
mov eax, dword [esi + 4]
lea ecx, [esp + 0x10]
push eax
call fcn.004023a0
test eax, eax
je 0x40d120
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 0x40d2e9
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
mov ebx, eax
test ebx, ebx
je 0x40d2e9
mov edx, 0x43babc
test edx, edx
jne 0x40d158
mov dword [esp + 0x14], edx
jmp 0x40d167
push 0x43babc
call dword [sym.imp.KERNEL32.dll_lstrlenA]
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 0x40d2ed
push str.RAVXP.EXE
push esi
call fcn.0042a63f
add esp, 8
test eax, eax
je 0x40d1a2
lea esi, [eax + ebx]
push str.RAVXP.EXE
push esi
inc edi
call fcn.0042a63f
add esp, 8
test eax, eax
jne 0x40d18c
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea esi, [esi + eax + 1]
cmp esi, ebp
jb 0x40d17a
test edi, edi
jle 0x40d2e9
lea ecx, [esp + 0x10]
call fcn.00409b40
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 0x40d1e9
cmp dword [esi - 0xc], 1
jle 0x40d23f
lea eax, [esi - 0xc]
push ebp
lea ecx, [esp + 0x14]
mov dword [esp + 0x24], eax
call fcn.004023a0
test eax, eax
je 0x40d2e9
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 [0x43734c]
je 0x40d23b
push eax
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x40d23b
mov ecx, dword [esp + 0x20]
push ecx
call fcn.004292c0
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 0x40d2e6
push str.RAVXP.EXE
push esi
call fcn.0042a63f
mov edi, eax
add esp, 8
test edi, edi
je 0x40d2cb
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.0042a050
mov ecx, esi
mov esi, 0x43babc
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.0042a63f
mov edi, eax
add esp, 0x14
test edi, edi
jne 0x40d264
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 0x40d250
mov esi, dword [esp + 0x10]
mov dword [esi - 8], ebp
mov esi, dword [esp + 0x10]
mov edx, dword [esp + 0x30]
mov al, byte [edx + 0x251]
test al, al
je 0x40d64b
mov eax, str.RAVSTUB.EXE
test eax, eax
je 0x40d4a5
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
call esi
mov ebx, eax
test ebx, ebx
je 0x40d4a1
mov ecx, 0x43babc
test ecx, ecx
jne 0x40d32e
mov dword [esp + 0x14], ecx
jmp 0x40d339
push 0x43babc
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 0x40d4a5
push str.RAVSTUB.EXE
push esi
call fcn.0042a63f
add esp, 8
test eax, eax
je 0x40d374
lea esi, [eax + ebx]
push str.RAVSTUB.EXE
push esi
inc edi
call fcn.0042a63f
add esp, 8
test eax, eax
jne 0x40d35e
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea esi, [esi + eax + 1]
cmp esi, ebp
jb 0x40d34c
test edi, edi
jle 0x40d4a1
lea ecx, [esp + 0x10]
call fcn.00409b40
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 0x40d3bb
cmp dword [esi - 0xc], 1
jle 0x40d3f7
lea edx, [esi - 0xc]
push ebp
lea ecx, [esp + 0x14]
mov dword [esp + 0x20], edx
call fcn.004023a0
test eax, eax
je 0x40d4a1
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.00409b10
mov esi, dword [esp + 0x10]
mov eax, dword [esi - 8]
add eax, esi
cmp esi, eax
mov dword [esp + 0x20], eax
jae 0x40d49e
push str.RAVSTUB.EXE
push esi
call fcn.0042a63f
mov edi, eax
add esp, 8
test edi, edi
je 0x40d483
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.0042a050
mov ecx, esi
mov esi, 0x43babc
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.0042a63f
mov edi, eax
add esp, 0x14
test edi, edi
jne 0x40d41c
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 0x40d408
mov esi, dword [esp + 0x10]
mov dword [esi - 8], ebp
mov esi, dword [esp + 0x10]
mov ecx, str.RAVMOND.EXE
test ecx, ecx
je 0x40d64b
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenA]
push ecx
call esi
mov ebx, eax
test ebx, ebx
je 0x40d647
mov edx, 0x43babc
test edx, edx
jne 0x40d4d4
mov dword [esp + 0x14], edx
jmp 0x40d4df
push 0x43babc
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 0x40d64b
push str.RAVMOND.EXE
push esi
call fcn.0042a63f
add esp, 8
test eax, eax
je 0x40d51a
lea esi, [eax + ebx]
push str.RAVMOND.EXE
push esi
inc edi
call fcn.0042a63f
add esp, 8
test eax, eax
jne 0x40d504
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea esi, [esi + eax + 1]
cmp esi, ebp
jb 0x40d4f2
test edi, edi
jle 0x40d647
lea ecx, [esp + 0x10]
call fcn.00409b40
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 0x40d561
cmp dword [esi - 0xc], 1
jle 0x40d59d
lea eax, [esi - 0xc]
push ebp
lea ecx, [esp + 0x14]
mov dword [esp + 0x20], eax
call fcn.004023a0
test eax, eax
je 0x40d647
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.00409b10
mov esi, dword [esp + 0x10]
mov eax, dword [esi - 8]
add eax, esi
cmp esi, eax
mov dword [esp + 0x20], eax
jae 0x40d644
push str.RAVMOND.EXE
push esi
call fcn.0042a63f
mov edi, eax
add esp, 8
test edi, edi
je 0x40d629
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.0042a050
mov ecx, esi
mov esi, 0x43babc
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.0042a63f
mov edi, eax
add esp, 0x14
test edi, edi
jne 0x40d5c2
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 0x40d5ae
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 0x40d693
mov eax, dword [0x43734c]
lea ecx, [esi - 0xc]
cmp ecx, eax
je 0x40d9df
add esi, 0xfffffff4
push esi
call dword [sym.imp.KERNEL32.dll_InterlockedDecrement]
test eax, eax
jg 0x40d9df
mov edx, dword [esp + 0x10]
add edx, 0xfffffff4
push edx
call fcn.004292c0
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.00402000
cmp dword [esp + 0x2c], edi
je 0x40d9d6
mov eax, dword [esp + 0x24]
cmp eax, 1
jl 0x40d9d6
inc eax
push eax
call fcn.00429728
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.0042a8c0
mov edi, 0x437a2c
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.00402020
test ebp, ebp
mov esi, ebp
je 0x40d9cd
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
je 0x40d9cd
push 0x3b
push esi
call fcn.0042a488
mov ebx, eax
add esp, 8
test ebx, ebx
jne 0x40d771
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.0042a8c0
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.0042a488
add esp, 0x14
test eax, eax
je 0x40d7e5
lea edx, [esp + 0x34]
push 0x2b
push edx
call fcn.0042a488
lea ecx, [esp + 0x3c]
lea edx, [esp + 0x3c]
sub eax, ecx
push eax
lea eax, [esp + 0x78]
push edx
push eax
call fcn.0042a8c0
add esp, 0x14
jmp 0x40d7f9
lea ecx, [esp + 0x34]
push 0x38
lea edx, [esp + 0x70]
push ecx
push edx
call fcn.0042a8c0
add esp, 0xc
lea eax, [esp + 0x6c]
push 0
push eax
lea ecx, [esp + 0x18]
call fcn.00409be0
test eax, eax
je 0x40d822
jle 0x40d9c2
mov ecx, dword [esp + 0x10]
cmp byte [eax + ecx - 1], 0x3b
jne 0x40d9c2
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 0x43c41a
lea edx, [esp + 0xa8]
push str._sRAVXP.EXE
push edx
stosb byte es:[edi], al
call fcn.00429590
mov eax, dword [0x43d848]
add esp, 0xc
cmp eax, 6
je 0x40d895
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.00401fa0
push 0x1f4
call dword [sym.imp.KERNEL32.dll_Sleep]
mov ecx, dword [esp + 0x18]
push 0
push 0x43babc
lea edx, [esp + 0x3c]
push 0x64
push edx
call fcn.00401fa0
test eax, eax
jne 0x40d9a0
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 0x43babc
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.004295f0
add esp, 8
test eax, eax
jne 0x40d985
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, 0x437a2c
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 0x40d9c2
mov edx, dword [esp + 0x3b8]
push eax
lea eax, [esp + 0x38]
push eax
push str.CallProcess__s_EXIT_return__d
push 0x43bb00
mov byte [edx], 0
call fcn.004042f0
add esp, 0x10
lea esi, [ebx + 1]
test esi, esi
jne 0x40d747
push ebp
call fcn.004292c0
add esp, 4
lea ecx, [esp + 0x10]
call fcn.004024e0
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x3a0
ret 8