Function at 0x4a2580
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x28
push ebx
push esi
push edi
mov edi, eax
mov esi, dword [edi]
test dword [esi + 0xc], 0x4000000
movzx eax, byte [edi + 0x1ba]
mov dword [ebp - 4], esi
mov dword [ebp - 0x24], eax
je 0x4a2b03
cmp dword [edi + 0xc], 0
jne 0x4a25c8
mov eax, esi
call fcn.004818c0
mov dword [edi + 0xc], eax
test eax, eax
je 0x4a25c8
push 0x84
call fcn.00481a90
add esp, 4
mov ebx, dword [ebp + 8]
mov edx, dword [ebx + 0x44]
mov eax, 0xfff0bdc0
mov dword [ebp - 0xc], eax
test edx, edx
je 0x4a2600
xor eax, eax
mov dword [ebp - 0xc], eax
cmp dword [esi + 4], eax
jle 0x4a2600
mov ecx, dword [esi + 8]
add ecx, 0xc
lea ebx, [ebx]
cmp dword [ecx], edx
je 0x4a25fd
inc eax
add ecx, 0x10
cmp eax, dword [esi + 4]
jl 0x4a25f0
mov dword [ebp - 0xc], eax
mov ecx, dword [esi + 8]
add eax, eax
mov edx, dword [ecx + eax*8]
mov eax, dword [ebx + 0x24]
mov dword [ebp - 0x20], edx
mov dword [ebp - 8], eax
test eax, eax
je 0x4a269a
mov ebx, eax
jmp 0x4a2623
mov ebx, dword [ebp - 8]
xor eax, eax
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], eax
cmp byte [edi + 0x1ba], al
je 0x4a264f
mov eax, dword [ebp - 0x20]
mov ecx, dword [ebx + 8]
mov edx, dword [ebp - 4]
push eax
push ecx
push edx
call fcn.00497fc0
add esp, 0xc
jmp 0x4a2701
mov esi, dword [edi]
cmp byte [esi + 0x7c], 0
mov eax, dword [ebp - 8]
mov ebx, dword [eax + 8]
jne 0x4a26b2
lea ecx, [edi + 8]
push ecx
call fcn.004aa700
add esp, 4
test eax, eax
je 0x4a26b2
inc dword [edi + 0x40]
mov dword [edi + 4], eax
cmp dword [ebp - 0x24], 0
je 0x4a2b03
mov eax, dword [ebp - 4]
cmp byte [eax + 0x1e], 0
jne 0x4a2b03
mov ecx, dword [ebp - 8]
mov eax, dword [ecx + 4]
mov dword [ebp - 8], eax
test eax, eax
jne 0x4a2620
mov ebx, dword [ebp + 8]
mov ecx, dword [ebx + 4]
mov dword [ebp - 0x28], ecx
mov eax, ecx
test ecx, ecx
jne 0x4a2857
mov dword [ebp - 0x14], ecx
jmp 0x4a2870
mov esi, dword [ebp - 0x20]
mov edx, dword [edi]
push esi
push ebx
push edx
call fcn.00497fc0
add esp, 0xc
mov dword [ebp - 0x10], eax
test eax, eax
jne 0x4a26fe
push ebx
test esi, esi
je 0x4a26e4
push esi
push str.no_such_table
push str._s:__s._s
push edi
call fcn.0046e510
add esp, 0x14
jmp 0x4a26f7
push str.no_such_table
push str._s:__s
push edi
call fcn.0046e510
add esp, 0x10
mov eax, dword [ebp - 0x10]
mov byte [edi + 0x12], 1
mov ebx, dword [ebp - 8]
mov esi, eax
test esi, esi
je 0x4a2673
lea eax, [ebp - 0x14]
push eax
push ebx
push esi
push edi
lea eax, [ebp - 0x1c]
call fcn.004a10a0
add esp, 0x10
test eax, eax
jne 0x4a2673
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x4a2731
mov dword [ebp - 0x10], eax
jmp 0x4a273d
mov ecx, dword [ebx + 0x24]
lea edx, [ebp - 0x28]
mov dword [ebp - 0x28], ecx
mov dword [ebp - 0x10], edx
mov eax, dword [ebp - 8]
xor ebx, ebx
cmp dword [eax + 0x14], ebx
jle 0x4a27b1
mov eax, dword [ebp - 0x10]
lea ebx, [ebx]
mov ecx, dword [eax + ebx*4]
mov edx, dword [ebp + 8]
cmp ecx, dword [edx + 8]
jne 0x4a2762
mov dword [eax + ebx*4], 0xffffffff
mov ecx, dword [ebp - 4]
cmp dword [ecx + 0xf8], 0
je 0x4a27a8
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x4a277d
mov edx, dword [eax + 8]
mov eax, dword [edx + ebx*4]
jmp 0x4a2780
mov eax, dword [esi + 8]
mov ecx, dword [esi + 0x10]
mov edx, dword [ebp - 0xc]
lea eax, [eax + eax*2]
mov eax, dword [ecx + eax*8]
push edx
push eax
mov eax, dword [esi + 4]
push eax
call fcn.00497790
xor ecx, ecx
add esp, 0xc
cmp eax, 2
mov eax, dword [ebp - 0x10]
sete cl
mov dword [ebp - 0x18], ecx
mov edx, dword [ebp - 8]
inc ebx
cmp ebx, dword [edx + 0x14]
jl 0x4a2750
mov eax, dword [esi + 4]
mov ecx, dword [esi + 0x18]
mov ebx, dword [ebp - 0xc]
push eax
push 0
push ecx
push ebx
mov eax, edi
call fcn.004979d0
mov eax, dword [ebp + 0xc]
inc dword [edi + 0x44]
add esp, 0x10
test eax, eax
je 0x4a27f1
mov edx, dword [ebp - 0x18]
mov ecx, dword [ebp - 8]
push edx
mov edx, dword [ebp - 0x14]
push 0xffffffffffffffff
push eax
mov eax, dword [ebp - 0x10]
push eax
push ecx
push edx
push esi
push ebx
push edi
call fcn.004a1330
add esp, 0x24
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x4a2816
mov ecx, dword [ebp - 0x18]
mov edx, dword [ebp - 0x10]
push ecx
mov ecx, dword [ebp - 0x14]
push 1
push eax
mov eax, dword [ebp - 8]
push edx
push eax
push ecx
push esi
push ebx
push edi
call fcn.004a1330
add esp, 0x24
mov ecx, dword [ebp - 0x1c]
test ecx, ecx
je 0x4a2849
mov eax, dword [ebp - 4]
cmp ecx, dword [eax + 0xf0]
jb 0x4a2849
cmp ecx, dword [eax + 0xf4]
jae 0x4a2849
mov edx, dword [eax + 0xec]
mov dword [ecx], edx
dec dword [eax + 0xe4]
mov dword [eax + 0xec], ecx
jmp 0x4a268a
push ecx
call fcn.0046c2e0
add esp, 4
jmp 0x4a268a
cmp byte [ecx], 0
je 0x4a2866
lea esp, [esp]
inc eax
cmp byte [eax], 0
jne 0x4a2860
sub eax, ecx
and eax, 0x3fffffff
mov dword [ebp - 0x14], eax
mov esi, dword [ebx + 0x44]
add esi, 0x34
cmp dword [esi + 0xc], 0
mov dword [ebp - 0x20], esi
je 0x4a28b7
mov edx, dword [ebp - 0x14]
xor eax, eax
cmp edx, eax
jle 0x4a28b1
jmp 0x4a2890
movzx esi, byte [ecx]
movzx esi, byte [esi + 0x58e240]
lea ebx, [eax*8]
xor esi, ebx
dec edx
xor eax, esi
inc ecx
test edx, edx
jg 0x4a2890
mov ecx, dword [ebp - 0x28]
mov esi, dword [ebp - 0x20]
xor edx, edx
div dword [esi]
jmp 0x4a28b9
xor edx, edx
mov eax, dword [ebp - 0x14]
push eax
push ecx
mov eax, esi
call fcn.0046f680
add esp, 8
test eax, eax
je 0x4a2b03
mov ebx, dword [eax + 8]
xor eax, eax
mov dword [ebp - 8], ebx
cmp ebx, eax
je 0x4a2b03
mov esi, dword [ebp - 4]
cmp byte [ebx + 0x18], 0
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0xc], eax
jne 0x4a2904
cmp dword [edi + 0x1a8], eax
jne 0x4a2904
cmp byte [edi + 0x158], 0
je 0x4a2af3
mov edx, dword [ebp + 8]
lea ecx, [ebp - 0x1c]
push ecx
push ebx
push edx
push edi
lea eax, [ebp - 0xc]
call fcn.004a10a0
add esp, 0x10
test eax, eax
je 0x4a2936
cmp dword [ebp - 0x24], 0
je 0x4a2b03
cmp byte [esi + 0x1e], 0
jne 0x4a2b03
jmp 0x4a2af3
cmp byte [esi + 0x1e], 0
mov eax, dword [ebp - 0xc]
jne 0x4a2ac0
cmp byte [esi + 0xe2], 0
je 0x4a298a
mov eax, 0x40
cmp ax, word [esi + 0xe0]
ja 0x4a298a
mov eax, dword [esi + 0xec]
test eax, eax
je 0x4a298a
mov ecx, dword [eax]
inc dword [esi + 0xe4]
mov dword [esi + 0xec], ecx
mov ecx, dword [esi + 0xe4]
cmp ecx, dword [esi + 0xe8]
jle 0x4a2986
mov dword [esi + 0xe8], ecx
mov esi, eax
jmp 0x4a29e4
cmp dword [0x5bd648], 0
je 0x4a29c5
mov eax, dword [0x5c3f40]
test eax, eax
je 0x4a29a6
push eax
call dword [0x5bd690]
add esp, 4
lea ebx, [ebp - 0x20]
mov eax, 0x40
call fcn.0046bf40
mov eax, dword [0x5c3f40]
test eax, eax
je 0x4a29d3
push eax
call dword [0x5bd698]
jmp 0x4a29d0
push 0x40
call dword [0x5bd660]
mov dword [ebp - 0x20], eax
add esp, 4
mov esi, dword [ebp - 0x20]
test esi, esi
jne 0x4a29e1
mov edx, dword [ebp - 4]
mov byte [edx + 0x1e], 1
mov ebx, dword [ebp - 8]
test esi, esi
je 0x4a2aba
push 0x40
push 0
push esi
call fcn.00530110
mov edx, dword [ebp - 4]
mov eax, 1
mov word [esi + 2], ax
movsx ecx, word [esi]
add esp, 0xc
push ecx
push eax
push edx
mov eax, esi
call fcn.0049bbe0
mov esi, eax
mov eax, dword [ebp - 4]
add esp, 0xc
cmp byte [eax + 0x1e], 0
jne 0x4a2ab1
movsx eax, word [esi]
lea ecx, [eax*8]
sub ecx, eax
mov dword [esi + ecx*8 - 0x2c], 0
mov dword [esi + ecx*8 - 0x30], 0
mov edx, dword [ebx]
lea eax, [esi + ecx*8 - 0x30]
mov dword [esi + 0x14], edx
mov eax, dword [ebx]
mov ecx, dword [eax + 4]
mov dword [esi + 0xc], ecx
mov eax, edx
mov ecx, 1
add word [eax + 0x20], cx
mov edx, dword [edi + 0x44]
mov eax, dword [ebp + 0x10]
mov dword [esi + 0x20], edx
add dword [edi + 0x44], ecx
test eax, eax
je 0x4a2a86
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ebp + 8]
push 0xffffffffffffffff
push eax
mov eax, dword [ebp - 0xc]
push eax
push ebx
push ecx
push edx
push esi
push edi
call fcn.004a1bc0
add esp, 0x20
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x4a2aa7
mov ecx, dword [ebp - 0x1c]
mov edx, dword [ebp + 8]
push 1
push eax
mov eax, dword [ebp - 0xc]
push eax
push ebx
push ecx
push edx
push esi
push edi
call fcn.004a1bc0
add esp, 0x20
mov eax, dword [ebp - 4]
mov dword [esi + 0xc], 0
push esi
call fcn.0049be30
add esp, 4
mov eax, dword [ebp - 0xc]
mov esi, dword [ebp - 4]
test eax, eax
je 0x4a2aea
cmp eax, dword [esi + 0xf0]
jb 0x4a2aea
cmp eax, dword [esi + 0xf4]
jae 0x4a2aea
mov ecx, dword [esi + 0xec]
mov dword [eax], ecx
dec dword [esi + 0xe4]
mov dword [esi + 0xec], eax
jmp 0x4a2af3
push eax
call fcn.0046c2e0
add esp, 4
mov ebx, dword [ebx + 0xc]
xor eax, eax
mov dword [ebp - 8], ebx
cmp ebx, eax
jne 0x4a28e3
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret