Function at 0x5a74b0
Capabilities:
Delete registry key
Set registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5df100
mov eax, dword fs:[0]
push eax
sub esp, 0x38
push esi
push edi
mov eax, dword [0x64f494]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
push dword [ebp + 8]
lea eax, [ebp - 0x1c]
push eax
call fcn.005a7d80
add esp, 8
mov esi, dword [ebp - 0x1c]
lea eax, [ebp - 0x44]
push 1
xorps xmm0, xmm0
mov dword [ebp - 4], 0
push eax
movups xmmword [ebp - 0x44], xmm0
mov dword [ebp - 0x34], 0
call dword [sym.imp.ADVAPI32.dll_InitializeSecurityDescriptor]
push 1
push 0
push 1
lea eax, [ebp - 0x44]
push eax
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorDacl]
push 0x40000
push esi
push SysReAllocString
lea ecx, [ebp - 0x30]
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x28], 0
call fcn.0041b380
mov esi, dword [ebp - 0x30]
test eax, eax
jne 0x5a7563
lea eax, [ebp - 0x44]
push eax
push 4
push esi
call dword [sym.imp.ADVAPI32.dll_RegSetKeySecurity]
push 0x5e6574
lea ecx, [ebp - 0x30]
call fcn.004234c0
mov edi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
test esi, esi
je 0x5a7570
push esi
call edi
push dword [ebp - 0x1c]
push SysReAllocString
call dword [sym.imp.SHLWAPI.dll_SHDeleteKeyW]
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x28], 0
push 0
push 0
push 0x2001f
push 0
push 0
push dword [ebp - 0x1c]
lea ecx, [ebp - 0x30]
mov byte [ebp - 4], 1
push SysReAllocString
call fcn.005a73e0
cmp eax, 0xb7
je 0x5a75d0
test eax, eax
je 0x5a75d0
mov eax, dword [ebp - 0x30]
test eax, eax
je 0x5a75c9
push eax
call edi
xor dl, dl
jmp 0x5a7747
cmp word [0x65c398], 0
jne 0x5a76b7
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], 0
push eax
push 8
mov dword [ebp - 0x14], 0
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x5a76b7
mov esi, dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
lea eax, [ebp - 0x14]
push eax
push 0
push 0
push 1
push dword [ebp - 0x18]
call esi
push dword [ebp - 0x14]
call fcn.0054add3
push dword [ebp - 0x14]
mov edi, eax
push 0
push edi
call fcn.00520870
add esp, 0x10
lea eax, [ebp - 0x14]
push eax
push dword [ebp - 0x14]
push edi
push 1
push dword [ebp - 0x18]
call esi
test eax, eax
je 0x5a76b7
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [edi]
call dword [sym.imp.ADVAPI32.dll_IsValidSid]
test eax, eax
jne 0x5a7667
push edi
call fcn.0054adb6
add esp, 4
jmp 0x5a76b7
push dword [edi]
call dword [sym.imp.ADVAPI32.dll_GetSidSubAuthorityCount]
movzx eax, byte [eax]
dec eax
push eax
push dword [edi]
call dword [sym.imp.ADVAPI32.dll_GetSidSubAuthority]
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], 0
push eax
push dword [edi]
call sub.ADVAPI32.dll_ConvertSidToStringSidW
push dword [ebp - 0x20]
push 0x5f0c14
push 0x104
push 0x65c398
call fcn.0040d390
push edi
call fcn.0054adb6
add esp, 0x14
push dword [ebp - 0x20]
call dword [sym.imp.KERNEL32.dll_LocalFree]
mov edi, dword [ebp + 0xc]
push 0x65c398
push edi
push dword [ebp + 8]
call fcn.005aa700
mov esi, dword [ebp - 0x30]
mov edx, eax
add esp, 0xc
test edx, edx
je 0x5a7709
mov ecx, edx
lea eax, [ecx + 2]
mov dword [ebp - 0x24], eax
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x5a76e0
sub ecx, dword [ebp - 0x24]
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
push edx
push 1
push 0
push 0x621d40
push esi
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test edi, edi
je 0x5a773a
mov ecx, edi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x5a7712
sub ecx, edx
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
push edi
push 1
push 0
push str.ProgId
push esi
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test esi, esi
je 0x5a7745
push esi
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dl, 1
mov eax, dword [ebp - 0x1c]
or ecx, 0xffffffff
mov byte [ebp - 0xd], dl
add eax, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lock xadd dword [eax + 0xc], ecx
dec ecx
test ecx, ecx
jg 0x5a7780
mov ecx, dword [eax]
push eax
mov edx, dword [ecx]
call dword [edx + 4]
mov al, byte [ebp - 0xd]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret
mov al, dl
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret