Function at 0x40f69c
Capabilities:
Delete file
Delete registry value
Get common file path
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4285c4
mov eax, dword fs:[0]
push eax
mov eax, 0x1eec
call fcn.0041a800
mov eax, dword [0x439450]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x1ec4], eax
mov byte [ebp - 0x1e99], 1
call dword [sym.imp.ADVAPI32.dll_RevertToSelf]
call fcn.0040f2e6
lea eax, [ebp - 0x1ea4]
push eax
push 0xf003f
xor ebx, ebx
push ebx
push dword [0x43c5c0]
mov dword [ebp - 0x1ea4], ebx
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov esi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push 4
pop edi
cmp eax, ebx
jne 0x40f757
cmp dword [ebp - 0x1ea4], ebx
je 0x40f757
lea eax, [ebp - 0x1ee8]
push eax
lea eax, [ebp - 0x1ee4]
push eax
lea eax, [ebp - 0x1ef4]
push eax
push ebx
push 0x43c570
push dword [ebp - 0x1ea4]
mov dword [ebp - 0x1ee4], ebx
mov dword [ebp - 0x1ee8], edi
call esi
test eax, eax
jne 0x40f75d
mov byte [ebp - 0x1e99], bl
mov dword [ebp - 0x1eac], 2
cmp byte [ebp - 0x1e99], bl
je 0x40f848
lea eax, [ebp - 0x1ee0]
push eax
lea eax, [ebp - 0x1ec8]
push eax
lea eax, [ebp - 0x1ef8]
push eax
push ebx
push 0x43c520
push dword [ebp - 0x1ea4]
mov dword [ebp - 0x1ec8], ebx
mov dword [ebp - 0x1ee0], edi
call esi
test eax, eax
jne 0x40f848
mov eax, dword [ebp - 0x1ec8]
mov ecx, 0x400
cmp eax, ecx
ja 0x40f7f5
je 0x40f842
cmp eax, 0x20
ja 0x40f7d9
je 0x40f842
cmp eax, 2
jbe 0x40f842
cmp eax, edi
je 0x40f842
cmp eax, 8
je 0x40f842
cmp eax, 0x10
jmp 0x40f836
mov ecx, eax
sub ecx, 0x40
je 0x40f842
sub ecx, 0x40
je 0x40f842
sub ecx, 0x80
je 0x40f842
sub ecx, 0x100
jmp 0x40f836
mov ecx, 0x8000
cmp eax, ecx
ja 0x40f81c
je 0x40f842
cmp eax, 0x800
je 0x40f842
cmp eax, 0x1000
je 0x40f842
cmp eax, 0x2000
je 0x40f842
cmp eax, 0x4000
jmp 0x40f836
cmp eax, 0x10000
je 0x40f842
cmp eax, 0x20000
je 0x40f842
cmp eax, 0x40000
je 0x40f842
cmp eax, 0x7ffff
mov dword [ebp - 0x1eac], 2
jne 0x40f848
mov dword [ebp - 0x1eac], eax
mov dword [ebp - 0x1ea8], ebx
cmp byte [ebp - 0x1e99], bl
je 0x40fb1d
mov esi, dword [sym.imp.KERNEL32.dll_SetDllDirectoryW]
push 0x430814
call esi
mov edi, dword [sym.imp.KERNEL32.dll_LoadLibraryW]
push 0x43c4d0
call edi
push ebx
mov dword [ebp - 0x1ea8], eax
call esi
cmp dword [ebp - 0x1ea8], ebx
jne 0x40f89c
push 0x43c480
call edi
mov dword [ebp - 0x1ea8], eax
cmp eax, ebx
jne 0x40f89c
mov byte [ebp - 0x1e99], bl
cmp byte [ebp - 0x1e99], bl
je 0x40fb1d
xor eax, eax
mov dword [ebp - 0x1ea0], ebx
mov word [ebp - 0xa38], ax
mov word [ebp - 0xe48], ax
mov dword [ebp - 0x1eb8], ebx
mov dword [ebp - 0x1ebc], ebx
mov edi, 0x104
xor eax, eax
mov word [ebp - 0x420], ax
mov word [ebp - 0x830], ax
lea eax, [ebp - 0x1eb4]
push eax
lea eax, [ebp - 0x830]
push eax
lea eax, [ebp - 0x1ecc]
push eax
push ebx
lea eax, [ebp - 0x1ec0]
push eax
lea eax, [ebp - 0x420]
push eax
push dword [ebp - 0x1eb8]
xor esi, esi
push dword [ebp - 0x1ea4]
inc esi
mov dword [ebp - 0x1ecc], esi
mov dword [ebp - 0x1ec0], edi
mov dword [ebp - 0x1eb4], 0x208
call dword [sym.imp.ADVAPI32.dll_RegEnumValueW]
mov dword [ebp - 0x1eec], eax
cmp eax, ebx
jne 0x40faa8
cmp dword [ebp - 0x1ea0], 4
jge 0x40faa8
cmp dword [ebp - 0x1ecc], esi
jne 0x40faa8
mov ecx, dword [ebp - 0x1ec0]
cmp ecx, 5
jbe 0x40faa8
cmp word [ebp - 0x420], 0x63
jne 0x40faa8
cmp word [ebp - 0x41e], 0x72
jne 0x40faa8
cmp word [ebp - 0x41c], 0x61
jne 0x40faa8
cmp word [ebp - 0x41a], 0x73
jne 0x40faa8
cmp word [ebp - 0x418], 0x68
jne 0x40faa8
mov eax, dword [ebp - 0x1ebc]
lea esi, [ebp + eax - 0x1e88]
lea ebx, [ebp + eax - 0x1668]
xor eax, eax
mov word [ebx], ax
xor edx, edx
mov eax, 0x103
mov word [esi], dx
mov dword [ebp - 0x1eb0], ecx
cmp ecx, eax
jb 0x40f9dd
mov dword [ebp - 0x1eb0], eax
push dword [ebp - 0x1eb0]
lea eax, [ebp - 0x420]
push eax
push edi
push esi
call fcn.0041a729
mov ecx, dword [ebp - 0x1eb0]
xor eax, eax
mov edi, 0x103
add esp, 0x10
mov word [esi + ecx*2], ax
cmp dword [ebp - 0x1eb4], edi
jae 0x40fa13
mov edi, dword [ebp - 0x1eb4]
push edi
lea eax, [ebp - 0x830]
push eax
push 0x104
push ebx
call fcn.0041a729
xor eax, eax
mov word [ebx + edi*2], ax
mov edi, dword [ebp - 0x1ea0]
add esp, 0x10
dec edi
cmp dword [ebp - 0x1ea0], 1
jl 0x40fa85
push dword [ebp + edi*4 - 0x1edc]
push esi
call fcn.0041a6eb
pop ecx
pop ecx
test eax, eax
jns 0x40fa73
dec edi
mov eax, dword [ebp + edi*4 - 0x1ed8]
mov dword [ebp + edi*4 - 0x1ed4], eax
mov eax, dword [ebp + edi*4 - 0x1e94]
mov dword [ebp + edi*4 - 0x1e90], eax
jns 0x40fa3f
jmp 0x40fa81
mov dword [ebp + edi*4 - 0x1ed8], esi
mov dword [ebp + edi*4 - 0x1e94], ebx
test edi, edi
jns 0x40fa91
mov dword [ebp - 0x1edc], esi
mov dword [ebp - 0x1e98], ebx
inc dword [ebp - 0x1ea0]
add dword [ebp - 0x1ebc], 0x208
xor ebx, ebx
mov edi, 0x104
inc dword [ebp - 0x1eb8]
cmp dword [ebp - 0x1eec], ebx
je 0x40f8cf
cmp dword [ebp - 0x1ea0], 4
jl 0x40fb1d
push dword [ebp - 0x1ed4]
lea eax, [ebp - 0xa38]
push edi
push eax
call fcn.004171b6
push dword [ebp - 0x1e90]
lea eax, [ebp - 0xe48]
push edi
push eax
call fcn.004171b6
add esp, 0x18
lea eax, [ebp - 0xa38]
push eax
push dword [ebp - 0x1ea4]
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
cmp eax, ebx
je 0x40fb0a
mov byte [ebp - 0x1e99], 0
lea eax, [ebp - 0xe48]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor edi, edi
cmp byte [ebp - 0x1e99], 0
je 0x40fb46
push 0x43c458
push dword [ebp - 0x1ea8]
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov edi, eax
cmp edi, ebx
jne 0x40fb46
mov byte [ebp - 0x1e99], 0
xor eax, eax
mov dword [ebp - 0x1ea0], ebx
mov word [ebp - 0x218], ax
mov word [ebp - 0x628], ax
cmp byte [ebp - 0x1e99], al
je 0x40fdb0
lea eax, [ebp - 0x628]
push eax
mov esi, 0x102
push esi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
cmp eax, ebx
jne 0x40fb95
push esi
lea eax, [ebp - 0x628]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
cmp eax, ebx
je 0x40fd94
add eax, eax
cmp word [ebp + eax - 0x62a], 0x5c
je 0x40fbb7
push 0x5c
pop ecx
mov word [ebp + eax - 0x628], cx
xor ecx, ecx
mov word [ebp + eax - 0x626], cx
lea eax, [ebp - 0x218]
push eax
push ebx
push 0x43c238
lea eax, [ebp - 0x628]
push eax
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
cmp eax, ebx
jne 0x40fbdc
mov byte [ebp - 0x1e99], 0
cmp byte [ebp - 0x1e99], 0
je 0x40fd94
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push ebx
push 0x80
push 2
push ebx
push 1
push 0x40000000
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x1ea0], eax
cmp eax, 0xffffffff
jne 0x40fc2b
mov byte [ebp - 0x1e99], 0
cmp byte [ebp - 0x1e99], 0
je 0x40fd94
mov esi, dword [ebp - 0x1ec4]
cmp esi, ebx
je 0x40fc69
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push ebx
mov dword [ebp - 0x1ed8], eax
push ebx
lea eax, [ebp - 0x1ed8]
mov dword [ebp - 0x1ed4], esi
mov dword [ebp - 0x1ed0], 1
push eax
jmp 0x40fc6c
push ebx
push ebx
push ebx
push dword [ebp - 0x1eac]
push dword [ebp - 0x1ea0]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call edi
cmp eax, ebx
jne 0x40fc97
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x40fd94
cmp dword [0x43c180], ebx
je 0x40fce1
call fcn.0040f68a
mov edi, eax
cmp edi, ebx
je 0x40fce1
lea eax, [ebp - 0x218]
push eax
lea ecx, [ebp - 0x1ef0]
call fcn.0040d51a
mov dword [ebp - 4], ebx
mov esi, dword [edi]
push 2
mov ecx, eax
call fcn.0040df5b
push eax
push 6
mov ecx, edi
call dword [esi + 0xc]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x1ef0]
call fcn.0040d56e
lea eax, [ebp - 0x1e98]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemTime]
xor esi, esi
inc esi
movzx eax, word [ebp - 0x1e8e]
push esi
push eax
movzx eax, word [ebp - 0x1e90]
push eax
movzx eax, word [ebp - 0x1e92]
push eax
movzx eax, word [ebp - 0x1e96]
push eax
movzx eax, word [ebp - 0x1e98]
push eax
lea eax, [ebp - 0xc40]
push 0x43c250
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x20
push ebx
push ebx
lea eax, [ebp - 0x1ec4]
push eax
push ebx
lea eax, [ebp - 0xc40]
push eax
push dword [ebp - 0x1ea4]
inc esi
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
je 0x40fcf1
lea eax, [ebp - 0x218]
push eax
call fcn.00418ec2
pop ecx
lea eax, [eax + eax + 2]
push eax
lea eax, [ebp - 0x218]
push eax
push 1
push ebx
lea eax, [ebp - 0xc40]
push eax
push dword [ebp - 0x1ea4]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
je 0x40fd8b
mov byte [ebp - 0x1e99], 0
cmp byte [ebp - 0x1e99], 0
jne 0x40fdb0
cmp word [ebp - 0x218], bx
je 0x40fdb0
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp dword [ebp - 0x1ea4], ebx
je 0x40fdca
push dword [ebp - 0x1ea4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [ebp - 0x1ea4], ebx
cmp dword [ebp - 0x1ea0], ebx
je 0x40fdde
push dword [ebp - 0x1ea0]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x1ea8], ebx
je 0x40fdf2
push dword [ebp - 0x1ea8]
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov eax, dword [0x43c5c4]
cmp eax, ebx
je 0x40fe02
push eax
call dword [sym.imp.KERNEL32.dll_SetEvent]
xor eax, eax
inc eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.00416261
leave
ret