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

Disassembly:
sub esp, 0x58
push ebx
push ebp
mov ebp, dword [esp + 0x64]
mov eax, dword [ebp]
push esi
mov esi, dword [esp + 0x70]
mov dword [esp + 0x10], eax
xor eax, eax
push edi
xor edi, edi
cmp dword [esp + 0x78], edi
setne al
movzx ecx, byte [eax + esi + 0x19]
cmp ecx, edi
mov dword [esp + 0x44], eax
mov eax, dword [esi + eax*4 + 0x1c]
mov dword [esp + 0x2c], ecx
je 0x550153
cmp eax, edi
jne 0x550153
mov eax, dword [esp + 0x70]
lea ecx, [esp + 0x20]
push ecx
lea edx, [esp + 0x28]
push edx
push esi
push eax
push ebp
mov dword [esp + 0x38], edi
mov dword [esp + 0x34], edi
mov dword [esp + 0x54], edi
mov dword [esp + 0x2c], edi
mov dword [esp + 0x30], edi
mov dword [esp + 0x3c], edi
mov dword [esp + 0x24], edi
call fcn.00548190
add esp, 0x14
test eax, eax
jne 0x5500f2
cmp dword [esi + 0x14], edi
mov dword [esp + 0x6c], edi
jle 0x54fe45
mov eax, 3
mov dword [esp + 0x58], 0x5fcc24
mov dword [esp + 0x5c], eax
mov dword [esp + 0x60], 0x5f3658
mov dword [esp + 0x64], eax
lea esp, [esp]
mov eax, dword [esp + 0x20]
test eax, eax
je 0x54f8e1
mov ecx, dword [esp + 0x6c]
mov edx, dword [eax + ecx*4]
jmp 0x54f8e8
mov edx, dword [esp + 0x74]
mov edx, dword [edx + 0x24]
mov eax, dword [esp + 0x24]
test eax, eax
je 0x54f909
mov eax, dword [eax + 8]
mov ecx, dword [esp + 0x6c]
mov eax, dword [eax + ecx*4]
mov ecx, dword [esp + 0x70]
mov ecx, dword [ecx + 0xc]
lea eax, [eax + eax*2]
mov ecx, dword [ecx + eax*8]
jmp 0x54f90e
mov ecx, 0x5fcc20
lea eax, [edx + edx*2]
mov edx, dword [esp + 0x74]
mov edx, dword [edx]
mov edx, dword [edx + 0xc]
add eax, eax
add eax, eax
add eax, eax
test ecx, ecx
mov edx, dword [eax + edx]
mov dword [esp + 0x3c], eax
mov dword [esp + 0x48], ecx
mov dword [esp + 0x50], edx
mov eax, ecx
je 0x54f94f
cmp byte [ecx], 0
je 0x54f948
lea ebx, [ebx]
add eax, 1
cmp byte [eax], 0
jne 0x54f940
sub eax, ecx
and eax, 0x3fffffff
test edx, edx
mov dword [esp + 0x4c], eax
mov eax, edx
je 0x54f96f
cmp byte [edx], 0
je 0x54f968
mov edi, edi
add eax, 1
cmp byte [eax], 0
jne 0x54f960
sub eax, edx
and eax, 0x3fffffff
mov dword [esp + 0x38], eax
mov dword [esp + 0x54], eax
mov eax, dword [ebp]
push 1
push 0x1a
push eax
lea eax, [esp + 0x5c]
call fcn.005459e0
mov esi, dword [ebp]
add esp, 0xc
test eax, eax
mov dword [esp + 0x34], eax
jne 0x54f9aa
push eax
push esi
call fcn.00540330
push 0
push esi
call fcn.00540330
add esp, 0x10
jmp 0x54f9b1
mov esi, eax
call fcn.00538330
mov ecx, dword [ebp]
push 1
push 0x1a
push ecx
lea eax, [esp + 0x54]
call fcn.005459e0
mov esi, dword [ebp]
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x54f9e1
push eax
push esi
call fcn.00540330
push edi
push esi
call fcn.00540330
add esp, 0x10
jmp 0x54f9e8
mov esi, edi
call fcn.00538330
mov edx, dword [ebp]
push 1
push 0x1a
push edx
lea eax, [esp + 0x64]
call fcn.005459e0
mov esi, dword [ebp]
mov ebx, eax
add esp, 0xc
test ebx, ebx
jne 0x54fa18
push eax
push esi
call fcn.00540330
push ebx
push esi
call fcn.00540330
add esp, 0x10
jmp 0x54fa1f
mov esi, ebx
call fcn.00538330
mov esi, dword [ebp]
mov ecx, 0x30
call fcn.0053c960
mov esi, eax
test esi, esi
mov dword [esp + 0x30], esi
je 0x54fa53
push 0x30
push 0
push esi
call fcn.005b4520
add esp, 0xc
mov byte [esi], 0x76
mov word [esi + 0x1e], 0xffff
mov dword [esi + 0x2c], 1
mov ecx, dword [esp + 0x30]
mov eax, ebx
mov ebx, dword [ebp]
call fcn.00545b30
mov esi, dword [ebp]
mov ecx, 0x30
call fcn.0053c960
mov esi, eax
test esi, esi
je 0x54fa91
push 0x30
push 0
push esi
call fcn.005b4520
add esp, 0xc
mov byte [esi], 0x4c
mov word [esi + 0x1e], 0xffff
mov dword [esi + 0x2c], 1
mov edi, dword [esp + 0x34]
mov eax, dword [esp + 0x30]
mov ebx, dword [ebp]
mov ecx, esi
call fcn.00545b30
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x14]
mov eax, esi
call fcn.00545bc0
cmp dword [esp + 0x78], 0
mov dword [esp + 0x18], eax
je 0x54fc76
mov eax, dword [ebp]
push 1
push 0x1a
push eax
lea eax, [esp + 0x54]
call fcn.005459e0
mov esi, dword [ebp]
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x54faf1
push eax
push esi
call fcn.00540330
push edi
push esi
call fcn.00540330
add esp, 0x10
jmp 0x54faf8
mov esi, edi
call fcn.00538330
mov ecx, dword [ebp]
push 1
push 0x1a
push ecx
lea eax, [esp + 0x6c]
call fcn.005459e0
mov esi, dword [ebp]
mov ebx, eax
add esp, 0xc
test ebx, ebx
jne 0x54fb28
push eax
push esi
call fcn.00540330
push ebx
push esi
call fcn.00540330
add esp, 0x10
jmp 0x54fb2f
mov esi, ebx
call fcn.00538330
mov esi, dword [ebp]
mov ecx, 0x30
call fcn.0053c960
mov esi, eax
test esi, esi
mov dword [esp + 0x30], esi
je 0x54fb63
push 0x30
push 0
push esi
call fcn.005b4520
add esp, 0xc
mov byte [esi], 0x76
mov word [esi + 0x1e], 0xffff
mov dword [esi + 0x2c], 1
mov ecx, dword [esp + 0x30]
mov eax, ebx
mov ebx, dword [ebp]
call fcn.00545b30
mov edx, dword [ebp]
push 1
push 0x1a
push edx
lea eax, [esp + 0x54]
call fcn.005459e0
mov esi, dword [ebp]
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x54fba1
push eax
push esi
call fcn.00540330
push edi
push esi
call fcn.00540330
add esp, 0x10
jmp 0x54fba8
mov esi, edi
call fcn.00538330
mov eax, dword [ebp]
push 1
push 0x1a
push eax
lea eax, [esp + 0x64]
call fcn.005459e0
mov esi, dword [ebp]
mov ebx, eax
add esp, 0xc
test ebx, ebx
jne 0x54fbd8
push eax
push esi
call fcn.00540330
push ebx
push esi
call fcn.00540330
add esp, 0x10
jmp 0x54fbdf
mov esi, ebx
call fcn.00538330
mov esi, dword [ebp]
mov ecx, 0x30
call fcn.0053c960
mov esi, eax
test esi, esi
mov dword [esp + 0x34], esi
je 0x54fc13
push 0x30
push 0
push esi
call fcn.005b4520
add esp, 0xc
mov byte [esi], 0x76
mov word [esi + 0x1e], 0xffff
mov dword [esi + 0x2c], 1
mov ecx, dword [esp + 0x34]
mov eax, ebx
mov ebx, dword [ebp]
call fcn.00545b30
mov esi, dword [ebp]
mov ecx, 0x30
call fcn.0053c960
mov esi, eax
test esi, esi
je 0x54fc51
push 0x30
push 0
push esi
call fcn.005b4520
add esp, 0xc
mov byte [esi], 0x46
mov word [esi + 0x1e], 0xffff
mov dword [esi + 0x2c], 1
mov edi, dword [esp + 0x30]
mov eax, dword [esp + 0x34]
mov ebx, dword [ebp]
mov ecx, esi
call fcn.00545b30
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x14]
mov eax, esi
call fcn.00545bc0
mov dword [esp + 0x10], eax
mov eax, dword [esp + 0x2c]
cmp eax, 6
je 0x54fe2d
cmp eax, 9
jne 0x54fd46
cmp dword [esp + 0x78], 0
je 0x54fe2d
mov ecx, dword [ebp]
push 1
push 0x1a
push ecx
lea eax, [esp + 0x54]
call fcn.005459e0
mov esi, dword [ebp]
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x54fcc7
push eax
push esi
call fcn.00540330
push edi
push esi
call fcn.00540330
add esp, 0x10
jmp 0x54fcce
mov esi, edi
call fcn.00538330
mov edx, dword [ebp]
push 1
push 0x1a
push edx
lea eax, [esp + 0x6c]
call fcn.005459e0
mov esi, dword [ebp]
mov ebx, eax
add esp, 0xc
test ebx, ebx
jne 0x54fcfe
push eax
push esi
call fcn.00540330
push ebx
push esi
call fcn.00540330
add esp, 0x10
jmp 0x54fd05
mov esi, ebx
call fcn.00538330
mov esi, dword [ebp]
mov ecx, 0x30
call fcn.0053c960
mov esi, eax
test esi, esi
je 0x54fd35
push 0x30
push 0
push esi
call fcn.005b4520
add esp, 0xc
mov byte [esi], 0x76
mov word [esi + 0x1e], 0xffff
mov dword [esi + 0x2c], 1
mov eax, ebx
mov ebx, dword [ebp]
mov ecx, esi
call fcn.00545b30
jmp 0x54fdd4
cmp eax, 8
jne 0x54fd85
mov eax, dword [esp + 0x74]
mov ecx, dword [eax]
mov edx, dword [ecx + 0xc]
mov eax, dword [esp + 0x3c]
mov eax, dword [edx + eax + 4]
test eax, eax
push 0
push 0
je 0x54fd74
mov ecx, dword [esp + 0x1c]
push eax
push ecx
call fcn.0054dca0
add esp, 0x10
jmp 0x54fdd6
xor edi, edi
lea eax, [edi + 0x62]
mov ecx, ebp
call fcn.00545b90
add esp, 8
jmp 0x54fdd6
mov esi, dword [ebp]
mov ecx, 0x30
call fcn.0053c960
mov esi, eax
test esi, esi
je 0x54fdb5
push 0x30
push 0
push esi
call fcn.005b4520
add esp, 0xc
mov byte [esi], 0x62
mov word [esi + 0x1e], 0xffff
mov dword [esi + 0x2c], 1
test esi, esi
mov edi, dword [ebp]
jne 0x54fdcf
push esi
push edi
call fcn.00540330
push esi
push edi
call fcn.00540330
add esp, 0x10
jmp 0x54fdd4
call fcn.00538330
mov eax, esi
mov edx, dword [esp + 0x1c]
mov ecx, eax
mov eax, ebp
call fcn.00546260
test eax, eax
mov dword [esp + 0x1c], eax
je 0x54fe2d
cmp dword [esp + 0x50], 0
mov ecx, dword [eax]
mov eax, dword [eax + 0xc]
mov esi, dword [ebp]
lea edx, [ecx + ecx*4]
lea ebx, [eax + edx*4 - 0x14]
jne 0x54fe05
xor esi, esi
jmp 0x54fe2a
mov edi, dword [esp + 0x38]
lea ecx, [edi + 1]
call fcn.0053c960
mov esi, eax
test esi, esi
je 0x54fe2a
mov ecx, dword [esp + 0x50]
push edi
push ecx
push esi
call fcn.005b64d0
add esp, 0xc
mov byte [esi + edi], 0
mov dword [ebx + 4], esi
mov eax, dword [esp + 0x6c]
mov edx, dword [esp + 0x74]
add eax, 1
cmp eax, dword [edx + 0x14]
mov dword [esp + 0x6c], eax
jl 0x54f8d0
mov eax, dword [esp + 0x20]
mov esi, dword [esp + 0x14]
push eax
push esi
call fcn.00531d40
mov ecx, dword [esp + 0x7c]
mov edx, dword [ecx]
mov ecx, dword [edx]
add esp, 8
test ecx, ecx
mov dword [esp + 0x3c], ecx
mov eax, ecx
je 0x54fe7f
cmp byte [ecx], 0
je 0x54fe78
mov edi, edi
add eax, 1
cmp byte [eax], 0
jne 0x54fe70
sub eax, ecx
and eax, 0x3fffffff
cmp dword [esp + 0x2c], 6
mov dword [esp + 0x24], eax
jne 0x54ff63
mov dword [esp + 0x60], ecx
push 0x38
push esi
mov ecx, str.foreign_key_constraint_failed
mov dword [esp + 0x6c], eax
call fcn.00545ae0
mov ebx, eax
add esp, 8
test ebx, ebx
mov dword [esp + 0x6c], ebx
je 0x54feb4
mov byte [ebx + 1], 2
mov ecx, 0x40
mov edi, esi
call fcn.0053c960
mov esi, eax
test esi, esi
je 0x54fefd
push 0x40
push 0
push esi
call fcn.005b4520
mov word [esi + 2], 1
movsx eax, word [esi]
add esp, 0xc
push eax
push 1
push edi
mov eax, esi
call fcn.00541450
add esp, 0xc
cmp byte [edi + 0x1e], 0
mov esi, eax
je 0x54ff01
push esi
mov esi, edi
call fcn.00539080
add esp, 4
xor esi, esi
jmp 0x54ff2f
movsx eax, word [esi]
lea ecx, [eax*8]
sub ecx, eax
push edi
lea eax, [esp + 0x64]
lea ebx, [esi + ecx*8 - 0x30]
call fcn.005410f0
mov dword [ebx + 4], eax
push edi
xor eax, eax
call fcn.005410f0
mov dword [ebx], eax
mov ebx, dword [esp + 0x74]
add esp, 8
mov edx, dword [esp + 0x18]
push 0
push 0
push 0
push 0
push 0
push 0
push edx
push esi
mov ecx, ebx
xor edx, edx
mov eax, ebp
call fcn.00546260
push ebp
call fcn.00548680
add esp, 0x24
mov dword [esp + 0x28], eax
mov dword [esp + 0x18], 0
jmp 0x54ff65
mov edi, esi
mov ebx, dword [esp + 0x24]
mov al, byte [edi + 0xea]
add ebx, 0x4d
mov ecx, ebx
mov esi, edi
mov byte [esp + 0x6c], al
mov byte [edi + 0xea], 0
call fcn.0053c960
mov esi, eax
test esi, esi
mov dword [esp + 0x20], esi
je 0x54ff9c
push ebx
push 0
push esi
call fcn.005b4520
add esp, 0xc
test esi, esi
mov dword [esp + 0x38], esi
je 0x550095
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x24]
lea ebx, [eax + 0x24]
mov dword [eax + 0x1c], ebx
push ecx
mov dword [ebx + 0x10], ecx
mov ecx, dword [esp + 0x40]
lea eax, [ebx + 0x28]
push ecx
push eax
mov dword [ebx + 0xc], eax
call fcn.005b64d0
mov edx, dword [esp + 0x24]
push 0
push 1
push edx
push edi
call fcn.0054dca0
mov dword [ebx + 0x14], eax
mov eax, dword [esp + 0x38]
push 1
push eax
push edi
call fcn.005403d0
mov ecx, dword [esp + 0x50]
push 1
push ecx
push edi
mov dword [ebx + 0x18], eax
call fcn.00546170
add esp, 0x34
cmp dword [esp + 0x10], 0
mov dword [ebx + 8], eax
je 0x550099
mov esi, dword [ebp]
mov ecx, 0x30
call fcn.0053c960
mov esi, eax
test esi, esi
je 0x55003b
push 0x30
push 0
push esi
call fcn.005b4520
add esp, 0xc
mov byte [esi], 0x13
mov word [esi + 0x1e], 0xffff
mov dword [esi + 0x2c], 1
test esi, esi
mov ebp, dword [ebp]
jne 0x550059
mov edx, dword [esp + 0x10]
push edx
push ebp
call fcn.00540330
push esi
push ebp
call fcn.00540330
add esp, 0x10
jmp 0x55007a
mov eax, dword [esp + 0x10]
mov ecx, 0x100
mov dword [esi + 8], eax
test word [eax + 2], cx
je 0x550075
or word [esi + 2], cx
mov eax, dword [eax + 0x14]
mov dword [esi + 0x14], eax
call fcn.00538330
push 0
push 1
push esi
push edi
mov dword [esp + 0x20], esi
call fcn.0054dca0
mov ecx, dword [esp + 0x30]
add esp, 0x10
mov dword [ecx + 0xc], eax
jmp 0x550099
mov ebx, dword [esp + 0x40]
mov eax, dword [esp + 0x18]
mov dl, byte [esp + 0x6c]
push eax
push edi
mov byte [edi + 0xea], dl
call fcn.00540330
mov ecx, dword [esp + 0x18]
push ecx
push edi
call fcn.00540330
mov edx, dword [esp + 0x2c]
push edx
call fcn.00538470
mov esi, dword [esp + 0x3c]
add esp, 0x14
test esi, esi
je 0x5500df
push esi
push edi
call fcn.00539b10
push esi
push edi
call fcn.00531d40
add esp, 0x10
cmp byte [edi + 0x1e], 1
jne 0x5500fc
mov ebx, dword [esp + 0x20]
mov eax, dword [esp + 0x14]
call fcn.00541850
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x58
ret
mov eax, dword [esp + 0x2c]
cmp eax, 6
je 0x55011b
cmp eax, 9
jne 0x550116
cmp dword [esp + 0x78], 0
jne 0x550116
mov byte [ebx], 0x6a
jmp 0x55011e
mov byte [ebx], 0x6b
jmp 0x55011e
mov byte [ebx], 0x74
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x70]
cmp dword [esp + 0x78], 0
mov dword [ebx + 4], eax
mov edx, dword [ecx + 0x40]
mov dword [eax + 0x14], edx
mov ecx, dword [ecx + 0x40]
mov edx, dword [esp + 0x74]
mov dword [eax + 0x18], ecx
mov ecx, dword [esp + 0x44]
mov dword [edx + ecx*4 + 0x1c], eax
setne dl
add dl, 0x6a
mov byte [eax + 8], dl
mov eax, dword [esp + 0x38]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x58
ret