Function at 0x10003090
Capabilities:
Print debug messages
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x14
mov eax, dword [section..data]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov ebx, ecx
mov dword [ebp - 0x14], edx
push 0x400
mov dword [ebp - 0x10], ebx
call fcn.10009692
push ebx
mov esi, eax
push str.Policy_query:__S_r_n
push esi
call dword [sym.imp.USER32.dll_wsprintfA]
mov edi, dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
add esp, 0x10
push esi
call edi
push 0
push 0x80
push 4
push 0
push 3
push 0x40000000
push str._rdpwrap.txt
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov ebx, dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov dword [ebp - 0xc], eax
cmp eax, 0xffffffff
je 0x10003133
push 2
push 0
push 0
push eax
call ebx
mov ecx, esi
lea edx, [ecx + 1]
nop dword [eax]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x10003110
push 0
lea eax, [ebp - 8]
sub ecx, edx
push eax
push ecx
push esi
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_WriteFile]
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push esi
call fcn.1000969b
mov esi, dword [ebp - 0x10]
lea edx, [ebp - 0xc]
add esp, 4
mov ecx, esi
call fcn.10002c80
test al, al
mov eax, dword [ebp - 0x14]
je 0x100031eb
mov esi, dword [ebp - 0xc]
push 0x400
mov dword [eax], esi
call fcn.10009692
push esi
mov edi, eax
mov eax, dword [sym.imp.USER32.dll_wsprintfA]
push str.Policy_rewrite:__i_r_n
push edi
call eax
add esp, 0x10
push edi
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
mov eax, dword [sym.imp.KERNEL32.dll_CreateFileW]
push 0
push 0x80
push 4
push 0
push 3
push 0x40000000
push str._rdpwrap.txt
call eax
mov esi, eax
cmp esi, 0xffffffff
je 0x100031cf
push 2
push 0
push 0
push esi
call ebx
mov ecx, edi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x100031b0
push 0
lea eax, [ebp - 8]
sub ecx, edx
push eax
push ecx
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call fcn.1000969b
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10009684
mov esp, ebp
pop ebp
ret
push eax
push esi
call dword [0x10030ebc]
mov dword [ebp - 0x10], eax
test eax, eax
jne 0x1000328f
push 0x400
call fcn.10009692
push dword [ebp - 0xc]
mov esi, eax
mov eax, dword [sym.imp.USER32.dll_wsprintfA]
push str.Policy_result:__i_r_n
push esi
call eax
add esp, 0x10
push esi
call edi
mov eax, dword [sym.imp.KERNEL32.dll_CreateFileW]
push 0
push 0x80
push 4
push 0
push 3
push 0x40000000
push str._rdpwrap.txt
call eax
mov edi, eax
cmp edi, 0xffffffff
je 0x10003272
push 2
push 0
push 0
push edi
call ebx
mov ecx, esi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x10003253
push 0
lea eax, [ebp - 8]
sub ecx, edx
push eax
push ecx
push esi
push edi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push esi
call fcn.1000969b
mov eax, dword [ebp - 0x10]
add esp, 4
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10009684
mov esp, ebp
pop ebp
ret
push str.Policy_request_failed_r_n
call edi
mov eax, dword [sym.imp.KERNEL32.dll_CreateFileW]
push 0
push 0x80
push 4
push 0
push 3
push 0x40000000
push str._rdpwrap.txt
call eax
mov esi, eax
cmp esi, 0xffffffff
je 0x100032df
push 2
push 0
push 0
push esi
call ebx
push 0
lea eax, [ebp - 8]
push eax
push 0x17
push str.Policy_request_failed_r_n
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0x10]
xor ecx, ebp
pop edi
pop esi
pop ebx
call fcn.10009684
mov esp, ebp
pop ebp
ret