Function at 0x46de80
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1c
mov eax, dword [ebp + 0xc]
push ebx
mov ebx, ecx
mov dword [ebp - 8], ebx
push esi
push edi
cmp eax, 9
ja 0x46de9b
mov dword [0x4d1aa4], eax
mov ecx, dword [ebx + 0xa8]
lea edi, [ebx + 4]
add ecx, 5
mov eax, 0x2aaaaaab
imul ecx
mov ecx, dword [edi + 0x10]
mov eax, edx
shr eax, 0x1f
add eax, edx
mov dword [ebp - 4], eax
dec eax
add eax, dword [ebx]
cdq
idiv dword [ebx]
mov edx, eax
mov dword [ebp - 0x10], edx
cmp ecx, 0xb
jb 0x46deed
mov dword [edi + 0x10], 0xb
mov ecx, edi
cmp dword [edi + 0x14], 0xf
jbe 0x46dee5
mov ecx, dword [edi]
lea eax, [ebx + 4]
mov byte [ecx + 0xb], 0
jmp 0x46df03
mov eax, edi
mov byte [ecx + 0xb], 0
jmp 0x46df03
mov eax, 0xb
sub eax, ecx
mov ecx, edi
push 0
push eax
call fcn.00464400
mov edx, dword [ebp - 0x10]
mov eax, edi
cmp dword [edi + 0x14], 0xf
mov ecx, edi
mov esi, edi
jbe 0x46df11
mov ecx, dword [edi]
mov esi, eax
lea eax, [edx + 0x30]
mov byte [ecx + 7], al
mov eax, esi
cmp dword [edi + 0x14], 0xf
jbe 0x46df23
mov eax, dword [esi]
mov edi, esi
mov byte [eax + 9], 0x30
cmp edx, 1
jle 0x46df55
mov al, byte [0x4d1aa4]
mov ecx, edi
add al, 0x30
movzx eax, al
push eax
call fcn.004231a0
mov eax, dword [0x4d1aa4]
lea esi, [ebx + 4]
inc eax
mov ecx, 0xa
cdq
idiv ecx
mov dword [0x4d1aa4], edx
push 0x2c
mov ecx, edi
call fcn.004231a0
mov al, byte [ebx + 0xac]
cmp al, 0x3f
je 0x46df70
push eax
mov ecx, edi
call fcn.004231a0
push 0x2c
mov ecx, edi
call fcn.004231a0
mov eax, dword [ebx + 0x14]
lea edi, [ebx + 0xb4]
mov ecx, dword [edi + 4]
mov dword [ebp - 0x14], eax
mov eax, dword [edi]
mov dword [ebp - 0x1c], edi
cmp eax, ecx
je 0x46dfa4
push edi
push ecx
push eax
call fcn.0042ae50
mov eax, dword [edi]
lea esi, [ebx + 4]
add esp, 0xc
mov dword [edi + 4], eax
mov eax, dword [ebp - 0x10]
xor edx, edx
mov dword [ebp + 0xc], edx
mov dword [ebp - 0xc], edx
test eax, eax
jle 0x46e163
dec eax
mov dword [ebp - 0x18], eax
nop dword [eax + eax]
mov ecx, dword [esi + 0x10]
mov ebx, dword [ebp - 0x14]
cmp ebx, ecx
ja 0x46dfdd
mov dword [esi + 0x10], ebx
mov eax, esi
cmp dword [esi + 0x14], 0xf
jbe 0x46dfd7
mov eax, dword [esi]
mov byte [eax + ebx], 0
jmp 0x46dfee
mov eax, ebx
sub eax, ecx
mov ecx, esi
push 0
push eax
call fcn.00464400
mov edx, dword [ebp + 0xc]
cmp dword [esi + 0x14], 0xf
mov eax, esi
jbe 0x46dff8
mov eax, dword [esi]
inc byte [eax + 9]
xor ebx, ebx
mov edi, dword [ebp - 4]
cmp edx, edi
jge 0x46e088
lea edi, [edx + edx*2]
add edi, edi
nop dword [eax]
mov ecx, dword [ebp - 8]
cmp ebx, dword [ecx]
jge 0x46e085
mov eax, edi
imul edx, edx, 0xfffe
sar eax, 3
add ecx, eax
and dl, 7
movzx eax, byte [ecx + 0x1c]
movzx ecx, byte [ecx + 0x1d]
shl eax, 8
or eax, ecx
mov ecx, 0xa
sub cl, dl
mov edx, dword [ebp - 8]
shr eax, cl
mov ecx, edi
and eax, 0x3f
sub ecx, dword [edx + 0xa8]
add ecx, 6
test ecx, ecx
jle 0x46e05b
mov edx, 0xff
shl edx, cl
and eax, edx
cmp eax, 0x28
setae cl
lea ecx, [ecx*8 + 0x30]
add cl, al
movzx eax, cl
mov ecx, esi
push eax
call fcn.004231a0
mov edx, dword [ebp + 0xc]
inc ebx
inc edx
add edi, 6
mov dword [ebp + 0xc], edx
cmp edx, dword [ebp - 4]
jl 0x46e010
mov edi, dword [ebp - 4]
push 0x2c
mov ecx, esi
call fcn.004231a0
mov eax, dword [ebp - 0x18]
cmp dword [ebp - 0xc], eax
jne 0x46e0a9
mov ecx, dword [ebp - 8]
lea eax, [edi + edi*2]
add eax, eax
sub eax, dword [ecx + 0xa8]
jmp 0x46e0ab
xor eax, eax
add al, 0x30
mov ecx, esi
movzx eax, al
push eax
call fcn.004231a0
mov edx, dword [esi + 0x10]
xor ebx, ebx
lea ecx, [ebx + 1]
cmp edx, ecx
jbe 0x46e0eb
cmp dword [esi + 0x14], 0xf
jbe 0x46e0e0
mov edi, dword [esi]
nop dword [eax]
movsx eax, byte [edi + ecx]
inc ecx
xor ebx, eax
cmp ecx, edx
jb 0x46e0d0
jmp 0x46e0eb
movsx eax, byte [esi + ecx]
inc ecx
xor ebx, eax
cmp ecx, edx
jb 0x46e0e0
push 0x2a
mov ecx, esi
call fcn.004231a0
mov ecx, ebx
mov edx, 0x37
sar ecx, 4
mov eax, 0x30
cmp ecx, 0xa
cmovge eax, edx
add al, cl
mov ecx, esi
movzx eax, al
push eax
call fcn.004231a0
and ebx, 0xf
mov ecx, esi
cmp ebx, 0xa
sbb al, al
and al, 0xf9
add al, 0x37
add al, bl
movzx eax, al
push eax
call fcn.004231a0
mov edi, dword [ebp - 0x1c]
push esi
mov eax, dword [edi + 4]
cmp eax, dword [edi + 8]
je 0x46e148
mov ecx, eax
call fcn.00416790
add dword [edi + 4], 0x18
jmp 0x46e150
push eax
mov ecx, edi
call fcn.0046cf00
mov eax, dword [ebp - 0xc]
mov edx, dword [ebp + 0xc]
inc eax
mov dword [ebp - 0xc], eax
cmp eax, dword [ebp - 0x10]
jl 0x46dfc0
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8