Function at 0x409980
Capabilities:
Get graphical window text

Disassembly:
sub esp, 0xdd4
push ebx
push ebp
push esi
push edi
mov edi, dword [esp + 0xdec]
mov dword [esp + 0x10], 0
test edi, edi
je 0x4099c0
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
lea edx, [esp + 0x28]
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
jmp 0x4099d2
lea ecx, [esp + 0x28]
push 0xff
push ecx
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
mov ebp, dword [esp + 0xde8]
push ebp
call dword [sym.imp.USER32.dll_IsWindowVisible]
test eax, eax
je 0x409e75
lea edx, [esp + 0x28]
push edx
call fcn.00405050
add esp, 4
test eax, eax
je 0x409e75
mov esi, dword [sym.imp.MSVCRT.dll_strrchr]
lea eax, [esp + 0x28]
push 0x5c
push eax
call esi
add esp, 8
test eax, eax
je 0x409e75
lea ecx, [esp + 0x28]
push 0x5c
push ecx
call esi
mov edi, eax
add esp, 8
inc edi
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x128]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov ebx, dword [sym.imp.USER32.dll_FindWindowExA]
mov eax, ecx
mov esi, edi
mov edi, edx
push 0
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
push 0x40e188
and ecx, 3
push 0
rep movsb byte es:[edi], byte [esi]
push ebp
call ebx
test eax, eax
je 0x409a75
push 0
push 0x40e188
push 0
push ebp
call ebx
mov dword [esp + 0xde8], eax
mov ebp, eax
push 0
push 0x40e370
push 0
push ebp
call ebx
test eax, eax
mov dword [esp + 0x14], eax
je 0x409e75
lea ecx, [esp + 0x228]
push ecx
push 0xbb8
push 0xd
push eax
call dword [sym.imp.USER32.dll_SendMessageA]
test eax, eax
je 0x409e75
lea edx, [esp + 0x228]
push 0x20
push edx
mov byte [esp + 0xde8], 0
call dword [sym.imp.MSVCRT.dll_strchr]
mov ebp, eax
add esp, 8
test ebp, ebp
je 0x409e75
cmp byte [ebp + 3], 0x3a
jne 0x409b81
cmp byte [ebp + 6], 0x3a
jne 0x409b81
cmp byte [ebp + 9], 0xd
jne 0x409b81
mov eax, 1
lea ecx, [ebp - 1]
cmp byte [ecx], 0xa
je 0x409b11
mov edx, ebp
lea esi, [esp + 0x228]
sub edx, eax
cmp edx, esi
jb 0x409b11
inc eax
dec ecx
cmp eax, 0x10
jl 0x409af6
cmp eax, 0xd
jg 0x409b81
cmp eax, 2
jl 0x409b81
dec eax
mov edi, ebp
sub edi, eax
mov byte [ebp], 0
mov esi, edi
lea eax, [esp + 0x18]
mov dl, byte [eax]
mov cl, dl
cmp dl, byte [esi]
jne 0x409b4e
test cl, cl
je 0x409b4a
mov dl, byte [eax + 1]
mov cl, dl
cmp dl, byte [esi + 1]
jne 0x409b4e
add eax, 2
add esi, 2
test cl, cl
jne 0x409b2a
xor eax, eax
jmp 0x409b53
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x409b81
mov ecx, dword [esp + 0x10]
xor eax, eax
inc ecx
lea edx, [esp + 0x18]
mov dword [esp + 0x10], ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
mov eax, ecx
mov esi, edi
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
inc ebp
push 0x20
push ebp
call dword [sym.imp.MSVCRT.dll_strchr]
mov ebp, eax
add esp, 8
test ebp, ebp
jne 0x409ad0
cmp dword [esp + 0x10], 5
jl 0x409e75
push ebp
push 0x40e364
push ebp
mov ebp, dword [esp + 0xdf4]
push ebp
call ebx
test eax, eax
je 0x409c25
push 0
push 0x40e364
push eax
push ebp
call ebx
test eax, eax
je 0x409c25
push 0
push 0x40e364
push eax
push ebp
call ebx
mov esi, eax
test esi, esi
je 0x409c25
push 0x40e358
push 0x40e350
push 0
push esi
call ebx
test eax, eax
je 0x409c25
push 0
push 0x40e188
push eax
push esi
call ebx
mov esi, eax
test esi, esi
je 0x409c25
push 0x40e340
push 0x40e2f4
push 0
push esi
call ebx
test eax, eax
je 0x409c25
push eax
push eax
call dword [sym.imp.USER32.dll_GetDlgCtrlID]
and eax, 0xffff
push eax
push 0x111
push esi
jmp 0x409c32
push 0
push 0x84d2
push 0x111
push ebp
call dword [sym.imp.USER32.dll_PostMessageA]
push ebp
xor edi, edi
call dword [sym.imp.USER32.dll_IsWindowVisible]
test eax, eax
je 0x409e75
mov ebx, dword [sym.imp.KERNEL32.dll_Sleep]
cmp edi, 0x12c
jge 0x409e75
push 0x40e338
push 0x40e188
call dword [sym.imp.USER32.dll_FindWindowA]
mov esi, eax
test esi, esi
jne 0x409c93
push 0xa
call ebx
mov ecx, dword [esp + 0xde8]
inc edi
push ecx
call dword [sym.imp.USER32.dll_IsWindowVisible]
test eax, eax
jne 0x409c4f
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xdd4
ret
mov edx, dword [esp + 0x14]
push 0x40e508
push 0
push 0xc
push edx
call dword [sym.imp.USER32.dll_SendMessageA]
mov ebp, dword [sym.imp.USER32.dll_FindWindowExA]
push 0
push 0x40e328
push 0
push esi
call ebp
mov edi, eax
test edi, edi
jne 0x409cd3
push eax
push 0x40e1b4
push eax
push esi
call ebp
mov edi, eax
test edi, edi
je 0x409e68
push edi
xor ebp, ebp
call dword [sym.imp.USER32.dll_IsWindowVisible]
test eax, eax
jne 0x409cf8
cmp ebp, 0x12c
jge 0x409cf8
push 0xa
call ebx
push edi
inc ebp
call dword [sym.imp.USER32.dll_IsWindowVisible]
test eax, eax
je 0x409ce0
lea eax, [esp + 0x28]
push eax
push 0
push 0xc
push edi
call dword [sym.imp.USER32.dll_SendMessageA]
push 0x40e31c
push 0x40e350
push 0
push esi
call dword [sym.imp.USER32.dll_FindWindowExA]
test eax, eax
je 0x409e68
push eax
push eax
call dword [sym.imp.USER32.dll_GetDlgCtrlID]
and eax, 0xffff
push eax
push 0x111
push esi
call dword [sym.imp.USER32.dll_PostMessageA]
mov ebp, dword [esp + 0x14]
xor edi, edi
push ebp
call dword [sym.imp.USER32.dll_IsWindowVisible]
test eax, eax
je 0x409e58
cmp edi, 0x7d0
jge 0x409e58
push 0x3c
call ebx
cmp edi, 0x32
jge 0x409d79
push 0x40e508
push 0
push 0xc
push ebp
call dword [sym.imp.USER32.dll_SendMessageA]
jmp 0x409db5
lea ecx, [esp + 0x228]
push ecx
push 0xbb8
push 0xd
push ebp
call dword [sym.imp.USER32.dll_SendMessageA]
test eax, eax
je 0x409db5
push 1
push 0
lea edx, [esp + 0x130]
push 0
lea eax, [esp + 0x234]
push edx
push eax
call fcn.00402500
add esp, 0x14
test eax, eax
jne 0x409e1c
push 0x40e310
push 0x40e188
call dword [sym.imp.USER32.dll_FindWindowA]
mov esi, eax
test esi, esi
je 0x409dfc
push 0x40e308
push 0x40e350
push 0
push esi
call dword [sym.imp.USER32.dll_FindWindowExA]
test eax, eax
je 0x409dfc
push eax
push eax
call dword [sym.imp.USER32.dll_GetDlgCtrlID]
and eax, 0xffff
push eax
push 0x111
push esi
call dword [sym.imp.USER32.dll_PostMessageA]
push ebp
inc edi
call dword [sym.imp.USER32.dll_IsWindowVisible]
test eax, eax
jne 0x409d52
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xdd4
ret
push 0x14
call ebx
mov esi, dword [sym.imp.USER32.dll_SendMessageA]
push 0x40e508
push 0
push 0xc
push ebp
call esi
push 0xc8
call ebx
push 0x40e508
push 0
push 0xc
push ebp
call esi
push 0x320
call ebx
push 0x40e508
push 0
push 0xc
push ebp
call esi
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0xdd4
ret
push 0
push 0
push 0x10
push esi
call dword [sym.imp.USER32.dll_PostMessageA]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0xdd4
ret