Function at 0x402010
Capabilities:
Delete registry key
Query or enumerate registry key
Query or enumerate registry value

Disassembly:
sub esp, 0x310
push ebx
push ebp
push esi
push edi
mov edi, str.SystemCurrentControlSetServicesClassUSBIOClass
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x120]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov ebp, dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x120]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov dword [esp + 0x1c], 0x100
and ecx, 3
mov dword [esp + 0x14], 0
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x10]
push ecx
push edx
push 0x80000002
call ebp
mov ebx, dword [sym.imp.ADVAPI32.dll_RegEnumKeyA]
test eax, eax
jne 0x40215e
mov ecx, dword [esp + 0x10]
lea eax, [esp + 0x20]
xor esi, esi
push 0x100
push eax
push esi
push ecx
call ebx
test eax, eax
jne 0x40213c
mov edi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
mov ebp, dword [sym.imp.MSVCRT.dll__mbscmp]
mov ecx, dword [esp + 0x10]
lea edx, [esp + 0x18]
lea eax, [esp + 0x20]
push edx
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
test eax, eax
jne 0x40211c
mov ecx, dword [esp + 0x18]
lea edx, [esp + 0x1c]
lea eax, [esp + 0x220]
push edx
push eax
push 0
push 0
push str.ProviderName
push ecx
call edi
lea edx, [esp + 0x220]
push edx
call fcn.00402680
lea eax, [esp + 0x224]
push str.eturbotouch_inc.
push eax
call ebp
add esp, 0xc
test eax, eax
jne 0x40211c
mov ecx, dword [esp + 0x18]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [esp + 0x10]
lea edx, [esp + 0x20]
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
test eax, eax
je 0x40211c
inc esi
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x20]
push 0x100
push ecx
push esi
push edx
call ebx
test eax, eax
je 0x4020a3
mov ebp, dword [sym.imp.ADVAPI32.dll_RegOpenKeyA]
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
jne 0x40215e
lea ecx, [esp + 0x120]
push ecx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
mov edi, str.SystemCurrentControlSetServicesClassff646f80_8def_11d2_9449_00105a075f6b
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x120]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x120]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x10]
push ecx
push edx
push 0x80000002
call ebp
test eax, eax
jne 0x402205
mov ecx, dword [esp + 0x10]
mov eax, 0x100
push eax
lea eax, [esp + 0x24]
xor esi, esi
push eax
push esi
push ecx
call ebx
test eax, eax
jne 0x4021e3
mov eax, dword [esp + 0x10]
lea edx, [esp + 0x20]
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
test eax, eax
je 0x4021cd
inc esi
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x20]
push 0x100
push ecx
push esi
push edx
call ebx
test eax, eax
je 0x4021b8
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
jne 0x402205
lea ecx, [esp + 0x120]
push ecx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
mov edi, str.SystemCurrentControlSetServicesVxDeTouch
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x120]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x120]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x10]
push ecx
push edx
push 0x80000002
call ebp
test eax, eax
jne 0x4022ae
mov ecx, dword [esp + 0x10]
mov eax, 0x100
push eax
lea eax, [esp + 0x24]
xor esi, esi
push eax
push esi
push ecx
call ebx
test eax, eax
jne 0x40228a
mov eax, dword [esp + 0x10]
lea edx, [esp + 0x20]
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
test eax, eax
je 0x402274
inc esi
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x20]
push 0x100
push ecx
push esi
push edx
call ebx
test eax, eax
je 0x40225f
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
jne 0x4022b6
lea ecx, [esp + 0x120]
push ecx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
jmp 0x4022b6
mov dword [esp + 0x14], 1
mov edi, str.EnumUSBVID_1234PID_5678
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x120]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
lea edx, [esp + 0x120]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea ecx, [esp + 0x10]
push ecx
push edx
push 0x80000002
call ebp
test eax, eax
jne 0x40235d
mov ecx, dword [esp + 0x10]
mov eax, 0x100
push eax
lea eax, [esp + 0x24]
xor esi, esi
push eax
push esi
push ecx
call ebx
test eax, eax
jne 0x40233b
mov eax, dword [esp + 0x10]
lea edx, [esp + 0x20]
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
test eax, eax
je 0x402325
inc esi
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x20]
push 0x100
push ecx
push esi
push edx
call ebx
test eax, eax
je 0x402310
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
jne 0x40235d
lea ecx, [esp + 0x120]
push ecx
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyA]
mov eax, dword [esp + 0x14]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x310
ret