Function at 0x4ad0655b
Capabilities:
Manipulate console buffer

Disassembly:
mov eax, dword [eax*4 + 0x4ad2faa4]
xor edx, edx
inc edx
shl edx, cl
and eax, edx
pop ebp
ret 4
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x40
push ebx
push esi
push edi
push dword [ebp + 0xc]
call fcn.4ad05b41
test eax, eax
jne 0x4ad0710d
xor edi, edi
push dword [ebp + 0x14]
and dword [ebp - 4], 0
push dword [ebp + 0x10]
push 0x4ad05d8c
push dword [ebp + 8]
call fcn.4ad065ff
mov ebx, eax
test ebx, ebx
mov dword [ebp + 0x10], ebx
mov dword [ebp + 0x14], str.auditpol_is_not_recognized_as_an_internal_or_external_command__r_noperable_program_or_batch_file._r_n
je 0x4ad065e6
mov esi, dword [sym.imp.KERNEL32.dll_SetConsoleMode]
test edi, edi
jne 0x4ad0714a
lea ecx, [ebp - 0x10]
push ecx
lea eax, [ebx + ebx]
push eax
push dword [ebp + 0x14]
push dword [ebp + 0xc]
call fcn.4ad064bd
test eax, eax
je 0x4ad0713f
lea eax, [ebx + ebx]
cmp dword [ebp - 0x10], eax
jne 0x4ad0713f
and dword [ebp - 4], 0
sub dword [ebp + 0x10], ebx
mov eax, dword [ebp + 0x14]
lea eax, [eax + ebx*2]
mov dword [ebp + 0x14], eax
jne 0x4ad065a5
cmp dword [ebp - 4], 0
jne 0x4ad1709d
mov eax, dword [ebp - 4]
pop edi
pop esi
pop ebx
leave
ret 0x10
push dword [ebp + 0xc]
call dword [sym.imp.msvcrt.dll__get_osfhandle]
mov edi, eax
pop ecx
lea eax, [ebp - 0x28]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetConsoleScreenBufferInfo]
test eax, eax
je 0x4ad06576
movsx ecx, word [ebp - 0x1c]
movsx eax, word [ebp - 0x18]
sub eax, ecx
dec eax
mov dword [ebp - 8], eax
jmp 0x4ad06578
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x4ad17095
cmp byte [0x4ad34b83], 0
jne 0x4ad16f99
mov ebx, 0xa0
cmp dword [ebp + 0x10], ebx
ja 0x4ad07164
mov ebx, dword [ebp + 0x10]
push 0
lea eax, [ebp - 4]
push eax
push ebx
push dword [ebp + 0x14]
push edi
call dword [sym.imp.KERNEL32.dll_WriteConsoleW]
test eax, eax
jne 0x4ad065d4
jmp 0x4ad1707b
mov eax, dword [0x4ad3da20]
cmp eax, dword [ebp - 8]
jb 0x4ad17044
mov ebx, dword [sym.imp.KERNEL32.dll_GetConsoleScreenBufferInfo]
and dword [0x4ad3da20], 0
lea eax, [ebp - 0x28]
push eax
push edi
call ebx
test eax, eax
je 0x4ad17044
push 0
lea eax, [ebp - 4]
push eax
push dword [0x4ad3da18]
push dword [0x4ad3da1c]
push edi
call dword [sym.imp.KERNEL32.dll_WriteConsoleW]
test eax, eax
je 0x4ad17044
push 0xfffffffffffffff6
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_FlushConsoleInputBuffer]
lea eax, [ebp - 0xc]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_GetConsoleMode]
push 0
push edi
call esi
call dword [sym.imp.msvcrt.dll__getch]
push dword [ebp - 0xc]
mov dword [ebp + 8], eax
push edi
call esi
lea eax, [ebp - 0x40]
push eax
push edi
call ebx
lea eax, [ebp - 4]
push eax
push dword [ebp - 0x24]
lea eax, [ebp - 0x40]
push eax
lea eax, [ebp - 0x28]
push eax
call fcn.4ad1e089
push eax
push 0x20
push edi
call dword [sym.imp.KERNEL32.dll_FillConsoleOutputCharacterW]
push dword [ebp - 0x24]
push edi
call dword [sym.imp.KERNEL32.dll_SetConsoleCursorPosition]
cmp word [ebp + 8], 3
je 0x4ad17089
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp + 0x10]
lea ecx, [eax + ecx*2]
jmp 0x4ad1706b
mov edx, dword [0x4ad3da20]
cmp edx, dword [ebp - 8]
jae 0x4ad1706f
mov dx, word [eax]
inc eax
inc eax
cmp dx, 0xa
jne 0x4ad1706b
inc dword [0x4ad3da20]
cmp eax, ecx
jb 0x4ad1704f
sub eax, dword [ebp + 0x14]
sar eax, 1
mov ebx, eax
jmp 0x4ad07164
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 4], eax
jmp 0x4ad065d8
call fcn.4ad10a43
xor eax, eax
jmp 0x4ad065f3
mov dword [ebp - 4], eax
jmp 0x4ad065e6
cmp dword [ebp + 0xc], 2
jne 0x4ad065f0
push 1
call fcn.4ad040e7
lea eax, [ecx - 0x20]
shr eax, 5
inc eax
mov edx, eax
neg edx
shl edx, 5
add ecx, edx
jmp 0x4ad03cf3