Function at 0x4161c0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push 0xffffffffffffffff
push 0x41a9e8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x58
push ebx
push ebp
mov ebp, ecx
push esi
lea ecx, [esp + 0x34]
call sub.MFC42.DLL_CStringArray::CStringArray
xor esi, esi
or ebx, 0xffffffff
mov dword [esp + 0x6c], esi
lea ecx, [esp + 0x20]
call sub.MFC42.DLL_CString::CString_2
inc esi
lea eax, [esp + 0x20]
push esi
push str.COM_d
push eax
mov byte [esp + 0x78], 1
call sub.MFC42.DLL_CString::Format
mov edx, dword [esp + 0x48]
add esp, 0xc
lea ecx, [esp + 0x20]
push ecx
push edx
lea ecx, [esp + 0x3c]
call sub.MFC42.DLL_CStringArray::SetAtGrow
lea ecx, [esp + 0x20]
mov byte [esp + 0x6c], 0
call sub.MFC42.DLL_CString::CString
cmp esi, 0xff
jl 0x4161ef
push edi
xor eax, eax
push 2
mov ecx, 6
lea edi, [esp + 0x54]
push eax
mov dword [esp + 0x54], 0x1c
push eax
rep stosd dword es:[edi], eax
push 0x425d18
call dword [sym.imp.SETUPAPI.dll_SetupDiGetClassDevsA]
mov edi, eax
lea eax, [esp + 0x4c]
push eax
push 0
push edi
mov dword [esp + 0x34], 0
call dword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInfo]
test eax, eax
je 0x416620
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::CString_2
lea ecx, [esp + 0x14]
mov byte [esp + 0x70], 2
call sub.MFC42.DLL_CString::CString_2
lea ecx, [esp + 0x20]
mov byte [esp + 0x70], 3
call sub.MFC42.DLL_CString::CString_2
lea ecx, [esp + 0x18]
mov byte [esp + 0x70], 4
call sub.MFC42.DLL_CString::CString_2
mov eax, dword [esp + 0x28]
mov byte [esp + 0x70], 5
cmp eax, 0xff
ja 0x4165e8
push 0
push 0x104
push 0x104
lea ecx, [esp + 0x30]
call sub.MFC42.DLL_CString::GetBuffer
lea ecx, [esp + 0x54]
push eax
push ecx
push edi
call dword [sym.imp.SETUPAPI.dll_SetupDiGetDeviceInstanceIdA]
push 0
push 0x104
push 0x104
lea ecx, [esp + 0x20]
call sub.MFC42.DLL_CString::GetBuffer
mov esi, dword [sym.imp.SETUPAPI.dll_SetupDiGetDeviceRegistryPropertyA]
push eax
push 0
lea edx, [esp + 0x5c]
push 0xc
push edx
push edi
call esi
push 0
push 0x104
push 0x104
lea ecx, [esp + 0x2c]
call sub.MFC42.DLL_CString::GetBuffer
push eax
push 0
lea eax, [esp + 0x5c]
push 4
push eax
push edi
call esi
push 0
push 0x104
push 0x104
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::GetBuffer
push eax
push 0
lea ecx, [esp + 0x5c]
push 1
push ecx
push edi
call esi
push 0xffffffffffffffff
lea ecx, [esp + 0x28]
call sub.MFC42.DLL_CString::ReleaseBuffer
push 0xffffffffffffffff
lea ecx, [esp + 0x18]
call sub.MFC42.DLL_CString::ReleaseBuffer
push 0xffffffffffffffff
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::ReleaseBuffer
push 0xffffffffffffffff
lea ecx, [esp + 0x1c]
call sub.MFC42.DLL_CString::ReleaseBuffer
push 4
push 0x28
lea ecx, [esp + 0x1c]
call sub.MFC42.DLL_CString::ReverseFind
lea edx, [esp + 0x30]
push eax
push edx
lea ecx, [esp + 0x20]
call sub.MFC42.DLL_CString::Mid_1
mov eax, dword [eax]
push str._COM
push eax
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
lea ecx, [esp + 0x2c]
test eax, eax
sete byte [esp + 0x13]
call sub.MFC42.DLL_CString::CString
mov al, byte [esp + 0x13]
test al, al
je 0x416590
lea eax, [esp + 0x14]
lea ecx, [esp + 0x1c]
push eax
call fcn.0041a126
push 0x28
lea ecx, [esp + 0x20]
mov byte [esp + 0x74], 6
call sub.MFC42.DLL_CString::ReverseFind
inc eax
lea ecx, [esp + 0x30]
push eax
push ecx
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::Mid
push eax
lea ecx, [esp + 0x20]
mov byte [esp + 0x74], 7
call fcn.0041a006
lea ecx, [esp + 0x30]
mov byte [esp + 0x70], 6
call sub.MFC42.DLL_CString::CString
push 0x42de0c
lea ecx, [esp + 0x20]
call sub.MFC42.DLL_CString::TrimRight
lea edx, [esp + 0x34]
push 3
push edx
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::Mid
mov eax, dword [eax]
push 0xa
push 0
push eax
call dword [sym.imp.MSVCRT.dll_strtoul]
mov esi, eax
add esp, 0xc
lea ecx, [esp + 0x34]
dec esi
call sub.MFC42.DLL_CString::CString
mov eax, dword [esp + 0x18]
push str.USBVID_34BFPID_1004REV_0100MI_01
push eax
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
test eax, eax
je 0x416559
mov ecx, dword [esp + 0x18]
push str.USBVID_34BFPID_1005REV_0100MI_01
push ecx
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
test eax, eax
je 0x416559
mov edx, dword [esp + 0x18]
push str.USBVID_34BFPID_1004REV_0100MI_03
push edx
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
test eax, eax
je 0x416541
mov eax, dword [esp + 0x18]
push str.USBVID_34BFPID_1005REV_0100MI_03
push eax
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
test eax, eax
je 0x416541
mov ecx, dword [esp + 0x18]
push str.USBVID_34BFPID_FF0AREV_0100MI_00
push ecx
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
test eax, eax
jne 0x4164e4
lea edx, [esi + 1]
lea eax, [esp + 0x14]
push edx
push str.STC_USB_CDC1__COM_d_
push eax
jmp 0x416567
mov ecx, dword [esp + 0x18]
push str.USBVID_34BFPID_FF0AREV_0100MI_02
push ecx
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
test eax, eax
jne 0x416513
lea edx, [esi + 1]
lea eax, [esp + 0x14]
push edx
push str.STC_USB_CDC2__COM_d_
push eax
call sub.MFC42.DLL_CString::Format
add esp, 0xc
jmp 0x416571
mov ecx, dword [esp + 0x18]
push str.USBVID_34BFPID_FF02REV_0100
push ecx
call dword [sym.imp.MSVCRT.dll__mbsicmp]
add esp, 8
test eax, eax
jne 0x41653a
lea edx, [esi + 1]
lea eax, [esp + 0x14]
push edx
push str.STC_USB_CDC__COM_d_
push eax
jmp 0x416567
cmp ebx, 0xffffffff
jne 0x416571
jmp 0x41656f
lea ecx, [esi + 1]
lea edx, [esp + 0x14]
push ecx
push str.STC_USB_Link1D__CDC2___COM_d_
push edx
call sub.MFC42.DLL_CString::Format
add esp, 0xc
jmp 0x416571
lea eax, [esi + 1]
lea ecx, [esp + 0x14]
push eax
push str.STC_USB_Link1D__CDC1___COM_d_
push ecx
call sub.MFC42.DLL_CString::Format
add esp, 0xc
mov ebx, esi
mov eax, dword [esp + 0x3c]
lea edx, [esp + 0x14]
push edx
lea ecx, [eax + esi*4]
call fcn.0041a006
lea ecx, [esp + 0x1c]
mov byte [esp + 0x70], 5
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x18]
mov byte [esp + 0x70], 4
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x20]
mov byte [esp + 0x70], 3
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x14]
mov byte [esp + 0x70], 2
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x24]
mov byte [esp + 0x70], 0
call sub.MFC42.DLL_CString::CString
mov eax, dword [esp + 0x28]
lea ecx, [esp + 0x4c]
inc eax
push ecx
push eax
push edi
mov dword [esp + 0x34], eax
call dword [sym.imp.SETUPAPI.dll_SetupDiEnumDeviceInfo]
test eax, eax
jne 0x41627f
jmp 0x416620
lea ecx, [esp + 0x18]
mov byte [esp + 0x70], 4
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x20]
mov byte [esp + 0x70], 3
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x14]
mov byte [esp + 0x70], 2
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x24]
mov byte [esp + 0x70], 0
call sub.MFC42.DLL_CString::CString
push edi
call dword [sym.imp.SETUPAPI.dll_SetupDiDestroyDeviceInfoList]
cmp ebx, 0xffffffff
jne 0x416644
push 0
push str.Main_COMx
push str.Settings
mov ecx, 0x431b78
call sub.MFC42.DLL_CWinApp::GetProfileIntA
mov ebx, eax
mov edx, dword [ebp + 0x100]
mov esi, dword [sym.imp.USER32.dll_SendMessageA]
push 0
push 0
push 0x146
push edx
call esi
test eax, eax
je 0x416688
mov eax, dword [ebp + 0x100]
push 0
push 0
push 0x144
push eax
call esi
mov ecx, dword [ebp + 0x100]
push 0
push 0
push 0x146
push ecx
call esi
test eax, eax
jne 0x416660
xor edi, edi
mov edx, dword [esp + 0x3c]
mov eax, dword [edi + edx]
push eax
mov eax, dword [ebp + 0x100]
push 0
push 0x143
push eax
call esi
add edi, 4
cmp edi, 0x3fc
jl 0x41668a
mov edi, 1
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::CString_2
push 0x4312
push 0x5354
push edi
lea ecx, [ebp + 0x720]
mov byte [esp + 0x7c], 8
call fcn.004104b0
cmp eax, 0xffffffff
je 0x41673d
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
lea ecx, [esp + 0x28]
push str.STC_USB_Writer__USB_d_
push ecx
call sub.MFC42.DLL_CString::Format
mov edx, dword [esp + 0x30]
mov eax, dword [ebp + 0x100]
add esp, 0xc
push edx
push 0
push 0x143
push eax
call esi
mov ecx, dword [ebp + 0x100]
mov ebx, eax
push 0x53544312
push ebx
push 0x151
push ecx
call esi
lea ecx, [esp + 0x24]
mov byte [esp + 0x70], 0
call sub.MFC42.DLL_CString::CString
inc edi
cmp edi, 0x100
jl 0x4166b2
jmp 0x41674b
lea ecx, [esp + 0x24]
mov byte [esp + 0x70], 0
call sub.MFC42.DLL_CString::CString
mov edi, 1
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::CString_2
push 0
push 0x4313
push 0x5354
push edi
lea ecx, [ebp + 0x720]
mov byte [esp + 0x80], 9
call fcn.0040fe30
cmp eax, 0xffffffff
je 0x4167e3
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
lea edx, [esp + 0x28]
push str.STC_USB_Writer__HID_d_
push edx
call sub.MFC42.DLL_CString::Format
mov eax, dword [esp + 0x30]
mov ecx, dword [ebp + 0x100]
add esp, 0xc
push eax
push 0
push 0x143
push ecx
call esi
mov edx, dword [ebp + 0x100]
mov ebx, eax
push 0x53544313
push ebx
push 0x151
push edx
call esi
lea ecx, [esp + 0x24]
mov byte [esp + 0x70], 0
call sub.MFC42.DLL_CString::CString
inc edi
cmp edi, 0x100
jl 0x416750
jmp 0x41689b
lea ecx, [esp + 0x24]
mov byte [esp + 0x70], 0
call sub.MFC42.DLL_CString::CString
cmp edi, 0x100
jge 0x41689b
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::CString_2
push 0
push 0x1001
push 0x34bf
push edi
lea ecx, [ebp + 0x720]
mov byte [esp + 0x80], 0xa
call fcn.0040fe30
cmp eax, 0xffffffff
je 0x41688d
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
lea eax, [esp + 0x28]
push str.STC_USB_Writer__HID_d_
push eax
call sub.MFC42.DLL_CString::Format
mov ecx, dword [esp + 0x30]
mov edx, dword [ebp + 0x100]
add esp, 0xc
push ecx
push 0
push 0x143
push edx
call esi
mov ebx, eax
mov eax, dword [ebp + 0x100]
push 0x34bf1001
push ebx
push 0x151
push eax
call esi
lea ecx, [esp + 0x24]
mov byte [esp + 0x70], 0
call sub.MFC42.DLL_CString::CString
inc edi
cmp edi, 0x100
jl 0x4167fd
jmp 0x41689b
lea ecx, [esp + 0x24]
mov byte [esp + 0x70], 0
call sub.MFC42.DLL_CString::CString
mov edi, 1
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::CString_2
push 0
push 0x1004
push 0x34bf
push edi
lea ecx, [ebp + 0x720]
mov byte [esp + 0x80], 0xb
call fcn.0040fe30
cmp eax, 0xffffffff
je 0x416930
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
lea ecx, [esp + 0x28]
push str.STC_USB_Link1__LNK_d_
push ecx
call sub.MFC42.DLL_CString::Format
mov edx, dword [esp + 0x30]
mov eax, dword [ebp + 0x100]
add esp, 0xc
push edx
push 0
push 0x143
push eax
call esi
mov ecx, dword [ebp + 0x100]
mov ebx, eax
push 0x34bf1004
push ebx
push 0x151
push ecx
call esi
lea ecx, [esp + 0x24]
mov byte [esp + 0x70], 0
call sub.MFC42.DLL_CString::CString
inc edi
cmp edi, 0x100
jl 0x4168a0
jmp 0x41693e
lea ecx, [esp + 0x24]
mov byte [esp + 0x70], 0
call sub.MFC42.DLL_CString::CString
mov edi, 1
lea ecx, [esp + 0x24]
call sub.MFC42.DLL_CString::CString_2
push 0
push 0x1005
push 0x34bf
push edi
lea ecx, [ebp + 0x720]
mov byte [esp + 0x80], 0xc
call fcn.0040fe30
cmp eax, 0xffffffff
je 0x4169d3
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
lea edx, [esp + 0x28]
push str.STC_USB_Link1__LNK_d_
push edx
call sub.MFC42.DLL_CString::Format
mov eax, dword [esp + 0x30]
mov ecx, dword [ebp + 0x100]
add esp, 0xc
push eax
push 0
push 0x143
push ecx
call esi
mov edx, dword [ebp + 0x100]
mov ebx, eax
push 0x34bf1005
push ebx
push 0x151
push edx
call esi
lea ecx, [esp + 0x24]
mov byte [esp + 0x70], 0
call sub.MFC42.DLL_CString::CString
inc edi
cmp edi, 0x100
jl 0x416943
jmp 0x4169e1
lea ecx, [esp + 0x24]
mov byte [esp + 0x70], 0
call sub.MFC42.DLL_CString::CString
cmp ebx, 0xffffffff
pop edi
je 0x4169fd
mov eax, dword [ebp + 0x100]
push 0
push 0
push 0x146
push eax
call esi
cmp ebx, eax
jl 0x4169ff
xor ebx, ebx
mov ecx, dword [ebp + 0x100]
push 0
push ebx
push 0x14e
push ecx
call esi
lea edx, [esp + 0x30]
push 0xe
push edx
mov ecx, ebp
call fcn.00418c00
mov eax, dword [eax]
push 0x42da64
push eax
call dword [sym.imp.MSVCRT.dll__mbscmp]
add esp, 8
lea ecx, [esp + 0x30]
test eax, eax
sete bl
call sub.MFC42.DLL_CString::CString
test bl, bl
je 0x416a79
lea eax, [esp + 0x30]
push 0xf
push eax
mov ecx, ebp
call fcn.00418c00
mov eax, dword [eax]
push 0
push 0
push eax
call dword [sym.imp.MSVCRT.dll_strtoul]
mov ecx, dword [ebp + 0x100]
add esp, 0xc
push 0
push eax
push 0x14e
push ecx
call esi
lea ecx, [esp + 0x30]
call sub.MFC42.DLL_CString::CString
lea ecx, [esp + 0x34]
mov dword [esp + 0x6c], 0xffffffff
call fcn.0041a114
mov ecx, dword [esp + 0x64]
pop esi
pop ebp
mov eax, 1
pop ebx
mov dword fs:[0], ecx
add esp, 0x64
ret