Function at 0x1003b840
Capabilities:
Allocate or change rwx memory
Check for software breakpoints
Hook routines via microsoft detours

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x38
mov eax, dword [0x10195134]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
mov esi, edx
mov ebx, ecx
xor edi, edi
mov dword [ebp - 0x30], ebx
test esi, esi
jne 0x1003b876
pop edi
pop esi
lea eax, [edx + 0x57]
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.100da971
mov esp, ebp
pop ebp
ret 0xc
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
cmp dword [0x1019a670], eax
je 0x1003b89c
pop edi
pop esi
mov eax, 0x10dd
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.100da971
mov esp, ebp
pop ebp
ret 0xc
mov eax, dword [0x1019a62c]
test eax, eax
jne 0x1003bca7
test ebx, ebx
je 0x1003b8c3
mov ecx, dword [ebx]
test ecx, ecx
jne 0x1003b8db
mov dword [0x1019a62c], 6
mov dword [0x1019a678], ebx
pop edi
pop esi
mov eax, 6
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.100da971
mov esp, ebp
pop ebp
ret 0xc
xor eax, eax
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x28], eax
call fcn.1003b280
mov ebx, eax
mov ecx, esi
mov dword [ebp - 0x24], ebx
call fcn.1003b280
mov dword [ebp - 0x38], eax
cmp eax, ebx
jne 0x1003b90c
cmp dword [0x10199858], edi
jne 0x1003bc9d
jmp 0x1003bc60
push 0x18
call fcn.100da9b5
mov dword [ebp - 0x28], eax
lea edx, [ebp - 0x18]
lea eax, [ebp - 0x1c]
mov ecx, ebx
push eax
call fcn.1003ade0
mov ecx, dword [0x1019a674]
add esp, 8
mov edi, dword [ebp - 0x1c]
mov ebx, dword [ebp - 0x18]
mov eax, dword [0x1019a67c]
test ecx, ecx
jne 0x1003b948
test eax, eax
je 0x1003b95b
mov ecx, eax
mov dword [0x1019a674], ecx
mov edx, dword [ecx + 8]
test edx, edx
je 0x1003b95b
cmp edx, ebx
jb 0x1003b95b
cmp edx, edi
jbe 0x1003b9e2
mov ecx, eax
mov dword [0x1019a674], ecx
test eax, eax
je 0x1003b987
test ecx, ecx
je 0x1003b97a
mov eax, dword [ecx + 8]
test eax, eax
je 0x1003b97a
cmp eax, ebx
jb 0x1003b97a
cmp eax, edi
jbe 0x1003b9e2
mov ecx, dword [ecx + 4]
mov dword [0x1019a674], ecx
test ecx, ecx
jne 0x1003b96b
mov ecx, dword [ebp - 0x24]
mov edx, ebx
movzx eax, cx
push edi
sub ecx, eax
call fcn.1003b0e0
mov ecx, eax
add esp, 4
test ecx, ecx
je 0x1003bc5b
mov dword [ecx], 0x52727464
xor edx, edx
mov dword [ecx + 8], 0
mov esi, 0x38b
mov eax, dword [0x1019a67c]
mov dword [ecx + 4], eax
lea eax, [ecx + 0xffa8]
mov dword [0x1019a674], ecx
mov dword [0x1019a67c], ecx
mov dword [eax + 0x40], edx
mov edx, eax
sub eax, 0x48
sub esi, 1
jne 0x1003b9d2
mov dword [ecx + 8], edx
mov edx, dword [ecx + 8]
mov dword [ebp - 0x14], edx
cmp edx, ebx
jb 0x1003bc5b
cmp edx, edi
ja 0x1003bc5b
mov eax, dword [edx + 0x40]
xorps xmm0, xmm0
mov dword [ecx + 8], eax
lea eax, [edx + 0x38]
mov dword [edx], 0xcccccccc
mov dword [edx + 4], 0xcccccccc
mov dword [edx + 8], 0xcccccccc
mov edi, dword [ebp - 0x24]
mov dword [edx + 0xc], 0xcccccccc
mov dword [edx + 0x10], 0xcccccccc
mov dword [edx + 0x14], 0xcccccccc
mov dword [edx + 0x18], 0xcccccccc
mov dword [edx + 0x1c], 0xcccccccc
mov dword [edx + 0x20], 0xcccccccc
mov dword [edx + 0x24], 0xcccccccc
mov dword [edx + 0x28], 0xcccccccc
mov dword [edx + 0x2c], 0xcccccccc
mov dword [edx + 0x30], 0xcccccccc
mov dword [edx + 0x34], 0xcccccccc
mov dword [edx + 0x40], 0xcccccccc
mov dword [edx + 0x44], 0xcccccccc
mov dword [ebp - 0x20], eax
movq qword [eax], xmm0
mov eax, dword [ebp - 0x14]
mov ebx, eax
add eax, 0x1e
mov dword [ebp - 0x2c], edx
mov edx, edi
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x18], 0
lea eax, [ebp - 0xc]
mov dword [ebp - 0xc], 0
push eax
push ecx
push edx
mov ecx, ebx
mov esi, edx
call fcn.1003bcc0
mov edx, eax
mov eax, dword [ebp - 0xc]
sub eax, esi
add eax, edx
add ebx, eax
mov dword [ebp - 0x1c], ebx
mov ebx, edx
mov ah, byte [ebp - 0x1c]
sub ebx, edi
sub ah, byte [ebp - 0x14]
mov cl, bl
mov edi, dword [ebp - 0x20]
and cl, 7
inc dword [ebp - 0x20]
mov al, ah
shl al, 3
or cl, al
mov byte [ebp - 0xd], ah
mov byte [edi], cl
mov ecx, dword [ebp - 0x18]
mov edi, dword [ebp - 0x24]
inc ecx
mov dword [ebp - 0x18], ecx
cmp ecx, 8
jae 0x1003bb47
mov al, byte [esi]
cmp al, 0xeb
je 0x1003bb47
cmp al, 0xe9
je 0x1003bb47
cmp al, 0xe0
je 0x1003bb47
cmp al, 0xc2
je 0x1003bb47
cmp al, 0xc3
je 0x1003bb47
cmp al, 0xcc
je 0x1003bb47
cmp al, 0xf3
jne 0x1003bb3d
cmp byte [esi + 1], 0xc3
je 0x1003bb47
cmp al, 0x26
je 0x1003bb24
cmp al, 0x2e
je 0x1003bb24
cmp al, 0x36
je 0x1003bb24
cmp al, 0x3e
je 0x1003bb24
cmp al, 0x64
je 0x1003bb24
cmp al, 0x65
jne 0x1003bb30
cmp byte [esi + 1], 0xff
jne 0x1003bb30
cmp byte [esi + 2], 0x25
je 0x1003bb47
cmp ebx, 5
jae 0x1003bb79
mov ebx, dword [ebp - 0x1c]
jmp 0x1003ba94
cmp al, 0xff
jne 0x1003bb0c
cmp byte [esi + 1], 0x25
jmp 0x1003bb2e
cmp ebx, 5
jae 0x1003bb70
nop dword [eax]
mov ecx, edx
call fcn.1003ae70
test eax, eax
je 0x1003bc4b
add edx, eax
mov ebx, edx
sub ebx, edi
cmp ebx, 5
jb 0x1003bb50
mov ah, byte [ebp - 0xd]
mov ecx, dword [ebp - 0x18]
cmp ecx, 8
ja 0x1003bc4b
mov esi, dword [ebp - 0x34]
cmp dword [ebp - 0x1c], esi
jbe 0x1003bb82
int3
mov byte [esi], ah
mov eax, dword [ebp - 0x14]
push ebx
push edi
mov byte [eax + 0x36], bl
add eax, 0x20
push eax
call fcn.100dc770
add esp, 0xc
cmp ebx, 0x19
jbe 0x1003bba7
mov edi, 6
jmp 0x1003bc60
mov eax, dword [ebp - 0x14]
lea edx, [ebx + edi]
mov ecx, dword [ebp - 0x38]
mov dword [eax + 0x44], ecx
movzx ecx, byte [esi]
add ecx, eax
mov dword [eax + 0x40], edx
lea eax, [ecx + 5]
mov byte [ecx], 0xe9
sub edx, eax
mov eax, esi
mov dword [ecx + 1], edx
add ecx, 5
sub eax, ecx
xor edx, edx
cmp ecx, esi
cmova eax, edx
test eax, eax
je 0x1003bbe7
push eax
push 0xcc
push ecx
call fcn.100dccf0
add esp, 0xc
lea eax, [ebp - 8]
mov dword [ebp - 8], 0
push eax
push 0x40
push ebx
push edi
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
test eax, eax
jne 0x1003bc0a
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
jmp 0x1003bc60
mov ecx, dword [ebp - 0x28]
mov eax, dword [ebp - 0x30]
mov dword [ecx + 8], eax
mov eax, dword [ebp - 0x14]
mov dword [ecx + 0x10], eax
mov dword [ecx + 0xc], edi
mov dword [ecx + 4], 0
mov eax, dword [ebp - 8]
pop edi
mov dword [ecx + 0x14], eax
mov eax, dword [0x1019a684]
pop esi
mov dword [ecx], eax
xor eax, eax
mov dword [0x1019a684], ecx
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.100da971
mov esp, ebp
pop ebp
ret 0xc
cmp dword [0x10199858], 0
mov edi, 9
jne 0x1003bc66
jmp 0x1003bc60
mov edi, 8
mov dword [0x1019a62c], edi
mov ebx, dword [ebp - 0x2c]
test ebx, ebx
je 0x1003bc8b
push 0x48
push 0
mov esi, ebx
push ebx
and esi, 0xffff0000
call fcn.100dccf0
mov eax, dword [esi + 8]
add esp, 0xc
mov dword [ebx + 0x40], eax
mov dword [esi + 8], ebx
mov eax, dword [ebp - 0x28]
test eax, eax
je 0x1003bc9d
push 0x18
push eax
call fcn.100da9a2
add esp, 8
mov eax, dword [ebp - 0x30]
mov dword [0x1019a678], eax
mov eax, edi
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.100da971
mov esp, ebp
pop ebp
ret 0xc