Function at 0x476510
Capabilities:
Enumerate pe sections

Disassembly:
sub esp, 0x24
mov eax, dword [esp + 0x28]
push ebx
push ebp
push esi
movzx edx, word [eax + 0x18]
mov esi, dword [eax + 0x38]
mov ebp, esi
movzx ecx, byte [eax + 9]
push edi
movzx edi, word [eax + 0x12]
mov eax, dword [eax + 0x34]
mov dword [esp + 0x2c], edx
mov dword [esp + 0x1c], 0
lea edx, [edi + edx*2]
mov dword [esp + 0x10], esi
mov ebx, dword [eax + 0x28]
movzx eax, byte [ecx + esi + 7]
mov dword [esp + 0x24], edx
lea edx, [ecx + esi]
mov dword [esp + 0x28], ebp
mov dword [esp + 0x14], edi
mov dword [esp + 0x18], ebx
mov dword [esp + 0x20], edx
cmp eax, dword [esp + 0x3c]
jg 0x4767ad
movzx edi, byte [edx + 1]
lea ecx, [ebx - 4]
movzx eax, byte [edx + 2]
shl edi, 8
or edi, eax
cmp edi, ecx
jle 0x4765aa
push 0x52b284
push 0x101a3
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.00466a50
add esp, 0x14
mov eax, 0xb
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
test edi, edi
je 0x4767a9
movzx eax, byte [edi + esi]
movzx ebp, byte [edi + esi + 1]
shl eax, 8
or ebp, eax
cmp ebp, ecx
jle 0x4765d9
push 0x101a6
call fcn.004abc10
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
test ebp, ebp
je 0x4765f2
cmp byte [esi + ebp], 0
jne 0x4767a7
cmp byte [esi + ebp + 1], 0
jne 0x4767a7
mov eax, dword [esp + 0x24]
movzx ecx, byte [edi + esi + 2]
add eax, esi
movzx ebx, byte [edx + 5]
mov dword [esp + 0x1c], eax
movzx eax, byte [edi + esi + 3]
shl ecx, 8
or ecx, eax
shl ebx, 8
movzx eax, byte [edx + 6]
or ebx, eax
mov dword [esp + 0x3c], 0
mov dword [esp + 0x28], ecx
mov dword [esp + 0x30], ebx
cmp ebx, edi
jl 0x476641
push 0x101ae
call fcn.004abc10
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
lea eax, [ecx + edi]
test ebp, ebp
je 0x47671d
mov dword [esp + 0x2c], eax
cmp eax, ebp
jle 0x476669
push 0x101b1
call fcn.004abc10
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
movzx edx, byte [esi + ebp + 2]
movzx eax, byte [esi + ebp + 3]
shl edx, 8
or edx, eax
mov dword [esp + 0x3c], edx
lea eax, [edx + ebp]
cmp eax, dword [esp + 0x18]
jle 0x47669a
push 0x101b3
call fcn.004abc10
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
mov eax, ebp
lea esi, [ecx + edx]
sub eax, ecx
sub eax, edi
push eax
mov eax, dword [esp + 0x30]
add eax, dword [esp + 0x14]
push eax
lea eax, [esi + edi]
add eax, dword [esp + 0x18]
push eax
call dword [sym.imp.MSVCRT.dll_memmove]
mov ecx, esi
add esp, 0xc
mov esi, dword [esp + 0x10]
mov dword [esp + 0x28], ecx
add ebx, ecx
mov eax, edi
mov ecx, dword [esp + 0x30]
sub eax, ecx
push eax
mov dword [esp + 0x30], ebx
lea eax, [ecx + esi]
push eax
lea eax, [ebx + esi]
push eax
call dword [sym.imp.MSVCRT.dll_memmove]
mov edx, dword [esp + 0x20]
add esp, 0xc
add edx, esi
cmp edx, dword [esp + 0x1c]
jae 0x47675f
mov ebx, dword [esp + 0x28]
mov esi, dword [esp + 0x1c]
lea esp, [esp]
movzx ecx, byte [edx]
movzx eax, byte [edx + 1]
shl ecx, 8
or ecx, eax
cmp ecx, edi
jge 0x476738
lea eax, [ecx + ebx]
sar eax, 8
mov byte [edx], al
lea eax, [ecx + ebx]
jmp 0x47674d
cmp eax, dword [esp + 0x18]
jle 0x4766c8
push 0x101b7
call fcn.004abc10
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
cmp ecx, ebp
jge 0x476750
mov eax, dword [esp + 0x3c]
add eax, ecx
sar eax, 8
mov byte [edx], al
mov al, byte [esp + 0x3c]
add al, cl
mov byte [edx + 1], al
add edx, 2
cmp edx, esi
jb 0x476700
mov ebx, dword [esp + 0x2c]
mov esi, dword [esp + 0x10]
mov edx, dword [esp + 0x20]
movzx eax, byte [edx + 7]
mov edi, dword [esp + 0x24]
sub eax, edi
mov ecx, dword [esp + 0x38]
add eax, ebx
cmp eax, dword [ecx + 0x14]
je 0x476919
push 0x52b284
push 0x101ee
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.00466a50
add esp, 0x14
mov eax, 0xb
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
mov ebp, esi
mov edi, dword [esp + 0x14]
mov ecx, ebx
mov dword [esp + 0x3c], 0
add ecx, 0xfffffffc
cmp dword [esp + 0x2c], 0
mov dword [esp + 0x30], ecx
jle 0x4768ba
add edi, esi
jmp 0x4767d0
movzx esi, byte [edi]
movzx eax, byte [edi + 1]
shl esi, 8
or esi, eax
cmp esi, dword [esp + 0x24]
jl 0x4768ee
cmp esi, ecx
jg 0x4768ee
lea eax, [esi + ebp]
push eax
mov eax, dword [esp + 0x3c]
push eax
mov eax, dword [eax + 0x4c]
call eax
movzx ebp, ax
add esp, 8
sub ebx, ebp
cmp ebx, dword [esp + 0x24]
jl 0x4768c3
lea eax, [esi + ebp]
cmp eax, dword [esp + 0x18]
jg 0x4768c3
mov eax, ebx
mov byte [edi + 1], bl
sar eax, 8
cmp dword [esp + 0x1c], 0
mov byte [edi], al
jne 0x476879
cmp ebx, esi
je 0x476894
mov eax, dword [esp + 0x38]
mov eax, dword [eax + 0x34]
mov eax, dword [eax]
mov eax, dword [eax + 0xd0]
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x20]
movzx ecx, byte [eax + 5]
movzx eax, byte [eax + 6]
shl ecx, 8
or ecx, eax
mov eax, ebp
sub eax, ecx
add eax, ebx
push eax
mov eax, dword [esp + 0x14]
add eax, ecx
push eax
mov eax, dword [esp + 0x24]
add eax, ecx
push eax
call sub.MSVCRT.dll_memcpy
mov eax, dword [esp + 0x28]
add esp, 0xc
mov dword [esp + 0x28], eax
push ebp
mov ebp, dword [esp + 0x2c]
lea eax, [esi + ebp]
mov esi, dword [esp + 0x14]
push eax
lea eax, [ebx + esi]
push eax
call sub.MSVCRT.dll_memcpy
add esp, 0xc
jmp 0x47689c
mov esi, dword [esp + 0x10]
mov ebp, dword [esp + 0x28]
mov ecx, dword [esp + 0x3c]
add edi, 2
inc ecx
cmp ecx, dword [esp + 0x2c]
mov dword [esp + 0x3c], ecx
mov ecx, dword [esp + 0x30]
jl 0x4767d0
mov edx, dword [esp + 0x20]
mov byte [edx + 7], 0
jmp 0x476763
push 0x52b284
push 0x101d9
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.00466a50
add esp, 0x14
mov eax, 0xb
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
push 0x52b284
push 0x101d3
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.00466a50
add esp, 0x14
mov eax, 0xb
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret
mov byte [edx + 6], bl
mov eax, ebx
sar eax, 8
sub ebx, edi
mov byte [edx + 5], al
lea eax, [edi + esi]
push ebx
push 0
push eax
mov word [edx + 1], 0
call sub.MSVCRT.dll_memset
add esp, 0xc
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x24
ret