Function at 0x1000411f
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1000dab9
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x81c
push edi
mov dword [ebp - 4], 2
mov dword [ebp - 0x10], 0
mov dword [ebp - 0x418], 4
call fcn.1000398b
test eax, eax
jne 0x10004188
lea eax, [ebp - 0x41c]
push eax
push 0xf003f
push 0
lea ecx, [ebp + 0xc]
call fcn.10003420
push eax
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov dword [ebp - 0x414], eax
jmp 0x100041df
lea edx, [ebp - 0x41c]
push edx
push 0xf013f
push 0
lea ecx, [ebp + 0xc]
call fcn.10003420
push eax
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov dword [ebp - 0x414], eax
cmp dword [ebp - 0x414], 0
je 0x100041df
lea ecx, [ebp - 0x41c]
push ecx
push 0xf023f
push 0
lea ecx, [ebp + 0xc]
call fcn.10003420
push eax
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExA]
mov dword [ebp - 0x414], eax
mov byte [ebp - 0x410], 0
mov ecx, 0xff
xor eax, eax
lea edi, [ebp - 0x40f]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea ecx, [ebp + 0x14]
call fcn.10003420
push eax
lea eax, [ebp - 0x410]
push eax
call dword [sym.imp.MSVCRT.dll_sprintf]
add esp, 8
cmp dword [ebp + 0x18], 1
je 0x1000421d
cmp dword [ebp + 0x18], 7
jne 0x1000425e
lea ecx, [ebp - 0x410]
push ecx
call sub.MSVCRT.dll_strlen
add esp, 4
add eax, 1
push eax
lea edx, [ebp - 0x410]
push edx
mov eax, dword [ebp + 0x18]
push eax
push 0
lea ecx, [ebp + 0x10]
call fcn.10003420
push eax
mov ecx, dword [ebp - 0x41c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov dword [ebp - 0x414], eax
jmp 0x1000431f
cmp dword [ebp + 0x18], 4
jne 0x100042a1
lea edx, [ebp - 0x410]
push edx
call dword [sym.imp.MSVCRT.dll_atoi]
add esp, 4
mov dword [ebp - 0x10], eax
push 4
lea eax, [ebp - 0x10]
push eax
mov ecx, dword [ebp + 0x18]
push ecx
push 0
lea ecx, [ebp + 0x10]
call fcn.10003420
push eax
mov edx, dword [ebp - 0x41c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov dword [ebp - 0x414], eax
jmp 0x1000431f
cmp dword [ebp + 0x18], 3
jne 0x1000431f
mov byte [ebp - 0x81c], 0
mov ecx, 0xff
xor eax, eax
lea edi, [ebp - 0x81b]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea ecx, [ebp + 0x14]
call fcn.10003490
push eax
lea ecx, [ebp + 0x14]
call fcn.10003420
push eax
lea eax, [ebp - 0x81c]
push eax
call sub.MSVCRT.dll_memcpy
add esp, 0xc
lea ecx, [ebp + 0x14]
call fcn.10003490
mov dword [ebp - 0x820], eax
mov ecx, dword [ebp - 0x820]
push ecx
lea edx, [ebp - 0x81c]
push edx
mov eax, dword [ebp + 0x18]
push eax
push 0
lea ecx, [ebp + 0x10]
call fcn.10003420
push eax
mov ecx, dword [ebp - 0x41c]
push ecx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov dword [ebp - 0x414], eax
cmp dword [ebp - 0x414], 0
jne 0x1000436e
mov edx, dword [ebp - 0x41c]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [ebp - 0x824], 1
mov byte [ebp - 4], 1
lea ecx, [ebp + 0xc]
call sub.MFC42.DLL_CString::CString
mov byte [ebp - 4], 0
lea ecx, [ebp + 0x10]
call sub.MFC42.DLL_CString::CString
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x14]
call sub.MFC42.DLL_CString::CString
mov eax, dword [ebp - 0x824]
jmp 0x100043b2
mov eax, dword [ebp - 0x41c]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov dword [ebp - 0x828], 0
mov byte [ebp - 4], 1
lea ecx, [ebp + 0xc]
call sub.MFC42.DLL_CString::CString
mov byte [ebp - 4], 0
lea ecx, [ebp + 0x10]
call sub.MFC42.DLL_CString::CString
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x14]
call sub.MFC42.DLL_CString::CString
mov eax, dword [ebp - 0x828]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
mov esp, ebp
pop ebp
ret