Function at 0x42ff61
Capabilities:
Check os version
Create directory
Get common file path

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x4708ee
mov eax, dword fs:[0]
push eax
sub esp, 0x3c8
mov eax, dword [0x49b7f8]
xor eax, esp
mov dword [esp + 0x3c0], eax
push ebx
push esi
push edi
mov eax, dword [0x49b7f8]
xor eax, esp
push eax
lea eax, [esp + 0x3d8]
mov dword fs:[0], eax
mov esi, edx
mov dword [esp + 0x14], esi
mov edi, ecx
mov dword [esp + 0x1c], edi
mov eax, dword [ebp + 0xc]
xor ebx, ebx
push 0x47c2d4
lea ecx, [esp + 0x50]
mov dword [esp + 0x24], eax
mov dword [esp + 0x34], ebx
call fcn.00407d70
mov dword [esp + 0x3e0], ebx
cmp byte [ebp + 0x10], bl
je 0x42ffe2
push str.Limb16
lea ecx, [esp + 0x50]
call fcn.00407e80
push str.Shell32.dll
mov dword [esp + 0x2c], ebx
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov ebx, eax
mov dword [esp + 0x2c], ebx
test ebx, ebx
je 0x43000b
push str.SHGetKnownFolderPath
push ebx
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [esp + 0x28], eax
push 0x110
lea eax, [esp + 0xb4]
push 0
push eax
mov byte [esp + 0x3ec], 1
call fcn.00454000
add esp, 0xc
lea eax, [esp + 0xac]
push eax
mov dword [esp + 0xb0], 0x114
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
cmp dword [esp + 0xb0], 6
mov edx, 0x8000
jb 0x430274
cmp esi, 8
ja case.default.0x43005b
jmp dword [esi*4 + 0x430419]
mov esi, 0x47c264
jmp 0x430098
mov esi, 0x47c274
jmp 0x430098
mov esi, 0x47c244
jmp 0x430098
mov esi, 0x47c224
jmp 0x430098
mov esi, 0x47c284
jmp 0x430098
mov esi, 0x47c234
jmp 0x430098
mov esi, 0x47c214
jmp 0x430098
mov esi, 0x47c254
lea edi, [esp + 0x34]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
movsd dword es:[edi], dword [esi]
mov edi, dword [esp + 0x1c]
mov esi, dword [esp + 0x14]
mov ecx, dword [esp + 0x28]
and dword [esp + 0x24], 0
test ecx, ecx
je 0x430274
lea eax, [esp + 0x24]
push eax
xor eax, eax
cmp byte [ebp + 8], al
push 0
cmovne eax, edx
push eax
lea eax, [esp + 0x40]
push eax
call ecx
cmp eax, 0x80004001
je 0x43026f
push dword [esp + 0x24]
lea ecx, [esp + 0x18]
call fcn.004132b0
mov byte [esp + 0x3e0], 2
cmp dword [esp + 0x60], 0x10
lea eax, [esp + 0x4c]
cmovae eax, dword [esp + 0x4c]
push eax
lea ecx, [esp + 0x18]
call fcn.004133f0
push 0x4849c0
lea ecx, [esp + 0x18]
call fcn.004133f0
cmp byte [ebp + 8], 0
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
je 0x43017a
push 0
push dword [esp + 0x18]
call edi
test eax, eax
jne 0x43017a
call esi
cmp eax, 0xb7
je 0x43017a
call esi
push eax
push dword [esp + 0x18]
lea eax, [esp + 0x9c]
push str.Failed_to_create_directory__S__error_d
push eax
call fcn.0042fa5d
add esp, 0x10
push eax
lea ecx, [esp + 0x68]
mov byte [esp + 0x3e4], 3
call fcn.00401250
push 0x48e968
lea eax, [esp + 0x68]
push eax
call fcn.00454ac3
mov eax, dword [esp + 0x20]
test eax, eax
je 0x4301e0
push eax
lea ecx, [esp + 0x18]
call fcn.004133f0
cmp byte [ebp + 8], 0
je 0x4301e0
push 0
push dword [esp + 0x18]
call edi
test eax, eax
jne 0x4301e0
call esi
cmp eax, 0xb7
je 0x4301e0
call esi
push eax
push dword [esp + 0x18]
lea eax, [esp + 0x9c]
push str.Failed_to_create_subdirectory__S__error_d
push eax
call fcn.0042fa5d
add esp, 0x10
push eax
lea ecx, [esp + 0x68]
mov byte [esp + 0x3e4], 4
call fcn.00401250
push 0x48e968
lea eax, [esp + 0x68]
jmp 0x430174
push dword [esp + 0x14]
lea ecx, [esp + 0x1c]
call fcn.004132b0
push 0x104
lea ecx, [esp + 0x1c]
mov byte [esp + 0x3e4], 5
call fcn.00410cc0
push eax
call dword [sym.imp.SHLWAPI.dll_PathAddBackslashW]
push ecx
lea ecx, [esp + 0x1c]
call fcn.00413490
mov esi, dword [esp + 0x1c]
push dword [esp + 0x18]
mov ecx, esi
call fcn.00408580
lea ecx, [esp + 0x18]
call fcn.00410c00
lea ecx, [esp + 0x14]
call fcn.00410c00
test ebx, ebx
je 0x430240
push ebx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
lea ecx, [esp + 0x4c]
call fcn.00404060
mov eax, esi
mov ecx, dword [esp + 0x3d8]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x3c0]
xor ecx, esp
call fcn.0044f834
mov esp, ebp
pop ebp
ret
mov edx, 0x8000
xor eax, eax
cmp byte [ebp + 8], al
lea ecx, [esp + 0x7c]
cmovne eax, edx
lea edx, [esp + 0x4c]
mov dword [esp + 0x24], eax
call fcn.0042f884
mov byte [esp + 0x3e0], 6
mov eax, dword [esp + 0x20]
test eax, eax
je 0x4302ef
push eax
lea ecx, [esp + 0x38]
call fcn.00407d70
lea edx, [esp + 0x34]
lea ecx, [esp + 0x64]
mov byte [esp + 0x3e0], 7
call fcn.0042f884
push 0xffffffffffffffff
push 0
push eax
lea ecx, [esp + 0x88]
mov byte [esp + 0x3ec], 8
call fcn.0040a040
lea ecx, [esp + 0x64]
call fcn.00408690
lea ecx, [esp + 0x34]
mov byte [esp + 0x3e0], 6
call fcn.00404060
cmp esi, 8
ja case.0x4302f4.7
jmp dword [esi*4 + 0x43043d]
push 0x1c
pop ecx
jmp 0x43031c
push 0x23
jmp 0x4302fd
push 2
jmp 0x4302fd
push 0x17
jmp 0x4302fd
push 0x26
jmp 0x4302fd
xor ecx, ecx
jmp 0x43031c
push 0x1a
jmp 0x4302fd
mov ecx, dword [esp + 0x20]
cmp dword [esp + 0x90], 8
lea edx, [esp + 0x1c4]
push edx
lea eax, [esp + 0x80]
cmovae eax, dword [esp + 0x80]
or ecx, dword [esp + 0x28]
push eax
xor eax, eax
push eax
push eax
push ecx
push eax
call dword [sym.imp.SHELL32.dll_SHGetFolderPathAndSubDirW]
test eax, eax
jne 0x4303e2
lea eax, [esp + 0x1c4]
push eax
lea ecx, [esp + 0x24]
call fcn.004132b0
mov byte [esp + 0x3e0], 9
push dword [esp + 0x20]
lea ecx, [esp + 0x1c]
call fcn.004132b0
push 0x104
lea ecx, [esp + 0x1c]
mov byte [esp + 0x3e4], 0xa
call fcn.00410cc0
push eax
call dword [sym.imp.SHLWAPI.dll_PathAddBackslashW]
push ecx
lea ecx, [esp + 0x1c]
call fcn.00413490
push dword [esp + 0x18]
mov ecx, edi
call fcn.00408580
lea ecx, [esp + 0x18]
call fcn.00410c00
lea ecx, [esp + 0x20]
call fcn.00410c00
lea ecx, [esp + 0x7c]
call fcn.00408690
test ebx, ebx
je 0x4303d2
push ebx
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
lea ecx, [esp + 0x4c]
call fcn.00404060
mov eax, edi
jmp 0x43024b
push eax
lea eax, [esp + 0x98]
push str.Bad_result_from_SHGetFolderPathAndSubDirW_d
push eax
call fcn.0042fa5d
add esp, 0xc
push eax
lea ecx, [esp + 0x68]
mov byte [esp + 0x3e4], 0xb
call fcn.00401250
push 0x48e968
lea eax, [esp + 0x68]
jmp 0x430174