Function at 0x4089a0
Capabilities:
Delete file
Print debug messages
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x417611
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x73c
push ebx
push ebp
mov ebp, ecx
push esi
push edi
lea ecx, [esp + 0x2c]
call sub.MFC42u.DLL_CString::CString_4
xor ebx, ebx
push 0x10
mov dword [esp + 0x758], ebx
call sub.MFC42u.DLL_operatornew
mov esi, eax
add esp, 4
mov dword [esp + 0x34], esi
cmp esi, ebx
mov byte [esp + 0x754], 1
je 0x408a10
push ecx
mov ecx, esp
mov dword [esp + 0x44], esp
push str.SOFTWAREMicrosoftMSSQLserv80Setup
call sub.MFC42u.DLL_CString::CString_1
push 0x80000002
mov ecx, esi
call fcn.0040ec20
mov esi, eax
jmp 0x408a12
xor esi, esi
push ecx
mov byte [esp + 0x758], 0
mov ecx, esp
mov dword [esp + 0x38], esp
push str.SQLPath
call sub.MFC42u.DLL_CString::CString_1
lea eax, [esp + 0x20]
mov ecx, esi
push eax
call fcn.0040ed20
mov ecx, dword [esp + 0x1c]
mov byte [esp + 0x754], 2
mov eax, dword [ecx - 8]
cmp eax, 4
jge 0x408ae3
cmp esi, ebx
je 0x408a5c
mov edx, dword [esi]
push 1
mov ecx, esi
call dword [edx + 4]
push 0x10
call sub.MFC42u.DLL_operatornew
mov esi, eax
add esp, 4
mov dword [esp + 0x34], esi
cmp esi, ebx
mov byte [esp + 0x754], 3
je 0x408a99
push ecx
mov ecx, esp
mov dword [esp + 0x44], esp
push str.SoftwareMicrosoftMSSQLServerSetup
call sub.MFC42u.DLL_CString::CString_1
push 0x80000002
mov ecx, esi
call fcn.0040ec20
mov esi, eax
jmp 0x408a9b
xor esi, esi
push ecx
mov byte [esp + 0x758], 2
mov ecx, esp
mov dword [esp + 0x38], esp
push str.SQLPath
call sub.MFC42u.DLL_CString::CString_1
lea eax, [esp + 0x48]
mov ecx, esi
push eax
call fcn.0040ed20
push eax
lea ecx, [esp + 0x20]
mov byte [esp + 0x758], 4
call sub.MFC42u.DLL_CString::operator_2
lea ecx, [esp + 0x44]
mov byte [esp + 0x754], 2
call sub.MFC42u.DLL_CString::CString
mov edx, dword [esp + 0x1c]
mov ecx, 0x81
xor eax, eax
lea edi, [esp + 0x10e]
mov word [esp + 0x10c], bx
push 0x104
rep stosd dword es:[edi], eax
lea ecx, [esp + 0x110]
push ecx
push edx
stosw word es:[edi], ax
call dword [sym.imp.KERNEL32.dll_GetShortPathNameW]
test eax, eax
jne 0x408b26
push str.GetShortPathName_failed__using_m_strSphinxPath_n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
jmp 0x408b37
lea eax, [esp + 0x10c]
lea ecx, [esp + 0x1c]
push eax
call fcn.00415d82
lea ecx, [esp + 0x1c]
push ecx
mov ecx, dword [ebp + 0x290]
call fcn.00414660
cmp esi, ebx
je 0x408b54
mov edx, dword [esi]
push 1
mov ecx, esi
call dword [edx + 4]
mov eax, dword [ebp + 0x290]
mov ecx, dword [eax + 0x120]
mov edx, dword [eax + 0x128]
mov eax, dword [esp + 0x1c]
push ecx
push edx
push eax
lea ecx, [esp + 0x38]
push str._sbinn_replupd.exe__ActionType_CheckStatus__SecurityMode_0__UserName_sa__Password___s___Server__s
push ecx
call sub.MFC42u.DLL_CString::Format_1
add esp, 0x14
lea ecx, [esp + 0x20]
call sub.MFC42u.DLL_CString::CString_4
mov edx, dword [ebp + 0x290]
lea ecx, [esp + 0x20]
mov byte [esp + 0x754], 5
mov eax, dword [edx + 0x134]
push eax
push str._sreplupd.out
push ecx
call sub.MFC42u.DLL_CString::Format_1
mov edx, dword [esp + 0x2c]
mov esi, dword [sym.imp.KERNEL32.dll_DeleteFileW]
add esp, 0xc
push edx
call esi
lea ecx, [esp + 0x24]
call sub.MFC42u.DLL_CString::CString_4
mov eax, dword [ebp + 0x290]
lea edx, [esp + 0x24]
mov byte [esp + 0x754], 6
mov ecx, dword [eax + 0x134]
push ecx
push str._sreplupd_err.out
push edx
call sub.MFC42u.DLL_CString::Format_1
mov eax, dword [esp + 0x30]
add esp, 0xc
push eax
call esi
mov ecx, dword [esp + 0x24]
push ecx
lea ecx, [esp + 0x24]
call fcn.00409e10
push eax
push ecx
lea edx, [esp + 0x38]
mov ecx, esp
mov dword [esp + 0x40], esp
push edx
call sub.MFC42u.DLL_CString::CString_3
lea ecx, [esp + 0x80]
call fcn.0040e3d0
push ebx
lea ecx, [esp + 0x78]
mov byte [esp + 0x758], 7
call fcn.0040e750
lea ecx, [esp + 0x14]
call sub.MFC42u.DLL_CString::CString_4
lea ecx, [esp + 0x28]
mov byte [esp + 0x754], 8
call sub.MFC42u.DLL_CString::CString_4
lea ecx, [esp + 0x10]
mov byte [esp + 0x754], 9
call sub.MFC42u.DLL_CString::CString_4
lea ecx, [esp + 0x74]
mov byte [esp + 0x754], 0xa
call fcn.0040e9f0
mov esi, eax
cmp esi, ebx
mov ebx, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov dword [esp + 0x44], esi
je 0x408d5d
lea ecx, [esp + 0x58]
call sub.MFC42u.DLL_CFile::CFile
mov eax, dword [esp + 0x24]
push 0
push 0
push eax
lea ecx, [esp + 0x64]
mov byte [esp + 0x760], 0xb
call sub.MFC42u.DLL_CFile::Open
test eax, eax
jne 0x408cb9
mov byte [esp + 0x754], 0xa
lea ecx, [esp + 0x58]
jmp 0x4092b9
lea ecx, [esp + 0x314]
push ecx
lea ecx, [esp + 0x5c]
call sub.MFC42u.DLL_CFile::GetStatus
test eax, eax
je 0x408d43
mov edx, dword [esp + 0x320]
lea edi, [edx + 1]
push edi
push 8
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
test esi, esi
jne 0x408cfb
mov byte [esp + 0x754], 0xa
lea ecx, [esp + 0x58]
jmp 0x4092b9
mov eax, dword [esp + 0x320]
lea ecx, [esp + 0x58]
push eax
push esi
add edi, edi
call sub.MFC42u.DLL_CFile::Read
push edi
push edi
lea ecx, [esp + 0x30]
call sub.MFC42u.DLL_CString::GetBuffer
push eax
push 0xffffffffffffffff
push esi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
push 0xffffffffffffffff
lea ecx, [esp + 0x2c]
call sub.MFC42u.DLL_CString::ReleaseBuffer
push esi
push 0
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
mov esi, dword [esp + 0x44]
lea ecx, [esp + 0x58]
call sub.MFC42u.DLL_CFile::Close
lea ecx, [esp + 0x58]
mov byte [esp + 0x754], 0xa
call fcn.00415e72
lea eax, [esi - 2]
cmp eax, 0xa
ja case.0x408d65.8
jmp dword [eax*4 + 0x409364]
push 0x7d2
jmp 0x408ddf
push 0x7d3
jmp 0x408d9f
push 0x7d4
jmp 0x408dbf
push 0x7d5
jmp 0x408ddf
push 0x7d6
jmp 0x408d9f
push 0x7d7
jmp 0x408dbf
push 0xa
jmp 0x408ddf
push 0x7db
lea ecx, [esp + 0x14]
call sub.MFC42u.DLL_CString::LoadStringW
mov eax, dword [esp + 0x10]
lea ecx, [esp + 0x14]
push eax
push esi
push 0x15f
push ecx
jmp 0x408df8
push 0x7dc
lea ecx, [esp + 0x14]
call sub.MFC42u.DLL_CString::LoadStringW
mov edx, dword [esp + 0x10]
lea eax, [esp + 0x14]
push edx
push esi
push 0x15f
push eax
jmp 0x408df8
push 0x7cf
lea ecx, [esp + 0x14]
call sub.MFC42u.DLL_CString::LoadStringW
mov ecx, dword [esp + 0x10]
lea edx, [esp + 0x14]
push ecx
push esi
push 0x15f
push edx
call sub.MFC42u.DLL_CString::Format
add esp, 0x10
test esi, esi
je 0x408e39
mov eax, dword [esp + 0x28]
mov ecx, dword [eax - 8]
test ecx, ecx
je 0x408e2b
push 0x4223f4
lea ecx, [esp + 0x18]
call sub.MFC42u.DLL_CString::operator_1
lea ecx, [esp + 0x28]
push ecx
lea ecx, [esp + 0x18]
call sub.MFC42u.DLL_CString::operator
mov edx, dword [esp + 0x14]
push 0
push 0
push edx
call sub.MFC42u.DLL_AfxMessageBox
lea ecx, [esp + 0x48]
call sub.MFC42u.DLL_CFile::CFile
mov eax, dword [esp + 0x20]
push 0
push 0
push eax
lea ecx, [esp + 0x54]
mov byte [esp + 0x760], 0xc
call sub.MFC42u.DLL_CFile::Open
test eax, eax
je 0x4092ad
lea ecx, [esp + 0x18]
call sub.MFC42u.DLL_CString::CString_4
lea ecx, [esp + 0x530]
mov byte [esp + 0x754], 0xd
push ecx
lea ecx, [esp + 0x4c]
call sub.MFC42u.DLL_CFile::GetStatus
test eax, eax
je 0x40929c
mov edx, dword [esp + 0x53c]
lea edi, [edx + 1]
push edi
push 8
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
test esi, esi
je 0x40929c
mov eax, dword [esp + 0x53c]
lea ecx, [esp + 0x48]
push eax
push esi
add edi, edi
call sub.MFC42u.DLL_CFile::Read
push edi
push edi
lea ecx, [esp + 0x20]
call sub.MFC42u.DLL_CString::GetBuffer
push eax
push 0xffffffffffffffff
push esi
push 0
push 0
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
push 0xffffffffffffffff
lea ecx, [esp + 0x1c]
call sub.MFC42u.DLL_CString::ReleaseBuffer
push esi
push 0
call ebx
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
lea ecx, [esp + 0x48]
call sub.MFC42u.DLL_CFile::Close
lea ecx, [esp + 0x38]
call sub.MFC42u.DLL_CString::CString_4
lea ecx, [esp + 0x30]
mov byte [esp + 0x754], 0xe
call sub.MFC42u.DLL_CString::CString_4
lea ecx, [esp + 0x3c]
mov byte [esp + 0x754], 0xf
call sub.MFC42u.DLL_CString::CString_4
push 0x4223f0
lea ecx, [esp + 0x1c]
mov byte [esp + 0x758], 0x10
call sub.MFC42u.DLL_CString::Find
mov esi, eax
test esi, esi
jl 0x409269
mov ecx, dword [esp + 0x18]
cmp dword [ecx - 8], 0x38
jl 0x409269
cmp esi, 0xffffffff
jle 0x4090c8
mov edi, dword [sym.imp.MSVCRT.dll_wcscmp]
mov bl, 0x14
mov edx, dword [esp + 0x38]
push esi
cmp dword [edx - 8], 1
jge 0x408ff4
lea eax, [esp + 0x6c]
lea ecx, [esp + 0x1c]
push eax
call sub.MFC42u.DLL_CString::Left
push eax
lea ecx, [esp + 0x3c]
mov byte [esp + 0x758], 0x11
call sub.MFC42u.DLL_CString::operator_2
lea ecx, [esp + 0x68]
mov byte [esp + 0x754], 0x10
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x6c]
push 1
push ecx
lea ecx, [esp + 0x40]
call sub.MFC42u.DLL_CString::Right
push eax
lea ecx, [esp + 0x3c]
mov byte [esp + 0x758], 0x12
call sub.MFC42u.DLL_CString::operator_2
lea ecx, [esp + 0x6c]
mov byte [esp + 0x754], 0x10
call sub.MFC42u.DLL_CString::CString
mov edx, dword [esp + 0x38]
push 0x4210cc
push edx
call edi
add esp, 8
test eax, eax
je 0x409269
jmp 0x40907c
lea eax, [esp + 0x74]
lea ecx, [esp + 0x1c]
push eax
call sub.MFC42u.DLL_CString::Left
push eax
lea ecx, [esp + 0x34]
mov byte [esp + 0x758], 0x13
call sub.MFC42u.DLL_CString::operator_2
lea ecx, [esp + 0x70]
mov byte [esp + 0x754], 0x10
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x40]
push 1
push ecx
lea ecx, [esp + 0x38]
call sub.MFC42u.DLL_CString::Right
push eax
lea ecx, [esp + 0x34]
mov byte [esp + 0x758], bl
call sub.MFC42u.DLL_CString::operator_2
lea ecx, [esp + 0x40]
mov byte [esp + 0x754], 0x10
call sub.MFC42u.DLL_CString::CString
mov edx, dword [esp + 0x30]
push 0x422354
push edx
call edi
mov ecx, dword [ebp + 0x290]
add esp, 8
test eax, eax
sete al
and eax, 0xff
mov dword [ecx + 0x158], eax
inc esi
lea ecx, [esp + 0x34]
push esi
push ecx
lea ecx, [esp + 0x20]
call sub.MFC42u.DLL_CString::Mid_1
push eax
lea ecx, [esp + 0x1c]
mov byte [esp + 0x758], 0x15
call sub.MFC42u.DLL_CString::operator_2
lea ecx, [esp + 0x34]
mov byte [esp + 0x754], 0x10
call sub.MFC42u.DLL_CString::CString
push 0x4223f0
lea ecx, [esp + 0x1c]
call sub.MFC42u.DLL_CString::Find
mov esi, eax
cmp esi, 0xffffffff
jg 0x408f65
push 0x4212ac
lea ecx, [esp + 0x1c]
call sub.MFC42u.DLL_CString::Find
inc eax
lea edx, [esp + 0x34]
push eax
push edx
lea ecx, [esp + 0x20]
call sub.MFC42u.DLL_CString::Mid_1
push eax
lea ecx, [esp + 0x40]
mov byte [esp + 0x758], 0x16
call sub.MFC42u.DLL_CString::operator_2
lea ecx, [esp + 0x34]
mov byte [esp + 0x754], 0x10
call sub.MFC42u.DLL_CString::CString
mov eax, dword [ebp + 0x290]
push 0xd3
mov esi, dword [eax + 0x118]
mov ecx, esi
call fcn.00403d50
push 0
push ecx
lea edx, [esp + 0x38]
mov ecx, esp
mov dword [esp + 0x48], esp
push edx
call sub.MFC42u.DLL_CString::CString_3
push 0xa8
mov ecx, esi
call fcn.00403f40
push 0
push ecx
lea eax, [esp + 0x44]
mov ecx, esp
mov dword [esp + 0x48], esp
push eax
call sub.MFC42u.DLL_CString::CString_3
push 0xa9
mov ecx, esi
call fcn.00403f40
mov ebp, dword [ebp + 0x290]
lea ecx, [esp + 0x3c]
push ecx
lea ecx, [ebp + 0x130]
call sub.MFC42u.DLL_CString::operator_2
mov eax, dword [esp + 0x44]
xor edx, edx
test eax, eax
sete dl
lea ecx, [esp + 0x3c]
mov esi, edx
mov byte [esp + 0x754], 0xf
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x30]
mov byte [esp + 0x754], 0xe
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x38]
mov byte [esp + 0x754], 0xd
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x18]
mov byte [esp + 0x754], 0xc
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x48]
mov byte [esp + 0x754], 0xa
call fcn.00415e72
lea ecx, [esp + 0x10]
mov byte [esp + 0x754], 9
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x28]
mov byte [esp + 0x754], 8
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x14]
mov byte [esp + 0x754], 7
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x74]
mov byte [esp + 0x754], 6
call fcn.0040e530
mov byte [esp + 0x754], 5
lea ecx, [esp + 0x24]
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x20]
mov byte [esp + 0x754], 2
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x1c]
mov byte [esp + 0x754], 0
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x2c]
mov dword [esp + 0x754], 0xffffffff
call sub.MFC42u.DLL_CString::CString
mov eax, esi
jmp 0x40934b
lea ecx, [esp + 0x3c]
mov byte [esp + 0x754], 0xf
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x30]
mov byte [esp + 0x754], 0xe
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x38]
mov byte [esp + 0x754], 0xd
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x18]
mov byte [esp + 0x754], 0xc
call sub.MFC42u.DLL_CString::CString
mov byte [esp + 0x754], 0xa
lea ecx, [esp + 0x48]
call fcn.00415e72
lea ecx, [esp + 0x10]
mov byte [esp + 0x754], 9
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x28]
mov byte [esp + 0x754], 8
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x14]
mov byte [esp + 0x754], 7
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x74]
mov byte [esp + 0x754], 6
call fcn.0040e530
lea ecx, [esp + 0x24]
mov byte [esp + 0x754], 5
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x20]
mov byte [esp + 0x754], 2
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x1c]
mov byte [esp + 0x754], 0
call sub.MFC42u.DLL_CString::CString
lea ecx, [esp + 0x2c]
mov dword [esp + 0x754], 0xffffffff
call sub.MFC42u.DLL_CString::CString
xor eax, eax
mov ecx, dword [esp + 0x74c]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x748
ret