Function at 0x401173
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
mov eax, 0x402be0
call sub.MSVCRT.dll__EH_prolog
sub esp, 0x10
push ebx
push esi
mov esi, ecx
push edi
push str.CString
mov dword [ebp - 0x10], 0x400
mov eax, dword [esi + 0xc]
mov dword [ebp - 0x14], 1
push eax
call dword [sym.imp.MSVCRT.dll__mbscmp]
pop ecx
test eax, eax
pop ecx
jne 0x401239
mov eax, dword [esi + 4]
lea edi, [esi + 0x10]
push edi
push eax
push dword [esi + 0x14]
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyA]
test eax, eax
jne 0x401239
xor ebx, ebx
cmp dword [ebp + 0xc], ebx
je 0x4012b0
cmp dword [ebp + 0x10], 2
jae 0x401214
mov eax, dword [esi + 8]
lea ecx, [ebp - 0x10]
lea ebx, [esi + 0x18]
push ecx
push ebx
push 0
push 0
push eax
push dword [edi]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
jne 0x401239
mov ecx, dword [ebp + 8]
push ebx
call sub.MFC42.DLL_CString::operator_1
push dword [esi + 0x10]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
leave
ret 0xc
mov eax, dword [esi + 8]
lea ecx, [ebp - 0x10]
lea ebx, [esi + 0x18]
push ecx
lea ecx, [ebp - 0x18]
push ebx
push ecx
push 0
push eax
mov dword [ebp - 0x18], 7
push dword [edi]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExA]
test eax, eax
je 0x40123f
and dword [ebp - 0x14], 0
jmp 0x4011f7
mov ecx, dword [ebp + 8]
xor edi, edi
call sub.MFC42.DLL_CString::Empty
cmp dword [ebp - 0x10], edi
jbe 0x4011f7
call sub.MFC42.DLL_AfxGetEmptyString
mov eax, dword [eax]
lea ecx, [ebp + 0x10]
mov dword [ebp + 0x10], eax
lea eax, [ebx + edi]
push eax
call sub.MFC42.DLL_CString::operator_1
mov edi, dword [ebp + 8]
and dword [ebp - 4], 0
lea eax, [ebp + 0x10]
mov ecx, edi
push eax
call fcn.00402774
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0x10]
call sub.MFC42.DLL_CString::CString
mov eax, dword [edi]
mov edi, dword [eax - 8]
cmp edi, dword [ebp - 0x10]
jae 0x4011f7
cmp byte [ebx + edi], 0
jne 0x4012a6
mov ecx, dword [ebp + 8]
push 0x5e
call sub.MFC42.DLL_CString::operator_2
inc edi
cmp edi, dword [ebp - 0x10]
jb 0x401290
cmp edi, dword [ebp - 0x10]
jb 0x40124e
jmp 0x4011f7
cmp dword [ebp + 0x10], 2
jae 0x4012e5
mov eax, dword [ebp + 8]
mov edx, dword [esi + 8]
mov eax, dword [eax]
mov ecx, dword [eax - 8]
inc ecx
push ecx
push eax
xor eax, eax
cmp dword [ebp + 0x10], ebx
setne al
inc eax
push eax
push ebx
push edx
push dword [edi]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
je 0x4011f7
jmp 0x4013af
mov edi, dword [ebp + 8]
lea ecx, [ebp + 0xc]
mov eax, dword [edi]
mov eax, dword [eax - 8]
mov dword [ebp + 0x10], eax
call sub.MFC42.DLL_CString::CString_2
push 0
mov dword [ebp - 4], 1
push 0x5e
mov ecx, edi
call sub.MFC42.DLL_CString::Find
mov edi, eax
cmp edi, 0xffffffff
jle 0x401370
mov ecx, dword [ebp + 8]
sub eax, ebx
push eax
lea eax, [ebp - 0x1c]
push ebx
push eax
call sub.MFC42.DLL_CString::Mid
push eax
lea ecx, [ebp + 0xc]
mov byte [ebp - 4], 2
call sub.MFC42.DLL_CString::operator
lea ecx, [ebp - 0x1c]
mov byte [ebp - 4], 1
call sub.MFC42.DLL_CString::CString
mov eax, dword [ebp + 0xc]
push dword [eax - 8]
push eax
lea eax, [esi + ebx + 0x18]
push eax
call sub.MSVCRT.dll_memcpy
add esp, 0xc
cmp edi, dword [ebp + 0x10]
jge 0x401366
mov eax, dword [ebp + 8]
mov eax, dword [eax]
cmp byte [eax + edi], 0x5e
jne 0x401366
and byte [esi + edi + 0x18], 0
inc edi
jmp 0x40134e
mov ecx, dword [ebp + 8]
push edi
mov ebx, edi
push 0x5e
jmp 0x401305
cmp dword [ebp + 0x10], 0
je 0x4013a3
push dword [ebp + 0x10]
mov eax, dword [esi + 8]
lea ecx, [esi + 0x18]
push ecx
push 7
push 0
push eax
push dword [esi + 0x10]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
test eax, eax
jne 0x4013a3
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0xc]
call sub.MFC42.DLL_CString::CString
jmp 0x4011f7
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp + 0xc]
call sub.MFC42.DLL_CString::CString
xor eax, eax
jmp 0x401203