Function at 0x1007ff80
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x158
mov eax, dword [0x101fc010]
xor eax, ebp
mov dword [ebp - 4], eax
mov edx, dword [ebp + 0x10]
xorps xmm0, xmm0
mov eax, dword [ebp + 0x1c]
mov ecx, dword [ebp + 8]
mov dword [ebp - 0x13c], eax
mov eax, dword [edx]
mov dword [ebp - 0x120], ecx
mov dword [ebp - 0x140], edx
mov dword [ebp - 0x11c], eax
mov dword [ebp - 0x128], 0
push esi
mov esi, dword [ebp + 0x14]
mov dword [ebp - 0x12c], esi
mov dword [ebp - 0x138], esi
push edi
mov edi, dword [ebp + 0xc]
mov dword [ebp - 0x130], edi
movupd xmmword [ebp - 0x154], xmm0
cmp ecx, 5
jg 0x10080109
mov dword [esi], 0
lea edi, [ecx - 1]
mov dword [esi + ecx*4 - 4], edi
cmp ecx, 4
je 0x100800f1
mov ecx, 1
lea edx, [edi - 1]
cmp edi, ecx
jle 0x10080088
cmp edx, 8
jb 0x10080077
movdqa xmm1, xmmword [0x1019d560]
and edx, 0x80000007
jns 0x1008002a
dec edx
or edx, 0xfffffff8
inc edx
mov eax, edi
sub eax, edx
lea edx, [esi + 4]
mov dword [ebp - 0x138], eax
mov esi, eax
lea esp, [esp]
movd xmm0, ecx
lea eax, [ecx + 4]
pshufd xmm0, xmm0, 0
lea edx, [edx + 0x20]
paddd xmm0, xmm1
add ecx, 8
movdqu xmmword [edx - 0x20], xmm0
movd xmm0, eax
pshufd xmm0, xmm0, 0
paddd xmm0, xmm1
movdqu xmmword [edx - 0x10], xmm0
cmp ecx, esi
jl 0x10080040
mov esi, dword [ebp - 0x12c]
cmp ecx, edi
jge 0x10080088
jmp 0x10080080
mov dword [esi + ecx*4], ecx
inc ecx
cmp ecx, edi
jl 0x10080080
cmp dword [ebp - 0x120], 5
jne 0x10080790
cmp dword [ebp + 0x18], 0x10
mov ecx, dword [ebp - 0x13c]
jne 0x100800bc
movaps xmm0, xmmword [0x101a23e0]
pop edi
movdqu xmmword [ecx], xmm0
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10176850
mov esp, ebp
pop ebp
ret
mov dword [ebp - 0x14c], 0x3f800000
mov eax, dword [ebp - 0x14c]
mov dword [ebp - 0x148], 0
mov dword [ecx], eax
mov eax, dword [ebp - 0x148]
pop edi
mov dword [ecx + 4], eax
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10176850
mov esp, ebp
pop ebp
ret
mov dword [esi + 4], 2
mov edx, 2
mov dword [esi + 8], 1
jmp 0x100805c1
mov dword [ebp + edi*4 - 0x8c], 1
mov dword [ebp + edi*4 - 0x114], 0
test edi, edi
jle 0x10080172
lea eax, [ebp + edi*4 - 0x90]
mov esi, edi
mov ecx, edi
mov dword [ebp - 0x118], eax
xor eax, eax
lea edi, [ebp - 0x114]
rep stosd dword es:[edi], eax
mov ecx, dword [ebp - 0x118]
lea eax, [ebp - 0x8c]
mov edi, edx
sub edi, eax
mov edi, edi
mov eax, dword [edi + ecx]
lea ecx, [ecx - 4]
imul eax, dword [ecx + 8]
mov dword [ecx + 4], eax
dec esi
jne 0x10080150
mov esi, dword [ebp - 0x12c]
mov eax, dword [ebp - 0x11c]
mov edi, dword [ebp - 0x130]
cmp dword [ebp + 0x20], 0
je 0x10080189
cmp eax, dword [edx + edi*4 - 4]
cmovne esi, dword [ebp - 0x13c]
mov dword [ebp - 0x12c], esi
test al, 1
jne 0x1008049f
mov edi, dword [ebp - 0x88]
imul edi, eax
mov dword [ebp - 0x128], 0
sar edi, 1
mov edx, edi
mov dword [ebp - 0x158], edi
sar edx, 1
mov dword [ebp - 0x134], edx
cmp eax, 1
jbe 0x100801cc
mov ecx, 1
inc dword [ebp - 0x128]
rol ecx, 1
cmp ecx, eax
jb 0x100801c0
cmp eax, 2
jg 0x100801df
mov dword [esi], 0
mov dword [esi + 4], edi
jmp 0x10080374
cmp eax, 0x100
jg 0x1008029f
mov ecx, 0xa
sub ecx, dword [ebp - 0x128]
mov dword [ebp - 0x144], ecx
lea ecx, [eax - 4]
mov dword [ebp - 0x124], ecx
xor ecx, ecx
mov dword [ebp - 0x118], ecx
cmp dword [ebp - 0x124], ecx
jl 0x10080374
mov eax, dword [ebp - 0x144]
movzx eax, al
mov dword [ebp - 0x144], eax
lea eax, [edx + edi]
lea edi, [esi + 8]
mov dword [ebp - 0x148], eax
mov esi, dword [ebp - 0x158]
lea esp, [esp]
mov eax, ecx
lea edi, [edi + 0x10]
mov cl, byte [ebp - 0x144]
sar eax, 2
movzx edx, byte [eax + 0x101f84d0]
shr edx, cl
imul edx, dword [ebp - 0x88]
mov ecx, dword [ebp - 0x118]
add ecx, 4
mov dword [ebp - 0x118], ecx
mov dword [edi - 0x18], edx
lea eax, [edx + esi]
mov dword [edi - 0x14], eax
mov eax, dword [ebp - 0x134]
add eax, edx
mov dword [edi - 0x10], eax
mov eax, dword [ebp - 0x148]
add eax, edx
mov dword [edi - 0xc], eax
cmp ecx, dword [ebp - 0x124]
jle 0x10080240
mov eax, dword [ebp - 0x11c]
jmp 0x1008036e
mov ecx, 0x22
mov dword [ebp - 0x118], 0
sub ecx, dword [ebp - 0x128]
mov dword [ebp - 0x148], ecx
test eax, eax
jle 0x10080374
lea eax, [esi + 8]
xor edx, edx
mov esi, dword [ebp - 0x134]
mov dword [ebp - 0x124], eax
mov ecx, edx
sar ecx, 2
movzx eax, cl
movzx edx, byte [eax + 0x101f84d0]
mov eax, ecx
sar eax, 8
and eax, 0xff
shl edx, 8
movzx eax, byte [eax + 0x101f84d0]
add edx, eax
mov eax, ecx
sar eax, 0x10
and eax, 0xff
shl edx, 8
sar ecx, 0x18
movzx eax, byte [eax + 0x101f84d0]
add edx, eax
movzx eax, byte [ecx + 0x101f84d0]
mov ecx, dword [ebp - 0x148]
shl edx, 8
add edx, eax
shr edx, cl
imul edx, dword [ebp - 0x88]
mov ecx, dword [ebp - 0x124]
mov dword [ecx - 8], edx
lea eax, [edx + edi]
mov dword [ecx - 4], eax
lea eax, [edx + esi]
mov dword [ecx], eax
lea eax, [esi + edi]
add eax, edx
mov edx, dword [ebp - 0x118]
mov dword [ecx + 4], eax
add edx, 4
mov eax, dword [ebp - 0x11c]
add ecx, 0x10
mov dword [ebp - 0x118], edx
mov dword [ebp - 0x124], ecx
cmp edx, eax
jl 0x100802d3
mov esi, dword [ebp - 0x12c]
mov edx, dword [ebp - 0x110]
mov ecx, dword [ebp - 0x120]
inc edx
cmp dword [ebp - 0x130], 2
mov dword [ebp - 0x118], edx
jl 0x10080568
mov edi, dword [ebp - 0x84]
mov dword [ebp - 0x134], eax
cmp eax, ecx
jge 0x10080568
lea ecx, [eax*4]
add ecx, esi
mov dword [ebp - 0x130], ecx
xor ecx, ecx
test eax, eax
jle 0x100803df
mov edx, dword [ebp - 0x130]
mov eax, dword [esi + ecx*4]
lea edx, [edx + 4]
add eax, edi
inc ecx
mov dword [edx - 4], eax
mov eax, dword [ebp - 0x11c]
cmp ecx, eax
jl 0x100803c3
mov edx, dword [ebp - 0x118]
add dword [ebp - 0x134], eax
lea ecx, [eax*4]
add dword [ebp - 0x130], ecx
mov ecx, dword [ebp - 0x120]
cmp dword [ebp - 0x134], ecx
jge 0x10080568
mov ecx, dword [ebp - 0x140]
inc edx
add edi, dword [ebp - 0x84]
mov dword [ebp - 0x124], 1
mov dword [ebp - 0x118], edx
mov dword [ebp - 0x110], edx
cmp edx, dword [ecx + 4]
jl 0x100803b7
mov esi, dword [ebp - 0x124]
lea edx, [ebp - 0x110]
mov ecx, 4
lea ecx, [ecx]
mov eax, dword [ebp + ecx - 0x84]
inc esi
sub eax, dword [ebp + ecx - 0x8c]
mov dword [edx], 0
add edi, eax
lea edx, [ebp - 0x114]
mov dword [ebp - 0x124], esi
lea ecx, [esi*4]
mov esi, dword [ebp - 0x140]
add edx, ecx
mov eax, dword [edx]
inc eax
cmp eax, dword [ecx + esi]
mov esi, dword [ebp - 0x124]
mov dword [edx], eax
jge 0x10080440
mov edx, dword [ebp - 0x110]
mov esi, dword [ebp - 0x12c]
mov eax, dword [ebp - 0x11c]
mov dword [ebp - 0x118], edx
jmp 0x100803b7
xor ecx, ecx
mov dword [ebp - 0x118], 1
cmp dword [ebp - 0x120], 1
mov dword [esi], ecx
jle 0x10080562
lea ebx, [ebx]
mov eax, dword [ebp - 0x114]
xor edi, edi
add ecx, dword [ebp - 0x88]
inc eax
mov dword [ebp - 0x11c], ecx
mov dword [ebp - 0x114], eax
cmp eax, dword [edx]
jl 0x10080546
mov esi, dword [ebp - 0x11c]
lea edx, [ebp - 0x114]
xor ecx, ecx
lea ecx, [ecx]
mov eax, dword [ebp + ecx - 0x84]
lea edi, [edi + 1]
sub eax, dword [ebp + ecx - 0x8c]
lea ecx, [edi*4]
mov dword [edx], 0
add esi, eax
lea edx, [ebp - 0x114]
mov dword [ebp - 0x11c], esi
mov esi, dword [ebp - 0x140]
add edx, ecx
mov eax, dword [edx]
inc eax
cmp eax, dword [ecx + esi]
mov esi, dword [ebp - 0x11c]
mov dword [edx], eax
jge 0x100804f0
mov esi, dword [ebp - 0x12c]
mov ecx, dword [ebp - 0x11c]
mov edx, dword [ebp - 0x140]
mov eax, dword [ebp - 0x118]
mov dword [esi + eax*4], ecx
inc eax
mov dword [ebp - 0x118], eax
cmp eax, dword [ebp - 0x120]
jl 0x100804c0
mov ecx, dword [ebp - 0x120]
mov eax, dword [ebp - 0x138]
cmp esi, eax
je 0x100805bb
mov edx, ecx
mov dword [eax], 0
and edx, 1
cmp edx, ecx
jge 0x100805bb
lea edi, [edx + 1]
jmp 0x10080590
mov ecx, dword [esi + edx*4 + 4]
mov eax, dword [esi + edx*4]
mov esi, dword [ebp - 0x138]
mov dword [esi + eax*4], edx
mov eax, esi
mov esi, dword [ebp - 0x12c]
add edx, 2
mov dword [eax + ecx*4], edi
add edi, 2
mov ecx, dword [ebp - 0x120]
cmp edx, ecx
jl 0x10080590
mov edx, dword [ebp - 0x128]
movsd xmm6, qword [0x101a23f0]
lea eax, [ecx - 1]
test ecx, eax
jne 0x100805f1
movsd xmm0, qword [0x1019b448]
shl edx, 4
movsd xmm4, qword [edx + 0x101a1dd0]
movsd xmm5, qword [edx + 0x101a1dc8]
xorpd xmm4, xmm6
jmp 0x1008063e
movsd xmm1, qword [0x101a23d8]
movd xmm0, ecx
cvtdq2pd xmm0, xmm0
divsd xmm1, xmm0
movaps xmm0, xmm1
call sub.MSVCR120.dll___libm_sse2_sin
movsd xmm6, qword [0x101a23f0]
movapd xmm4, xmm0
movsd xmm0, qword [0x1019b448]
movapd xmm2, xmm4
mov ecx, dword [ebp - 0x120]
movapd xmm1, xmm0
mulsd xmm2, xmm4
xorps xmm5, xmm5
subsd xmm1, xmm2
sqrtsd xmm5, xmm1
lea eax, [ecx + 1]
movapd xmm2, xmm5
cdq
movapd xmm3, xmm4
sub eax, edx
mov edx, eax
sar edx, 1
cmp dword [ebp + 0x18], 0x10
jne 0x100806fe
mov edi, dword [ebp - 0x13c]
xorps xmm1, xmm1
movsd qword [edi], xmm0
movsd qword [edi + 8], xmm1
test cl, 1
jne 0x10080688
movsd xmm0, qword [0x1019e4f8]
mov eax, edx
add eax, eax
movsd qword [edi + eax*8], xmm0
movsd qword [edi + eax*8 + 8], xmm1
cmp edx, 1
jle 0x10080790
shl ecx, 4
lea eax, [edi - 0x10]
add eax, ecx
lea esi, [edi + 0x10]
dec edx
lea ecx, [ecx]
movsd xmm0, xmm2
movapd xmm1, xmm2
unpcklpd xmm0, xmm3
movdqu xmmword [esi], xmm0
add esi, 0x10
movapd xmm0, xmm3
mulsd xmm1, xmm5
xorpd xmm0, xmm6
movsd qword [eax], xmm2
movsd qword [eax + 8], xmm0
movapd xmm0, xmm3
mulsd xmm0, xmm4
sub eax, 0x10
mulsd xmm3, xmm5
subsd xmm1, xmm0
movapd xmm0, xmm4
mulsd xmm0, xmm2
movapd xmm2, xmm1
addsd xmm3, xmm0
dec edx
jne 0x100806a0
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.10176850
mov esp, ebp
pop ebp
ret
mov esi, dword [ebp - 0x13c]
mov dword [esi], 0x3f800000
mov dword [esi + 4], 0
test cl, 1
jne 0x10080725
mov dword [esi + edx*8], 0xbf800000
mov dword [esi + edx*8 + 4], 0
mov eax, 1
cmp edx, eax
jle 0x10080790
dec ecx
lea ecx, [esi + ecx*8]
xorps xmm0, xmm0
xorps xmm1, xmm1
cvtsd2ss xmm0, xmm3
cvtsd2ss xmm1, xmm2
movss dword [esi + eax*8 + 4], xmm0
movapd xmm0, xmm3
xorpd xmm0, xmm6
movss dword [esi + eax*8], xmm1
cvtsd2ss xmm0, xmm0
inc eax
movss dword [ecx], xmm1
movapd xmm1, xmm2
movss dword [ecx + 4], xmm0
movapd xmm0, xmm3
mulsd xmm0, xmm4
sub ecx, 8
mulsd xmm1, xmm5
mulsd xmm3, xmm5
subsd xmm1, xmm0
movapd xmm0, xmm4
mulsd xmm0, xmm2
movapd xmm2, xmm1
addsd xmm3, xmm0
cmp eax, edx
jl 0x10080732
mov ecx, dword [ebp - 4]
pop edi
xor ecx, ebp
pop esi
call fcn.10176850
mov esp, ebp
pop ebp
ret