Function at 0x4974c0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffff24
push ebx
push esi
push edi
mov esi, edx
mov dword [ebp - 8], eax
xor ecx, ecx
cmp dword [ebp - 8], 0
je 0x4974fb
mov eax, dword [ebp - 8]
cmp dword [eax + 0x24], 0
jne 0x4974e6
cmp dword [eax + 0x20], 0
je 0x497d62
mov eax, dword [ebp - 8]
cmp dword [eax + 0x1c], 0
je 0x497d62
jmp 0x49751d
test esi, esi
je 0x497d62
cmp dword [esi + 8], 0
jne 0x49750d
cmp dword [esi + 4], 0
je 0x497d62
cmp dword [esi + 0x10], 0
je 0x497d62
mov eax, 0x3184
call fcn.0040d864
mov ebx, eax
xor eax, eax
mov dword [ebp - 0x10], eax
mov dword [ebp - 4], ebx
cmp dword [ebp - 8], 0
je 0x497592
mov eax, dword [ebp - 8]
mov esi, eax
lea edi, [ebx + 0x20c]
mov ecx, 0x41b
rep movsd dword es:[edi], dword [esi]
xor eax, eax
mov dword [ebx + 0x1284], eax
mov dword [ebx + 0x278], 0
mov dword [ebx + 0x27c], 0
mov dword [ebx + 0x280], 0
mov dword [ebx + 0x284], 0
mov dword [ebx + 0x288], 0
mov dword [ebx + 0x28c], 0
jmp 0x4977f9
mov edx, dword [esi + 0xc]
dec edx
test edx, edx
jl 0x4975fe
inc edx
xor eax, eax
imul ecx, eax, 0x214
mov edi, dword [esi + 0x2c]
mov dword [edi + ecx*8 + 0x80], 0
mov dword [edi + ecx*8 + 0x84], 0
imul ecx, eax, 0x214
mov edi, dword [esi + 0x2c]
mov dword [edi + ecx*8 + 0x88], 0
mov dword [edi + ecx*8 + 0x8c], 0
imul ecx, eax, 0x214
mov edi, dword [esi + 0x2c]
mov dword [edi + ecx*8 + 0x90], 0
mov dword [edi + ecx*8 + 0x94], 0
inc eax
dec edx
jne 0x49759d
mov eax, dword [esi + 0x2c]
push esi
lea esi, [eax + 0x14]
lea edi, [ebx + 0x20c]
mov ecx, 0x41b
rep movsd dword es:[edi], dword [esi]
pop esi
mov edx, dword [esi + 0xc]
dec edx
test edx, edx
jl 0x497650
inc edx
xor eax, eax
imul ecx, eax, 0x214
mov edi, dword [esi + 0x2c]
cmp byte [edi + ecx*8 + 0x1c], 0
jne 0x49764c
imul edx, eax, 0x214
mov ecx, dword [esi + 0x2c]
push esi
lea esi, [ecx + edx*8 + 0x14]
lea edi, [ebx + 0x20c]
mov ecx, 0x41b
rep movsd dword es:[edi], dword [esi]
pop esi
jmp 0x497650
inc eax
dec edx
jne 0x49761e
mov edx, dword [esi + 0xc]
dec edx
test edx, edx
jl 0x497693
inc edx
xor eax, eax
imul ecx, eax, 0x214
mov edi, dword [esi + 0x2c]
cmp dword [edi + ecx*8 + 0x7c], 0
je 0x49768f
imul edx, eax, 0x214
mov ecx, dword [esi + 0x2c]
mov edx, dword [ecx + edx*8 + 0x7c]
mov dword [ebx + 0x274], edx
imul edx, eax, 0x214
mov ecx, dword [esi + 0x2c]
xor edi, edi
mov dword [ecx + edx*8 + 0x7c], edi
jmp 0x497693
inc eax
dec edx
jne 0x49765b
push esi
lea edi, [ebx + 0x1278]
mov ecx, 0x9a
rep movsd dword es:[edi], dword [esi]
pop esi
mov dword [ebx + 0x218], 0xffffffff
mov eax, dword [ebx + 0x127c]
mov dword [ebx + 0x22c], eax
mov eax, dword [ebx + 0x1280]
mov dword [ebx + 0x230], eax
mov eax, dword [ebx + 0x1288]
mov dword [ebx + 0x228], eax
mov word [ebx + 0x224], 0xff
mov di, 0x3f
mov word [ebx + 0x226], di
cmp dword [ebx + 0x1280], 0
jne 0x4976fc
cmp dword [ebx + 0x127c], 0
jae 0x497786
jmp 0x497702
jge 0x497786
movzx eax, word [ebx + 0x224]
movzx edx, di
imul edx
xor edx, edx
push edx
push eax
mov eax, dword [ebx + 0x127c]
mov edx, dword [ebx + 0x1280]
neg eax
adc edx, 0
neg edx
call fcn.00405210
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
jbe 0x497749
movzx eax, word [ebx + 0x224]
movzx edx, word [ebx + 0x226]
imul edx
sub eax, dword [ebp - 4]
mov dword [ebp - 4], eax
movzx eax, word [ebx + 0x224]
movzx edx, word [ebx + 0x226]
imul edx
xor edx, edx
push edx
push eax
mov eax, dword [ebx + 0x127c]
mov edx, dword [ebx + 0x1280]
push edx
push eax
mov eax, dword [ebp - 4]
xor edx, edx
sub dword [esp], eax
sbb dword [esp + 4], edx
pop eax
pop edx
call fcn.0040517c
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], edx
jmp 0x4977d5
movzx eax, word [ebx + 0x224]
movzx edx, di
imul edx
xor edx, edx
push edx
push eax
mov eax, dword [ebx + 0x127c]
mov edx, dword [ebx + 0x1280]
call fcn.00405210
mov dword [ebp - 4], eax
movzx eax, word [ebx + 0x224]
movzx edx, word [ebx + 0x226]
imul edx
xor edx, edx
push edx
push eax
mov eax, dword [ebx + 0x127c]
mov edx, dword [ebx + 0x1280]
call fcn.0040517c
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], edx
mov eax, dword [ebp - 0x38]
mov dword [ebx + 0x21c], eax
mov eax, dword [ebp - 0x34]
mov dword [ebx + 0x220], eax
mov eax, ebx
call fcn.004807d8
test al, al
jne 0x4977f9
mov eax, esi
call fcn.00492a14
mov eax, dword [0x66d234]
mov eax, dword [eax]
mov eax, dword [eax + 0x434]
mov edx, eax
shl edx, 0x10
shr eax, 0x10
or edx, eax
mov eax, dword [0x66d234]
mov eax, dword [eax]
mov eax, dword [eax + 0x438]
xor eax, edx
xor eax, 0x230a4cf0
mov dword [ebx + 0x2664], eax
mov edx, dword [0x66d234]
mov edx, dword [edx]
test byte [edx + 0x437], 0x80
je 0x497860
mov edx, eax
and edx, 0xff
shl edx, 0x18
mov ecx, eax
and ecx, 0xff00
shl ecx, 8
or edx, ecx
and eax, 0xffff0000
xor edx, eax
mov dword [ebx + 0x2664], edx
mov eax, dword [ebp - 8]
xor dword [ebp - 4], eax
lea esi, [ebx + 0x21c]
lea edi, [ebx + 0x14e4]
mov ecx, 8
rep movsd dword es:[edi], dword [esi]
mov edx, dword [ebx + 0x14f0]
mov dword [ebx + 0x14e0], edx
mov edx, dword [0x66d74c]
mov edx, dword [edx]
mov dword [ebx + 0x264c], edx
mov dword [ebx + 0x309c], eax
mov byte [ebx + 0x304c], 0
mov dword [ebx + 0x3094], 0xffffffff
mov dword [ebx + 0x2658], 0xffffffff
mov dword [ebx + 0x265c], 0xffffffff
mov dword [ebx + 0x2660], 0xffffffff
mov eax, dword [0x66d5b4]
mov eax, dword [eax]
xor edx, edx
mov dword [ebp - 0x40], eax
mov dword [ebp - 0x3c], edx
cmp dword [ebp - 0x3c], 0
jne 0x4978e5
cmp dword [ebp - 0x40], 0
jae 0x497945
jmp 0x4978e7
jge 0x497945
mov eax, dword [ebx + 0x14e0]
xor edx, edx
push edx
push eax
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 0x3c]
neg eax
adc edx, 0
neg edx
call fcn.00405210
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
jbe 0x497918
mov eax, dword [ebx + 0x14e0]
sub eax, dword [ebp - 4]
mov dword [ebp - 4], eax
mov eax, dword [ebx + 0x14e0]
xor edx, edx
push edx
push eax
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 0x3c]
push edx
push eax
mov eax, dword [ebp - 4]
xor edx, edx
sub dword [esp], eax
sbb dword [esp + 4], edx
pop eax
pop edx
call fcn.0040517c
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x44], edx
jmp 0x497978
mov eax, dword [ebx + 0x14e0]
xor edx, edx
push edx
push eax
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 0x3c]
call fcn.00405210
mov dword [ebp - 4], eax
mov eax, dword [ebx + 0x14e0]
xor edx, edx
push edx
push eax
mov eax, dword [ebp - 0x40]
mov edx, dword [ebp - 0x3c]
call fcn.0040517c
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x44], edx
mov eax, dword [ebp - 0x48]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp - 0xc]
xor edx, edx
cmp edx, dword [ebx + 0x14f8]
jne 0x497995
cmp eax, dword [ebx + 0x14f4]
jbe 0x4979a0
jmp 0x497997
jle 0x4979a0
mov eax, dword [ebx + 0x14f4]
mov dword [ebp - 0xc], eax
xor eax, eax
mov dword [ebp - 4], eax
mov eax, dword [ebx + 0xf14]
mov dword [ebp - 0x18], eax
mov eax, dword [ebx + 0xf18]
mov dword [ebp - 0x14], eax
mov eax, dword [ebp - 0x18]
mov edx, dword [ebp - 0x14]
cmp edx, 0
jne 0x4979c5
cmp eax, 0
je 0x497a7a
lea eax, [ebx + 0xf26]
mov edx, dword [eax]
mov dword [ebp - 0x20], edx
mov edx, dword [eax + 4]
mov dword [ebp - 0x1c], edx
mov eax, dword [ebp - 0x20]
mov edx, dword [ebp - 0x1c]
cmp edx, 0
jne 0x4979ea
cmp eax, 0
je 0x497a7a
lea edx, [ebx + 0xf26]
xor eax, eax
mov ecx, 0x10
sub ecx, eax
movzx esi, word [edx]
shr esi, cl
mov ecx, eax
mov edi, 1
shl edi, cl
dec edi
and esi, edi
mov ecx, eax
movsx edi, word [edx]
shl edi, cl
and edi, 0xffff
or esi, edi
xor dword [ebp - 4], esi
add edx, 2
inc eax
cmp eax, 0xa
jne 0x4979f8
movzx eax, word [ebp - 2]
xor word [ebp - 4], ax
movzx eax, word [ebp - 4]
movzx edx, ax
shr edx, 8
and ax, 0xff
shl eax, 8
or dx, ax
mov word [ebp - 2], dx
movzx eax, word [ebp - 2]
lea edx, [ebx + 0xf14]
xor ax, word [edx]
lea edx, [ebx + 0xf14]
xor ax, word [edx + 2]
lea edx, [ebx + 0xf14]
xor ax, word [edx + 4]
lea edx, [ebx + 0xf14]
xor ax, word [edx + 6]
mov word [ebp - 2], ax
lea eax, [ebx + 0x1504]
call fcn.00497380
lea eax, [ebx + 0x253c]
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebx + 0x14e0]
call fcn.00467584
mov eax, dword [0x66d46c]
movzx eax, byte [eax]
mov byte [ebx + 0x25c4], al
mov eax, ebx
call fcn.00488e24
mov eax, dword [ebp - 4]
mov dword [ebx + 0x309c], eax
xor eax, eax
mov dword [ebp - 4], eax
cmp byte [ebx + 0x214], 0
jne 0x497b4f
mov eax, ebx
call fcn.004807d8
test al, al
jne 0x497b4f
cmp byte [ebx + 0x216], 0
je 0x497b4f
mov eax, dword [ebx + 0xf14]
mov dword [ebp - 0x28], eax
mov eax, dword [ebx + 0xf18]
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x28]
mov edx, dword [ebp - 0x24]
cmp edx, 0
jne 0x497afd
cmp eax, 0
je 0x497b4f
lea eax, [ebx + 0xf26]
mov edx, dword [eax]
mov dword [ebp - 0x30], edx
mov edx, dword [eax + 4]
mov dword [ebp - 0x2c], edx
mov eax, dword [ebp - 0x30]
mov edx, dword [ebp - 0x2c]
cmp edx, 0
jne 0x497b1e
cmp eax, 0
je 0x497b4f
lea eax, [ebx + 0xf3a]
mov eax, dword [eax]
mov dword [ebp - 0x10], eax
lea eax, [ebx + 0xf3e]
mov eax, dword [eax]
xor dword [ebp - 0x10], eax
lea eax, [ebx + 0xf42]
mov eax, dword [eax]
xor dword [ebp - 0x10], eax
mov byte [ebx + 0x304c], 1
xor dword [ebp - 0x10], 0x2eebf30a
xor eax, eax
mov dword [ebx + 0x2528], eax
xor eax, eax
mov dword [ebx + 0x252c], eax
xor eax, eax
mov dword [ebx + 0x2530], eax
xor eax, eax
mov dword [ebx + 0x2534], eax
xor eax, eax
mov dword [ebx + 0x2538], eax
mov dword [ebx + 0x27f0], 0xaa55ecec
xor eax, eax
mov dword [ebx + 0x250c], eax
xor eax, eax
mov dword [ebx + 0x2510], eax
xor eax, eax
mov dword [ebx + 0x2514], eax
xor eax, eax
mov dword [ebx + 0x251c], eax
mov byte [ebx + 0x2809], 0
xor eax, eax
mov dword [ebx + 0x280c], eax
xor eax, eax
mov dword [ebx + 0x2650], eax
xor eax, eax
mov dword [ebx + 0x2624], eax
xor eax, eax
mov dword [ebx + 0x2628], eax
mov eax, dword [0x66d5bc]
cmp byte [eax], 0
sete al
mov byte [ebx + 0x3046], al
cmp byte [ebx + 0x255], 0
je 0x497c41
cmp byte [ebx + 0x304c], 0
je 0x497c41
mov eax, dword [0x66d1d0]
mov edx, 0xfffffffe
call fcn.004424f0
mov eax, dword [0x66d5f4]
mov edx, 1
call fcn.004424f0
mov edx, dword [ebp - 0x10]
xor edx, 0x7cf26abd
or edx, 0x80000000
and edx, 0xfffffffe
mov eax, dword [0x66d1d0]
call fcn.004424e4
mov edx, dword [ebp - 0x10]
xor edx, 0x7cf26abd
or edx, 0x80000000
and edx, 1
mov eax, dword [0x66d5f4]
call fcn.004424e4
mov dword [ebp - 0x4c], ebx
mov esi, 0x4b6cdf11
mov dword [ebp - 0x50], esi
mov eax, dword [0x66d660]
mov dword [ebp - 0x54], eax
lea eax, [ebp - 0xdc]
mov dword [ebp - 0x58], eax
mov dword [ebp - 0x5c], 0x80
xor esi, esi
xor edx, edx
mov eax, dword [ebp - 0x54]
movzx eax, byte [eax + esi]
cmp dl, 4
jne 0x497c86
mov edx, esi
sub edx, 4
add edx, dword [ebp - 0x54]
mov edx, dword [edx]
add edx, dword [ebp - 0x50]
mov dword [ebp - 0x50], edx
xor edx, edx
movzx ecx, dl
lea edi, [ebp - 0x50]
movzx ecx, byte [edi + ecx]
xor al, cl
inc edx
mov ecx, dword [ebp - 0x58]
lea edi, [ecx + esi]
mov byte [edi], al
cmp dword [ebp - 0x5c], 0
jle 0x497caa
cmp dword [ebp - 0x5c], 1
je 0x497cb5
dec dword [ebp - 0x5c]
inc esi
cmp dword [ebp - 0x5c], 0
jne 0x497c68
test al, al
jne 0x497c68
mov eax, dword [ebp - 0x4c]
mov eax, dword [eax + 0x14f4]
mov esi, eax
lea edx, [ebp - 0xdc]
mov ecx, 0x80
mov eax, esi
call fcn.00461634
xor eax, 0xb64b16c6
xor eax, 0x8f1f1f4c
mov edx, dword [ebp - 0x4c]
mov dword [edx + 0x30a0], eax
lea eax, [ebp - 0xdc]
xor ecx, ecx
mov edx, 0x80
call fcn.004032f4
mov eax, ebx
call fcn.004807e0
lea eax, [ebx + 0xf26]
xor ecx, ecx
mov edx, 0x14
call fcn.004032f4
lea eax, [ebx + 0xf3a]
xor ecx, ecx
mov edx, 0x28
call fcn.004032f4
mov eax, 0x497d6c
call fcn.00461788
movzx eax, al
mov dword [ebx + 0x2818], eax
mov eax, 0x497d84
call fcn.00461788
push eax
mov eax, 0x497d98
call fcn.00461788
pop edx
xor dl, al
movzx eax, dl
mov dword [ebx + 0x3024], eax
mov dword [ebx + 0x3180], 0x497338
mov ecx, ebx
mov eax, ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret