Function at 0x1004ffb0
Capabilities:
Enumerate pe sections

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x14
push ebx
mov ebx, eax
mov eax, dword [ebp + 0x10]
push esi
push edi
mov dword [esp + 0x1c], eax
mov dword [esp + 0x18], ebx
test eax, eax
jle 0x100502c2
mov edi, dword [ebp + 8]
dec dword [ebp + 0x10]
cmp dword [edi + 0x10], 0
je 0x100502c2
cmp ebx, 1
jl 0x100502c9
mov ecx, dword [ebp + 0x14]
mov eax, ebx
mov edx, edi
call fcn.1004fec0
test eax, eax
jne 0x100502c2
mov ecx, dword [edi + 4]
mov dword [esp + 0x10], ecx
test ebx, ebx
je 0x10050293
mov esi, dword [ecx + 0x28]
test esi, esi
jne 0x10050107
mov edi, dword [ecx + 0xa8]
lea eax, [esp + 0xc]
push eax
push 1
push ebx
call fcn.10040200
mov edi, dword [ebp + 8]
mov ecx, dword [esp + 0x1c]
mov esi, eax
add esp, 0xc
test esi, esi
jne 0x10050107
mov edi, dword [esp + 0xc]
cmp dword [edi + 0x10], eax
jne 0x10050124
mov dword [edi + 0x10], ecx
cmp ebx, 0x7fffffff
ja 0x100500af
mov eax, dword [0x100cc4a4]
mov esi, dword [ecx + 0x80]
cdq
idiv esi
inc eax
cmp ebx, eax
je 0x100500af
cmp byte [ecx + 0xd], 0
jne 0x10050090
cmp dword [ecx + 0x18], ebx
jb 0x10050090
mov edx, dword [ecx + 0x3c]
cmp dword [edx], 0
je 0x10050090
mov eax, edi
call fcn.10042ed0
mov esi, eax
test esi, esi
je 0x10050124
jmp 0x100500d0
cmp ebx, dword [ecx + 0x84]
jbe 0x1005009f
mov esi, 0xd
jmp 0x100500d0
mov eax, dword [edi]
push esi
push 0
push eax
call sub.MSVCR90.dll_memset
add esp, 0xc
jmp 0x10050124
push 0x100ba064
push 0x989f
push str.database_corruption_at_line__d_of___.10s_
mov eax, 0xb
call fcn.1003c0c0
add esp, 0xc
mov esi, 0xb
test byte [edi + 0x14], 2
je 0x100500dd
mov eax, edi
call fcn.10040160
mov eax, dword [edi + 0x18]
dec dword [eax + 0xc]
cmp dword [edi + 0xc], 1
jne 0x100500f0
mov dword [eax + 0x2c], 0
mov ecx, dword [eax + 0x28]
push 1
push edi
push ecx
call dword [0x100cc440]
mov edi, dword [ebp + 8]
mov ecx, dword [esp + 0x1c]
add esp, 0xc
push ecx
call fcn.10044680
add esp, 4
mov dword [esp + 0xc], 0
test esi, esi
jne 0x100502af
mov edi, dword [esp + 0xc]
cmp dword [ebp + 0xc], 0
mov ecx, dword [edi]
mov dword [esp + 0x10], ecx
je 0x10050217
movzx esi, byte [ecx + 4]
movzx edx, byte [ecx + 5]
movzx eax, byte [ecx + 6]
shl esi, 8
or esi, edx
movzx edx, byte [ecx + 7]
shl esi, 8
or esi, eax
mov eax, dword [ebp + 8]
shl esi, 8
or esi, edx
mov edx, dword [eax]
cmp byte [edx + 0x14], 0
je 0x1005017b
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp + 8]
push eax
push 0
mov al, 2
mov edi, ebx
call fcn.1004ff20
mov edi, dword [esp + 0x14]
mov ecx, dword [esp + 0x18]
add esp, 8
mov edx, dword [ebp + 8]
mov eax, dword [edx]
mov eax, dword [eax + 0x24]
cdq
and edx, 3
add eax, edx
sar eax, 2
sub eax, 2
cmp esi, eax
jle 0x100501af
mov esi, dword [ebp + 8]
push ebx
mov ebx, dword [ebp + 0x14]
push str.freelist_leaf_count_too_big_on_page__d
call fcn.1004fe50
add esp, 8
dec dword [ebp + 0x10]
jmp 0x10050241
test esi, esi
jle 0x10050212
lea ebx, [ecx + 0xa]
mov dword [esp + 0x14], esi
movzx edi, byte [ebx - 2]
movzx ecx, byte [ebx - 1]
movzx edx, byte [ebx]
movzx eax, byte [ebx + 1]
shl edi, 8
or edi, ecx
mov ecx, dword [ebp + 8]
shl edi, 8
or edi, edx
mov edx, dword [ecx]
shl edi, 8
or edi, eax
cmp byte [edx + 0x14], 0
je 0x100501f3
mov eax, dword [ebp + 0x14]
push eax
push 0
mov al, 2
call fcn.1004ff20
add esp, 8
mov ecx, dword [ebp + 0x14]
mov edx, dword [ebp + 8]
mov eax, edi
call fcn.1004fec0
add ebx, 4
sub dword [esp + 0x14], 1
jne 0x100501ba
mov edi, dword [esp + 0xc]
mov ecx, dword [esp + 0x10]
sub dword [ebp + 0x10], esi
jmp 0x10050249
mov edx, dword [ebp + 8]
mov eax, dword [edx]
cmp byte [eax + 0x14], 0
je 0x10050249
cmp dword [ebp + 0x10], 0
jle 0x10050249
mov edx, dword [ebp + 0x14]
push edx
push ebx
call fcn.1003d640
mov ecx, dword [ebp + 8]
mov edi, eax
mov al, 4
call fcn.1004ff20
add esp, 8
mov ecx, dword [esp + 0x10]
mov edi, dword [esp + 0xc]
movzx ebx, byte [ecx]
movzx eax, byte [ecx + 1]
movzx edx, byte [ecx + 2]
mov esi, dword [edi + 0x10]
shl ebx, 8
or ebx, eax
movzx eax, byte [ecx + 3]
shl ebx, 8
or ebx, edx
shl ebx, 8
or ebx, eax
mov eax, edi
call fcn.10040370
mov ecx, dword [esi + 0xa8]
cmp dword [ecx + 0xc], 0
jne 0x10050282
call fcn.100424c0
cmp dword [ebp + 0x10], 0
jg 0x1004ffd1
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0x100ba064
push 0x9878
push str.database_corruption_at_line__d_of___.10s_
mov eax, 0xb
call fcn.1003c0c0
add esp, 0xc
push ebx
mov ebx, dword [ebp + 0x14]
push str.failed_to_get_page__d
mov esi, edi
call fcn.1004fe50
add esp, 8
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
mov ecx, dword [ebp + 0x10]
mov ebx, dword [ebp + 0x14]
push edx
push eax
inc ecx
push ecx
push str._d_of__d_pages_missing_from_overflow_list_starting_at__d
mov esi, edi
call fcn.1004fe50
add esp, 0x10
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret