Function at 0x4099c0
Capabilities:
Inspect section memory permissions

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x60
mov eax, dword [ebp + 8]
push esi
push edi
mov edi, dword [eax]
xor esi, esi
cmp byte [edi + 0x1c], 0
mov dword [ebp - 8], edi
je 0x4099e3
pop edi
mov eax, 0x3e3
pop esi
mov esp, ebp
pop ebp
ret
mov eax, dword [edi + 0xc]
push ebx
mov ebx, dword [eax]
mov dword [ebp - 0x18], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 4], ebx
cmp eax, esi
jne 0x409a00
mov ecx, 1
mov dword [ebp - 0xc], ecx
jmp 0x409a0a
mov ecx, dword [eax]
mov dword [ebp - 0xc], ecx
mov ecx, 1
mov dword [ebp - 0x14], esi
cmp dword [ebp - 0xc], esi
jbe 0x40a005
jmp 0x409a20
mov eax, dword [ebp + 0xc]
cmp eax, 7
ja case.default.0x409a2c
jmp dword [eax*4 + 0x40a010]
mov edx, dword [edi + 0x14]
mov ecx, dword [ebp + 8]
mov edx, dword [edx + 0xc]
lea eax, [ebp - 0x40]
push eax
push ecx
call edx
mov esi, eax
add esp, 8
test esi, esi
jne 0x409ff9
test byte [ebp - 0x3c], 0xe0
jne case.default.0x409a2c
mov eax, dword [ebp - 0x40]
mov edx, ebx
call fcn.00406ea0
test eax, eax
jne case.default.0x409a2c
mov eax, dword [ebp - 8]
push eax
call fcn.004081f0
mov ebx, eax
xor eax, eax
mov ecx, 8
lea esi, [ebp - 0x40]
mov edi, ebx
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [ebp - 4]
push eax
push ecx
mov dword [ebx + 0x44], 0x80000000
mov dword [ebx + 0x10], eax
mov dword [ebx + 0x14], eax
mov dword [ebx + 0x48], eax
mov dword [ebx + 0x4c], eax
call fcn.00406cb0
mov edi, dword [ebp - 8]
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x409abe
mov edx, dword [edi + 0xc]
push ebx
push eax
push edx
call fcn.00400f70
add esp, 0xc
mov esi, eax
mov eax, esi
sub eax, 0
je 0x409af2
dec eax
jne 0x409fd5
mov ecx, dword [ebx]
mov edx, dword [ebp + 8]
lea eax, [ebp - 0x10]
push eax
push ecx
push 8
push edx
mov dword [ebp - 0x10], 1
call fcn.00409300
mov esi, eax
add esp, 0x10
test esi, esi
jne 0x409fd5
add edi, 0x30
push edi
add ebx, 0x30
push ebx
call fcn.00406fd0
add esp, 8
jmp 0x409fde
mov eax, dword [edi + 0x14]
mov edx, dword [ebp + 8]
mov eax, dword [eax + 0xc]
lea ecx, [ebp - 0x40]
push ecx
push edx
call eax
mov esi, eax
add esp, 8
test esi, esi
jne 0x409ff9
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 4]
call fcn.00406ea0
mov ebx, eax
test ebx, ebx
je case.default.0x409a2c
mov ecx, dword [ebp + 8]
cmp dword [ebx + 0x3c], ecx
jne case.default.0x409a2c
mov edx, dword [edi + 0xc]
push ebx
push 4
push edx
call fcn.00400f70
add esp, 0xc
mov esi, eax
sub eax, 0
je 0x409b8b
dec eax
jne 0x409fe1
mov ecx, dword [ebx]
mov edx, dword [ebp + 8]
lea eax, [ebp - 0x10]
push eax
push ecx
push 0x80000008
push edx
mov dword [ebp - 0x10], 1
call fcn.00409300
mov esi, eax
add esp, 0x10
test esi, esi
jne 0x409ff9
lea eax, [ebx + 0x20]
push eax
call fcn.00407000
mov ecx, dword [ebp - 4]
push 0
push ecx
mov eax, ebx
call fcn.00406df0
lea edx, [ebx + 0x30]
push edx
mov dword [ebx + 0x44], 0
call fcn.00407000
add esp, 0x10
mov eax, ebx
mov ecx, edi
call fcn.004084c0
jmp 0x409fe1
mov eax, dword [edi + 0x14]
mov edx, dword [ebp + 8]
mov eax, dword [eax + 0xc]
lea ecx, [ebp - 0x40]
push ecx
push edx
call eax
mov esi, eax
add esp, 8
test esi, esi
jne 0x409ff9
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 4]
call fcn.00406ea0
mov ebx, eax
test ebx, ebx
je case.default.0x409a2c
mov ecx, dword [edi + 0xc]
push ebx
push 1
push ecx
call fcn.00400f70
mov esi, eax
add esp, 0xc
cmp esi, 1
jne 0x409c27
mov dl, byte [ebx + 4]
and dl, 0x90
cmp dl, 0x10
je case.default.0x409a2c
or dword [ebx + 0x44], 0x20000000
xor esi, esi
jmp 0x409f19
test esi, esi
jne 0x409ff9
or dword [ebx + 0x44], 0x4000000
jmp 0x409f19
mov eax, dword [edi + 0x14]
mov edx, dword [ebp + 8]
mov eax, dword [eax + 0xc]
lea ecx, [ebp - 0x40]
push ecx
push edx
call eax
mov esi, eax
add esp, 8
test esi, esi
jne 0x409ff9
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 4]
call fcn.00406ea0
mov ebx, eax
test ebx, ebx
je case.default.0x409a2c
mov ecx, dword [edi + 0xc]
push ebx
push 2
push ecx
call fcn.00400f70
mov esi, eax
add esp, 0xc
cmp esi, 1
jne 0x409c91
and dword [ebx + 0x44], 0xdfffffff
xor esi, esi
jmp 0x409f19
test esi, esi
jne 0x409ff9
and dword [ebx + 0x44], 0xfbffffff
jmp 0x409f19
mov edx, dword [edi + 0x14]
mov ecx, dword [ebp + 8]
mov edx, dword [edx + 0xc]
lea eax, [ebp - 0x40]
push eax
push ecx
call edx
mov esi, eax
add esp, 8
test esi, esi
jne 0x409ff9
mov eax, dword [ebp - 0x40]
mov edx, ebx
call fcn.00406ea0
mov esi, eax
test esi, esi
je case.default.0x409a2c
mov al, byte [esi + 4]
mov dl, byte [ebp - 0x3c]
and al, 0x90
xor ecx, ecx
cmp al, 0x10
sete cl
and dl, 0x90
xor eax, eax
cmp dl, 0x10
sete al
cmp eax, ecx
jne case.default.0x409a2c
mov ecx, dword [esi + 0x58]
mov ebx, dword [esi + 0x5c]
push ecx
lea edx, [ebp - 0x38]
push edx
lea eax, [esi + 8]
push eax
call fcn.00401870
mov ecx, 8
sub ecx, ebx
push ecx
lea edx, [ebp + ebx - 0x38]
push edx
lea eax, [ebx + esi + 8]
push eax
call fcn.00401870
mov cl, byte [ebp - 0x3c]
push esi
mov byte [esi + 4], cl
mov edx, dword [edi + 0xc]
push 3
push edx
call fcn.00400f70
mov esi, eax
add esp, 0x24
cmp esi, 1
jne 0x409fe1
xor esi, esi
jmp 0x409f19
mov eax, dword [edi + 0x14]
mov edx, dword [ebp + 8]
mov eax, dword [eax + 0x10]
lea ecx, [ebp - 0x60]
push ecx
push edx
call eax
mov esi, eax
add esp, 8
test esi, esi
jne 0x409ff9
mov eax, dword [ebp - 0x60]
mov edx, ebx
call fcn.00406ea0
test eax, eax
je case.default.0x409a2c
cmp dword [ebx + 0x474], esi
je 0x409dac
mov ecx, dword [eax + 0x44]
test ecx, 0x8000000
je 0x409fed
test byte [ebp - 0x5c], 2
je 0x409da1
or ecx, 2
mov dword [eax + 0x44], ecx
jmp 0x409e3b
and ecx, 0xfffffffd
mov dword [eax + 0x44], ecx
jmp 0x409e3b
mov cl, byte [eax + 4]
and cl, 0x90
cmp cl, 0x10
jne 0x409dc4
test dword [eax + 0x44], 0xf00
jne case.default.0x409a2c
mov esi, dword [ebp - 0x50]
mov edx, esi
or edx, dword [ebp - 0x4c]
je 0x409dee
mov ecx, dword [ebx + 0x24]
mov edx, dword [ebx + 0x20]
shrd edx, ecx, 0xf
shr ecx, 0xf
cmp dword [ebp - 0x4c], ecx
jb case.default.0x409a2c
ja 0x409dee
cmp esi, edx
jb case.default.0x409a2c
xor ecx, ecx
mov word [eax + 0x44], cx
mov edx, dword [ebp - 0x5c]
and edx, 0xffff
or edx, 0x8000000
or dword [eax + 0x44], edx
mov ecx, dword [ebp - 0x58]
sub ecx, dword [ebx + 0x480]
mov edx, dword [ebp - 0x54]
sbb edx, dword [ebx + 0x484]
mov dword [eax + 0x10], ecx
mov dword [eax + 0x14], edx
mov ecx, dword [ebp - 0x50]
mov dword [eax + 0x48], ecx
mov edx, dword [ebp - 0x4c]
mov dword [eax + 0x4c], edx
mov ecx, dword [ebp - 0x48]
mov dword [eax + 0x50], ecx
mov edx, dword [ebp - 0x44]
mov dword [eax + 0x54], edx
call fcn.00406b30
mov ecx, dword [edi + 0xc]
lea eax, [ebp - 0x60]
push eax
push 5
push ecx
call fcn.00400f70
mov esi, eax
add esp, 0xc
cmp esi, 1
jne 0x409fe4
xor esi, esi
jmp 0x409f1c
cmp dword [ebx + 0x474], 0
mov dword [ebp - 0xc], ecx
jne 0x409fed
mov edx, dword [ebp + 8]
push 0
mov dword [ebx + 0x474], edx
mov eax, dword [edi + 0xc]
push 6
push eax
call fcn.00400f70
mov esi, eax
add esp, 0xc
cmp esi, 1
jne 0x409fe4
mov edx, dword [ebp + 8]
mov eax, dword [edx + 8]
lea ecx, [ebp - 0x20]
push ecx
push eax
xor esi, esi
call fcn.00400f20
mov edi, dword [ebp - 8]
mov ebx, dword [edi + 0x30]
add edi, 0x30
add esp, 8
mov dword [ebp - 0x10], esi
cmp edi, ebx
je 0x409f16
test ebx, ebx
je 0x409f16
lea esp, [esp]
mov ecx, dword [ebx + 8]
mov eax, dword [ecx + 0x44]
test eax, 0x8000000
je 0x409ef4
or eax, 0x40000000
mov dword [ecx + 0x44], eax
test al, 1
jne 0x409ee5
mov edx, dword [ebp - 0x20]
add dword [ecx + 0x10], edx
mov eax, dword [ebp - 0x1c]
adc dword [ecx + 0x14], eax
mov eax, dword [ebp - 4]
push ecx
call fcn.004080f0
add esp, 4
add dword [ebp - 0x10], eax
mov ebx, dword [ebx]
cmp edi, ebx
je 0x409efe
test ebx, ebx
jne 0x409ec0
cmp dword [ebp - 0x10], esi
je 0x409f16
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x20]
mov ebx, dword [ebp - 0x18]
push ecx
push edx
call fcn.00409950
add esp, 8
mov edi, dword [ebp - 8]
mov ebx, dword [ebp - 4]
mov eax, dword [ebp - 0x14]
inc eax
mov dword [ebp - 0x14], eax
cmp eax, dword [ebp - 0xc]
jae 0x40a005
mov ecx, 1
jmp 0x409a20
mov eax, dword [ebp + 8]
mov dword [ebp - 0xc], ecx
cmp eax, dword [ebx + 0x474]
jne case.default.0x409a2c
push 0
mov dword [ebx + 0x474], 0
mov ecx, dword [edi + 0xc]
push 7
push ecx
call fcn.00400f70
mov esi, eax
add esp, 0xc
cmp esi, 1
jne 0x409fe4
mov eax, dword [edi + 0x30]
lea edx, [edi + 0x30]
xor esi, esi
cmp edx, eax
je 0x409f94
test eax, eax
je 0x409f94
lea esp, [esp]
mov ecx, dword [eax + 8]
and dword [ecx + 0x44], 0xb7ffffff
mov eax, dword [eax]
cmp edx, eax
je 0x409f94
test eax, eax
jne 0x409f80
lea edi, [ebx + 0x34]
mov ebx, dword [ebp + 8]
lea ebx, [ebx]
mov eax, dword [edi]
cmp edi, eax
je 0x409f16
test eax, eax
je 0x409f16
mov ecx, dword [eax + 8]
test dword [ecx + 0x44], 0x80000000
je 0x409fa0
cmp dword [ecx + 0x3c], ebx
jne 0x409fa0
mov ecx, dword [eax]
test ecx, ecx
je 0x409fa0
mov edx, dword [eax + 4]
mov dword [edx], ecx
mov dword [ecx + 4], edx
mov dword [eax], esi
jmp 0x409fa0
mov eax, ebx
mov ecx, edi
call fcn.004084c0
mov edi, dword [ebp - 8]
mov ebx, dword [ebp - 4]
test esi, esi
jne 0x409ff9
jmp 0x409f1c
mov esi, 0xe0000006
jmp 0x409ff9
mov esi, 0x57
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x40a005
mov edx, dword [ebp - 0x14]
mov dword [eax], edx
pop ebx
pop edi
mov eax, esi
pop esi
mov esp, ebp
pop ebp
ret