Function at 0x51aa40
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5ba5de
mov eax, dword fs:[0]
push eax
sub esp, 0x910
mov eax, dword [0x68683c]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 0x10]
mov eax, dword [ebp + 0xc]
mov edi, dword [ebp + 0x14]
mov ebx, dword [ebp + 8]
mov ecx, esi
mov dword [ebp - 0x8e0], eax
mov dword [ebp - 0x900], esi
mov dword [ebp - 0x8f8], edi
call fcn.0041b6b0
lea ecx, [ebp - 0x370]
call fcn.005165e0
lea ecx, [ebp - 0xe0]
mov dword [ebp - 4], 0
call fcn.00516a20
lea ecx, [ebp - 0x8d8]
mov byte [ebp - 4], 1
call fcn.005190e0
push ebx
lea ecx, [ebp - 0xcc]
mov byte [ebp - 4], 2
mov dword [ebp - 0xd8], 1
call fcn.0041e780
lea ecx, [ebp - 0xcc]
call fcn.004078c0
push edi
add eax, eax
lea ecx, [ebp - 0x8d8]
push ecx
lea edx, [ebp - 0xe0]
add eax, eax
push edx
add eax, eax
mov ebx, 3
push 1
lea ecx, [ebp - 0x370]
mov dword [ebp - 0xd0], eax
mov dword [ebp - 0xd4], ebx
call fcn.00519ea0
lea ecx, [ebp - 0x91c]
call fcn.0041b9a0
mov eax, dword [ebp - 0x8e0]
push eax
lea ecx, [ebp - 0x91c]
mov byte [ebp - 4], bl
mov byte [ebp - 0x904], 1
call fcn.0041e780
lea ecx, [ebp - 0x91c]
call fcn.004078c0
mov ebx, eax
mov dword [ebp - 0x8fc], ebx
cmp ebx, 2
jb 0x51acfd
test bl, 7
jne 0x51acfd
push 8
push 0xa6
mov ecx, esi
call fcn.0041c700
lea ecx, [ebp - 0x91c]
push ecx
mov ecx, esi
call fcn.0041e780
shr ebx, 3
mov ecx, esi
mov dword [ebp - 0x8e4], ebx
call fcn.0041b6d0
xor ecx, ecx
mov esi, eax
mov dword [ebp - 0x8e0], ecx
mov eax, dword [ebp - 0x8e4]
mov ebx, 1
lea edi, [esi + 8]
cmp eax, ebx
jl 0x51ac2d
imul cl
mov byte [ebp - 0x8d9], al
mov eax, dword [esi + 4]
mov ecx, dword [edi]
mov edx, dword [esi]
mov dword [ebp - 0x8f0], eax
lea eax, [ebp - 0x8f4]
mov dword [ebp - 0x8ec], ecx
mov ecx, eax
push eax
mov dword [ebp - 0x8f4], edx
mov edx, dword [edi + 4]
push ecx
lea ecx, [ebp - 0x370]
mov dword [ebp - 0x8e8], edx
call fcn.005171d0
mov edx, dword [ebp - 0x8f4]
mov eax, dword [ebp - 0x8f0]
mov cl, byte [ebp - 0x8d9]
mov dword [esi + 4], eax
mov eax, dword [ebp - 0x8e8]
mov dword [esi], edx
mov edx, dword [ebp - 0x8ec]
add cl, bl
xor byte [esi + 7], cl
mov dword [edi], edx
mov dword [edi + 4], eax
inc ebx
add edi, 8
cmp ebx, dword [ebp - 0x8e4]
jle 0x51abb7
mov ecx, dword [ebp - 0x8e0]
inc ecx
mov dword [ebp - 0x8e0], ecx
cmp ecx, 5
jle 0x51ab99
mov edi, dword [ebp - 0x900]
mov ecx, edi
mov bl, 1
call fcn.004078c0
mov ecx, dword [ebp - 0x8fc]
add ecx, 8
cmp eax, ecx
je 0x51ac83
mov esi, dword [ebp - 0x8f8]
mov edx, dword [esi]
mov eax, dword [edx + 0x14]
push str.Output_is_not_the_expected_size.
mov ecx, esi
call eax
mov ecx, edi
call fcn.004078c0
push eax
push str.outNumBytes
mov ecx, esi
call fcn.00459e10
xor bl, bl
lea ecx, [ebp - 0x91c]
mov byte [ebp - 4], 2
call fcn.0041c170
lea ecx, [ebp - 0x8d8]
mov byte [ebp - 4], 1
call fcn.00516960
mov dword [ebp - 0xe0], vtable._ckSymSettings.0
lea ecx, [ebp - 0x74]
mov byte [ebp - 4], 9
call fcn.0041c170
lea ecx, [ebp - 0x90]
mov byte [ebp - 4], 8
call fcn.0041c170
lea ecx, [ebp - 0xac]
mov byte [ebp - 4], 7
call fcn.0041c170
lea ecx, [ebp - 0xcc]
mov byte [ebp - 4], 0
call fcn.0041c170
lea ecx, [ebp - 0x370]
mov dword [ebp - 4], 0xffffffff
call fcn.00516660
mov al, bl
jmp 0x51ad8d
mov edx, dword [edi]
mov eax, dword [edx + 0x14]
push str.Key_data_must_be_a_multiple_of_8_bytes_in_length.
mov ecx, edi
call eax
push ebx
push str.keyDataLen
mov ecx, edi
call fcn.00459e10
lea ecx, [ebp - 0x91c]
mov byte [ebp - 4], 2
call fcn.0041c170
lea ecx, [ebp - 0x8d8]
mov byte [ebp - 4], 1
call fcn.00516960
mov dword [ebp - 0xe0], vtable._ckSymSettings.0
lea ecx, [ebp - 0x74]
mov byte [ebp - 4], 6
call fcn.0041c170
lea ecx, [ebp - 0x90]
mov byte [ebp - 4], 5
call fcn.0041c170
lea ecx, [ebp - 0xac]
mov byte [ebp - 4], 4
call fcn.0041c170
lea ecx, [ebp - 0xcc]
mov byte [ebp - 4], 0
call fcn.0041c170
lea ecx, [ebp - 0x370]
mov dword [ebp - 4], 0xffffffff
call fcn.00516660
xor al, al
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.005a6cf8
mov esp, ebp
pop ebp
ret