Function at 0x401d70
Capabilities:
Set current directory

Disassembly:
sub esp, 0xc
push ebx
push ebp
push esi
mov esi, eax
lea eax, [esp + 0x14]
push edi
push eax
mov byte [esp + 0x1b], 1
mov dword [esp + 0x1c], 0
call dword [sym.imp.VLIHubAPI.dll_VA_GetAPIVersion]
add esp, 4
cmp dword [esp + 0x18], 0x366
je 0x401dee
push str.APIVersion_is_not_equal_ToolVersion_n
mov esi, 0xfffffffe
call fcn.004077ee
mov ecx, dword [esp + 0x1c]
add esp, 4
push 0x2366
push ecx
push str.APIVersion:__x__ToolVersion:__x_n
call fcn.004032b0
mov edx, dword [esp + 0x24]
add esp, 0xc
push esi
push 0x2366
push edx
push str.API_Version:__x_is_not_equal_Tool_Version:__x_nreturn_code_d_n
mov ecx, 0x422070
call fcn.00403460
add esp, 0x10
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret
cmp esi, 2
jne 0x401e05
mov eax, 0x422070
call fcn.00406a90
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret
cmp esi, 3
jne 0x401e1c
mov eax, 0x422070
call fcn.00406320
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret
cmp esi, 9
je 0x402188
cmp esi, 0xa
je 0x402185
cmp esi, 0x11
je 0x40208d
cmp esi, 0x12
je 0x40208d
cmp esi, 0x15
je 0x40208d
cmp esi, 0x16
je 0x40208d
mov ebp, dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
cmp esi, 0xf
je 0x401ed7
cmp esi, 0x17
je 0x401ed7
cmp esi, 0x10
je 0x401ede
cmp esi, 0x14
je 0x401ede
cmp esi, 4
je 0x401ede
cmp esi, 0x13
jne 0x401e7f
mov byte [0x421065], 0
jmp 0x401ede
push 1
call fcn.00401530
add esp, 4
test al, al
jne 0x401ede
push 0x421f68
push 1
mov byte [esp + 0x1f], al
call fcn.00401250
add esp, 8
push 0x421f68
call ebp
push 0
call fcn.00401530
add esp, 4
test al, al
jne 0x401ede
mov esi, 0xfffffffd
push esi
push str.Driver_Install_Failed_nreturn_code_d_n
mov ecx, 0x422070
call fcn.00403460
add esp, 8
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret
or byte [0x428428], 3
mov eax, 0x422070
call fcn.00404d70
mov edi, eax
test edi, edi
jne 0x401fdd
cmp esi, 1
je 0x401fcc
cmp esi, 0xf
je 0x401fcc
cmp esi, 0x10
je 0x401fcc
cmp esi, 0x17
jne 0x401f2b
movzx eax, byte [0x421068]
push eax
mov ecx, 0x422070
call fcn.00406de0
mov edi, eax
jmp 0x402066
cmp esi, 5
jne 0x401f45
push 0
push esi
push str._n_d._Enumerater_Hub_Status:__d_n
call fcn.004032b0
add esp, 0xc
jmp 0x402066
cmp esi, 7
jne 0x401f5b
push 0x422070
call fcn.00405fe0
mov edi, eax
jmp 0x402066
cmp esi, 0xc
je 0x401fa6
cmp esi, 0xd
je 0x401fb9
cmp esi, 0xe
jne 0x401f76
mov byte [0x428420], 0
jmp 0x402066
cmp esi, 0x13
jne 0x401f8c
push 0x422070
call fcn.00406ba0
mov edi, eax
jmp 0x402066
cmp esi, 0x14
jne 0x402066
push 0x422070
call fcn.00406d20
mov edi, eax
jmp 0x402066
push 1
push 0x422070
call fcn.00406c60
mov edi, eax
jmp 0x402066
push 2
push 0x422070
call fcn.00406c60
mov edi, eax
jmp 0x402066
mov ecx, 0x422070
call fcn.004059d0
mov edi, eax
jmp 0x402066
cmp edi, 1
jne 0x401ff6
push str.check_ini_setting_fail_n
call fcn.004032b0
add esp, 4
mov edi, 0xff
jmp 0x402006
push str.check_device_fail_n
call fcn.004032b0
add esp, 4
or edi, 0xffffffff
push edi
push esi
push str._n_d._Function:__d_n
call fcn.004032b0
add esp, 0xc
cmp esi, 7
jne 0x40202b
push 0
lea ebx, [esi - 6]
call fcn.00405da0
push str._Result__n
jmp 0x402046
cmp esi, 1
je 0x402041
cmp esi, 0xb
je 0x402041
cmp esi, 0x10
je 0x402041
push str._Result__n
jmp 0x402046
push str._Result__nUpdate_FW_n
mov ecx, 0x422070
call fcn.00403460
add esp, 4
push edi
push str.return_code_d_n
mov ecx, 0x422070
call fcn.00403460
add esp, 8
cmp byte [esp + 0x17], 0
jne 0x402083
push 0x421f68
push 0
call fcn.00401250
add esp, 8
push 0x421f68
call ebp
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret
mov byte [esp + 0x17], 1
mov bl, 1
cmp esi, 0x11
je 0x4020b3
cmp esi, 0x15
je 0x4020b3
cmp esi, 0x12
je 0x4020a8
cmp esi, 0x16
jne 0x4020bc
mov byte [0x428428], 2
xor bl, bl
jmp 0x4020bc
mov byte [0x428428], 1
mov bl, 1
mov edi, 0x422070
call fcn.00404880
movzx edi, al
cmp esi, 0x15
je 0x4020d6
cmp esi, 0x16
jne 0x4020eb
cmp esi, 0x15
sete al
movzx ecx, al
mov byte [esp + 0x17], al
push ecx
mov eax, 0x422070
call fcn.00406b50
push str._Result__n
mov ecx, 0x422070
call fcn.00403460
add esp, 4
mov eax, str.Install
cmp bl, 1
je 0x40210c
mov eax, str.Uninstall
push eax
push str._s_New_Driver
mov ecx, 0x422070
call fcn.00403460
add esp, 8
cmp esi, 0x15
je 0x402129
cmp esi, 0x16
jne 0x40214d
cmp byte [esp + 0x17], 1
mov eax, str.Disable
je 0x40213a
mov eax, str.Enable
push eax
push str.and__s_Suspend_Status
mov ecx, 0x422070
call fcn.00403460
add esp, 8
mov eax, str.Failed
test edi, edi
je 0x40215b
mov eax, str.Successfully
mov edx, edi
neg edx
sbb edx, edx
and edx, 3
add edx, 0xfffffffd
push edx
push eax
push str._s_nreturn_code_d_n
mov ecx, 0x422070
call fcn.00403460
add esp, 0xc
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret
cmp esi, 9
sete bl
movzx eax, bl
push eax
mov eax, 0x422070
call fcn.00406b50
push str._Result__n
mov ecx, 0x422070
mov esi, eax
call fcn.00403460
add esp, 4
mov eax, str.Disable
cmp bl, 1
je 0x4021bc
mov eax, str.Enable
push eax
push str._s_Suspend_Status
mov ecx, 0x422070
call fcn.00403460
add esp, 8
mov eax, str.Successfully
test esi, esi
je 0x4021dd
mov eax, str.Failed
mov ecx, esi
neg ecx
sbb ecx, ecx
and ecx, 0xfffffffd
push ecx
push eax
push str._s_nreturn_code_d_n
mov ecx, 0x422070
call fcn.00403460
add esp, 0xc
pop edi
mov eax, esi
pop esi
pop ebp
pop ebx
add esp, 0xc
ret