Function at 0x497500
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
push ebx
push esi
xor esi, esi
mov dword [ebp - 0x1c], edx
push edi
mov dword [ebp - 0xc], ecx
mov dword [ebp - 0x10], esi
mov dword [ebp - 0x14], esi
cmp dword [ecx + 0xa4], esi
jne case.default.0x497537
mov ecx, dword [ecx + 4]
mov ebx, dword [ebp + 0x10]
mov dword [ebp - 0x18], ecx
lea edi, [ecx - 3]
test ebx, ebx
je 0x4975a7
lea eax, [ebx - 3]
cmp eax, 5
ja case.default.0x497537
jmp dword [eax*4 + 0x4977b8]
mov ecx, 0x4f63e0
jmp 0x497566
mov ecx, 0x4f62f0
jmp 0x497566
mov ecx, 0x4f63b0
jmp 0x497566
mov ecx, 0x4f6320
jmp 0x497566
mov ecx, 0x4f6380
jmp 0x497566
mov ecx, 0x4f6350
mov eax, 0x4f5df0
cmp dword [0x4f5df0], esi
je case.default.0x497537
cmp dword [eax + 0x10], ebx
je 0x49758b
add eax, 0x14
cmp dword [eax], esi
jne 0x497573
pop edi
pop esi
mov eax, 0xffffbf80
pop ebx
mov esp, ebp
pop ebp
ret
mov edx, dword [eax]
mov esi, dword [eax + 4]
mov eax, 0xfffffff6
sub eax, esi
mov dword [ebp - 0x14], edx
add edi, eax
mov dword [ebp - 0x10], esi
movzx eax, byte [ecx]
mov ecx, dword [ebp - 0x18]
jmp 0x4975aa
mov eax, dword [ebp + 0x14]
sub edi, eax
mov dword [ebp - 8], eax
cmp edi, 8
jb case.default.0x497537
cmp edi, ecx
ja case.default.0x497537
mov eax, dword [ebp + 0x1c]
lea esi, [eax + 1]
push edi
push 0xff
mov byte [eax], 0
mov byte [esi], 1
inc esi
push esi
call fcn.004bc0b0
add esi, edi
add esp, 0xc
mov byte [esi], 0
inc esi
test ebx, ebx
jne 0x4975ef
push dword [ebp - 8]
push dword [ebp + 0x18]
push esi
call fcn.004bbb30
add esp, 0xc
jmp 0x49763d
mov ebx, dword [ebp - 0x10]
mov byte [esi], 0x30
push ebx
push dword [ebp - 0x14]
lea eax, [ebx + 8]
mov byte [esi + 2], 0x30
add al, byte [ebp - 8]
mov byte [esi + 1], al
lea eax, [ebx + 4]
mov byte [esi + 3], al
mov byte [esi + 4], 6
mov byte [esi + 5], bl
add esi, 6
push esi
call fcn.004bbb30
mov eax, dword [ebp - 8]
add esi, ebx
push eax
push dword [ebp + 0x18]
mov word [esi], 5
mov byte [esi + 2], 4
mov byte [esi + 3], al
add esi, 4
push esi
call fcn.004bbb30
add esp, 0x18
mov edi, dword [ebp - 0xc]
push dword [edi + 4]
push 1
call fcn.004c3cf4
mov ebx, eax
add esp, 8
mov dword [ebp - 0x14], ebx
test ebx, ebx
je 0x497672
push dword [edi + 4]
push 1
call fcn.004c3cf4
add esp, 8
mov esi, eax
push ebx
test esi, esi
jne 0x49767e
call fcn.004c3b98
add esp, 4
pop edi
pop esi
mov eax, 0xfffffff0
pop ebx
mov esp, ebp
pop ebp
ret
push dword [ebp + 0x1c]
mov edx, dword [ebp - 0x1c]
mov ecx, edi
push dword [ebp + 8]
call fcn.004961b0
add esp, 0xc
mov dword [ebp - 8], eax
test eax, eax
jne 0x49779b
push esi
mov edx, ebx
mov ecx, edi
call fcn.00495f00
add esp, 4
mov dword [ebp - 8], eax
test eax, eax
jne 0x49779b
mov edx, dword [edi + 4]
xor bl, bl
test edx, edx
je 0x497779
cmp edx, 0x20
jb 0x49775a
mov ebx, dword [ebp + 0x1c]
mov ecx, edx
and ecx, 0xffffffe0
mov edi, esi
sub edi, ebx
mov dword [ebp - 0x1c], ecx
mov dword [ebp - 0x18], edi
xorps xmm3, xmm3
mov edi, dword [ebp - 0xc]
lea ecx, [ebx + 0x10]
mov ebx, dword [ebp - 0x1c]
xorps xmm2, xmm2
mov edx, dword [ebp - 0x18]
nop
movups xmm0, xmmword [ecx - 0x10]
lea ecx, [ecx + 0x20]
movups xmm1, xmmword [eax + esi]
add eax, 0x20
pxor xmm1, xmm0
por xmm3, xmm1
movups xmm1, xmmword [edx + ecx - 0x20]
movups xmm0, xmmword [ecx - 0x20]
pxor xmm1, xmm0
por xmm2, xmm1
cmp eax, ebx
jb 0x4976f0
mov edx, dword [edi + 4]
por xmm2, xmm3
movaps xmm0, xmm2
psrldq xmm0, 8
por xmm2, xmm0
movups xmm0, xmm2
psrldq xmm0, 4
por xmm2, xmm0
movups xmm0, xmm2
psrldq xmm0, 2
por xmm2, xmm0
movups xmm0, xmm2
psrldq xmm0, 1
por xmm2, xmm0
movd ebx, xmm2
cmp eax, edx
jae 0x497779
mov ecx, dword [ebp + 0x1c]
mov edi, esi
sub edi, dword [ebp + 0x1c]
add ecx, eax
sub edx, eax
mov al, byte [ecx + edi]
lea ecx, [ecx + 1]
xor al, byte [ecx - 1]
or bl, al
sub edx, 1
jne 0x497766
mov edi, dword [ebp - 0xc]
mov byte [ebp - 1], bl
cmp byte [ebp - 1], 0
mov ebx, dword [ebp - 0x14]
je 0x49778c
mov edi, 0xffffbd00
jmp 0x49779e
push dword [edi + 4]
push ebx
push dword [ebp + 0x1c]
call fcn.004bbb30
add esp, 0xc
mov edi, dword [ebp - 8]
push ebx
call fcn.004c3b98
push esi
call fcn.004c3b98
add esp, 8
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret