Function at 0x412df0
Capabilities:
Check if file exists
Create directory
Get common file path
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x82c
mov eax, dword [0x4f9008]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
push 0x208
lea eax, [ebp - 0x414]
mov ebx, ecx
push 0
push eax
call fcn.004773d0
push 0x208
lea eax, [ebp - 0x824]
push 0
push eax
call fcn.004773d0
push 0x208
lea eax, [ebp - 0x20c]
push 0
push eax
call fcn.004773d0
push 0x208
lea eax, [ebp - 0x61c]
push 0
push eax
call fcn.004773d0
push 0
call fcn.0047cfa5
push eax
call fcn.0047d857
add esp, 0x38
xor esi, esi
lea edi, [esi + 0x1c]
nop dword [eax]
call fcn.0047d836
cdq
idiv edi
mov ax, word [ebx + edx*2 + 4]
mov word [ebp + esi*2 - 0x414], ax
inc esi
cmp esi, 0xc
jl 0x412e70
lea ecx, [ebp - 0x414]
add ecx, 0xfffffffe
mov ax, word [ecx + 2]
lea ecx, [ecx + 2]
test ax, ax
jne 0x412e94
mov eax, dword [0x4d58e4]
xor esi, esi
mov dword [ecx], eax
mov eax, dword [0x4d58e8]
mov dword [ecx + 4], eax
call fcn.0047d836
cdq
idiv edi
mov ax, word [ebx + edx*2 + 4]
mov word [ebp + esi*2 - 0x20c], ax
inc esi
cmp esi, 0xc
jl 0x412eb1
lea ecx, [ebp - 0x20c]
add ecx, 0xfffffffe
mov ax, word [ecx + 2]
lea ecx, [ecx + 2]
test ax, ax
jne 0x412ed5
mov eax, dword [0x4d58ec]
xor esi, esi
mov dword [ecx], eax
mov eax, dword [0x4d58f0]
mov dword [ecx + 4], eax
call fcn.0047d836
cdq
idiv edi
mov ax, word [ebx + edx*2 + 4]
mov word [ebp + esi*2 - 0x61c], ax
inc esi
cmp esi, 0xc
jl 0x412ef2
lea ecx, [ebp - 0x61c]
add ecx, 0xfffffffe
mov ax, word [ecx + 2]
lea ecx, [ecx + 2]
test ax, ax
jne 0x412f16
mov eax, dword [0x4d58f4]
xor esi, esi
mov dword [ecx], eax
mov eax, dword [0x4d58f8]
mov dword [ecx + 4], eax
call fcn.0047d836
cdq
idiv edi
mov ax, word [ebx + edx*2 + 4]
mov word [ebp + esi*2 - 0x824], ax
inc esi
cmp esi, 0xc
jl 0x412f33
lea ecx, [ebp - 0x824]
add ecx, 0xfffffffe
nop word [eax + eax]
mov ax, word [ecx + 2]
lea ecx, [ecx + 2]
test ax, ax
jne 0x412f60
mov eax, dword [0x4d58fc]
mov edx, dword [ebx]
mov dword [ecx], eax
mov eax, dword [0x4d5900]
mov dword [ecx + 4], eax
lea ecx, [ebp - 0x414]
movzx eax, word [ecx]
lea ecx, [ecx + 2]
mov word [edx], ax
lea edx, [edx + 2]
test ax, ax
jne 0x412f83
mov ecx, dword [ebx]
lea edx, [ebp - 0x20c]
add ecx, 0x208
movzx eax, word [edx]
lea edx, [edx + 2]
mov word [ecx], ax
lea ecx, [ecx + 2]
test ax, ax
jne 0x412fa2
mov ecx, dword [ebx]
lea edx, [ebp - 0x61c]
add ecx, 0x410
movzx eax, word [edx]
lea edx, [edx + 2]
mov word [ecx], ax
lea ecx, [ecx + 2]
test ax, ax
jne 0x412fc1
mov ecx, dword [ebx]
lea edx, [ebp - 0x824]
add ecx, 0x618
movzx eax, word [edx]
lea edx, [edx + 2]
mov word [ecx], ax
lea ecx, [ecx + 2]
test ax, ax
jne 0x412fe0
push 0x208
lea eax, [ebp - 0x20c]
push 0
push eax
call fcn.004773d0
push 0x208
lea eax, [ebp - 0x414]
push 0
push eax
call fcn.004773d0
add esp, 0x18
lea eax, [ebp - 0x20c]
push 0
push 0x2b
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
lea edi, [ebp - 0x20c]
add edi, 0xfffffffe
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x413036
mov ecx, 6
lea eax, [ebp - 0x20c]
mov esi, str.ClodlySoft_
rep movsd dword es:[edi], dword [esi]
push eax
movsw word es:[edi], word [esi]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
jne 0x41306f
push eax
lea eax, [ebp - 0x20c]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
xor ecx, ecx
movzx eax, word [ebp + ecx - 0x20c]
lea ecx, [ecx + 2]
mov word [ebp + ecx - 0x416], ax
test ax, ax
jne 0x413071
lea edi, [ebp - 0x414]
add edi, 0xfffffffe
mov ax, word [edi + 2]
add edi, 2
test ax, ax
jne 0x413092
mov ecx, 7
lea eax, [ebp - 0x20c]
mov esi, str.cloudysoft.ini
rep movsd dword es:[edi], dword [esi]
push eax
movsw word es:[edi], word [esi]
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x413129
mov esi, dword [sym.imp.KERNEL32.dll_WritePrivateProfileStringW]
lea eax, [ebp - 0x414]
push eax
push dword [ebx]
push str.OID1
push str.Globals
call esi
lea eax, [ebp - 0x414]
push eax
mov eax, dword [ebx]
add eax, 0x208
push eax
push str.OID2
push str.Globals
call esi
lea eax, [ebp - 0x414]
push eax
mov eax, dword [ebx]
add eax, 0x410
push eax
push str.OID3
push str.Globals
call esi
lea eax, [ebp - 0x414]
push eax
mov eax, dword [ebx]
add eax, 0x618
push eax
push str.OID4
push str.Globals
call esi
lea eax, [ebp - 0x82c]
push eax
push 0xf003f
push 0
push str.software
push connect
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x41323f
push eax
lea eax, [ebp - 0x828]
push eax
push 0
push 0xf003f
push 0
push 0
push 0
push str.ClodlySoft
push dword [ebp - 0x82c]
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0x41323f
push dword [ebx]
mov esi, dword [sym.imp.KERNEL32.dll_lstrlenW]
call esi
mov edi, dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
lea eax, [eax*2 + 2]
push eax
push dword [ebx]
push 1
push 0
push str.OID1
push dword [ebp - 0x828]
call edi
mov eax, dword [ebx]
add eax, 0x208
push eax
call esi
lea eax, [eax*2 + 2]
push eax
mov eax, dword [ebx]
add eax, 0x208
push eax
push 1
push 0
push str.OID2
push dword [ebp - 0x828]
call edi
mov eax, dword [ebx]
add eax, 0x410
push eax
call esi
lea eax, [eax*2 + 2]
push eax
mov eax, dword [ebx]
add eax, 0x410
push eax
push 1
push 0
push str.OID3
push dword [ebp - 0x828]
call edi
mov eax, dword [ebx]
add eax, 0x618
push eax
call esi
lea eax, [eax*2 + 2]
push eax
mov eax, dword [ebx]
add eax, 0x618
push eax
push 1
push 0
push str.OID4
push dword [ebp - 0x828]
call edi
push dword [ebp - 0x828]
mov esi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
call esi
push dword [ebp - 0x82c]
call esi
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00475880
mov esp, ebp
pop ebp
ret