Function at 0x488020
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
mov ecx, dword [eax + 8]
cmp ecx, 5
jl 0x48816b
cmp ecx, 0x11
jg 0x48816b
mov ecx, dword [ebp + 0x10]
test byte [ecx + 0x12c], 2
je 0x48809a
mov ecx, dword [ebp + 0xc]
mov esi, dword [eax]
cmp ecx, 1
jne 0x488062
mov eax, dword [ebp + 0x14]
mov dl, byte [esi]
pop edi
pop esi
mov byte [eax], dl
xor eax, eax
pop ebx
pop ebp
ret
mov eax, ecx
cdq
sub eax, edx
sar eax, 1
test eax, eax
jle 0x488229
mov edi, dword [ebp + 0x14]
lea edx, [esi + ecx - 1]
sub edi, esi
mov ebx, eax
mov al, byte [esi]
mov cl, byte [edx]
xor cl, al
xor al, cl
mov byte [edi + esi], al
mov al, byte [edx]
xor al, cl
inc esi
mov byte [edi + edx], al
dec edx
dec ebx
jne 0x48807c
pop edi
pop esi
xor eax, eax
pop ebx
pop ebp
ret
mov ecx, dword [ebp + 0xc]
lea edx, [ecx - 1]
cmp edx, 7
ja case.0x4880a9.3
jmp dword [edx*4 + 0x488230]
mov ecx, dword [eax]
mov eax, dword [ebp + 0x14]
pop edi
pop esi
mov dl, byte [ecx]
pop ebx
mov byte [eax], dl
xor eax, eax
pop ebp
ret
mov ecx, dword [eax]
push ecx
call fcn.00488250
mov edx, dword [ebp + 0x14]
push eax
push edx
call fcn.004882f0
add esp, 0xc
xor eax, eax
pop edi
pop esi
pop ebx
pop ebp
ret
mov eax, dword [eax]
test al, 3
jne 0x4880e6
mov eax, dword [eax]
jmp 0x4880ef
push eax
call fcn.004882a0
add esp, 4
mov ecx, dword [ebp + 0x14]
test cl, 3
jne 0x488100
pop edi
mov dword [ecx], eax
pop esi
xor eax, eax
pop ebx
pop ebp
ret
push eax
push ecx
call fcn.00488360
add esp, 8
xor eax, eax
pop edi
pop esi
pop ebx
pop ebp
ret
mov eax, dword [eax]
test al, 3
jne 0x48811e
mov esi, dword [eax]
mov eax, dword [eax + 4]
jmp 0x48812b
push eax
call fcn.00497360
mov esi, eax
add esp, 4
mov eax, edx
mov ecx, dword [ebp + 0x14]
test cl, 3
jne 0x48813f
mov dword [ecx], esi
pop edi
mov dword [ecx + 4], eax
pop esi
xor eax, eax
pop ebx
pop ebp
ret
push eax
push esi
push ecx
call fcn.004883c0
add esp, 0xc
xor eax, eax
pop edi
pop esi
pop ebx
pop ebp
ret
mov esi, dword [eax]
mov edi, dword [ebp + 0x14]
mov eax, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
xor eax, eax
rep movsb byte es:[edi], byte [esi]
pop edi
pop esi
pop ebx
pop ebp
ret
cmp ecx, 0x19
jl 0x488175
cmp ecx, 0x1f
jle 0x488187
cmp ecx, 0x28
jl 0x488229
cmp ecx, 0x30
jg 0x488229
mov edx, dword [ecx*4 + 0x4b0fdc]
mov ecx, dword [ebp + 0x10]
cmp edx, 0xffffffff
movsx edi, byte [ecx + 0x120]
jne 0x4881a7
pop edi
pop esi
mov eax, 0x4000005f
pop ebx
pop ebp
ret
mov ecx, dword [eax]
lea eax, [edi + edi*2]
mov ebx, dword [ebp + 0x14]
mov esi, dword [ebp + 0xc]
lea edx, [edx + eax*2]
mov eax, dword [edx*4 + 0x4b1118]
test eax, eax
je 0x4881d8
push ebx
push 0
push ecx
call eax
add esp, 0xc
cmp eax, 1
je 0x4881f2
pop edi
pop esi
mov eax, 0x4000005f
pop ebx
pop ebp
ret
cmp esi, 4
jne 0x4881e3
mov eax, dword [ecx]
mov dword [ebx], eax
jmp 0x4881f2
cmp esi, 8
jne 0x4881f2
mov edx, dword [ecx]
mov dword [ebx], edx
mov eax, dword [ecx + 4]
mov dword [ebx + 4], eax
mov ecx, dword [ebp + 0x10]
test byte [ecx + 0x12c], 2
je 0x488229
test edi, edi
jne 0x488229
mov eax, esi
cdq
sub eax, edx
sar eax, 1
test eax, eax
jle 0x488229
lea esi, [esi + ebx - 1]
mov cl, byte [edi + ebx]
mov dl, cl
xor dl, byte [esi]
xor cl, dl
mov byte [edi + ebx], cl
mov cl, byte [esi]
xor cl, dl
inc edi
mov byte [esi], cl
dec esi
cmp edi, eax
jl 0x488211
pop edi
pop esi
xor eax, eax
pop ebx
pop ebp
ret