Function at 0x406230
Capabilities:
Create process on windows
Delete registry value
Persist via run registry key
Query or enumerate registry value
Set registry value

Disassembly:
push 0xffffffffffffffff
push 0x41a739
mov eax, dword fs:[0]
push eax
mov eax, 0x2538
call fcn.0040b4f0
mov eax, dword [0x4243c8]
xor eax, esp
mov dword [esp + 0x2534], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4243c8]
xor eax, esp
push eax
lea eax, [esp + 0x254c]
mov dword fs:[0], eax
xor ebx, ebx
mov dword [esp + 0x2554], ebx
call dword [0x42430c]
push 0x618
lea eax, [esp + 0x932]
push ebx
push eax
mov word [esp + 0x938], bx
call fcn.0040b3b0
push 0x618
lea ecx, [esp + 0x322]
push ebx
push ecx
mov word [esp + 0x328], bx
call fcn.0040b3b0
push 0x1fe
lea edx, [esp + 0x12e]
push ebx
push edx
mov dword [esp + 0x38], ebx
mov word [esp + 0x134], bx
call fcn.0040b3b0
push 0x7fe
lea eax, [esp + 0x1372]
push ebx
push eax
mov word [esp + 0x1378], bx
call fcn.0040b3b0
push 0x9fe
lea ecx, [esp + 0x1b7e]
push ebx
push ecx
mov dword [esp + 0x60], 0x400
mov word [esp + 0x1b84], bx
call fcn.0040b3b0
add esp, 0x3c
push ebx
push 1
push ebx
push ebx
push 4
lea ecx, [esp + 0x5c]
call fcn.004083b0
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x44], ebx
lea edx, [esp + 0x38]
push edx
lea eax, [esp + 0x2c]
push eax
lea ecx, [esp + 0x50]
mov byte [esp + 0x255c], 3
call fcn.00408da0
xor esi, esi
lea edi, [esp + 0x1b48]
mov ecx, dword [esp + 0x2c]
cmp ecx, ebx
je 0x4063a0
mov eax, dword [esp + 0x30]
sub eax, ecx
sar eax, 2
cmp esi, eax
jae 0x4063a0
mov eax, dword [ecx + esi*4]
cmp eax, ebx
je 0x40638e
mov eax, dword [eax]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
add esi, 1
add edi, 0x50
jmp 0x406360
xor eax, eax
push eax
push edi
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
add esi, 1
add edi, 0x50
jmp 0x406360
call fcn.00405f70
push 0x40
lea ecx, [esp + 0x94]
lea ebp, [esi + esi*4]
push ecx
shl ebp, 4
push 0x41c894
lea ebp, [esp + ebp + 0x1b54]
call dword [sym.imp.ole32.dll_StringFromGUID2]
lea edx, [esp + 0x90]
push edx
call dword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov edi, eax
cmp edi, ebx
jne 0x4063e5
push 0x8007000e
call fcn.00401030
push edi
push ebp
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
mov ebp, dword [sym.imp.OLEAUT32.dll_SysStringLen]
push edi
add esi, 1
call ebp
push 0x40
lea eax, [esi + esi*4]
lea edx, [esp + 0x94]
shl eax, 4
push edx
lea ecx, [esp + eax + 0x1b50]
push 0x41c884
mov dword [esp + 0x24], ecx
call dword [sym.imp.ole32.dll_StringFromGUID2]
lea eax, [esp + 0x90]
push eax
call dword [sym.imp.OLEAUT32.dll_SysReAllocString]
mov edi, eax
cmp edi, ebx
jne 0x40643d
push 0x8007000e
call fcn.00401030
mov ecx, dword [esp + 0x18]
push edi
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
push edi
add esi, 1
call ebp
cmp esi, ebx
jle 0x406536
mov ebp, esi
mov esi, dword [sym.imp.KERNEL32.dll_lstrcatW]
lea edi, [esp + 0x1b48]
jmp 0x406470
push str.CLSID_
lea edx, [esp + 0x114]
push edx
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
push edi
lea eax, [esp + 0x114]
push eax
call esi
push str.InprocServer32
lea ecx, [esp + 0x114]
push ecx
call esi
lea edx, [esp + 0x14]
push edx
push 0x20019
push ebx
lea eax, [esp + 0x11c]
push eax
push SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x4064f9
mov eax, dword [esp + 0x14]
lea ecx, [esp + 0x24]
push ecx
lea edx, [esp + 0x134c]
push edx
push ebx
push ebx
push ebx
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
cmp eax, ebx
jne 0x4064ee
lea ecx, [esp + 0x1348]
push ecx
call fcn.004034b0
add esp, 4
mov edx, dword [esp + 0x14]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push 0x200
lea eax, [esp + 0x114]
push ebx
push eax
call fcn.0040b3b0
push 0x800
lea ecx, [esp + 0x1358]
push ebx
push ecx
call fcn.0040b3b0
add esp, 0x18
add edi, 0x50
sub ebp, 1
mov dword [esp + 0x24], 0x400
jne 0x406470
push 0x3fe
lea edx, [esp + 0xf4e]
push ebx
push edx
mov word [esp + 0xf54], bx
call fcn.0040b3b0
mov esi, dword [esp + 0x2568]
push esi
lea eax, [esp + 0xf58]
push str._sdtor.exe
push eax
call fcn.0040b451
add esp, 0x18
push ebx
push 0x41c8a4
push str._unregserver
lea ecx, [esp + 0xf54]
push ecx
push str.open
push ebx
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
push esi
lea edx, [esp + 0x930]
push str.cmd__c__regsvr32__s__u__sShellService.dll_
push edx
call fcn.0040b451
push esi
lea eax, [esp + 0x320]
push str.cmd__c__rmdir__s__q___s__
push eax
call fcn.0040b451
mov ebp, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
add esp, 0x18
lea ecx, [esp + 0x14]
push ecx
push 2
push ebx
push str.SoftwareMicrosoftWindowsCurrentVersionRunOnce
push reloc.OLEAUT32.dll_SysReAllocString
call ebp
test eax, eax
jne 0x406794
mov esi, dword [sym.imp.RPCRT4.dll_UuidCreate]
lea edx, [esp + 0x80]
push edx
mov dword [esp + 0x20], ebx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x1c], ebx
call esi
mov edi, dword [sym.imp.ole32.dll_StringFromCLSID]
lea eax, [esp + 0x1c]
push eax
lea ecx, [esp + 0x84]
push ecx
call edi
lea edx, [esp + 0x60]
push edx
call esi
lea eax, [esp + 0x20]
push eax
lea ecx, [esp + 0x64]
push ecx
call edi
lea edx, [esp + 0x70]
push edx
call esi
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0x74]
push ecx
call edi
cmp dword [esp + 0x1c], ebx
je 0x4066d3
cmp dword [esp + 0x20], ebx
je 0x4066d3
cmp dword [esp + 0x18], ebx
je 0x4066d3
call dword [0x42430c]
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenW]
mov edi, dword [esp + 0x1c]
lea edx, [esp + 0x92c]
push edx
call esi
mov edx, dword [esp + 0x14]
lea eax, [eax + eax + 2]
push eax
lea ecx, [esp + 0x930]
push ecx
push 1
push ebx
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
push edx
call edi
mov ebp, dword [esp + 0x20]
lea eax, [esp + 0x310]
push eax
call esi
lea ecx, [eax + eax + 2]
mov eax, dword [esp + 0x14]
push ecx
lea edx, [esp + 0x314]
push edx
push 1
push ebx
push ebp
push eax
call edi
mov ebp, dword [esp + 0x18]
push str.cmd__c__regsvr32__s_Urlmon.dllregsvr32__s_Actxprxy.dllregsvr32__s_Oleaut32.dllregsvr32__s_Shell32.dll_
call esi
mov edx, dword [esp + 0x14]
lea ecx, [eax + eax + 2]
push ecx
push str.cmd__c__regsvr32__s_Urlmon.dllregsvr32__s_Actxprxy.dllregsvr32__s_Oleaut32.dllregsvr32__s_Shell32.dll_
push 1
push ebx
push ebp
push edx
call edi
mov ebp, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
jmp 0x40674b
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenW]
lea eax, [esp + 0x92c]
push eax
call esi
mov edi, dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
lea ecx, [eax + eax + 2]
mov eax, dword [esp + 0x14]
push ecx
lea edx, [esp + 0x930]
push edx
push 1
push ebx
push str.remove
push eax
call edi
lea ecx, [esp + 0x310]
push ecx
call esi
mov ecx, dword [esp + 0x14]
lea edx, [eax + eax + 2]
push edx
lea eax, [esp + 0x314]
push eax
push 1
push ebx
push str.remove2
push ecx
call edi
push str.cmd__c__regsvr32__s_Urlmon.dllregsvr32__s_Actxprxy.dllregsvr32__s_Oleaut32.dllregsvr32__s_Shell32.dll_
call esi
lea edx, [eax + eax + 2]
mov eax, dword [esp + 0x14]
push edx
push str.cmd__c__regsvr32__s_Urlmon.dllregsvr32__s_Actxprxy.dllregsvr32__s_Oleaut32.dllregsvr32__s_Shell32.dll_
push 1
push ebx
push str.rereg
push eax
call edi
mov eax, dword [esp + 0x1c]
cmp eax, ebx
mov esi, dword [sym.imp.ole32.dll_CoTaskMemFree]
je 0x406760
push eax
call esi
mov dword [esp + 0x1c], ebx
mov eax, dword [esp + 0x20]
cmp eax, ebx
je 0x40676f
push eax
call esi
mov dword [esp + 0x20], ebx
mov eax, dword [esp + 0x18]
cmp eax, ebx
je 0x40677e
push eax
call esi
mov dword [esp + 0x18], ebx
mov ecx, dword [esp + 0x14]
mov edi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push ecx
call edi
mov esi, dword [esp + 0x255c]
jmp 0x40679a
mov edi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
call fcn.004014b0
test al, al
lea edx, [esp + 0x14]
push edx
push 2
push ebx
je 0x4067c2
push str.SOFTWAREMicrosoftWindowsCurrentVersionexplorerSharedTaskScheduler
push reloc.OLEAUT32.dll_SysReAllocString
call ebp
test eax, eax
jne 0x4067e9
push str.8FB2D6CA_E258_48CF_9DAB_EEFB735E225C
jmp 0x4067d7
push str.SOFTWAREMicrosoftWindowsCurrentVersionShellServiceObjectDelayLoad
push reloc.OLEAUT32.dll_SysReAllocString
call ebp
test eax, eax
jne 0x4067e9
push str.shellservice
mov eax, dword [esp + 0x18]
push eax
call dword [sym.imp.ADVAPI32.dll_RegDeleteValueW]
mov ecx, dword [esp + 0x14]
push ecx
call edi
mov eax, dword [esp + 0x3c]
cmp eax, ebx
je 0x406813
mov edx, dword [esp + 0x24]
push edx
mov edx, dword [esp + 0x44]
lea ecx, [esp + 0x3c]
push ecx
push edx
push eax
call fcn.004059e0
mov eax, dword [esp + 0x4c]
push eax
call fcn.0040ad0b
add esp, 0x14
mov eax, dword [esp + 0x2c]
cmp eax, ebx
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x44], ebx
je 0x406849
mov ecx, dword [esp + 0x24]
push ecx
mov ecx, dword [esp + 0x34]
lea edx, [esp + 0x2c]
push edx
push ecx
push eax
call fcn.004059e0
mov edx, dword [esp + 0x3c]
push edx
call fcn.0040ad0b
add esp, 0x14
lea ecx, [esp + 0x48]
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
mov byte [esp + 0x2554], bl
call fcn.004083e0
lea eax, [esi - 0x10]
mov dword [esp + 0x2554], 0xffffffff
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40688c
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x254c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x2534]
xor ecx, esp
call fcn.0040b399
add esp, 0x2544
ret