Function at 0x506e90
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
push ebx
mov ebx, dword [ebp + 0x10]
push esi
mov esi, dword [ebp + 0xc]
push edi
mov edi, dword [ebp + 8]
test esi, esi
jne 0x506f49
cmp byte [edi], 0
jne 0x506f40
mov dl, byte [edi + 1]
test dl, 2
je 0x506f40
mov ecx, dword [edi + 0x20]
mov eax, dword [edi + 0x24]
mov esi, dword [ebp + 0x14]
cmp ecx, ebx
jne 0x506ee2
cmp eax, esi
jne 0x506ee4
mov eax, dword [ebp + 0x1c]
pop edi
pop esi
pop ebx
mov dword [eax], 0
xor eax, eax
mov esp, ebp
pop ebp
ret
cmp eax, esi
jg 0x506f40
jl 0x506eec
cmp ecx, ebx
jae 0x506f40
test dl, 8
jne 0x506fb8
add ecx, 1
adc eax, 0
cmp ecx, ebx
jne 0x506f40
cmp eax, esi
jne 0x506f40
mov eax, dword [ebp + 0x1c]
push 0
push edi
mov dword [eax], 0
call fcn.005074b0
add esp, 8
test eax, eax
jne 0x506f37
push edi
call fcn.004eef60
add esp, 4
cmp dword [edi + 0x20], ebx
jne 0x506f40
cmp dword [edi + 0x24], esi
jne 0x506f40
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
cmp eax, 0x65
jne 0x507454
mov dword [ebp - 0xc], 0
jmp 0x506fa2
mov ecx, dword [esi]
cmp word [ecx + 8], 0xd
ja 0x506f97
mov eax, dword [esi + 4]
movzx ebx, word [eax + 8]
mov eax, dword [ecx + 0x10]
mov al, byte [eax]
test al, al
je 0x506f6c
test al, 2
jne 0x506f97
or al, 0xff
mov dl, 1
jmp 0x506f71
mov al, 1
or dl, 0xff
mov byte [esi + 0xc], dl
mov byte [esi + 0xd], al
test bl, 4
je 0x506f85
mov dword [ebp - 0xc], 0x549a30
jmp 0x506f9e
test bl, 0x39
jne 0x506f97
cmp dword [ecx + 0x14], 0
mov dword [ebp - 0xc], 0x549c40
je 0x506f9e
mov dword [ebp - 0xc], 0x539710
mov byte [esi + 0xb], 0
push edi
call fcn.004f33c0
add esp, 4
test eax, eax
je 0x506fca
cmp eax, 0x10
jne 0x507454
mov eax, dword [ebp + 0x1c]
pop edi
pop esi
pop ebx
mov dword [eax], 0xffffffff
xor eax, eax
mov esp, ebp
pop ebp
ret
mov ecx, 1
lea ebx, [edi + 0x74]
sub ecx, dword [ebp + 0x18]
mov dword [ebp - 0x24], ecx
mov edx, dword [ebx]
xor eax, eax
mov dword [ebp - 0x14], eax
mov dword [ebp - 8], edx
movzx esi, word [edx + 0x18]
lea eax, [edx + 0x40]
dec esi
mov dword [ebp - 0x18], eax
mov ebx, esi
mov dword [ebp - 0x20], esi
sar ebx, cl
lea ecx, [edx + 0x1a]
cmp dword [ebp - 0xc], 0
mov word [edi + 0x46], bx
mov dword [ebp - 0x10], ecx
jne 0x507100
mov cl, byte [edx + 3]
mov eax, dword [eax]
mov dword [ebp - 0x20], eax
mov byte [ebp - 1], cl
mov ax, word [eax + ebx*2]
mov edi, dword [ebp - 0x10]
mov ch, al
mov cl, ah
movzx eax, cx
movzx ecx, word [edi]
mov edi, dword [ebp + 8]
and eax, ecx
add eax, dword [edx + 0x44]
cmp byte [ebp - 1], 0
je 0x50704f
cmp byte [eax], 0x80
jb 0x50704e
mov ecx, dword [edx + 0x3c]
lea ebx, [ebx]
inc eax
cmp eax, ecx
jae 0x507317
cmp byte [eax], 0x80
jae 0x507040
inc eax
lea ecx, [ebp - 0x2c]
push ecx
push eax
call fcn.005186d0
mov ecx, dword [ebp - 0x28]
add esp, 8
mov eax, dword [ebp - 0x2c]
cmp ecx, dword [ebp + 0x14]
jg 0x5070b2
jl 0x507070
mov edx, dword [ebp + 0x10]
cmp eax, edx
jae 0x5070b5
lea edx, [ebx + 1]
mov dword [ebp - 0x14], edx
cmp edx, esi
jle 0x5070ca
or edi, 0xffffffff
mov eax, dword [ebp - 8]
mov ecx, dword [ebp - 0x18]
mov esi, dword [ebp - 0x10]
cmp byte [eax + 8], 0
jne 0x507393
mov edi, dword [ebp + 8]
mov ebx, dword [ebp - 8]
movzx eax, word [ebx + 0x18]
cmp edx, eax
jl 0x50729c
movzx ecx, byte [ebx + 9]
mov eax, dword [ebx + 0x38]
mov edx, dword [ecx + eax + 8]
jmp 0x5072b4
mov edx, dword [ebp + 0x10]
cmp ecx, dword [ebp + 0x14]
jl 0x5070e1
jg 0x5070c0
cmp eax, edx
jbe 0x5070e1
mov edx, dword [ebp - 0x14]
lea esi, [ebx - 1]
cmp edx, esi
jg 0x5070da
mov eax, dword [ebp - 0x20]
lea ebx, [esi + edx]
mov edx, dword [ebp - 8]
sar ebx, 1
jmp 0x507013
mov edi, 1
jmp 0x50707d
mov edx, dword [ebp - 8]
mov word [edi + 0x46], bx
cmp byte [edx + 8], 0
jne 0x507341
mov ecx, dword [ebp - 0x18]
mov edx, ebx
mov esi, dword [ebp - 0x10]
mov dword [ebp - 0x14], edx
jmp 0x507093
mov eax, dword [eax]
mov ax, word [eax + ebx*2]
mov ch, al
mov cl, ah
mov eax, dword [ebp - 0x10]
movzx ecx, cx
movzx eax, word [eax]
and ecx, eax
mov eax, dword [ebp - 8]
add ecx, dword [edx + 0x44]
movzx eax, byte [eax + 0xb]
movzx edx, byte [ecx]
lea esi, [ecx + 1]
cmp edx, eax
ja 0x50713b
push dword [ebp + 0xc]
push esi
push edx
call dword [ebp - 0xc]
add esp, 0xc
mov edi, eax
jmp 0x507260
mov al, byte [esi]
test al, al
js 0x50716d
and edx, 0x7f
movzx eax, al
shl edx, 7
add edx, eax
mov eax, dword [ebp - 8]
movzx eax, word [eax + 0xe]
cmp edx, eax
ja 0x50716d
mov esi, dword [ebp + 0xc]
lea eax, [ecx + 2]
push esi
push eax
push edx
call dword [ebp - 0xc]
add esp, 0xc
mov edi, eax
jmp 0x507263
mov edx, dword [ebp - 8]
lea esi, [edi + 0x20]
push esi
movzx eax, byte [edx + 0xa]
sub ecx, eax
mov eax, dword [edx + 0x50]
push ecx
push edx
call eax
mov edi, dword [esi]
add esp, 0xc
cmp edi, 2
jl 0x507479
mov eax, dword [ebp + 8]
xor edx, edx
mov ecx, dword [eax + 0x14]
mov eax, edi
div dword [ecx + 0x28]
cmp eax, dword [ecx + 0x30]
ja 0x507479
lea eax, [edi + 0x12]
cdq
push edx
push eax
call fcn.0051c8d0
mov esi, eax
add esp, 8
test esi, esi
je 0x507464
mov eax, dword [ebp + 8]
push 0
push esi
push edi
push 0
push eax
mov word [eax + 0x46], bx
call fcn.004d9600
xor ecx, ecx
mov dword [ebp - 0x1c], eax
mov dword [esi + edi], ecx
add esp, 0x14
mov dword [esi + edi + 4], ecx
mov dword [esi + edi + 8], ecx
mov dword [esi + edi + 0xc], ecx
mov word [esi + edi + 0x10], cx
mov ecx, dword [ebp + 8]
and byte [ecx + 1], 0xfb
test eax, eax
jne 0x5073fc
push eax
push dword [ebp + 0xc]
push esi
push edi
call fcn.00539730
add esp, 0x10
mov edi, eax
cmp dword [0x5ac1c8], 0
je 0x507256
mov eax, dword [0x5b6e80]
test eax, eax
je 0x507227
push eax
call dword [0x5ac218]
add esp, 4
push esi
call dword [0x5ac1f4]
sub dword [0x5b6e20], eax
dec dword [0x5b6e44]
push esi
call dword [0x5ac1ec]
mov eax, dword [0x5b6e80]
add esp, 8
test eax, eax
je 0x507260
push eax
call dword [0x5ac220]
jmp 0x50725d
push esi
call dword [0x5ac1ec]
add esp, 4
mov esi, dword [ebp + 0xc]
test edi, edi
jns 0x507272
mov eax, dword [ebp - 0x20]
lea edx, [ebx + 1]
mov dword [ebp - 0x14], edx
jmp 0x507281
jle 0x5073b1
mov edx, dword [ebp - 0x14]
lea eax, [ebx - 1]
mov dword [ebp - 0x20], eax
cmp edx, eax
jg 0x50707d
mov edi, dword [ebp + 8]
lea ebx, [eax + edx]
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 0x18]
sar ebx, 1
jmp 0x507100
mov eax, dword [ecx]
mov ax, word [eax + edx*2]
mov ch, al
mov cl, ah
movzx eax, word [esi]
movzx ecx, cx
and ecx, eax
mov eax, dword [ebx + 0x38]
mov edx, dword [ecx + eax]
mov eax, dword [ebp - 0x14]
mov esi, dword [edi + 0x14]
movzx ecx, ax
mov al, byte [edi + 0x44]
mov word [edi + 0x46], cx
cmp al, 0x13
jge 0x507363
and byte [edi + 1], 0xf9
xor ebx, ebx
movsx eax, al
mov word [edi + 0x32], bx
lea ebx, [edi + 0x74]
bswap edx
mov word [edi + eax*2 + 0x48], cx
movsx ecx, byte [edi + 0x44]
mov eax, dword [ebx]
mov dword [edi + ecx*4 + 0x78], eax
xor eax, eax
inc byte [edi + 0x44]
mov word [edi + 0x46], ax
movzx eax, byte [edi + 2]
push eax
push edi
push ebx
push edx
push esi
call fcn.004eee70
add esp, 0x14
test eax, eax
jne 0x50744e
mov ecx, dword [ebp - 0x24]
jmp 0x506fd8
push 0x595f14
push 0x110ce
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.004d83d0
add esp, 0x14
mov eax, 0xb
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
or byte [edi + 1], 2
mov dword [edi + 0x20], eax
xor eax, eax
mov word [edi + 0x32], ax
mov eax, dword [ebp + 0x1c]
mov dword [edi + 0x24], ecx
pop edi
pop esi
mov dword [eax], 0
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret
push 0x595f14
push 0x10f32
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.004d83d0
add esp, 0x14
mov eax, 0xb
xor ecx, ecx
mov word [edi + 0x32], cx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 8]
mov word [eax + 0x46], bx
mov eax, dword [ebp + 0x1c]
mov dword [eax], edi
xor eax, eax
mov edi, dword [ebp + 8]
xor ecx, ecx
mov word [edi + 0x32], cx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0x1c]
mov edi, dword [ebp + 8]
mov dword [eax], 0
xor eax, eax
mov word [edi + 0x46], bx
cmp byte [esi + 0xb], al
je 0x50744e
push 0x595f14
push 0x11139
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.004d83d0
add esp, 0x14
mov eax, 0xb
xor ecx, ecx
mov word [edi + 0x32], cx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
cmp dword [0x5ac1c8], 0
je 0x50745b
mov eax, dword [0x5b6e80]
test eax, eax
je 0x507418
push eax
call dword [0x5ac218]
add esp, 4
push esi
call dword [0x5ac1f4]
sub dword [0x5b6e20], eax
dec dword [0x5b6e44]
push esi
call dword [0x5ac1ec]
mov eax, dword [0x5b6e80]
add esp, 8
test eax, eax
je 0x507448
push eax
call dword [0x5ac220]
add esp, 4
mov eax, dword [ebp - 0x1c]
mov edi, dword [ebp + 8]
xor ecx, ecx
mov word [edi + 0x32], cx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push esi
call dword [0x5ac1ec]
jmp 0x507445
mov edi, dword [ebp + 8]
xor ecx, ecx
mov eax, 7
mov word [edi + 0x32], cx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0x595f14
push 0x11119
push str.database_corruption
push str._s_at_line__d_of___.10s_
push 0xb
call fcn.004d83d0
mov edi, dword [ebp + 8]
add esp, 0x14
xor ecx, ecx
mov eax, 0xb
mov word [edi + 0x32], cx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret