Function at 0x401750
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
mov esi, ecx
mov eax, edx
push edi
xor edi, edi
mov dword [ebp - 4], eax
mov dword [ebp - 0x1c], esi
cmp byte [esi + 0x17], 0
jne 0x40181d
cmp dword [esi + 4], edi
jle 0x401812
xor ebx, ebx
nop word [eax + eax]
cmp byte [esi + 0x17], 0
jne 0x401791
mov al, byte [edi + eax]
cmp al, 0xff
je 0x401805
cmp al, 0xa
jbe 0x401805
mov eax, dword [esi + 0x20]
mov ecx, dword [eax + edi*4]
mov edx, ecx
shr edx, 1
lea eax, [ecx + ecx]
xor edx, eax
lea eax, [ecx + ecx]
and edx, 0x55555555
xor edx, eax
mov ecx, edx
shr ecx, 2
lea eax, [edx*4]
xor ecx, eax
lea eax, [edx*4]
and ecx, 0x33333333
xor ecx, eax
mov edx, ecx
mov eax, ecx
shr edx, 4
shl eax, 4
xor edx, eax
shl ecx, 4
and edx, 0xf0f0f0f
xor edx, ecx
mov ecx, edx
mov eax, edx
shr ecx, 8
shl eax, 8
xor ecx, eax
shl edx, 8
mov eax, dword [esi + 0x824]
and ecx, 0xff00ff
xor ecx, edx
rol ecx, 0x10
mov dword [ebx + eax], ecx
add ebx, 4
mov eax, dword [ebp - 4]
inc edi
cmp edi, dword [esi + 4]
jl 0x401780
mov eax, dword [esi + 0x82c]
jmp 0x4018a3
mov eax, dword [esi + 0x82c]
test eax, eax
jle 0x4018a3
mov eax, dword [esi + 0x20]
mov ecx, dword [eax + edi*4]
mov edx, ecx
shr edx, 1
lea eax, [ecx + ecx]
xor edx, eax
lea eax, [ecx + ecx]
and edx, 0x55555555
xor edx, eax
mov ecx, edx
shr ecx, 2
lea eax, [edx*4]
xor ecx, eax
lea eax, [edx*4]
and ecx, 0x33333333
xor ecx, eax
mov edx, ecx
mov eax, ecx
shl eax, 4
shr edx, 4
xor edx, eax
shl ecx, 4
and edx, 0xf0f0f0f
xor edx, ecx
mov ecx, edx
mov eax, edx
shr ecx, 8
shl eax, 8
xor ecx, eax
shl edx, 8
mov eax, dword [esi + 0x824]
and ecx, 0xff00ff
xor ecx, edx
rol ecx, 0x10
mov dword [eax + edi*4], ecx
inc edi
mov eax, dword [esi + 0x82c]
cmp edi, eax
jl 0x401827
push 0x401730
push 4
push eax
push dword [esi + 0x824]
call fcn.00501e60
mov ecx, dword [esi + 0x82c]
add esp, 0x10
mov eax, dword [esi + 0x824]
mov dword [eax + ecx*4], 0xffffffff
cmp byte [esi + 0x17], 0
je 0x4018da
mov eax, dword [esi + 0x82c]
jmp 0x4018dd
mov eax, dword [esi + 4]
xor ecx, ecx
mov dword [ebp - 0x14], eax
mov dword [ebp - 0xc], ecx
test eax, eax
jle 0x401a0e
nop dword [eax]
mov bh, byte [esi + 0x17]
test bh, bh
je 0x401905
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 4]
mov eax, dword [eax + ecx*4]
mov bl, byte [edx + eax]
jmp 0x40191d
mov eax, dword [ebp - 4]
mov bl, byte [eax + ecx]
cmp bl, 0xff
je 0x401a01
cmp bl, 0xa
jbe 0x401a01
mov eax, dword [esi + 0x20]
shl ecx, 2
mov dword [ebp - 0x20], ecx
mov edi, dword [esi + 0x82c]
mov ecx, dword [ecx + eax]
mov edx, ecx
shr edx, 1
lea eax, [ecx + ecx]
xor edx, eax
lea eax, [ecx + ecx]
and edx, 0x55555555
xor edx, eax
mov ecx, edx
shr ecx, 2
lea eax, [edx*4]
xor ecx, eax
lea eax, [edx*4]
and ecx, 0x33333333
xor ecx, eax
mov edx, ecx
mov eax, ecx
shr edx, 4
shl ecx, 4
shl eax, 4
xor edx, eax
and edx, 0xf0f0f0f
xor edx, ecx
mov ecx, edx
mov eax, edx
shr ecx, 8
shl eax, 8
xor ecx, eax
shl edx, 8
and ecx, 0xff00ff
xor ecx, edx
rol ecx, 0x10
mov dword [ebp - 0x10], ecx
xor ecx, ecx
mov dword [ebp - 8], ecx
cmp edi, 1
jle 0x4019d9
mov ecx, dword [esi + 0x824]
mov esi, dword [ebp - 8]
mov dword [ebp - 0x18], ecx
nop word [eax + eax]
mov edx, edi
shr edx, 1
lea eax, [edx + esi]
mov ecx, dword [ecx + eax*4]
cmp ecx, dword [ebp - 0x10]
cmovbe esi, eax
sub edi, edx
cmp ecx, dword [ebp - 0x10]
mov ecx, dword [ebp - 0x18]
cmova edi, edx
cmp edi, 1
jg 0x4019b0
mov dword [ebp - 8], esi
mov esi, dword [ebp - 0x1c]
mov ecx, dword [ebp - 8]
mov eax, dword [esi + 0x828]
lea edx, [eax + ecx*4]
test bh, bh
je 0x4019fc
mov eax, dword [ebp + 8]
mov edi, dword [ebp - 0x20]
mov eax, dword [edi + eax]
mov dword [edx], eax
mov eax, dword [esi + 8]
mov byte [ecx + eax], bl
mov ecx, dword [ebp - 0xc]
jmp 0x401a01
mov ecx, dword [ebp - 0xc]
mov dword [edx], ecx
inc ecx
mov dword [ebp - 0xc], ecx
cmp ecx, dword [ebp - 0x14]
jl 0x4018f0
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret