Function at 0x440030
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x24
mov eax, dword [esp + 0x3c]
test eax, eax
je 0x44007a
mov ecx, 0xfffffffe
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
cmp word [eax + ecx + 2], 0
lea ecx, [ecx + 2]
jne 0x440050
sar ecx, 1
mov edx, ecx
and edx, 2
mov esi, ecx
or ecx, 2
imul ecx, edx
xor edx, 2
and esi, 0xfffd
imul esi, edx
add ecx, esi
jmp 0x44007c
xor ecx, ecx
mov word [esp + 0x18], cx
mov edx, eax
test eax, eax
je 0x44008c
add ecx, 2
mov edx, ecx
mov word [esp + 0x1a], dx
mov dword [esp + 0x1c], eax
mov dword [esp], 0xc8cbcacd
mov word [esp + 4], 0
xor eax, eax
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
movzx ecx, byte [esp + eax]
lea edx, [eax - 0x3ef55dcd]
lea esi, [eax + 0x33]
or edx, esi
and edx, ecx
mov esi, edx
and esi, 0x3d
mov edi, edx
and edi, 2
mov ebx, edx
or ebx, 0xfd
inc ebx
imul ebx, esi
or edx, 2
imul edx, edi
sub ebx, edx
add ecx, eax
add ecx, 0xc10aa233
add ecx, ebx
inc cl
mov byte [esp + eax], cl
mov ecx, eax
and ecx, 4
or eax, 0xd1ba3f34
add eax, ecx
inc eax
mov ecx, eax
xor ecx, 0xd1ba3f34
and eax, 0xb
add eax, eax
sub eax, ecx
cmp eax, 6
jb 0x4400b0
mov ebx, dword [esp]
mov eax, dword [0x44ac38]
test eax, eax
je 0x44016f
xor ecx, ecx
mov edx, dword [0x44ac3c]
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
cmp dword [edx + ecx*8], 0xc0a4c970
je 0x440140
inc ecx
cmp eax, ecx
jne 0x440130
jmp 0x44016f
mov eax, dword [edx + ecx*8 + 4]
cmp eax, ebx
je 0x44016f
lea ecx, [esp + 0xc]
lea edx, [esp + 0x18]
push ecx
push 0
push 0
push 2
push edx
push dword [esp + 0x4c]
push 6
push eax
push dword [0x44ac40]
call fcn.0043b650
add esp, 0x24
mov ebx, eax
mov dword [esp], 0x53121133
xor eax, eax
nop
nop
nop
nop
nop
nop
nop
nop
mov ecx, eax
add cl, 0xc4
xor cl, byte [esp + eax]
add cl, 0x2c
mov byte [esp + eax], cl
inc eax
cmp eax, 4
jne 0x440180
cmp ebx, dword [esp]
jne 0x44036e
push dword [esp + 0xc]
call fcn.004386f0
add esp, 4
mov ecx, dword [esp + 0xc]
mov dword [esp + 8], ecx
mov dword [esp + 0x10], 0x77767966
mov word [esp + 0x14], 0
mov byte [esp + 0x16], 0
mov edx, 0xd3ec16
mov esi, 0xe9
nop
movzx edi, byte [esp + edx - 0xd3ec06]
mov ebx, esi
xor ebx, edx
and ebx, edi
xor ebx, edx
mov edi, 0x6e
sub edi, ebx
not ebx
and ebx, 1
or edi, 1
sub ebx, edi
mov byte [esp + edx - 0xd3ec06], bl
inc edx
dec esi
cmp edx, 0xd3ec1d
jne 0x4401d0
mov ecx, dword [esp + 0x10]
mov dword [esp + 0x20], ecx
mov dword [esp], 0xc8cbcacd
mov word [esp + 4], 0
xor ebx, ebx
nop
nop
nop
nop
nop
nop
movzx esi, byte [esp + ebx]
lea ebp, [ebx - 0x3ef55dcd]
lea edi, [ebx + 0x33]
or ebp, edi
and ebp, esi
mov edi, ebp
and edi, 0x3d
mov ecx, ebp
and ecx, 2
mov edx, ebp
or edx, 0xfd
inc edx
imul edx, edi
or ebp, 2
imul ebp, ecx
sub edx, ebp
lea ecx, [ebx + esi]
add ecx, 0xc10aa233
add ecx, edx
inc cl
mov byte [esp + ebx], cl
mov ecx, ebx
and ecx, 4
or ebx, 0xd1ba3f34
add ebx, ecx
inc ebx
mov ecx, ebx
xor ecx, 0xd1ba3f34
and ebx, 0xb
add ebx, ebx
sub ebx, ecx
cmp ebx, 6
jb 0x440220
mov ebx, dword [esp]
mov esi, dword [0x44ac38]
test esi, esi
je 0x4402e6
xor ebp, ebp
mov edi, dword [0x44ac3c]
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
cmp dword [edi + ebp*8], 0xc0a4c970
je 0x4402b0
inc ebp
cmp esi, ebp
jne 0x4402a0
jmp 0x4402e6
mov esi, dword [edi + ebp*8 + 4]
cmp esi, ebx
je 0x4402e6
lea ecx, [esp + 0xc]
lea edx, [esp + 0x18]
push ecx
push dword [esp + 0xc]
push eax
push dword [esp + 0x2c]
push edx
push dword [esp + 0x4c]
push 6
push esi
push dword [0x44ac40]
mov esi, eax
call fcn.0043b650
add esp, 0x24
mov ebx, eax
mov eax, esi
test ebx, ebx
mov edi, dword [esp + 0x48]
mov ebp, dword [esp + 0x44]
js 0x440365
mov edx, dword [esp + 0x40]
test edx, edx
je 0x4402ff
mov ecx, dword [eax + 4]
mov dword [edx], ecx
test edi, edi
je 0x440365
test ebp, ebp
je 0x440360
mov edx, dword [edi]
mov ecx, dword [eax + 8]
cmp edx, ecx
jb 0x440312
mov edx, ecx
lea esi, [eax + 0xc]
mov ecx, edx
shr ecx, 2
mov edi, ebp
xchg esi, esi
rep movsd dword es:[edi], dword [esi]
xchg esi, esi
mov ecx, edx
not ecx
or ecx, 0xfffffffc
add ecx, edx
lea edi, [ecx + ebp]
inc edi
lea esi, [eax + ecx]
add esi, 0xd
mov ecx, edx
shr ecx, 1
and ecx, 1
mov ebp, esi
mov dword [esp + 8], edi
xchg esi, ebp
rep movsw word es:[edi], word [esi]
xchg esi, ebp
test dl, 1
mov edi, dword [esp + 0x48]
je 0x440360
and edx, 2
movzx ecx, byte [esi + edx]
mov esi, dword [esp + 8]
mov byte [esi + edx], cl
mov ecx, dword [eax + 8]
mov dword [edi], ecx
push eax
call fcn.00438790
add esp, 4
mov eax, ebx
add esp, 0x24
pop esi
pop edi
pop ebx
pop ebp
ret