Function at 0x4074b0
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
mov eax, 0x15a0
call fcn.00407e40
mov esi, dword [esp + 0x15bc]
mov ebx, dword [esp + 0x15b8]
mov edi, dword [esp + 0x15b4]
lea eax, [esp + 0x1c]
push 0x84
push 0
push eax
call fcn.00407fe0
add esp, 0xc
cmp dword [esp + 0x15c4], 0
je 0x40758f
test esi, esi
mov ecx, esi
mov ebx, dword [esp + 0x15c0]
jle 0x407a1d
xor eax, eax
cmp ecx, 1
je 0x407558
mov ecx, dword [esp + 0x15bc]
and ecx, 0x7ffffffe
mov eax, dword [esp + 0x15b8]
lea eax, [eax + eax*8]
shl eax, 5
lea edx, [eax + edi]
add edx, 0x8f13
xor eax, eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx esi, byte [edx + eax - 1]
inc dword [esp + esi*4 + 0x1c]
movzx esi, byte [edx + eax]
inc dword [esp + esi*4 + 0x1c]
add eax, 2
cmp ecx, eax
jne 0x407540
mov ecx, dword [esp + 0x15bc]
test cl, 1
je 0x407a1d
mov ecx, dword [esp + 0x15b8]
lea ecx, [ecx + ecx*8]
shl ecx, 5
add ecx, edi
movzx eax, byte [eax + ecx + 0x8f12]
mov ecx, dword [esp + 0x15bc]
inc dword [esp + eax*4 + 0x1c]
jmp 0x407a1d
lea ebx, [ebx + ebx*8]
mov ebp, ebx
shl ebp, 6
test esi, esi
mov dword [esp + 0x10], ebx
jle 0x407643
cmp esi, 1
jne 0x407872
xor eax, eax
xor edi, edi
mov ecx, dword [esp + 0x15bc]
test cl, 1
je 0x4075e5
mov ecx, dword [esp + 0x15b4]
add ecx, ebp
add ecx, 0x8192
movzx ecx, word [ecx + eax*2]
test cx, cx
je 0x4075e5
mov word [esp + edi*4 + 0xa0], cx
mov word [esp + edi*4 + 0xa2], ax
inc edi
lea eax, [esp + 0x520]
push 0x800
push 0
push eax
call fcn.00407fe0
add esp, 0xc
test edi, edi
sete byte [esp + 3]
je 0x40765a
xor eax, eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx ecx, word [esp + eax*4 + 0xa0]
mov edx, ecx
not edx
or edx, 0xff
add edx, ecx
inc dword [esp + edx*4 + 0x524]
shr ecx, 8
inc dword [esp + ecx*4 + 0x920]
inc eax
cmp edi, eax
jne 0x407610
mov eax, dword [esp + 0x920]
jmp 0x407663
lea eax, [esp + 0x520]
push 0x800
push 0
push eax
call fcn.00407fe0
add esp, 0xc
xor edi, edi
mov byte [esp + 3], 1
xor eax, eax
mov dword [esp + 0xc], ebp
xor ecx, ecx
mov dword [esp + 8], edi
cmp eax, edi
setne cl
inc ecx
mov dword [esp + 0x14], ecx
lea edi, [esp + 0xa0]
lea eax, [esp + 0x1120]
xor ecx, ecx
xor edx, edx
jmp 0x4076a8
mov edx, dword [esp + 0x18]
inc edx
add ecx, 8
mov eax, edi
cmp edx, dword [esp + 0x14]
mov edi, dword [esp + 4]
je 0x407734
mov dword [esp + 4], eax
mov dword [esp + 0x18], edx
mov eax, edx
shl eax, 0xa
add eax, esp
add eax, 0x520
xor edx, edx
xor ebx, ebx
mov dword [esp + ebx*4 + 0xd20], edx
add edx, dword [eax + ebx*4]
mov ebp, ebx
and ebp, 1
xor ebx, 1
lea ebx, [ebx + ebp*2]
cmp ebx, 0x100
jb 0x4076c0
cmp byte [esp + 3], 0
jne 0x407690
xor eax, eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx edx, word [edi + eax*4]
shr edx, cl
movzx esi, dl
mov ebx, dword [esp + esi*4 + 0xd20]
mov ebp, dword [edi + eax*4]
mov edx, edi
mov edi, dword [esp + 4]
mov dword [edi + ebx*4], ebp
mov edi, edx
mov ebp, ebx
and ebx, 1
xor ebp, 1
lea ebx, [ebx*2]
add ebx, ebp
mov dword [esp + esi*4 + 0xd20], ebx
mov edx, dword [esp + 8]
inc eax
cmp edx, eax
jne 0x4076f0
jmp 0x407690
mov eax, dword [esp + 8]
push eax
push edi
mov edi, eax
call fcn.00407bb0
add esp, 8
test edi, edi
mov ebx, dword [esp + 0x15c0]
mov ebp, dword [esp + 0x10]
jle 0x4078e5
mov eax, edi
and eax, 3
xor ecx, ecx
cmp edi, 4
mov edi, dword [esp + 4]
jb 0x4077aa
mov edx, dword [esp + 8]
and edx, 0x7ffffffc
xor ecx, ecx
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx esi, word [edi + ecx*4]
inc dword [esp + esi*4 + 0x1c]
movzx esi, word [edi + ecx*4 + 4]
inc dword [esp + esi*4 + 0x1c]
movzx esi, word [edi + ecx*4 + 8]
inc dword [esp + esi*4 + 0x1c]
movzx esi, word [edi + ecx*4 + 0xc]
inc dword [esp + esi*4 + 0x1c]
add ecx, 4
cmp edx, ecx
jne 0x407780
test eax, eax
je 0x4077cd
mov edx, dword [esp + 4]
lea ecx, [edx + ecx*4]
xor edx, edx
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx esi, word [ecx + edx*4]
inc dword [esp + esi*4 + 0x1c]
inc edx
cmp eax, edx
jne 0x4077c0
mov edi, dword [esp + 8]
cmp edi, 1
je 0x4078e5
cmp ebx, 0x20
jge 0x407840
mov eax, dword [esp + ebx*4 + 0x1c]
mov edx, ebx
neg edx
mov ecx, ebx
and edx, 3
je 0x4077fc
nop
nop
add eax, dword [esp + ecx*4 + 0x20]
inc ecx
mov dword [esp + ebx*4 + 0x1c], eax
dec edx
jne 0x4077f0
lea edx, [ebx - 0x1d]
cmp edx, 3
jb 0x407838
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
add eax, dword [esp + ecx*4 + 0x20]
mov dword [esp + ebx*4 + 0x1c], eax
add eax, dword [esp + ecx*4 + 0x24]
mov dword [esp + ebx*4 + 0x1c], eax
add eax, dword [esp + ecx*4 + 0x28]
mov dword [esp + ebx*4 + 0x1c], eax
add eax, dword [esp + ecx*4 + 0x2c]
add ecx, 4
mov dword [esp + ebx*4 + 0x1c], eax
cmp ecx, 0x20
jne 0x407810
test ebx, ebx
jle 0x4078d5
lea edx, [ebx + 1]
xor ecx, ecx
xor eax, eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov esi, dword [esp + edx*4 + 0x18]
shl esi, cl
add eax, esi
dec edx
inc ecx
cmp edx, 1
ja 0x407850
mov edx, 1
mov ecx, ebx
shl edx, cl
cmp eax, edx
jne 0x407b6d
jmp 0x4078e5
mov ecx, esi
and ecx, 0x7ffffffe
lea edx, [edi + ebp]
add edx, 0x8194
xor eax, eax
xor edi, edi
jmp 0x40789b
add eax, 2
cmp ecx, eax
je 0x4075b0
movzx esi, word [edx + eax*2 - 2]
test si, si
je 0x4078b6
mov word [esp + edi*4 + 0xa0], si
mov word [esp + edi*4 + 0xa2], ax
inc edi
movzx esi, word [edx + eax*2]
test si, si
je 0x407890
mov word [esp + edi*4 + 0xa0], si
lea esi, [eax + 1]
mov word [esp + edi*4 + 0xa2], si
inc edi
jmp 0x407890
mov edx, 1
mov ecx, ebx
shl edx, cl
xor eax, eax
jmp 0x407b6d
shl ebp, 5
mov esi, dword [esp + 0x15b4]
lea eax, [esi + ebp]
add eax, 0x8f12
push 0x120
push 0
push eax
call fcn.00407fe0
add esp, 0xc
mov eax, dword [esp + 0xc]
add eax, esi
add eax, 0x8852
push 0x240
push 0
push eax
call fcn.00407fe0
add esp, 0xc
test ebx, ebx
mov esi, dword [esp + 4]
jle 0x407a0f
add esi, 0xfffffffe
mov eax, 1
add ebp, dword [esp + 0x15b4]
mov dword [esp + 4], esi
jmp 0x40795d
lea ecx, [eax + 1]
cmp eax, ebx
mov eax, ecx
je 0x407a0f
mov ecx, dword [esp + eax*4 + 0x1c]
test ecx, ecx
jle 0x407950
mov edx, ecx
and edx, 3
je 0x4079c0
mov dword [esp + 8], ecx
mov ecx, edi
lea ebx, [esi + edi*4]
xor esi, esi
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov ecx, ebp
movzx ebp, word [ebx]
mov byte [ebp + ecx + 0x8f12], al
mov ebp, ecx
inc esi
add ebx, 0xfffffffc
cmp edx, esi
jne 0x407980
sub edi, esi
mov ecx, dword [esp + 8]
mov edx, ecx
sub edx, esi
mov ebx, dword [esp + 0x15c0]
mov esi, dword [esp + 4]
cmp ecx, 4
jb 0x407950
jmp 0x4079c7
mov edx, ecx
cmp ecx, 4
jb 0x407950
dec edx
nop
nop
nop
nop
nop
nop
nop
nop
movzx ecx, word [esi + edi*4]
mov byte [ecx + ebp + 0x8f12], al
movzx ecx, word [esi + edi*4 - 4]
mov byte [ecx + ebp + 0x8f12], al
movzx ecx, word [esi + edi*4 - 8]
mov byte [ecx + ebp + 0x8f12], al
movzx ecx, word [esi + edi*4 - 0xc]
add edi, 0xfffffffc
mov byte [ecx + ebp + 0x8f12], al
add edx, 0xfffffffc
cmp edx, 0xfffffffe
jb 0x4079d0
jmp 0x407950
mov ecx, dword [esp + 0x15bc]
mov edi, dword [esp + 0x15b4]
mov dword [esp + 0x524], 0
cmp ebx, 2
jl 0x407a8d
lea ecx, [ebx - 1]
cmp ebx, 2
jne 0x407a3e
xor eax, eax
mov edx, 2
jmp 0x407a74
mov ebx, ecx
and ebx, 0xfffffffe
xor eax, eax
xor edx, edx
nop
nop
nop
nop
nop
nop
nop
nop
nop
add eax, dword [esp + edx*4 + 0x20]
add eax, eax
mov dword [esp + edx*4 + 0x528], eax
add eax, dword [esp + edx*4 + 0x24]
add eax, eax
mov dword [esp + edx*4 + 0x52c], eax
add edx, 2
cmp ebx, edx
jne 0x407a50
add edx, 2
test cl, 1
mov ecx, dword [esp + 0x15bc]
je 0x407a8d
add eax, dword [esp + edx*4 + 0x18]
add eax, eax
mov dword [esp + edx*4 + 0x520], eax
test ecx, ecx
jle 0x407b62
xor eax, eax
mov edx, dword [esp + 0x15b8]
lea esi, [edx + edx*8]
mov edx, esi
shl edx, 5
add edx, edi
shl esi, 6
add esi, edi
mov dword [esp + 4], esi
jmp 0x407adc
mov ecx, dword [esp + 4]
mov word [ecx + eax*2 + 0x8852], di
mov ecx, dword [esp + 0x15bc]
inc eax
cmp eax, ecx
je 0x407b62
movzx ebx, byte [eax + edx + 0x8f12]
test ebx, ebx
je 0x407ad3
mov ecx, dword [esp + ebx*4 + 0x520]
lea edi, [ecx + 1]
mov dword [esp + ebx*4 + 0x520], edi
xor edi, edi
cmp bl, 4
jb 0x407b3f
mov ebp, ebx
and ebp, 0xfffffffc
xor edi, edi
nop
nop
nop
nop
nop
nop
nop
nop
nop
mov esi, ecx
and esi, 1
shl esi, 2
lea esi, [esi + edi*8]
mov edi, ecx
and edi, 2
or edi, esi
mov esi, ecx
shr esi, 2
and esi, 1
or esi, edi
mov edi, ecx
shr edi, 3
and edi, 1
lea edi, [edi + esi*2]
shr ecx, 4
add ebp, 0xfffffffc
jne 0x407b10
and ebx, 3
je 0x407ac0
nop
nop
nop
nop
nop
nop
nop
nop
mov esi, ecx
and esi, 1
lea edi, [esi + edi*2]
shr ecx, 1
dec ebx
jne 0x407b50
jmp 0x407ac0
add esp, 0x15a0
pop esi
pop edi
pop ebx
pop ebp
ret
dec dword [esp + ebx*4 + 0x1c]
mov ecx, ebx
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
cmp ecx, 2
jl 0x407b98
mov esi, dword [esp + ecx*4 + 0x18]
dec ecx
test esi, esi
je 0x407b80
dec esi
mov dword [esp + ecx*4 + 0x1c], esi
add dword [esp + ecx*4 + 0x20], 2
dec eax
cmp eax, edx
jne 0x407b6d
jmp 0x4078e5