Function at 0x10040d40
Capabilities:
Inspect section memory permissions

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1596dfe
mov eax, dword fs:[0]
push eax
sub esp, 0x84
push ebx
push esi
mov eax, dword [0x15d0020]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, 8
shl eax, 2
mov ecx, dword [0x15d2a5c]
mov edx, dword [0x15d2a5c]
mov esi, dword [0x15d2a5c]
mov ebx, dword [esi + 0x84]
xor ebx, dword [edx + 0x44]
xor ebx, dword [ecx + eax]
and ebx, 0x10000
neg ebx
sbb ebx, ebx
neg ebx
movzx eax, bl
test eax, eax
je 0x10040dab
or eax, 0xffffffff
jmp 0x1004106f
call fcn.10042cd0
mov ecx, dword [0x15d5848]
and ecx, 1
jne 0x10040def
mov edx, dword [0x15d5848]
or edx, 1
mov dword [0x15d5848], edx
mov dword [ebp - 4], 0
mov ecx, 0x15d5838
call fcn.10043e90
push 0x15a6d10
call fcn.100d53df
add esp, 4
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp + 8]
mov dword [ebp - 0x14], eax
mov ecx, dword [ebp + 0xc]
mov dword [ebp - 0x10], ecx
movzx edx, byte [ebp + 0x10]
test edx, edx
jne 0x10040e4f
lea eax, [ebp - 0x14]
push eax
lea ecx, [ebp - 0x24]
push ecx
mov ecx, 0x15d5838
call fcn.10044080
mov edx, dword [eax]
mov dword [ebp - 0x20], edx
mov eax, dword [0x15d583c]
mov dword [ebp - 0x54], eax
mov ecx, dword [ebp - 0x54]
mov dword [ebp - 0x28], ecx
mov edx, dword [ebp - 0x20]
xor eax, eax
cmp edx, dword [ebp - 0x28]
sete al
movzx ecx, al
neg ecx
sbb ecx, ecx
add ecx, 1
movzx edx, cl
test edx, edx
je 0x10040e4f
mov eax, dword [ebp - 0x20]
mov eax, dword [eax + 0x14]
jmp 0x1004106f
mov dword [ebp - 0x1c], 0xffffffff
mov byte [ebp - 0x15], 0
cmp dword [ebp + 8], 0
je 0x10040e6b
mov ecx, dword [ebp + 8]
and ecx, 0x480001ff
je 0x10040e6f
mov byte [ebp - 0x15], 1
mov edx, dword [ebp + 8]
and edx, 0x200
je 0x10040e98
mov ecx, 0x15d2410
call fcn.10041160
movzx eax, al
test eax, eax
je 0x10040e93
call fcn.10091e70
mov dword [ebp - 0x1c], eax
jmp 0x10041040
mov ecx, dword [ebp + 8]
and ecx, 0x20000000
je 0x10040ec6
mov ecx, 0x15d2410
call fcn.10041080
movzx edx, al
test edx, edx
je 0x10040ec1
push 1
call fcn.10091000
add esp, 4
mov dword [ebp - 0x1c], eax
jmp 0x10041040
mov eax, dword [ebp + 8]
and eax, 0x400
je 0x10040ef6
movzx ecx, byte [ebp + 0x10]
test ecx, ecx
jne 0x10040ee9
mov ecx, 0x15d2410
call fcn.100410f0
movzx edx, al
test edx, edx
je 0x10040ef1
call fcn.100548a0
mov dword [ebp - 0x1c], eax
jmp 0x10041040
mov eax, dword [ebp + 8]
and eax, 1
je 0x10040f0d
mov ecx, dword [ebp - 0x1c]
push ecx
call fcn.100411d0
add esp, 4
mov dword [ebp - 0x1c], eax
mov edx, dword [ebp + 8]
and edx, 2
je 0x10040f26
push 1
mov eax, dword [ebp - 0x1c]
push eax
call fcn.10041550
add esp, 8
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp + 8]
and ecx, 4
je 0x10040f3d
mov edx, dword [ebp - 0x1c]
push edx
call fcn.10041710
add esp, 4
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 8]
and eax, 8
je 0x10040f54
mov ecx, dword [ebp - 0x1c]
push ecx
call fcn.10041860
add esp, 4
mov dword [ebp - 0x1c], eax
mov edx, dword [ebp + 8]
and edx, 0x10
je 0x10040f6d
push 1
mov eax, dword [ebp - 0x1c]
push eax
call fcn.10041950
add esp, 8
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp + 8]
and ecx, 0x20
je 0x10040f86
push 1
mov edx, dword [ebp - 0x1c]
push edx
call fcn.10041b40
add esp, 8
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 8]
and eax, 0x40
je 0x10040fab
call fcn.10042170
cmp dword [ebp + 0xc], eax
jge 0x10040fab
mov ecx, dword [ebp + 0xc]
push ecx
mov edx, dword [ebp - 0x1c]
push edx
call fcn.10042910
add esp, 8
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 8]
and eax, 0x80
je 0x10040fc4
mov ecx, dword [ebp - 0x1c]
push ecx
call fcn.10042940
add esp, 4
mov dword [ebp - 0x1c], eax
mov edx, dword [ebp + 8]
and edx, 0x8000000
je 0x10040fde
mov eax, dword [ebp - 0x1c]
push eax
call fcn.10042a50
add esp, 4
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp + 8]
and ecx, 0x100
je 0x10041025
mov edx, 8
shl edx, 2
mov eax, dword [0x15d2a5c]
mov ecx, dword [0x15d2a5c]
mov esi, dword [0x15d2a5c]
mov esi, dword [esi + 0x84]
xor esi, dword [ecx + 0x44]
xor esi, dword [eax + edx]
and esi, 0x1000
je 0x10041025
mov edx, dword [ebp - 0x1c]
push edx
call fcn.10042c20
add esp, 4
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp + 8]
and eax, 0x40000000
je 0x10041040
push 0
mov ecx, dword [ebp - 0x1c]
push ecx
call fcn.10041950
add esp, 8
mov dword [ebp - 0x1c], eax
cmp dword [ebp - 0x1c], 0
jne 0x10041059
mov eax, dword [ebp + 8]
and eax, 0x20000400
jne 0x10041059
mov ecx, dword [ebp - 0x1c]
add ecx, 1
mov dword [ebp - 0x1c], ecx
lea edx, [ebp - 0x14]
push edx
mov ecx, 0x15d5838
call fcn.10043f00
mov ecx, dword [ebp - 0x1c]
mov dword [eax], ecx
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret