Function at 0x4021e1
Capabilities:
Delete registry key
Get common file path
Link many functions at runtime
Query or enumerate registry key

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x290
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_LoadLibraryW]
push esi
push edi
xor edi, edi
push str.rpcrt4.dll
mov dword [ebp - 4], edi
mov dword [ebp - 8], edi
call ebx
cmp eax, edi
mov dword [0x41adb0], eax
je 0x4022b1
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.UuidFromStringW
push eax
call esi
cmp eax, edi
mov dword [0x41afd8], eax
je 0x4022b1
push str.WS2_32
call ebx
cmp eax, edi
mov dword [0x41adc0], eax
je 0x4022b1
push str.WSCDeinstallProvider
push eax
call esi
cmp eax, edi
mov dword [0x41adcc], eax
je 0x4022b1
push str.WSCInstallProvider
push dword [0x41adc0]
call esi
cmp eax, edi
mov dword [0x41adb8], eax
je 0x4022b1
push str.WSCUpdateProvider
push dword [0x41adc0]
call esi
push str.WSCEnumProtocols
mov dword [0x41adbc], eax
push dword [0x41adc0]
call esi
cmp eax, edi
mov dword [0x41adc8], eax
je 0x4022b1
push str.WSCWriteProviderOrder
push dword [0x41adc0]
call esi
push str.WSCGetProviderPath
mov dword [0x41adc4], eax
push dword [0x41adc0]
call esi
cmp eax, edi
mov dword [0x41afdc], eax
jne 0x4022b8
xor eax, eax
jmp 0x4025bb
lea eax, [ebp - 0x18]
push eax
push 0xf003f
push edi
push str.SOFTWAREInternet_Download_Manager
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x4023ed
lea eax, [ebp - 0x38]
mov dword [ebp - 0x1c], 0x50
push eax
push edi
push edi
lea eax, [ebp - 0x1c]
push edi
push eax
lea eax, [ebp - 0x88]
push eax
push edi
push dword [ebp - 0x18]
call dword [sym.imp.ADVAPI32.dll_RegEnumKeyExW]
cmp eax, 0x103
je 0x4023e2
lea eax, [ebp - 0x30]
push eax
lea eax, [ebp - 0x88]
push eax
call dword [0x41afd8]
cmp dword [ebp - 4], edi
je 0x402327
push dword [ebp - 4]
call sub.MSVCRT.dll_free
pop ecx
lea eax, [ebp - 0xc]
mov dword [ebp - 4], edi
push eax
lea eax, [ebp - 8]
push eax
push edi
push edi
mov dword [ebp - 8], edi
call dword [0x41adc8]
push dword [ebp - 8]
call sub.MSVCRT.dll_malloc
cmp eax, edi
pop ecx
mov dword [ebp - 4], eax
je 0x4023bf
lea ecx, [ebp - 0xc]
push ecx
lea ecx, [ebp - 8]
push ecx
push eax
push edi
call dword [0x41adc8]
cmp eax, 0xffffffff
mov dword [ebp - 0x14], eax
je 0x4023bf
xor esi, esi
cmp eax, edi
jle 0x4023bf
xor ebx, ebx
lea eax, [ebp - 0x30]
push 0x10
push eax
mov eax, dword [ebp - 4]
lea eax, [ebx + eax + 0x14]
push eax
call sub.MSVCRT.dll_memcmp
add esp, 0xc
test eax, eax
je 0x402395
inc esi
add ebx, 0x274
cmp esi, dword [ebp - 0x14]
jl 0x40236d
jmp 0x4023bf
imul esi, esi, 0x274
mov eax, dword [ebp - 4]
push dword [ebp - 0x14]
mov esi, dword [esi + eax + 0x24]
lea eax, [ebp - 4]
push eax
push esi
mov dword [ebp - 0x10], esi
mov dword [0x41c948], 1
call fcn.00401d66
add esp, 0xc
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x30]
push eax
call dword [0x41adcc]
lea eax, [ebp - 0x88]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.ADVAPI32.dll_RegDeleteKeyW]
jmp 0x4022da
push dword [ebp - 0x18]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
jmp 0x402417
mov esi, 0x4140c0
lea eax, [ebp - 0x30]
push eax
push dword [esi]
call dword [0x41afd8]
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 0x30]
push eax
call dword [0x41adcc]
add esi, 4
cmp esi, 0x414104
jl 0x4023f2
lea eax, [ebp - 0xc]
mov dword [ebp - 0x20], edi
push eax
lea eax, [ebp - 8]
push eax
mov dword [ebp - 8], edi
push dword [ebp - 4]
push edi
call dword [0x41adc8]
cmp dword [ebp - 4], edi
je 0x40243d
push dword [ebp - 4]
call sub.MSVCRT.dll_free
pop ecx
push dword [ebp - 8]
call sub.MSVCRT.dll_malloc
cmp eax, edi
pop ecx
mov dword [ebp - 4], eax
je 0x4024b1
lea ecx, [ebp - 0xc]
push ecx
lea ecx, [ebp - 8]
push ecx
push eax
push edi
call dword [0x41adc8]
cmp eax, 0xffffffff
mov dword [ebp - 0x14], eax
je 0x4024b1
xor esi, esi
cmp eax, edi
jle 0x4024b1
xor ebx, ebx
mov eax, dword [ebp - 4]
push 0x10
push 0x414108
lea eax, [ebx + eax + 0x14]
push eax
call sub.MSVCRT.dll_memcmp
add esp, 0xc
test eax, eax
je 0x402496
inc esi
add ebx, 0x274
cmp esi, dword [ebp - 0x14]
jl 0x40246d
jmp 0x4024b1
imul esi, esi, 0x274
mov eax, dword [ebp - 4]
push 1
mov eax, dword [esi + eax + 0x24]
mov dword [ebp - 0x10], eax
pop eax
mov dword [ebp - 0x20], eax
mov dword [0x41c948], eax
lea eax, [ebp - 0xc]
push eax
push 0x414108
call dword [0x41adcc]
cmp dword [ebp - 0x20], edi
je 0x402519
push dword [ebp - 4]
call sub.MSVCRT.dll_free
pop ecx
lea eax, [ebp - 0xc]
push eax
lea eax, [ebp - 8]
push eax
push edi
push edi
mov dword [ebp - 4], edi
mov dword [ebp - 8], edi
call dword [0x41adc8]
push dword [ebp - 8]
call sub.MSVCRT.dll_malloc
cmp eax, edi
pop ecx
mov dword [ebp - 4], eax
je 0x402527
lea ecx, [ebp - 0xc]
push ecx
lea ecx, [ebp - 8]
push ecx
push eax
push edi
call dword [0x41adc8]
cmp eax, 0xffffffff
je 0x402519
push eax
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x10]
call fcn.00401d66
add esp, 0xc
cmp dword [ebp - 4], edi
je 0x402527
push dword [ebp - 4]
call sub.MSVCRT.dll_free
pop ecx
push dword [0x41adc0]
mov esi, dword [sym.imp.KERNEL32.dll_FreeLibrary]
call esi
push dword [0x41adb0]
call esi
cmp dword [0x41c940], edi
je 0x4025b8
lea eax, [ebp - 0x290]
push 0x104
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
je 0x4025b8
lea eax, [ebp - 0x290]
push 0x414f2c
push eax
mov dword [ebp - 0x10], edi
call sub.MSVCRT.dll_wcscat
pop ecx
lea eax, [ebp - 0x10]
pop ecx
push edi
push eax
lea eax, [ebp - 0x290]
push 0x41b828
push eax
call fcn.00405972
cmp dword [ebp - 0x10], edi
je 0x4025b8
mov eax, dword [0x41b928]
cmp eax, edi
mov ecx, eax
jne 0x40259c
mov ecx, 0x41b92c
mov eax, dword [0x41b8f8]
cmp eax, edi
jne 0x4025aa
mov eax, 0x41b8fc
push 0x10030
push ecx
push eax
push edi
call dword [sym.imp.USER32.dll_MessageBoxW]
push 1
pop eax
pop edi
pop esi
pop ebx
leave
ret