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

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x68
mov rbx, qword [rcx + 8]
cmp byte [rcx + 0x11], 0
mov r14, qword [rbx]
mov rsi, rcx
mov ebp, edx
mov r13, r8
je 0x47fc83
add dword [rcx + 0x14], 1
cmp byte [rcx + 0x12], 0
je 0x47fd90
movzx eax, byte [rsi + 0x10]
cmp al, 2
je 0x47fda1
test ebp, ebp
jne 0x47fc9b
cmp al, 1
je 0x47fe1c
mov rax, qword [rsi]
movzx edx, word [rbx + 0x28]
test byte [rax + 0x33], 2
je 0x47fcf0
cmp byte [r14 + 0x12], 0
jne 0x47fcf0
and edx, 0xfffffffe
mov word [rbx + 0x28], dx
test ebp, ebp
je 0x47fd02
cmp byte [rbx + 0x24], 2
je 0x47fd07
test dl, 0x80
jne 0x47fd07
cmp ebp, 1
jle 0x47fd1a
mov rax, qword [rbx + 0x78]
test rax, rax
jne 0x47fce1
jmp 0x47fd1a
mov rax, qword [rax + 0x10]
test rax, rax
je 0x47fd1a
mov rcx, qword [rax]
cmp rcx, rsi
je 0x47fcd8
mov rax, qword [rcx]
jmp 0x47fd11
mov eax, edx
and eax, 1
test ax, ax
je 0x47fcb6
test ebp, ebp
jne 0x47fde8
test dl, 0x80
je 0x47fd1a
mov rax, qword [rbx + 0x80]
mov rax, qword [rax]
test rax, rax
jne 0x4802f0
cmp byte [rsi + 0x11], 0
je 0x47fe30
mov rax, qword [rsi + 8]
cmp rsi, qword [rax + 0x80]
je 0x47fd37
test byte [rax + 0x28], 0x40
jne 0x47fd66
mov rax, qword [rax + 0x78]
test rax, rax
jne 0x47fd55
jmp 0x47fe30
mov rax, qword [rax + 0x10]
test rax, rax
je 0x47fe30
cmp rsi, qword [rax]
je 0x47fd48
cmp dword [rax + 8], 1
jne 0x47fd48
cmp byte [rax + 0xc], 1
je 0x47fd48
mov r12d, 0x106
nop dword [rax]
sub dword [rsi + 0x14], 1
jne 0x47fdfa
mov rcx, qword [rsi + 8]
lea rdx, [rsi + 0x12]
call fcn.0040d4c0
jmp 0x47fdfa
call fcn.0040d4e0
movzx eax, byte [rsi + 0x10]
cmp al, 2
jne 0x47fc8f
test r13, r13
je 0x47fdb7
mov rax, qword [rbx + 0x18]
mov rax, qword [rax + 0x50]
mov eax, dword [rax + 0x28]
bswap eax
mov dword [r13], eax
test ebp, ebp
je 0x47fe28
mov rax, qword [rsi]
mov edx, dword [rax + 0x2f0]
cmp edx, dword [r14 + 0x80]
jle 0x47fe28
cmp byte [r14 + 0xa], 0
je 0x47fe28
mov rcx, r14
call fcn.004149a0
mov r12d, eax
jmp 0x47fdf0
mov r12d, 8
nop
cmp byte [rsi + 0x11], 0
jne 0x47fd70
mov eax, r12d
add rsp, 0x68
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov byte [rsi + 0x10], 1
test al, al
jne 0x47fe1c
mov byte [rbx + 0x24], 1
test r13, r13
jne 0x47fda6
nop dword [rax]
xor r12d, r12d
jmp 0x47fdf0
mov r10d, dword [rbx + 0x40]
and edx, 0xffffffef
mov word [rbx + 0x28], dx
test r10d, r10d
je 0x480300
mov rdi, qword [rbx + 0x18]
xor r12d, r12d
test rdi, rdi
je 0x47ffe4
test ebp, ebp
setne r15b
test r12d, r12d
sete dil
and dil, r15b
je 0x47ff50
test byte [rbx + 0x28], 1
je 0x480140
cmp byte [rbx + 0x24], 0
jne 0x47fde8
mov edi, 8
mov r12d, 8
mov rax, qword [rbx + 0x18]
test rax, rax
je 0x47fdf0
mov rcx, qword [rax + 0x70]
mov qword [rbx + 0x18], 0
mov r15, qword [rcx + 0x28]
call fcn.00418c80
mov rax, qword [r15 + 0x120]
mov eax, dword [rax + 0x18]
test eax, eax
je 0x480390
cmp edi, 5
jne 0x47fdf0
cmp byte [rbx + 0x24], 0
jne 0x47fdf0
mov rdi, qword [rbx + 8]
mov rax, qword [rdi + 0x288]
test rax, rax
je 0x47fdf0
mov edx, dword [rdi + 0x298]
test edx, edx
js 0x47fdf0
mov rcx, qword [rdi + 0x290]
call rax
test eax, eax
jne 0x47ffd0
mov dword [rdi + 0x298], 0xffffffff
jmp 0x47fdf0
mov byte [r14 + 0x16], 4
mov eax, dword [r14 + 0x20]
mov byte [r14 + 0x15], 2
mov qword [r14 + 0x60], 0
mov dword [r14 + 0x2c], eax
mov dword [r14 + 0x28], eax
mov dword [r14 + 0x24], eax
nop dword [rax]
mov edx, dword [rbx + 0x40]
test edx, edx
jne 0x480310
mov rcx, rbx
call fcn.0047fa20
mov r12d, eax
nop
test r12d, r12d
jne 0x480120
mov r10d, r15d
cmp byte [rsi + 0x10], 0
jne 0x47ff70
add dword [rbx + 0x3c], 1
cmp byte [rsi + 0x11], 0
jne 0x480418
movzx eax, byte [rbx + 0x24]
test r10b, r10b
je 0x47fe10
mov byte [rsi + 0x10], 2
cmp al, 1
ja 0x47ff89
mov byte [rbx + 0x24], 2
movzx eax, word [rbx + 0x28]
mov rdi, qword [rbx + 0x18]
mov qword [rbx + 0x80], rsi
mov edx, eax
or eax, 0x40
and edx, 0xffffffbf
cmp ebp, 2
cmovl eax, edx
mov word [rbx + 0x28], ax
mov rax, qword [rdi + 0x50]
mov eax, dword [rax + 0x1c]
bswap eax
cmp dword [rbx + 0x40], eax
jne 0x480438
test r13, r13
jne 0x47fda6
jmp 0x47fdbb
add dword [rdi + 0x298], 1
mov rdi, qword [rbx + 0x18]
test rdi, rdi
jne 0x47fe54
mov rcx, qword [rbx]
call fcn.0047d120
mov r12d, eax
test eax, eax
jne 0x480120
mov rax, qword [rbx]
lea r8, [rsp + 0x58]
xor r9d, r9d
mov edx, 1
mov qword [rsp + 0x38], r8
mov rcx, rax
call qword [rax + 0x110]
mov r12d, eax
test eax, eax
jne 0x480120
mov rax, qword [rsp + 0x58]
mov r8, qword [rsp + 0x38]
mov rdi, qword [rax + 0x10]
cmp dword [rdi + 4], 1
je 0x4803f8
mov r10, qword [rax + 8]
mov qword [rdi + 0x70], rax
mov qword [rdi + 0x48], rbx
mov qword [rdi + 0x50], r10
mov dword [rdi + 4], 1
mov byte [rdi + 9], 0x64
mov rax, qword [rbx + 8]
mov r15d, dword [r10 + 0x1c]
mov rcx, qword [rbx]
mov rax, qword [rax + 0x30]
bswap r15d
mov r11d, dword [rcx + 0x20]
and eax, 0x2000000
test r15d, r15d
je 0x480320
mov edx, dword [r10 + 0x18]
cmp dword [r10 + 0x5c], edx
jne 0x480320
test rax, rax
jne 0x48032e
movabs rdx, 0x332074616d726f
xor rdx, qword [r10 + 8]
movabs rax, 0x66206574694c5153
xor rax, qword [r10]
or rdx, rax
jne 0x4800d4
cmp byte [r10 + 0x12], 2
jbe 0x4800ba
or word [rbx + 0x28], 1
cmp byte [r10 + 0x13], 2
ja 0x4800d4
je 0x480550
cmp word [r10 + 0x15], 0x2040
je 0x4805a8
mov rcx, qword [rdi + 0x70]
call fcn.0047e8e0
cmp byte [rbx + 0x24], 0
mov qword [rbx + 0x18], 0
je 0x480540
mov r12d, 0x1a
jmp 0x47fdf0
mov rcx, qword [rdi + 0x70]
mov dword [rsp + 0x38], eax
call fcn.0047e8e0
mov eax, dword [rsp + 0x38]
mov qword [rbx + 0x18], 0
mov r12d, eax
nop word cs:[rax + rax]
cmp byte [rbx + 0x24], 0
movzx edi, r12b
jne 0x47febd
mov rax, qword [rbx + 0x18]
test rax, rax
je 0x47febd
jmp 0x47fe96
mov r12d, dword [r14 + 0x30]
test r12d, r12d
jne 0x4803e0
mov rax, qword [rsi]
cmp byte [rax + 0x66], 2
sete byte [r14 + 0x1a]
cmp byte [r14 + 0x15], 1
jne 0x47ff38
mov r10, qword [r14 + 0x128]
test r10, r10
je 0x480480
cmp byte [r14 + 8], 0
je 0x480205
cmp byte [r10 + 0x3f], 0
jne 0x480205
movzx eax, byte [r14 + 0x16]
cmp al, 5
je 0x480193
cmp al, 3
ja 0x4801c4
cmp byte [r14 + 0x11], 0
jne 0x480643
mov rcx, qword [r14 + 0x48]
mov edx, 4
mov rax, qword [rcx]
call qword [rax + 0x38]
mov r12d, eax
test eax, eax
jne 0x4803e0
mov byte [r14 + 0x16], 4
mov r10, qword [r14 + 0x128]
cmp byte [r10 + 0x3f], 0
mov rax, r10
jne 0x4801fd
mov rcx, qword [r10 + 8]
movsx edx, word [r10 + 0x3c]
mov qword [rsp + 0x38], r10
mov r9d, 5
mov r8d, 1
mov rax, qword [rcx]
add edx, 3
call qword [rax + 0x70]
mov rax, qword [r14 + 0x128]
mov r10, qword [rsp + 0x38]
mov byte [r10 + 0x3f], 1
mov r10, rax
cmp byte [r10 + 0x42], 0
jne 0x47fe74
cmp byte [r10 + 0x3f], 0
jne 0x480244
mov rcx, qword [r10 + 8]
mov qword [rsp + 0x38], r10
xor edx, edx
mov r9d, 0xa
mov r8d, 1
mov rax, qword [rcx]
call qword [rax + 0x70]
mov r10, qword [rsp + 0x38]
test eax, eax
mov r12d, eax
jne 0x4803e0
mov rax, qword [r10 + 0x30]
mov rdx, qword [r10 + 0x48]
mov byte [r10 + 0x40], 1
mov rcx, qword [r10 + 0x50]
mov rax, qword [rax]
xor rcx, qword [rax + 8]
xor rdx, qword [rax]
or rcx, rdx
jne 0x480298
mov rdx, qword [r10 + 0x58]
mov rcx, qword [r10 + 0x60]
xor rdx, qword [rax + 0x10]
xor rcx, qword [rax + 0x18]
or rcx, rdx
jne 0x480298
mov rdx, qword [r10 + 0x68]
mov rcx, qword [r10 + 0x70]
xor rdx, qword [rax + 0x20]
xor rcx, qword [rax + 0x28]
or rcx, rdx
je 0x47ff17
nop word [rax + rax]
cmp byte [r10 + 0x3f], 0
jne 0x4802c1
mov rcx, qword [r10 + 8]
mov qword [rsp + 0x38], r10
mov r9d, 9
xor edx, edx
mov r8d, 1
mov rax, qword [rcx]
call qword [rax + 0x70]
mov r10, qword [rsp + 0x38]
mov byte [r10 + 0x40], 0
cmp byte [rbx + 0x24], 0
jne 0x480408
mov rax, qword [rbx + 0x18]
test rax, rax
jne 0x480747
mov r12d, 5
jmp 0x47fec6
mov r12d, 0x106
jmp 0x47fdf0
or edx, 0x10
mov word [rbx + 0x28], dx
jmp 0x47fe44
mov r10d, edi
jmp 0x47ff5c
test r11d, r11d
je 0x48032e
test rax, rax
je 0x4804f1
mov r9d, dword [rbx + 0x38]
xor r15d, r15d
lea edx, [r9 - 0xc]
mov ecx, 0x80808081
sub r9d, 0x23
mov qword [rbx + 0x18], rdi
mov eax, edx
shl edx, 5
mov word [rbx + 0x2e], r9w
shl eax, 6
imul rdx, rcx
mov dword [rbx + 0x40], r15d
imul rax, rcx
shr rdx, 0x27
shr rax, 0x27
sub edx, 0x17
sub eax, 0x17
mov word [rbx + 0x2c], dx
mov word [rbx + 0x30], dx
cmp ax, 0x7f
mov edx, 0x7f
mov word [rbx + 0x2a], ax
cmova eax, edx
mov byte [rbx + 0x25], al
jmp 0x47fe4b
movzx eax, byte [r15 + 0x15]
cmp al, 6
je 0x4803c9
test al, al
je 0x4803c9
cmp al, 1
jbe 0x480460
mov rax, qword [0x0066ea70]
test rax, rax
je 0x4803b3
call rax
mov rcx, r15
call fcn.0047e690
mov rax, qword [0x0066ea78]
test rax, rax
je 0x4803c9
call rax
mov rcx, r15
call fcn.004129c0
jmp 0x47febd
cmp r12d, 0x205
jne 0x480120
jmp 0x4802c6
mov r10, qword [rdi + 0x50]
jmp 0x480053
mov r12d, 0x205
jmp 0x47fdf0
mov byte [rsi + 0x3c], 1
mov rax, qword [rbx + 0x78]
mov qword [rsi + 0x40], rax
lea rax, [rsi + 0x30]
mov qword [rbx + 0x78], rax
jmp 0x47ff70
mov rcx, qword [rdi + 0x70]
call fcn.004783b0
mov r12d, eax
test eax, eax
jne 0x47fdf0
mov eax, dword [rbx + 0x40]
mov rdx, qword [rdi + 0x50]
bswap eax
mov dword [rdx + 0x1c], eax
jmp 0x47ffbc
cmp byte [r15 + 8], 0
jne 0x4803c9
xor r8d, r8d
xor edx, edx
mov rcx, r15
call fcn.004182e0
jmp 0x4803c9
movzx eax, byte [r14 + 0x16]
cmp al, 5
je 0x4804f9
cmp al, 1
jbe 0x4804f9
cmp ebp, 1
jle 0x47ff17
cmp al, 5
je 0x4804a2
cmp al, 3
ja 0x47ff17
cmp byte [r14 + 0x11], 0
jne 0x47ff12
mov rcx, qword [r14 + 0x48]
mov edx, 4
mov rax, qword [rcx]
call qword [rax + 0x38]
mov r12d, eax
test eax, eax
je 0x47ff12
cmp eax, 5
jne 0x4803e0
mov rcx, qword [r14 + 0xf0]
call qword [r14 + 0xe8]
test eax, eax
je 0x480716
movzx eax, byte [r14 + 0x16]
cmp al, 5
jne 0x48049a
jmp 0x4804a2
mov r15d, r11d
jmp 0x48008e
cmp byte [r14 + 0x11], 0
jne 0x48051f
mov rcx, qword [r14 + 0x48]
mov edx, 2
mov rax, qword [rcx]
call qword [rax + 0x38]
mov r12d, eax
test eax, eax
jne 0x4803e0
movzx eax, byte [r14 + 0x16]
cmp al, 5
je 0x48052d
mov byte [r14 + 0x16], 2
mov eax, 2
cmp ebp, 1
jg 0x480496
jmp 0x47ff17
mov edi, 0x1a
mov r12d, 0x1a
jmp 0x47fe89
test byte [rbx + 0x28], 0x20
jne 0x4800c7
mov rdx, r8
mov qword [rsp + 0x40], r10
mov dword [rsp + 0x38], r11d
mov dword [rsp + 0x58], 0
call fcn.00418250
mov r11d, dword [rsp + 0x38]
mov r10, qword [rsp + 0x40]
test eax, eax
jne 0x4800fa
mov r9d, dword [rsp + 0x58]
test r9d, r9d
jne 0x4800c7
mov rcx, qword [rdi + 0x70]
call fcn.0047e8e0
jmp 0x47fe44
cmp byte [r10 + 0x17], 0x20
jne 0x4800d4
movzx eax, byte [r10 + 0x10]
shl eax, 8
mov edx, eax
movzx eax, byte [r10 + 0x11]
shl eax, 0x10
or eax, edx
lea edx, [rax - 1]
test edx, eax
jne 0x4800d4
lea edx, [rax - 0x101]
cmp edx, 0xfeff
ja 0x4800d4
or word [rbx + 0x28], 2
movzx r8d, byte [r10 + 0x14]
mov r9d, eax
sub r9d, r8d
cmp eax, dword [rbx + 0x34]
jne 0x48064d
cmp r11d, r15d
jae 0x480618
mov rax, qword [rbx + 8]
mov r15d, r11d
mov rax, qword [rax + 0x30]
and eax, 0x10000001
cmp rax, 1
jne 0x4806ca
cmp r9d, 0x1df
jbe 0x4800d4
mov dword [rbx + 0x38], r9d
mov ecx, dword [r10 + 0x34]
test ecx, ecx
setne byte [rbx + 0x21]
mov r8d, dword [r10 + 0x40]
test r8d, r8d
setne byte [rbx + 0x22]
jmp 0x480335
mov byte [r14 + 0x16], 4
jmp 0x4801c4
mov rcx, qword [rdi + 0x70]
mov dword [rsp + 0x4c], r8d
mov dword [rsp + 0x40], r9d
mov dword [rsp + 0x38], eax
call fcn.0047e8e0
mov rcx, qword [rbx + 0x88]
mov r9d, dword [rsp + 0x40]
mov eax, dword [rsp + 0x38]
mov r8d, dword [rsp + 0x4c]
test rcx, rcx
mov dword [rbx + 0x38], r9d
mov dword [rbx + 0x34], eax
je 0x4806aa
sub rcx, 4
mov dword [rsp + 0x38], r8d
mov qword [rbx + 0x88], rcx
call fcn.0040d340
mov r8d, dword [rsp + 0x38]
mov qword [rbx + 0x88], 0
mov rcx, qword [rbx]
lea rdx, [rbx + 0x34]
call fcn.0041ff70
mov r12d, eax
test eax, eax
jne 0x480120
mov rdi, qword [rbx + 0x18]
jmp 0x47fe4b
lea rax, [0x0061717c]
mov r9d, 0x1182a
lea r8, str.database_corruption
mov ecx, 0xb
mov qword [rsp + 0x20], rax
lea rdx, str._s_at_line__d_of___.10s_
call fcn.0042e6d0
mov rcx, qword [rdi + 0x70]
call fcn.0047e8e0
cmp byte [rbx + 0x24], 0
mov qword [rbx + 0x18], 0
je 0x480737
mov r12d, 0xb
jmp 0x47fdf0
cmp byte [rbx + 0x24], 0
jne 0x47fec6
mov rax, qword [rbx + 0x18]
test rax, rax
je 0x47fec6
mov edi, 5
jmp 0x47fe96
mov edi, 0xb
mov r12d, 0xb
jmp 0x47fe89
mov edi, 5
mov r12d, 5
jmp 0x47fe96