Function at 0x519c10
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
movzx eax, byte [ebx + 0x1ca]
push esi
push edi
mov edi, dword [ebx]
test dword [edi + 0x18], 0x4000000
mov dword [ebp - 8], edi
mov dword [ebp - 0x28], eax
je 0x51a165
mov ecx, dword [ebp + 8]
mov esi, dword [ecx + 0x44]
xor edx, edx
mov dword [ebp - 0xc], 0xfff0bdc0
cmp esi, edx
je 0x519c76
mov ecx, dword [edi + 0x14]
mov dword [ebp - 0xc], edx
cmp ecx, edx
jle 0x519c76
mov eax, dword [edi + 0x10]
add eax, 0xc
jmp 0x519c62
xor edx, edx
cmp dword [eax], esi
je 0x519c76
mov edx, dword [ebp - 0xc]
inc edx
add eax, 0x10
mov dword [ebp - 0xc], edx
cmp edx, ecx
jl 0x519c60
xor edx, edx
mov eax, dword [ebp - 0xc]
mov ecx, dword [edi + 0x10]
add eax, eax
mov eax, dword [ecx + eax*8]
mov ecx, dword [ebp + 8]
mov dword [ebp - 0x24], eax
mov eax, dword [ecx + 0x24]
mov dword [ebp - 4], eax
cmp eax, edx
je 0x519e11
jmp 0x519ca5
mov edi, dword [ebp - 8]
xor edx, edx
cmp byte [ebx + 0x1ca], 0
mov dword [ebp - 0x14], edx
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x1c], edx
je 0x519cd0
mov edx, dword [ebp - 0x24]
mov eax, dword [ebp - 4]
mov ecx, dword [eax + 8]
push edx
push ecx
push edi
call fcn.0050f4a0
add esp, 0xc
jmp 0x519e74
mov esi, dword [ebx]
cmp byte [esi + 0x7d], 0
mov edx, dword [ebp - 4]
mov edi, dword [edx + 8]
jne 0x519e28
lea eax, [ebx + 4]
push eax
call fcn.005222f0
add esp, 4
test eax, eax
je 0x519e28
inc dword [ebx + 0x44]
mov dword [ebx + 0xc], eax
xor esi, esi
cmp dword [ebp - 0x28], 0
je 0x51a165
mov eax, dword [ebp - 8]
cmp byte [eax + 0x36], 0
jne 0x51a165
test esi, esi
jne 0x519e00
mov edi, dword [ebx + 8]
test edi, edi
jne 0x519d41
mov eax, dword [ebx]
call fcn.004f6950
mov edi, eax
mov dword [ebx + 8], eax
test edi, edi
je 0x519d41
push 0x94
call fcn.004f6ab0
add esp, 4
mov ecx, dword [ebp - 4]
mov eax, dword [ecx + 0x14]
mov edx, dword [edi + 0x1c]
lea edx, [eax + edx + 1]
mov dword [ebp - 0x18], edx
mov dword [ebp - 0x10], 0
test eax, eax
jle 0x519dbe
add ecx, 0x24
mov dword [ebp - 0x20], ecx
mov eax, dword [ebp - 0x20]
mov ecx, dword [eax]
mov edx, dword [ebp + 0xc]
mov esi, dword [edi + 0x1c]
lea eax, [edx + ecx + 1]
mov dword [ebp - 0x1c], eax
cmp dword [edi + 0x20], esi
jg 0x519d82
call fcn.004f69d0
test eax, eax
jne 0x519dab
mov edx, dword [edi + 4]
inc dword [edi + 0x1c]
lea ecx, [esi + esi*4]
lea eax, [edx + ecx*4]
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x18]
mov dword [eax + 4], ecx
xor ecx, ecx
mov byte [eax + 3], 0
mov dword [eax + 8], edx
mov dword [eax + 0xc], ecx
mov dword [eax + 0x10], ecx
mov word [eax], 0x49
mov eax, dword [ebp - 0x10]
mov ecx, dword [ebp - 4]
add dword [ebp - 0x20], 8
inc eax
mov dword [ebp - 0x10], eax
cmp eax, dword [ecx + 0x14]
jl 0x519d62
movzx eax, byte [ecx + 0x18]
mov esi, dword [edi + 0x1c]
mov dword [ebp - 0x20], eax
cmp dword [edi + 0x20], esi
jg 0x519dd6
call fcn.004f69d0
test eax, eax
jne 0x519e00
mov edx, dword [edi + 4]
inc dword [edi + 0x1c]
lea ecx, [esi + esi*4]
lea eax, [edx + ecx*4]
mov ecx, dword [ebp - 0x20]
mov dword [eax + 4], ecx
xor ecx, ecx
mov byte [eax + 3], 0
mov dword [eax + 8], 0xffffffff
mov dword [eax + 0xc], ecx
mov dword [eax + 0x10], ecx
mov word [eax], 0x75
mov edx, dword [ebp - 4]
mov eax, dword [edx + 4]
mov dword [ebp - 4], eax
test eax, eax
jne 0x519ca0
mov edx, dword [ebp + 8]
mov ecx, dword [edx]
mov dword [ebp - 0x2c], ecx
mov eax, ecx
test ecx, ecx
jne 0x519fa1
jmp 0x519fb3
mov esi, dword [ebp - 0x24]
mov ecx, dword [ebx]
push esi
push edi
push ecx
call fcn.0050f4a0
add esp, 0xc
mov dword [ebp - 0x18], eax
test eax, eax
jne 0x519e74
push edi
test esi, esi
je 0x519e5a
push esi
push str.no_such_table
push str._s:__s._s
push ebx
call fcn.004dd1d0
add esp, 0x14
jmp 0x519e6d
push str.no_such_table
push str._s:__s
push ebx
call fcn.004dd1d0
add esp, 0x10
mov eax, dword [ebp - 0x18]
mov byte [ebx + 0x11], 1
mov esi, eax
test esi, esi
je 0x519cfe
mov eax, dword [ebp - 4]
lea edx, [ebp - 0x14]
push edx
push eax
push esi
push ebx
lea eax, [ebp - 0x20]
call fcn.00518820
add esp, 0x10
test eax, eax
jne 0x519cfe
mov edi, dword [ebp - 0x20]
test edi, edi
je 0x519ea7
mov dword [ebp - 0x18], edi
jmp 0x519eb8
mov ecx, dword [ebp - 4]
mov edx, dword [ecx + 0x24]
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x2c], edx
mov dword [ebp - 0x18], eax
mov edi, eax
mov ecx, dword [ebp - 4]
xor eax, eax
mov dword [ebp - 0x10], eax
cmp dword [ecx + 0x14], eax
jle 0x519f2d
mov edx, dword [edi + eax*4]
mov ecx, dword [ebp + 8]
cmp edx, dword [ecx + 4]
jne 0x519ed7
mov dword [edi + eax*4], 0xffffffff
mov edx, dword [ebp - 8]
cmp dword [edx + 0x10c], 0
je 0x519f21
mov ecx, dword [ebp - 0x14]
test ecx, ecx
je 0x519ef2
mov ecx, dword [ecx + 4]
mov eax, dword [ecx + eax*4]
jmp 0x519ef5
mov eax, dword [esi + 4]
mov ecx, dword [ebp - 0xc]
lea edx, [eax + eax*2]
mov eax, dword [esi + 0xc]
mov eax, dword [eax + edx*8]
mov edx, dword [esi]
push ecx
push eax
push edx
mov edi, ebx
call fcn.0050ecc0
mov edi, dword [ebp - 0x18]
xor ecx, ecx
add esp, 0xc
cmp eax, 2
mov eax, dword [ebp - 0x10]
sete cl
mov dword [ebp - 0x1c], ecx
mov edx, dword [ebp - 4]
inc eax
mov dword [ebp - 0x10], eax
cmp eax, dword [edx + 0x14]
jl 0x519ec5
mov eax, dword [esi]
mov ecx, dword [esi + 0x14]
mov edx, dword [ebp - 0xc]
push eax
push 0
push ecx
push edx
mov eax, ebx
call fcn.0050ef00
mov eax, dword [ebp + 0xc]
inc dword [ebx + 0x48]
add esp, 0x10
test eax, eax
je 0x519f6c
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ebp - 4]
push ecx
mov ecx, dword [ebp - 0xc]
push 0xffffffffffffffff
push eax
mov eax, dword [ebp - 0x14]
push edi
push edx
push eax
push esi
push ecx
push ebx
call fcn.00518a40
add esp, 0x24
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x519f91
mov edx, dword [ebp - 0x1c]
mov ecx, dword [ebp - 0x14]
push edx
mov edx, dword [ebp - 0xc]
push 1
push eax
mov eax, dword [ebp - 4]
push edi
push eax
push ecx
push esi
push edx
push ebx
call fcn.00518a40
add esp, 0x24
mov eax, dword [ebp - 0x20]
mov ecx, dword [ebp - 8]
call fcn.004daf00
jmp 0x519e00
cmp byte [ecx], 0
je 0x519fac
inc eax
cmp byte [eax], 0
jne 0x519fa6
sub eax, ecx
and eax, 0x3fffffff
mov esi, dword [edx + 0x44]
add esi, 0x38
cmp dword [esi + 0xc], 0
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x24], esi
je 0x519ffa
mov edx, eax
xor eax, eax
cmp edx, eax
jle 0x519ff1
lea ecx, [ecx]
movzx esi, byte [ecx]
movzx esi, byte [esi + 0x66da38]
lea edi, [eax*8]
xor esi, edi
dec edx
xor eax, esi
inc ecx
test edx, edx
jg 0x519fd0
mov ecx, dword [ebp - 0x2c]
mov esi, dword [ebp - 0x24]
xor edx, edx
div dword [esi]
mov eax, dword [ebp - 0x20]
jmp 0x519ffc
xor edx, edx
push eax
push ecx
mov eax, esi
call fcn.004de500
add esp, 8
test eax, eax
je 0x51a165
mov edi, dword [eax + 8]
xor esi, esi
cmp edi, esi
je 0x51a165
lea ecx, [ecx]
cmp byte [edi + 0x18], 0
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x14], esi
jne 0x51a03e
cmp dword [ebx + 0x1b0], esi
jne 0x51a03e
cmp byte [ebx + 0x17], 0
je 0x51a15a
mov ecx, dword [ebp + 8]
lea eax, [ebp - 0x20]
push eax
push edi
push ecx
push ebx
lea eax, [ebp - 0x14]
call fcn.00518820
add esp, 0x10
test eax, eax
je 0x51a072
cmp dword [ebp - 0x28], esi
je 0x51a165
mov edx, dword [ebp - 8]
cmp byte [edx + 0x36], 0
jne 0x51a165
jmp 0x51a15a
mov esi, dword [ebp - 8]
mov ecx, 0x48
call fcn.004db140
mov esi, eax
test esi, esi
je 0x51a14d
push 0x48
push 0
push esi
call fcn.005ff630
mov eax, 1
mov word [esi + 2], ax
movsx ecx, word [esi]
add esp, 0xc
push ecx
mov ecx, dword [ebp - 8]
push eax
mov eax, esi
call fcn.00513290
mov esi, eax
mov eax, dword [ebp - 8]
add esp, 8
cmp byte [eax + 0x36], 0
jne 0x51a144
movsx edx, word [esi]
shl edx, 6
mov dword [edx + esi - 0x34], 0
mov dword [edx + esi - 0x38], 0
lea eax, [edx + esi - 0x38]
mov eax, dword [edi]
mov dword [esi + 0x14], eax
mov ecx, dword [edi]
mov edx, dword [ecx]
mov dword [esi + 0xc], edx
mov ecx, 1
add word [eax + 0x20], cx
mov eax, dword [ebx + 0x48]
mov dword [esi + 0x28], eax
mov eax, dword [ebp + 0x10]
add dword [ebx + 0x48], ecx
test eax, eax
je 0x51a119
mov ecx, dword [ebp - 0x14]
mov edx, dword [ebp - 0x20]
push 0xffffffffffffffff
push eax
mov eax, dword [ebp + 8]
push ecx
push edi
push edx
push eax
push esi
push ebx
call fcn.00519510
add esp, 0x20
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x51a13a
mov ecx, dword [ebp - 0x14]
mov edx, dword [ebp - 0x20]
push 1
push eax
mov eax, dword [ebp + 8]
push ecx
push edi
push edx
push eax
push esi
push ebx
call fcn.00519510
add esp, 0x20
mov eax, dword [ebp - 8]
mov dword [esi + 0xc], 0
push esi
call fcn.005134b0
add esp, 4
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 8]
call fcn.004daf00
xor esi, esi
mov edi, dword [edi + 0xc]
cmp edi, esi
jne 0x51a020
pop edi
pop esi
mov esp, ebp
pop ebp
ret