Function at 0x10001f80
Capabilities:
Enumerate pe sections
Inspect section memory permissions

Disassembly:
sub esp, 0x18
mov edx, dword [ebx + 8]
push ebp
mov ebp, dword [esp + 0x20]
mov ecx, dword [ebp + 0x28]
push esi
xor eax, eax
push ebp
push ebx
mov dword [esp + 0x14], eax
mov dword [esp + 0x1c], ecx
mov dword [esp + 0x24], edx
mov byte [esp + 0x2c], al
mov dword [esp + 0x20], eax
call fcn.10004dd0
mov esi, eax
add esp, 8
test esi, esi
je 0x100021be
cmp dword [ebp + 0x18], 1
jne 0x10001fe9
mov eax, dword [ebp]
test eax, 0x2000
je 0x10001fe9
cmp dword [ebp + 0x20], 0
jne 0x10001fe9
test byte [esp + 0x14], 8
je 0x10001fe9
and eax, 0xffffdfff
push 3
push ebp
mov dword [ebp], eax
call fcn.10004630
add esp, 8
mov eax, dword [ebx + 0x10]
cmp eax, 2
jne 0x10002002
test dword [esi + 8], 0x800000
jne 0x100021be
cmp eax, eax
je 0x1000200f
test dword [esi + 8], 0x8000000
jne 0x100021be
mov ecx, dword [esi + 8]
test cl, 1
je 0x10002061
not ecx
test ecx, 0x40000000
je 0x1000202f
add dword [ebx + 8], 1
add dword [ebx + 0xc], 0xffffffff
js 0x100021be
mov ecx, dword [ebx + 8]
movzx edx, byte [ecx]
mov ecx, dword [esi + 8]
test ecx, 0x10000000
mov dword [esp + 0xc], edx
je 0x1000204d
test dl, 0x38
jne 0x100021be
test ecx, 0x100000
je 0x10002061
cmp edx, 0xc0
jb 0x100021be
mov edx, dword [esp + 0x14]
add dword [ebx + 8], 1
mov ecx, dword [ebp]
push edx
mov edx, dword [esi + 8]
call fcn.10001f40
mov dword [esp + 0x14], eax
mov eax, dword [ebx + 0x10]
add esp, 4
test ecx, 0x4000
mov dword [esp + 8], eax
je 0x10002096
mov eax, dword [eax*4 + 0x10024024]
mov dword [esp + 8], eax
push 0x38
push 0
push edi
call fcn.10005570
mov byte [edi + 9], 0xff
mov al, byte [esi + 3]
add esp, 0xc
test al, al
je 0x10002178
mov edx, dword [esp + 8]
lea ecx, [esp + 0x18]
push ecx
mov ecx, dword [esp + 0x14]
push edx
mov edx, dword [esp + 0x14]
push ecx
push ebp
push edx
push 0
movzx eax, al
push eax
push esi
push edi
push ebx
call fcn.10003270
add esp, 0x28
test eax, eax
je 0x100021be
mov al, byte [esi + 2]
test al, al
je 0x10002178
mov ecx, dword [esp + 8]
mov edx, dword [esp + 0x10]
push 0
push ecx
mov ecx, dword [esp + 0x14]
push edx
push ebp
push ecx
push 1
movzx edx, al
push edx
push esi
push edi
push ebx
call fcn.10003270
add esp, 0x28
test eax, eax
je 0x100021be
test dword [esi + 8], 0x20000
je 0x10002178
mov eax, dword [esp + 8]
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0xc]
push 0
push eax
movzx eax, byte [esi + 0x10]
push ecx
push ebp
push edx
push 2
push eax
push esi
push edi
push ebx
call fcn.10003270
add esp, 0x28
test eax, eax
je 0x100021be
test dword [esi + 8], 0x40000
je 0x10002178
mov ecx, dword [esp + 8]
mov edx, dword [esp + 0x10]
mov eax, dword [esp + 0xc]
push 0
push ecx
movzx ecx, byte [esi + 0x11]
push edx
push ebp
push eax
push 3
push ecx
push esi
push edi
push ebx
call fcn.10003270
add esp, 0x28
test eax, eax
je 0x100021be
test dword [esi + 8], 0x200000
je 0x10002190
push ebx
call fcn.100050d0
mov esi, eax
add esp, 4
test esi, esi
je 0x100021be
test dword [esi + 8], 0x400000
je 0x100021b3
add dword [ebx + 0xc], 0xffffffff
js 0x100021be
mov eax, dword [ebx + 8]
mov cl, byte [eax]
add eax, 1
cmp cl, 8
mov byte [esp + 0x24], cl
mov dword [ebx + 8], eax
jae 0x100021be
mov edx, dword [ebx + 8]
sub edx, dword [ebp + 8]
cmp edx, 0xf
jle 0x10002203
push 0x38
push 0
push edi
call fcn.10005570
mov eax, dword [esp + 0x28]
mov byte [edi + 9], 0xff
mov byte [edi + 4], 1
add esp, 0xc
mov dword [ebp + 4], 0
cmp byte [eax], 0x9b
jne 0x100021f8
or byte [edi + 0x32], 8
pop esi
mov word [edi + 0xc], 0x3db
mov eax, 1
pop ebp
add esp, 0x18
ret
pop esi
mov eax, 3
pop ebp
add esp, 0x18
ret
mov edx, 1
cmp dword [esp + 0x18], edx
jne 0x1000221e
test byte [esi + 8], 0x10
je 0x1000221e
or dword [ebp + 4], 0x10
or word [edi + 6], dx
jmp 0x10002249
mov eax, dword [esi + 8]
test al, 0x20
je 0x10002236
test byte [ebp], 0x20
je 0x10002236
or dword [ebp + 4], 0x20
or word [edi + 6], 2
jmp 0x10002249
test al, 0x40
je 0x10002249
test byte [ebp], 0x40
je 0x10002249
or dword [ebp + 4], 0x40
or word [edi + 6], 4
mov eax, dword [esi + 8]
mov ecx, eax
and ecx, 0x14000
cmp ecx, 0x14000
jne 0x1000228d
mov eax, dword [esp + 8]
or dword [ebp + 4], 0x4000
test eax, eax
je 0x10002369
cmp eax, edx
jne 0x10002280
mov ax, word [esi + 0x12]
mov word [edi + 0xc], ax
jmp 0x10002371
mov cx, word [esi + 0x14]
mov word [edi + 0xc], cx
jmp 0x10002371
mov ecx, eax
and ecx, 0xc000
cmp ecx, 0xc000
jne 0x100022b1
mov dx, word [esi + 4]
mov word [edi + 0xc], dx
or dword [ebp + 4], 0x4000
jmp 0x10002371
mov ecx, dword [esp + 0x10]
test ecx, ecx
jne 0x100022db
test eax, 0x10000
je 0x100022ce
test eax, 0x1000008
jne 0x100022ce
or dword [ebp + 4], 0x2000
mov ax, word [esi + 4]
mov word [edi + 0xc], ax
jmp 0x10002371
cmp ecx, edx
jne 0x10002330
or word [edi + 6], 0x100
test dword [esi + 8], 0x10000
je 0x10002369
or dword [ebp + 4], 0x2000
mov eax, dword [esi + 8]
test eax, 0x80000
je 0x10002319
cmp dword [esp + 0xc], 0xc0
jb 0x10002313
mov cx, word [esi + 4]
mov word [edi + 0xc], cx
jmp 0x10002371
mov dx, word [esi + 0x12]
jmp 0x1000236d
test eax, 0x400000
je 0x1000235f
movzx ax, byte [esp + 0x24]
add ax, word [esi + 4]
mov word [edi + 0xc], ax
jmp 0x10002371
or word [edi + 6], 0x200
mov eax, dword [esi + 8]
test eax, 0x4010000
je 0x10002369
test eax, 0x4000000
je 0x1000235f
test byte [esp + 0x14], 8
je 0x1000235f
or dword [ebp + 4], 0x2000000
mov ax, word [esi + 0x14]
mov word [edi + 0xc], ax
jmp 0x10002371
mov cx, word [esi + 0x12]
mov word [edi + 0xc], cx
jmp 0x10002371
mov dx, word [esi + 4]
mov word [edi + 0xc], dx
test dword [esi + 8], 0x8000
je 0x1000238a
test dword [ebp], 0x2000
je 0x1000238a
or dword [ebp + 4], 0x2000
test dword [esi + 8], 0x20000000
je 0x100023b4
mov eax, dword [esi + 0xc]
test al, 4
je 0x100023a1
test byte [esp + 0x14], 8
jne 0x100023ac
test al, 8
je 0x100023b4
test byte [esp + 0x14], 0x10
je 0x100023b4
mov ax, word [esi + 0x12]
mov word [edi + 0xc], ax
mov eax, dword [esp + 8]
and eax, 3
shl eax, 0xa
or word [edi + 6], ax
test dword [esi + 8], 0x80000000
movzx eax, word [edi + 6]
je 0x100023d6
or eax, 0x40
mov word [edi + 6], ax
push ebp
call fcn.100046c0
mov word [edi + 0x30], ax
mov cl, byte [esi + 1]
add esp, 4
cmp byte [edi + 8], 0
mov byte [edi + 0x32], cl
jne 0x100023f3
mov byte [edi + 8], 0xff
mov al, byte [edi + 9]
cmp al, 0xff
je 0x10002409
movzx edx, al
mov ax, word [edx*2 + 0x10024850]
or word [edi + 0x34], ax
mov cl, byte [ebx + 8]
sub cl, byte [esp + 0x1c]
pop esi
mov byte [edi + 4], cl
mov eax, 1
pop ebp
add esp, 0x18
ret