Function at 0x412ef7
Capabilities:
Get graphical window text
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x270
push 0x208
push 0
lea eax, [ebp - 0x270]
push eax
call fcn.0040132f
add esp, 0xc
lea ecx, [ebp - 4]
call fcn.00406f52
call dword [sym.imp.USER32.dll_GetForegroundWindow]
mov dword [ebp - 8], eax
push 0x104
lea eax, [ebp - 0x270]
push eax
push dword [ebp - 8]
call dword [sym.imp.USER32.dll_GetWindowTextW]
test eax, eax
jle 0x412f87
push 0x426e00
lea ecx, [ebp - 4]
call fcn.00406c53
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x270]
push eax
lea ecx, [ebp - 0x18]
call fcn.00406f64
mov dword [ebp - 0xc], eax
push dword [ebp - 0xc]
mov ecx, dword [ebp - 0x10]
call fcn.00406cc1
mov dword [ebp - 0x14], eax
push 0x426e04
mov ecx, dword [ebp - 0x14]
call fcn.00406c53
lea ecx, [ebp - 0x18]
call fcn.00406be2
jmp 0x412f94
push 0x426e08
lea ecx, [ebp - 4]
call fcn.00406a11
mov eax, dword [0x42cc9c]
add eax, 0x210
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
test eax, eax
je 0x413019
mov eax, dword [0x42cc9c]
add eax, 0x210
push eax
lea ecx, [ebp - 0x1c]
call fcn.00406f64
push eax
lea ecx, [ebp - 4]
call fcn.004069e1
mov dword [ebp - 0x20], eax
lea ecx, [ebp - 0x1c]
call fcn.00406be2
cmp dword [ebp - 0x20], 0
je 0x412fe7
mov eax, dword [0x42cc9c]
mov dword [eax + 0xa10], 1
jmp 0x413017
lea ecx, [ebp - 4]
call fcn.00406f44
mov dword [ebp - 0x24], eax
mov eax, dword [0x42cc9c]
add eax, 0x210
mov dword [ebp - 0x28], eax
push dword [ebp - 0x24]
push dword [ebp - 0x28]
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
mov eax, dword [0x42cc9c]
and dword [eax + 0xa10], 0
jmp 0x413049
lea ecx, [ebp - 4]
call fcn.00406f44
mov dword [ebp - 0x2c], eax
mov eax, dword [0x42cc9c]
add eax, 0x210
mov dword [ebp - 0x30], eax
push dword [ebp - 0x2c]
push dword [ebp - 0x30]
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
mov eax, dword [0x42cc9c]
and dword [eax + 0xa10], 0
push 0
push 0x80
push 4
push 0
push 1
push 4
mov ecx, dword [0x42cc9c]
add ecx, 0xc
call fcn.00406f44
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x34], eax
mov eax, dword [0x42cc9c]
mov ecx, dword [ebp - 0x34]
mov dword [eax + 4], ecx
mov eax, dword [0x42cc9c]
cmp dword [eax + 0xa10], 0
jne 0x413143
mov eax, dword [0x42cc9c]
add eax, 8
mov dword [ebp - 0x38], eax
push 0x426e1c
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov dword [ebp - 0x3c], eax
mov eax, dword [0x42cc9c]
mov eax, dword [eax + 4]
mov dword [ebp - 0x40], eax
push 0
push dword [ebp - 0x38]
push dword [ebp - 0x3c]
push 0x426e24
push dword [ebp - 0x40]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [0x42cc9c]
add eax, 8
mov dword [ebp - 0x44], eax
lea ecx, [ebp - 4]
call fcn.00406f1b
shl eax, 1
mov dword [ebp - 0x48], eax
lea ecx, [ebp - 4]
call fcn.00406f44
mov dword [ebp - 0x4c], eax
mov eax, dword [0x42cc9c]
mov eax, dword [eax + 4]
mov dword [ebp - 0x50], eax
push 0
push dword [ebp - 0x44]
push dword [ebp - 0x48]
push dword [ebp - 0x4c]
push dword [ebp - 0x50]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [0x42cc9c]
add eax, 8
mov dword [ebp - 0x54], eax
push 0x426e2c
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov dword [ebp - 0x58], eax
mov eax, dword [0x42cc9c]
mov eax, dword [eax + 4]
mov dword [ebp - 0x5c], eax
push 0
push dword [ebp - 0x54]
push dword [ebp - 0x58]
push 0x426e34
push dword [ebp - 0x5c]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [0x42cc9c]
add eax, 8
mov dword [ebp - 0x60], eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_lstrlenW]
shl eax, 1
mov dword [ebp - 0x64], eax
mov eax, dword [0x42cc9c]
mov eax, dword [eax + 4]
mov dword [ebp - 0x68], eax
push 0
push dword [ebp - 0x60]
push dword [ebp - 0x64]
push dword [ebp + 8]
push dword [ebp - 0x68]
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov eax, dword [0x42cc9c]
push dword [eax + 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [ebp - 4]
call fcn.00406be2
leave
ret