Function at 0x46edb0
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0x10
mov ecx, dword [esp + 0x18]
mov eax, dword [esp + 0x1c]
push ebx
mov ebx, dword [ecx + 4]
test ebx, ebx
push ebp
mov ebp, dword [eax + 8]
push esi
mov esi, dword [ecx + 8]
mov ecx, dword [esp + 0x20]
mov edx, dword [ecx + 8]
push edi
mov edi, dword [eax + 4]
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], edx
jl 0x46ef4e
test edi, edi
jl 0x46f0eb
cmp ebx, edi
jl 0x46ee90
mov eax, ecx
cmp dword [eax], ebx
jge 0x46ee1f
push ebx
push ecx
call fcn.0046f570
mov edx, dword [esp + 0x30]
mov ecx, dword [esp + 0x2c]
mov esi, dword [edx + 8]
mov eax, dword [esp + 0x34]
mov edx, dword [ecx + 8]
mov ebp, dword [eax + 8]
add esp, 8
mov dword [esp + 0x10], edx
cmp edx, esi
je 0x46ee69
mov eax, ebx
sub eax, edi
je 0x46ee69
add eax, 0xffffffff
mov dword [esp + 0x28], eax
lea eax, [esi + edi*4]
lea ecx, [edx + edi*4]
mov edx, dword [eax]
add eax, 4
cmp dword [esp + 0x28], 0
mov dword [esp + 0x2c], edx
je 0x46ee5f
mov edx, dword [esp + 0x2c]
mov dword [ecx], edx
mov edx, dword [eax]
add ecx, 4
add eax, 4
sub dword [esp + 0x28], 1
mov dword [esp + 0x2c], edx
jne 0x46ee46
mov eax, dword [esp + 0x2c]
mov edx, dword [esp + 0x10]
mov dword [ecx], eax
add edi, 0xffffffff
js 0x46ee89
mov ecx, edx
sub ebp, esi
lea eax, [esi + edi*4]
sub ecx, esi
mov esi, dword [eax + ebp]
xor esi, dword [eax]
sub edi, 1
mov dword [ecx + eax], esi
sub eax, 4
test edi, edi
jge 0x46ee77
mov edi, ebx
jmp 0x46ef26
cmp dword [ecx], edi
jge 0x46eebb
mov edx, ecx
push edi
push edx
call fcn.0046f570
mov eax, dword [esp + 0x30]
mov edx, dword [esp + 0x2c]
mov esi, dword [eax + 8]
mov eax, dword [edx + 8]
mov ecx, dword [esp + 0x34]
mov ebp, dword [ecx + 8]
add esp, 8
mov dword [esp + 0x10], eax
mov edx, eax
cmp edx, ebp
je 0x46ef06
mov eax, edi
sub eax, ebx
je 0x46ef06
add eax, 0xffffffff
mov dword [esp + 0x28], eax
lea eax, [ebp + ebx*4]
lea ecx, [edx + ebx*4]
mov edx, dword [eax]
add eax, 4
cmp dword [esp + 0x28], 0
mov dword [esp + 0x2c], edx
je 0x46eefc
mov edx, dword [esp + 0x2c]
mov dword [ecx], edx
mov edx, dword [eax]
add ecx, 4
add eax, 4
sub dword [esp + 0x28], 1
mov dword [esp + 0x2c], edx
jne 0x46eee3
mov eax, dword [esp + 0x2c]
mov edx, dword [esp + 0x10]
mov dword [ecx], eax
add ebx, 0xffffffff
js 0x46ef26
mov ecx, edx
sub ebp, esi
lea eax, [esi + ebx*4]
sub ecx, esi
mov esi, dword [eax + ebp]
xor esi, dword [eax]
sub ebx, 1
mov dword [eax + ecx], esi
sub eax, 4
test ebx, ebx
jge 0x46ef14
test edi, edi
jle 0x46ef3f
lea edx, [edx + edi*4 - 4]
mov edi, edi
cmp dword [edx], 0
jne 0x46ef3f
sub edi, 1
sub edx, 4
test edi, edi
jg 0x46ef30
mov ecx, dword [esp + 0x24]
mov dword [ecx + 4], edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10
ret
test edi, edi
jge 0x46f0db
neg edi
neg ebx
mov dword [esp + 0x2c], edi
lea edi, [ebx*4]
lea edx, [esp + 0x14]
push edi
push edx
mov dword [esp + 0x30], ebx
call fcn.0046f670
mov ebx, eax
mov eax, dword [esp + 0x30]
push 1
push eax
push esi
push ebx
call fcn.0046f6d0
mov dword [esp + 0x30], ebx
mov ebx, dword [esp + 0x44]
lea esi, [ebx*4]
lea ecx, [esp + 0x2c]
push esi
push ecx
call fcn.0046f670
push 1
push ebx
push ebp
push eax
mov dword [esp + 0x4c], eax
call fcn.0046f6d0
add esp, 0x30
cmp dword [esp + 0x28], ebx
jle 0x46efbd
mov ebx, dword [esp + 0x28]
mov eax, ebx
jmp 0x46efc3
mov eax, ebx
mov ebx, dword [esp + 0x28]
mov ebp, dword [esp + 0x24]
cmp dword [ebp], eax
jge 0x46efdb
push eax
push ebp
call fcn.0046f570
mov ebp, dword [ebp + 8]
add esp, 8
jmp 0x46efdf
mov ebp, dword [esp + 0x10]
mov ecx, dword [esp + 0x2c]
cmp ebx, ecx
jle 0x46f048
mov eax, ebx
sub eax, ecx
mov ebx, dword [esp + 0x18]
je 0x46f015
mov edx, dword [esi + ebx]
lea edi, [eax - 1]
lea eax, [esi + ebx]
add eax, 4
test edi, edi
lea ecx, [esi + ebp]
je 0x46f013
mov dword [ecx], edx
mov edx, dword [eax]
add ecx, 4
add eax, 4
sub edi, 1
jne 0x46f004
mov dword [ecx], edx
mov ecx, dword [esp + 0x2c]
add ecx, 0xffffffff
js 0x46f042
mov edx, dword [esp + 0x1c]
mov esi, ebp
sub edx, ebx
lea eax, [ebx + ecx*4]
sub esi, ebx
jmp 0x46f030
mov edi, dword [edx + eax]
xor edi, dword [eax]
sub ecx, 1
mov dword [eax + esi], edi
sub eax, 4
test ecx, ecx
jge 0x46f030
mov eax, dword [esp + 0x28]
jmp 0x46f0a6
mov eax, ecx
sub eax, ebx
je 0x46f075
mov edx, dword [esp + 0x1c]
lea esi, [eax - 1]
lea eax, [edi + edx]
mov edx, dword [eax]
add eax, 4
test esi, esi
lea ecx, [edi + ebp]
je 0x46f073
mov dword [ecx], edx
mov edx, dword [eax]
add ecx, 4
add eax, 4
sub esi, 1
jne 0x46f064
mov dword [ecx], edx
lea ecx, [ebx - 1]
test ecx, ecx
jl 0x46f0a2
mov edi, dword [esp + 0x18]
mov edx, dword [esp + 0x1c]
mov esi, ebp
sub edx, edi
lea eax, [edi + ecx*4]
sub esi, edi
lea ecx, [ecx]
mov edi, dword [edx + eax]
xor edi, dword [eax]
sub ecx, 1
mov dword [esi + eax], edi
sub eax, 4
test ecx, ecx
jge 0x46f090
mov eax, dword [esp + 0x2c]
test eax, eax
jle 0x46f0bf
lea ecx, [ebp + eax*4 - 4]
mov edi, edi
cmp dword [ecx], 0
jne 0x46f0bf
sub eax, 1
sub ecx, 4
test eax, eax
jg 0x46f0b0
mov edx, dword [esp + 0x14]
mov ecx, dword [esp + 0x24]
push edx
mov dword [ecx + 4], eax
call fcn.0046f6a0
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10
ret
mov dword [esp + 0x28], eax
mov eax, esi
mov esi, ebp
mov ebp, eax
mov eax, ebx
mov ebx, edi
mov edi, eax
neg edi
mov dword [esp + 0x2c], edi
add edi, edi
add edi, edi
lea eax, [esp + 0x14]
push edi
push eax
call fcn.0046f670
mov ecx, dword [esp + 0x34]
push 1
push ecx
push ebp
push eax
mov dword [esp + 0x34], eax
call fcn.0046f6d0
add esp, 0x18
cmp ebx, dword [esp + 0x2c]
mov eax, ebx
jg 0x46f121
mov eax, dword [esp + 0x2c]
mov ebp, dword [esp + 0x24]
add eax, 1
cmp dword [ebp], eax
jge 0x46f145
push eax
push ebp
call fcn.0046f570
mov edx, dword [esp + 0x30]
mov eax, dword [ebp + 8]
mov esi, dword [edx + 8]
add esp, 8
mov dword [esp + 0x10], eax
mov ebp, dword [esp + 0x2c]
cmp ebx, ebp
jle 0x46f1b5
mov eax, ebx
sub eax, ebp
je 0x46f185
mov ecx, dword [esp + 0x10]
mov edx, dword [edi + esi]
lea ebp, [eax - 1]
lea eax, [edi + esi]
add ecx, edi
add eax, 4
test ebp, ebp
je 0x46f17f
lea esp, [esp]
mov dword [ecx], edx
mov edx, dword [eax]
add ecx, 4
add eax, 4
sub ebp, 1
jne 0x46f170
mov ebp, dword [esp + 0x2c]
mov dword [ecx], edx
mov edi, dword [esp + 0x10]
lea ecx, [ebp - 1]
test ecx, ecx
jl 0x46f218
mov edx, dword [esp + 0x1c]
mov ebp, edi
sub edx, esi
lea eax, [esi + ecx*4]
sub ebp, esi
mov esi, dword [edx + eax]
xor esi, dword [eax]
sub ecx, 1
mov dword [eax + ebp], esi
sub eax, 4
test ecx, ecx
jge 0x46f1a1
jmp 0x46f218
mov eax, ebp
sub eax, ebx
je 0x46f1ea
mov edx, dword [esp + 0x10]
lea ebp, [eax - 1]
mov eax, dword [esp + 0x1c]
lea eax, [eax + ebx*4]
lea ecx, [edx + ebx*4]
mov edx, dword [eax]
add eax, 4
test ebp, ebp
je 0x46f1e4
mov dword [ecx], edx
mov edx, dword [eax]
add ecx, 4
add eax, 4
sub ebp, 1
jne 0x46f1d5
mov ebp, dword [esp + 0x2c]
mov dword [ecx], edx
add ebx, 0xffffffff
js 0x46f212
mov ecx, dword [esp + 0x1c]
mov edx, dword [esp + 0x10]
sub ecx, esi
lea eax, [esi + ebx*4]
sub edx, esi
mov edi, edi
mov esi, dword [eax + ecx]
xor esi, dword [eax]
sub ebx, 1
mov dword [edx + eax], esi
sub eax, 4
test ebx, ebx
jge 0x46f200
mov edi, dword [esp + 0x10]
mov ebx, ebp
push 1
push ebx
push edi
push edi
call fcn.0046f5c0
add esp, 0x10
test eax, eax
je 0x46f22f
mov dword [edi + ebx*4], eax
add ebx, 1
test ebx, ebx
jle 0x46f246
lea eax, [edi + ebx*4 - 4]
cmp dword [eax], 0
jne 0x46f246
sub ebx, 1
sub eax, 4
test ebx, ebx
jg 0x46f237
mov edx, dword [esp + 0x14]
mov ecx, dword [esp + 0x24]
neg ebx
push edx
mov dword [ecx + 4], ebx
call fcn.0046f6a0
add esp, 4
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10
ret