Function at 0x409400
Capabilities:
Get graphical window text

Disassembly:
mov eax, dword [esp + 0xc]
mov ecx, dword [esp + 8]
sub esp, 0x100
mov byte [eax], 0
mov byte [ecx], 0
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0x114]
push edi
call dword [sym.imp.USER32.dll_IsWindowVisible]
test eax, eax
je 0x40974e
lea edx, [esp + 0x10]
push 0xff
push edx
push edi
call dword [sym.imp.USER32.dll_GetClassNameA]
test eax, eax
je 0x40974e
mov esi, 0x40e030
lea eax, [esp + 0x10]
mov dl, byte [eax]
mov bl, byte [esi]
mov cl, dl
cmp dl, bl
jne 0x409478
test cl, cl
je 0x409474
mov dl, byte [eax + 1]
mov bl, byte [esi + 1]
mov cl, dl
cmp dl, bl
jne 0x409478
add eax, 2
add esi, 2
test cl, cl
jne 0x409450
xor eax, eax
jmp 0x40947d
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x40974e
mov esi, dword [sym.imp.USER32.dll_FindWindowExA]
push eax
push 0x40e030
push eax
push edi
call esi
test eax, eax
je 0x4094a7
push 0
push 0x40e030
push 0
push edi
call esi
mov edi, eax
mov ebx, dword [sym.imp.USER32.dll_GetWindow]
push 5
push edi
call ebx
mov ebp, eax
test ebp, ebp
je 0x40974e
lea eax, [esp + 0x10]
push eax
push 0x40
push 0xd
push ebp
call dword [sym.imp.USER32.dll_SendMessageA]
test eax, eax
je 0x40955e
mov esi, dword [sym.imp.MSVCRT.dll_strncmp]
push 3
lea ecx, [esp + 0x14]
push 0x40e1b4
push ecx
call esi
add esp, 0xc
test eax, eax
jne 0x409509
lea edi, [esp + 0x13]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, dword [esp + 0x118]
mov edx, ecx
jmp 0x409536
push 5
lea eax, [esp + 0x14]
push 0x40e1ac
push eax
call esi
add esp, 0xc
test eax, eax
jne 0x409542
lea edi, [esp + 0x15]
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov esi, edi
mov edi, dword [esp + 0x11c]
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [esp + 0x118]
cmp byte [eax], 0
je 0x40955e
mov ecx, dword [esp + 0x11c]
cmp byte [ecx], 0
jne 0x40974e
push 5
push ebp
call ebx
mov esi, eax
test esi, esi
je 0x4096a7
push 0
push 0x40e1a4
push 0
push ebp
call dword [sym.imp.USER32.dll_FindWindowExA]
cmp esi, eax
jne 0x4096a7
lea edx, [esp + 0x10]
push edx
push 0xff
push 0xd
push esi
call dword [sym.imp.USER32.dll_SendMessageA]
test eax, eax
je 0x4096a7
push 0
push 0
push 0
push 0x40e3b8
lea eax, [esp + 0x20]
push 0x40e19c
push eax
call fcn.00402320
push 0
push 0
push 0
push 0x40e3b8
lea ecx, [esp + 0x38]
push 0x40e194
push ecx
call fcn.00402320
push 0
push 0
push 0
push 0x40e3b8
lea edx, [esp + 0x50]
push 0x40e18c
push edx
call fcn.00402320
add esp, 0x48
lea eax, [esp + 0x10]
push 0
push 0
push 0
push 0x40e3b8
push 0x40e184
push eax
call fcn.00402320
mov al, byte [esp + 0x28]
add esp, 0x18
test al, al
lea ebx, [esp + 0x10]
je 0x409640
mov al, byte [ebx]
cmp al, 0x20
je 0x409624
cmp al, 0x28
jne 0x409638
lea ecx, [ebx + 1]
push ecx
call dword [sym.imp.MSVCRT.dll_atoi]
add esp, 4
cmp eax, 0x1869f
jg 0x409640
mov al, byte [ebx + 1]
inc ebx
test al, al
jne 0x40961a
cmp byte [ebx], 0
je 0x409652
mov edx, ebx
lea eax, [esp + 0x10]
sub edx, eax
cmp edx, 0xc
jle 0x4096cb
lea edi, [esp + 0x10]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, 0xc
jbe 0x40968a
mov esi, dword [sym.imp.MSVCRT.dll_strchr]
lea ecx, [esp + 0x12]
push 0x28
push ecx
call esi
add esp, 8
test eax, eax
je 0x40968a
lea edx, [esp + 0x12]
push 0x28
push edx
call esi
add esp, 8
mov byte [eax], 0
lea edi, [esp + 0x10]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, 0xc
jbe 0x409728
mov ebx, dword [sym.imp.USER32.dll_GetWindow]
push 2
push ebp
call ebx
mov ebp, eax
test ebp, ebp
jne 0x4094bc
mov eax, dword [esp + 0x11c]
pop edi
pop esi
pop ebp
movsx eax, byte [eax]
pop ebx
add esp, 0x100
ret
lea edi, [esp + 0x10]
or ecx, 0xffffffff
xor eax, eax
mov byte [ebx], 0
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, dword [esp + 0x11c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
inc ebx
rep movsb byte es:[edi], byte [esi]
push ebx
call dword [sym.imp.MSVCRT.dll_atoi]
mov ecx, dword [esp + 0x11c]
push eax
push 0x40e180
push ecx
call dword [sym.imp.MSVCRT.dll_sprintf]
mov eax, dword [esp + 0x12c]
add esp, 0x10
movsx eax, byte [eax]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x100
ret
lea edi, [esp + 0x10]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov edx, ecx
mov esi, edi
mov edi, dword [esp + 0x11c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov eax, dword [esp + 0x11c]
pop edi
pop esi
pop ebp
movsx eax, byte [eax]
pop ebx
add esp, 0x100
ret