Function at 0x406540
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x495b1e
mov eax, dword fs:[0]
push eax
sub esp, 0x290
mov eax, dword [0x4a93dc]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
xor ebx, ebx
mov dword [ebp - 0x13c], ebx
mov dword [ebp - 4], ebx
mov edi, vtable.std::basic_ios_wchar_t__struct_std::char_traits_wchar_t__.0
mov dword [ebp - 0x294], 0x49a3d8
mov dword [ebp - 0x284], 0x49a3e0
mov dword [ebp - 0x234], edi
lea eax, [ebp - 0x27c]
push eax
lea ecx, [ebp - 0x294]
mov byte [ebp - 4], 3
push ecx
mov dword [ebp - 0x13c], 1
call fcn.004077f0
mov dword [ebp - 4], 4
mov edx, dword [ebp - 0x294]
mov eax, dword [edx + 4]
lea ecx, [ebp - 0x27c]
push ecx
mov dword [ebp + eax - method.std::basic_stringstream_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__.virtual_0], vtable.std::basic_stringstream_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__.0
call fcn.00407b20
mov esi, vtable.std::basic_stringbuf_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__.0
mov dword [ebp - 0x27c], esi
mov dword [ebp - 0x240], ebx
mov dword [ebp - 0x23c], ebx
mov dword [ebp - 0x1ec], 0x49a3d8
mov dword [ebp - 0x1dc], 0x49a3e0
mov dword [ebp - 0x18c], edi
lea edx, [ebp - 0x1d4]
push edx
lea eax, [ebp - 0x1ec]
mov byte [ebp - 4], 7
push eax
mov dword [ebp - 0x13c], 3
call fcn.004077f0
mov edi, 8
mov dword [ebp - 4], edi
mov ecx, dword [ebp - 0x1ec]
mov edx, dword [ecx + 4]
lea eax, [ebp - 0x1d4]
push eax
mov dword [ebp + edx - method.std::basic_stringstream_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__.virtual_0], vtable.std::basic_stringstream_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__.0
call fcn.00407b20
mov dword [ebp - 0x1d4], esi
mov dword [ebp - 0x198], ebx
mov dword [ebp - 0x194], ebx
push 0x103
lea ecx, [ebp - 0x11b]
push ebx
mov byte [ebp - 4], 0xa
push ecx
mov byte [ebp - 0x11c], bl
call fcn.00489270
mov eax, dword [ebp + 0x40]
add esp, 0xc
cmp dword [ebp + 0x54], edi
jae 0x406696
lea eax, [ebp + 0x40]
push ebx
push 0x80
push 3
push ebx
push ebx
push 0x80000000
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp eax, 0xffffffff
jne 0x406729
lea ecx, [ebp - 0x1ec]
mov byte [ebp - 4], 6
call fcn.00406300
lea ecx, [ebp - 0x294]
mov byte [ebp - 4], 2
call fcn.00406300
cmp dword [ebp + 0x1c], edi
jb 0x4066e0
mov edx, dword [ebp + 8]
push edx
call fcn.00480861
add esp, 4
xor eax, eax
mov esi, 7
mov dword [ebp + 0x1c], esi
mov dword [ebp + 0x18], ebx
mov word [ebp + 8], ax
cmp dword [ebp + 0x38], edi
jb 0x406702
mov ecx, dword [ebp + 0x24]
push ecx
call fcn.00480861
add esp, 4
xor edx, edx
mov dword [ebp + 0x38], esi
mov dword [ebp + 0x34], ebx
mov word [ebp + 0x24], dx
cmp dword [ebp + 0x54], edi
jb 0x40671f
mov eax, dword [ebp + 0x40]
push eax
call fcn.00480861
add esp, 4
mov eax, 1
jmp 0x406975
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp + 0x40]
cmp dword [ebp + 0x54], edi
jae 0x40673b
lea ecx, [ebp + 0x40]
call fcn.004091a0
lea edx, [ebp - 0x11c]
sub edx, eax
mov cl, byte [eax]
mov byte [edx + eax], cl
inc eax
cmp cl, bl
jne 0x406748
push str.heal
push ecx
push 0x49a32c
push ecx
lea ecx, [ebp + 0x24]
push ecx
push ecx
push 0x49a32c
push ecx
lea edx, [ebp + 8]
push edx
push ecx
push 0x49a32c
push ecx
lea eax, [ebp - 0x284]
push 0x49a2c4
push eax
call fcn.004080f0
add esp, 0xc
push eax
call fcn.004080f0
add esp, 0xc
push eax
call fcn.004086f0
add esp, 0xc
push eax
call fcn.004080f0
add esp, 0xc
push eax
call fcn.004086f0
add esp, 0xc
push eax
call fcn.004080f0
add esp, 0xc
push eax
call fcn.004080f0
lea ecx, [ebp - 0x11c]
push ecx
lea edx, [ebp - 0x1dc]
push edx
call fcn.004089a0
add esp, 0x10
lea ecx, [ebp - 0x138]
lea eax, [ebp - 0x294]
call fcn.00406ef0
cmp dword [eax + 0x14], edi
jb 0x4067e9
mov eax, dword [eax]
lea ecx, [ebp - 0x140]
push ecx
push eax
push 0x80000002
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyW]
mov esi, eax
cmp dword [ebp - 0x124], edi
jb 0x406815
mov edx, dword [ebp - 0x138]
push edx
call fcn.00480861
add esp, 4
cmp esi, ebx
je 0x406891
lea ecx, [ebp - 0x1ec]
mov byte [ebp - 4], 6
call fcn.00406300
lea ecx, [ebp - 0x294]
mov byte [ebp - 4], 2
call fcn.00406300
cmp dword [ebp + 0x1c], edi
jb 0x406848
mov eax, dword [ebp + 8]
push eax
call fcn.00480861
add esp, 4
xor ecx, ecx
mov esi, 7
mov dword [ebp + 0x1c], esi
mov dword [ebp + 0x18], ebx
mov word [ebp + 8], cx
cmp dword [ebp + 0x38], edi
jb 0x40686a
mov edx, dword [ebp + 0x24]
push edx
call fcn.00480861
add esp, 4
xor eax, eax
mov dword [ebp + 0x38], esi
mov dword [ebp + 0x34], ebx
mov word [ebp + 0x24], ax
cmp dword [ebp + 0x54], edi
jb 0x406887
mov ecx, dword [ebp + 0x40]
push ecx
call fcn.00480861
add esp, 4
mov eax, 2
jmp 0x406975
lea ecx, [ebp - 0x138]
lea eax, [ebp - 0x1ec]
call fcn.00406ef0
mov ecx, dword [ebp + 0x40]
cmp dword [ebp + 0x54], edi
jae 0x4068ad
lea ecx, [ebp + 0x40]
cmp dword [eax + 0x14], edi
jb 0x4068b4
mov eax, dword [eax]
mov edx, dword [ebp + 0x50]
lea edx, [edx + edx + 2]
push edx
push ecx
push 1
push ebx
push eax
mov eax, dword [ebp - 0x140]
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov esi, eax
cmp dword [ebp - 0x124], edi
jb 0x4068e7
mov ecx, dword [ebp - 0x138]
push ecx
call fcn.00480861
add esp, 4
mov edx, dword [ebp - 0x140]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
neg esi
sbb esi, esi
and esi, 3
lea ecx, [ebp - 0x1ec]
mov dword [ebp - 0x13c], esi
mov byte [ebp - 4], 6
call fcn.00406300
lea ecx, [ebp - 0x294]
mov byte [ebp - 4], 2
call fcn.00406300
cmp dword [ebp + 0x1c], edi
jb 0x406930
mov eax, dword [ebp + 8]
push eax
call fcn.00480861
add esp, 4
xor ecx, ecx
mov esi, 7
mov dword [ebp + 0x1c], esi
mov dword [ebp + 0x18], ebx
mov word [ebp + 8], cx
cmp dword [ebp + 0x38], edi
jb 0x406952
mov edx, dword [ebp + 0x24]
push edx
call fcn.00480861
add esp, 4
xor eax, eax
mov dword [ebp + 0x38], esi
mov dword [ebp + 0x34], ebx
mov word [ebp + 0x24], ax
cmp dword [ebp + 0x54], edi
jb 0x40696f
mov ecx, dword [ebp + 0x40]
push ecx
call fcn.00480861
add esp, 4
mov eax, dword [ebp - 0x13c]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.0048036c
mov esp, ebp
pop ebp
ret