Function at 0x406ba0
Capabilities:
Persist via run registry key
Set registry value
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x424
mov eax, dword [0x5bb270]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
mov esi, ecx
push edi
cmp dword [esi + 0x3c], 1
jne 0x406de1
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x414], ax
lea eax, [ebp - 0x412]
push eax
call fcn.00537c80
add esp, 0xc
lea eax, [ebp - 0x418]
add esi, 0x150
mov ecx, esi
mov dword [ebp - 0x420], esi
push eax
call fcn.00403800
push dword [eax]
lea eax, [ebp - 0x414]
push str.DEL___s__r_n
push 0x104
push eax
call fcn.0053777e
mov edx, dword [ebp - 0x418]
or ebx, 0xffffffff
add edx, 0xfffffff0
add esp, 0x10
mov eax, ebx
lea ecx, [edx + 0xc]
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x406c37
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
lea eax, [ebp - 0x418]
mov dword [ebp - 0x424], 0
push eax
mov ecx, esi
call fcn.00403800
push 0
push 0x80
push 4
push 0
push 0
push 0x40000000
push dword [eax]
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, dword [ebp - 0x418]
mov esi, eax
add edi, 0xfffffff0
mov edx, ebx
lea ecx, [edi + 0xc]
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x406c8a
mov ecx, dword [edi]
push edi
mov eax, dword [ecx]
call dword [eax + 4]
cmp esi, 0xffffffff
jne 0x406ca2
pop edi
pop esi
xor eax, eax
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0053787e
mov esp, ebp
pop ebp
ret
push 2
push 0
push 0
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 0
lea eax, [ebp - 0x424]
push eax
lea eax, [ebp - 0x414]
push 0x104
push eax
call fcn.005372b7
add esp, 8
push eax
lea eax, [ebp - 0x414]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea eax, [ebp - 0x41c]
mov dword [ebp - 0x41c], 0
push eax
push 2
push 0
push str.SoftwareMicrosoftWindowsCurrentVersionRunOnce
push reloc.OLEAUT32.dll_SysReAllocString
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x406de1
push 0x206
push eax
mov word [ebp - 0x20c], ax
lea eax, [ebp - 0x20a]
push eax
call fcn.00537c80
mov edi, dword [ebp - 0x420]
lea eax, [ebp - 0x418]
add esp, 0xc
mov ecx, edi
push eax
call fcn.00403800
push dword [eax]
lea eax, [ebp - 0x20c]
push str.Command.com__C_START__M_Command.com__C_CALL___s_
push 0x104
push eax
call fcn.0053777e
mov edx, dword [ebp - 0x418]
add esp, 0x10
add edx, 0xfffffff0
mov ecx, ebx
lea eax, [edx + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x406d79
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
lea eax, [ebp - 0x20c]
push 0x104
push eax
call fcn.005372b7
add esp, 8
mov ecx, edi
lea esi, [eax + 1]
lea eax, [ebp - 0x420]
push eax
call fcn.00403910
push esi
lea ecx, [ebp - 0x20c]
push ecx
push 1
push 0
push dword [eax]
push dword [ebp - 0x41c]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov edx, dword [ebp - 0x420]
add edx, 0xfffffff0
lea eax, [edx + 0xc]
lock xadd dword [eax], ebx
dec ebx
test ebx, ebx
jg 0x406dd5
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push dword [ebp - 0x41c]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp - 4]
mov eax, 1
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0053787e
mov esp, ebp
pop ebp
ret