Function at 0x40c420
Capabilities:
Query environment variable
Query or enumerate registry value

Disassembly:
push 0xffffffffffffffff
push 0x5077f8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x30
push ebx
push ebp
push esi
mov esi, ecx
push edi
push str.Create_Unzip_Folder...
lea ecx, [esp + 0x18]
call fcn.004ea7b5
mov eax, dword [esp + 0x14]
xor ebx, ebx
push ebx
push 2
push eax
mov dword [esp + 0x54], ebx
call fcn.0041e3a0
add esp, 0xc
lea ecx, [esp + 0x10]
push 0x556998
call fcn.004ea7b5
push 0x556998
lea ecx, [esp + 0x24]
mov byte [esp + 0x4c], 1
call fcn.004ea7b5
push 0x104
push 0x104
lea ecx, [esp + 0x18]
mov byte [esp + 0x50], 2
call fcn.004eab86
push eax
push 0x540b3c
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
mov ebp, dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x104
jbe 0x40c4df
call ebp
push eax
lea ecx, [esp + 0x18]
push str._tGet_All_UserPath_failed._LastError:_d_n
push ecx
call fcn.004e3c81
mov edx, dword [esp + 0x20]
push ebx
push 1
push edx
call fcn.0041e3a0
add esp, 0x18
lea ecx, [esp + 0x10]
call fcn.004ea6c9
push 0xffffffffffffffff
lea ecx, [esp + 0x14]
call fcn.004eabd6
push 0x53d42c
lea ecx, [esp + 0x14]
call fcn.004e3dac
mov eax, dword [0x543c98]
mov edi, 1
mov dword [esp + 0x1c], eax
mov ecx, dword [esi + 0x1b8]
lea edx, [esp + 0x1c]
push ecx
push str.softwareTEC_sOcular.3Agent
push edx
mov byte [esp + 0x54], 3
call fcn.004e3c81
mov ecx, dword [esp + 0x28]
add esp, 0xc
lea eax, [esp + 0x24]
mov dword [esp + 0x24], ebx
push eax
push 0x20019
push ebx
push ecx
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
cmp eax, ebx
jne 0x40c5a7
lea edx, [esp + 0x30]
lea eax, [esp + 0x2c]
push edx
mov edx, dword [esp + 0x28]
lea ecx, [esp + 0x2c]
push eax
push ecx
push ebx
push str.NoAllUserDir
push edx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x48], 4
mov dword [esp + 0x44], ebx
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, ebx
jne 0x40c58f
cmp dword [esp + 0x28], 4
jne 0x40c58f
mov ecx, dword [esp + 0x2c]
xor eax, eax
cmp ecx, ebx
sete al
mov edi, eax
mov ecx, dword [esp + 0x24]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp edi, ebx
jne 0x40c5a7
lea ecx, [esp + 0x10]
call fcn.004ea6c9
call fcn.00481d00
push eax
lea ecx, [esp + 0x24]
call fcn.004ea8d8
mov ecx, dword [esp + 0x10]
cmp dword [ecx - 8], ebx
je 0x40c5d0
mov eax, dword [esp + 0x20]
cmp dword [eax - 8], ebx
je 0x40c5fd
mov ax, word [eax]
cmp ax, word [ecx]
je 0x40c5fd
call fcn.00481d10
push eax
lea ecx, [esp + 0x14]
call fcn.004ea8d8
push 0x53d42c
lea ecx, [esp + 0x14]
call fcn.004e3dac
push 0x540ac4
lea ecx, [esp + 0x14]
call fcn.004eab32
xor edi, edi
push 0x53d42c
lea ecx, [esp + 0x14]
call fcn.004e3dac
lea edx, [esp + 0x18]
push str._Y_m_d_H_M_S
lea eax, [esp + 0x38]
push edx
push eax
call fcn.0042baaf
mov ecx, eax
call fcn.0042c2f2
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x10]
push ecx
add esi, 0x90
push edx
push str._sIPGASZIP_s_
push esi
mov byte [esp + 0x58], 4
call fcn.004e3c81
mov eax, dword [esi]
add esp, 0x10
lea ecx, [esp + 0x14]
push eax
push str._tCreate_unzip_folder__s..._n
push ecx
call fcn.004e3c81
mov edx, dword [esp + 0x20]
push ebx
push 2
push edx
call fcn.0041e3a0
mov eax, dword [esi]
push eax
call fcn.00421920
add esp, 0x1c
test eax, eax
jne 0x40c791
call ebp
push eax
lea eax, [esp + 0x18]
push str._tCreate_folder_failed._LastError:_d_n
push eax
call fcn.004e3c81
mov ecx, dword [esp + 0x20]
push ebx
push 1
push ecx
call fcn.0041e3a0
add esp, 0x18
lea ecx, [esp + 0x10]
push 0x556998
call fcn.004ea8d8
call fcn.00481d10
push eax
lea ecx, [esp + 0x14]
call fcn.004ea8d8
push 0x53d42c
lea ecx, [esp + 0x14]
call fcn.004e3dac
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x10]
push edx
push eax
push str._sTempIPGASZIP_s_
push esi
call fcn.004e3c81
mov ecx, dword [esi]
add esp, 0x10
lea edx, [esp + 0x14]
push ecx
push str._tCreate_unzip_folder__s..._n
push edx
call fcn.004e3c81
mov eax, dword [esp + 0x20]
push ebx
push 2
push eax
call fcn.0041e3a0
mov eax, dword [esi]
push eax
call fcn.00421920
add esp, 0x1c
test eax, eax
jne 0x40c795
call ebp
push eax
lea ecx, [esp + 0x18]
push str._tCreate_folder_failed._LastError:_d_n
push ecx
call fcn.004e3c81
mov edx, dword [esp + 0x20]
push ebx
push 1
push edx
call fcn.0041e3a0
add esp, 0x18
lea ecx, [esp + 0x18]
mov byte [esp + 0x48], 3
call fcn.004ea741
lea ecx, [esp + 0x1c]
mov byte [esp + 0x48], 2
call fcn.004ea741
lea ecx, [esp + 0x20]
mov byte [esp + 0x48], 1
call fcn.004ea741
lea ecx, [esp + 0x10]
mov byte [esp + 0x48], bl
call fcn.004ea741
lea ecx, [esp + 0x14]
mov dword [esp + 0x48], 0xffffffff
call fcn.004ea741
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
mov ecx, dword [esp + 0x30]
mov dword fs:[0], ecx
add esp, 0x3c
ret
cmp edi, ebx
jne 0x40c7a6
mov esi, dword [esi]
call fcn.0047ec80
push eax
push 4
push esi
call dword [sym.imp.ADVAPI32.dll_SetFileSecurityW]
lea ecx, [esp + 0x18]
mov byte [esp + 0x48], 3
call fcn.004ea741
lea ecx, [esp + 0x1c]
mov byte [esp + 0x48], 2
call fcn.004ea741
lea ecx, [esp + 0x20]
mov byte [esp + 0x48], 1
call fcn.004ea741
lea ecx, [esp + 0x10]
mov byte [esp + 0x48], bl
call fcn.004ea741
lea ecx, [esp + 0x14]
mov dword [esp + 0x48], 0xffffffff
call fcn.004ea741
mov ecx, dword [esp + 0x40]
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
mov dword fs:[0], ecx
add esp, 0x3c
ret