Function at 0x4044e0
Capabilities:
Read .ini file

Disassembly:
push 0xffffffffffffffff
push 0x408bfb
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x310
push ebx
push esi
mov esi, ecx
push edi
lea ecx, [esp + 0xc]
call sub.MFC42.DLL_CString::CString
push 0x104
push 8
mov dword [esp + 0x32c], 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, 0x41
xor eax, eax
lea edi, [esp + 0x10]
rep stosd dword es:[edi], eax
mov ecx, 0x41
lea edi, [esp + 0x114]
rep stosd dword es:[edi], eax
mov eax, dword [esi + 0x104]
lea ecx, [esp + 0x114]
push eax
push str._sRework.ini
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 0xc
lea edx, [esp + 0x114]
push 0
push 0x80
push 3
push 0
push 0
push 0x80000000
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
lea ebx, [esi + 0x60]
push 0x6e
mov ecx, ebx
mov edi, eax
call sub.MFC42.DLL_CString::LoadStringA
cmp edi, 0xffffffff
jne 0x4045bb
mov ebx, dword [ebx]
push 0
push str.Profile_Error
push ebx
mov ecx, esi
call sub.MFC42.DLL_CWnd::MessageBoxA
lea ecx, [esp + 0xc]
mov dword [esp + 0x324], edi
call fcn.00407d8e
xor eax, eax
jmp 0x40489f
push ebp
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, dword [sym.imp.KERNEL32.dll_GetPrivateProfileStringA]
lea eax, [esp + 0x118]
push eax
lea ecx, [esp + 0x18]
push 0x104
lea edx, [esp + 0x224]
push ecx
push edx
push 0x40d1f0
push 0x40d1e8
call edi
lea eax, [esp + 0x14]
lea ecx, [esi + 0x7c]
push eax
call fcn.00407dc4
lea ecx, [esp + 0x118]
lea edx, [esp + 0x14]
push ecx
push 0x104
lea eax, [esp + 0x224]
push edx
push eax
push 0x40d1e4
push 0x40d1e8
call edi
lea ecx, [esp + 0x14]
push ecx
lea ecx, [esi + 0x80]
call fcn.00407dc4
lea edx, [esp + 0x118]
lea eax, [esp + 0x14]
push edx
push 0x104
lea ecx, [esp + 0x224]
push eax
push ecx
push str.USBMfStr
push str.USB_MANUFACTURE_STRING
call edi
lea edx, [esp + 0x14]
lea ecx, [esi + 0x84]
push edx
call fcn.00407dc4
lea eax, [esp + 0x118]
lea ecx, [esp + 0x14]
push eax
push 0x104
lea edx, [esp + 0x224]
push ecx
push edx
push str.USBPdStr
push str.USB_PRODUCT_STRING
call edi
lea eax, [esp + 0x14]
lea ecx, [esi + 0x8c]
push eax
call fcn.00407dc4
lea ecx, [esp + 0x118]
lea edx, [esp + 0x14]
push ecx
push 0x104
lea eax, [esp + 0x224]
push edx
push eax
push str.SCSIMfStr
push str.SCSI_MANUFACTURE_STRING
call edi
lea ecx, [esp + 0x14]
push ecx
lea ecx, [esi + 0x88]
call fcn.00407dc4
lea edx, [esp + 0x118]
lea eax, [esp + 0x14]
push edx
push 0x104
lea ecx, [esp + 0x224]
push eax
push ecx
push str.SCSIPdStr
push str.SCSI_PRODUCT_STRING
call edi
lea edx, [esp + 0x14]
lea ecx, [esi + 0x90]
push edx
call fcn.00407dc4
mov ebp, dword [sym.imp.KERNEL32.dll_GetPrivateProfileIntA]
lea eax, [esp + 0x118]
push eax
push 0
push str.Enable
push str.SERIAL_NUMBER
call ebp
cmp eax, 1
mov dword [esi + 0x94], eax
jne 0x40476c
lea ecx, [esp + 0x118]
lea edx, [esp + 0x14]
push ecx
push 0x104
lea eax, [esp + 0x224]
push edx
push eax
push 0x40d140
push str.SERIAL_NUMBER
call edi
lea ecx, [esp + 0x14]
push ecx
lea ecx, [esi + 0x98]
call fcn.00407dc4
jmp 0x404833
test eax, eax
jne 0x4047ab
lea edx, [esp + 0x118]
lea eax, [esp + 0x14]
push edx
push 0x104
lea ecx, [esp + 0x224]
push eax
push ecx
push str.FixSN
push str.SERIAL_NUMBER
call edi
lea edx, [esp + 0x14]
lea ecx, [esi + 0x9c]
push edx
call fcn.00407dc4
jmp 0x404833
lea eax, [esp + 0x118]
lea ecx, [esp + 0x14]
push eax
push 0x104
lea edx, [esp + 0x224]
push ecx
push edx
push 0x40d130
push str.SERIAL_NUMBER
call edi
lea eax, [esp + 0x14]
lea ecx, [esi + 0xa0]
push eax
call fcn.00407dc4
lea ecx, [esp + 0x118]
lea edx, [esp + 0x14]
push ecx
push 0x104
lea eax, [esp + 0x224]
push edx
push eax
push 0x40d128
push str.SERIAL_NUMBER
call edi
lea ecx, [esp + 0x14]
lea ebx, [esi + 0xa4]
push ecx
mov ecx, ebx
call fcn.00407dc4
mov ebx, dword [ebx]
push ebx
call dword [sym.imp.MSVCRT.dll_atol]
mov ecx, dword [esi + 0xf4]
add esp, 4
add eax, ecx
mov dword [esi + 0xf0], eax
lea edx, [esp + 0x118]
push edx
push 0
push str.PreCopyFile
push 0x40d054
call ebp
mov dword [esi + 0xec], eax
lea eax, [esp + 0x118]
push eax
lea ecx, [esp + 0x18]
push 0x104
lea edx, [esp + 0x224]
push ecx
push edx
push str.PreCopyFilePath1
push 0x40d054
call edi
lea eax, [esp + 0x14]
lea ecx, [esi + 0xe8]
push eax
call fcn.00407dc4
lea ecx, [esp + 0x10]
mov dword [esp + 0x328], 0xffffffff
call fcn.00407d8e
mov eax, 1
pop ebp
mov ecx, dword [esp + 0x31c]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x31c
ret