Function at 0x825130
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x2c
mov eax, dword [0xbcbae0]
mov ebx, dword [esp + 0x40]
mov esi, edx
xor eax, esp
mov edx, ebx
mov dword [esp + 0x28], eax
mov dword [esp], ecx
mov dword [esp + 8], esi
mov ecx, dword [ecx + 8]
push esi
call fcn.007f6170
add esp, 4
test byte [ebx + 0x24], 0x40
je 0x8251a7
mov eax, dword [esp]
mov edx, 0xffffffff
mov ecx, dword [eax + 8]
call fcn.007ebf40
cmp byte [eax], 0x5a
jne 0x8251a7
mov edi, dword [eax + 0x10]
cmp byte [edi], 0
je 0x8251a7
xor ecx, ecx
mov esi, edi
xor edx, edx
mov eax, dword [ebx + 4]
lea ebp, [edx + edx*4]
movzx eax, word [eax + ebp*4 + 0x10]
test al, 0x20
jne 0x82519d
test al, 0x40
je 0x82519c
mov byte [esi], 0x40
inc ecx
inc edx
cmp byte [edi + ecx], 0
lea esi, [edi + ecx]
jne 0x825186
movzx ecx, word [ebx + 0x2a]
test cx, cx
jle 0x8251db
xor eax, eax
mov esi, dword [ebx + 4]
lea edi, [eax + eax*4]
movzx edx, word [esi + edi*4 + 0x10]
test dl, 0x60
je 0x8251d3
lea ecx, [esi + edi*4 + 0x10]
or edx, 0x80
mov word [ecx], dx
movzx ecx, word [ebx + 0x2a]
inc eax
movsx edx, cx
cmp eax, edx
jl 0x8251b2
mov eax, dword [esp + 8]
mov ecx, dword [esp]
mov dword [esp + 0x24], ebx
mov dword [esp + 0x10], 0x8268c0
mov dword [esp + 0x14], 0
mov dword [esp + 0x18], 0
neg eax
mov dword [ecx + 0x34], eax
movzx eax, word [ebx + 0x2a]
xor edi, edi
test ax, ax
mov ebp, 0
mov dword [esp + 4], 0
jle 0x825483
mov eax, dword [ebx + 4]
lea ecx, [edi + edi*4]
movzx edx, word [eax + ecx*4 + 0x10]
test dl, dl
jns 0x825286
lea esi, [eax + ecx*4]
or edx, 0x100
mov word [esi + 0x10], dx
mov word [esp + 0x20], 0
mov edx, dword [eax + ecx*4 + 4]
lea ecx, [esp + 0xc]
call fcn.007f1950
and byte [esi + 0x11], 0xfe
cmp byte [esp + 0x20], 0
jns 0x825260
mov dword [esp + 4], esi
jmp 0x825286
movsx edx, di
mov ecx, ebx
call fcn.007edca0
cwde
mov ecx, dword [esp]
mov edx, esi
add eax, dword [esp + 8]
push eax
call fcn.007edd00
add esp, 4
and byte [esi + 0x10], 0x7f
mov ebp, 1
movsx eax, word [ebx + 0x2a]
inc edi
cmp edi, eax
jl 0x82521f
test ebp, ebp
je 0x82529e
cmp dword [esp + 4], 0
jne 0x825207
cmp dword [esp + 4], 0
je 0x825483
mov edx, fcn.007bd3b0
movzx ecx, byte [0xbb2c63]
imul edx, edx
and edx, 3
cmp edx, 1
seta al
not al
and al, 7
movzx eax, al
bt ecx, eax
jb 0x82546c
mov al, byte [0xbb2c63]
cmp edx, 1
mov ah, 1
seta cl
not cl
and cl, 7
xor cl, 7
shl ah, cl
or ah, al
lock cmpxchg byte [0xbb2c63], ah
jne 0x8252d6
mov ecx, fcn.007bd3b0
movzx eax, al
imul ecx, ecx
and ecx, 3
cmp ecx, 1
seta dl
not dl
and dl, 7
xor dl, 7
movzx edx, dl
bt eax, edx
jae 0x825336
cmp ecx, 1
movzx edx, byte [0xbb2c63]
seta al
not al
and al, 7
movzx eax, al
bt edx, eax
jae 0x825318
jmp 0x82546c
cmp ecx, 1
movzx ecx, byte [0xbb2c63]
seta al
not al
and al, 7
movzx eax, al
bt ecx, eax
jb 0x825449
mov eax, fcn.007bd3b0
xor ecx, ecx
imul eax, eax
and eax, 3
cmp eax, 1
mov eax, dword [0xbb2c40]
seta cl
xor ecx, 0xf260d2ef
add ecx, 0xa00
mov edx, ecx
xor eax, ecx
shr edx, 0x1f
mov dword [0xbb2c40], eax
not eax
or edx, ecx
and cl, 7
imul edx, eax
mov eax, dword [0xbb2c44]
lea esi, [edx + edx]
xor eax, edx
shr edx, 0x1e
mov dword [0xbb2c44], eax
or esi, edx
not eax
mov edx, dword [0xbb2c48]
imul eax, esi
lea esi, [eax*4]
xor edx, eax
shr eax, 0x1d
mov dword [0xbb2c48], edx
or esi, eax
not edx
mov eax, dword [0xbb2c4c]
imul edx, esi
lea esi, [edx*8]
xor eax, edx
shr edx, 0x1c
mov dword [0xbb2c4c], eax
or esi, edx
not eax
mov edx, dword [0xbb2c50]
imul eax, esi
mov esi, eax
shl esi, 4
xor edx, eax
shr eax, 0x1b
mov dword [0xbb2c50], edx
or eax, esi
not edx
mov edi, dword [0xbb2c54]
imul edx, eax
mov esi, edx
shl esi, 5
xor edi, edx
shr edx, 0x1a
mov dword [0xbb2c54], edi
or edx, esi
not edi
imul edi, edx
mov edx, dword [str.eZyfT]
mov esi, edi
shl esi, 6
xor edx, edi
shr edi, 0x19
mov dword [str.eZyfT], edx
or edi, esi
not edx
imul edx, edi
xor dword [0xbb2c5c], edx
mov dl, 1
shl dl, cl
or byte [0xbb2c63], dl
mov eax, fcn.007bd3b0
imul eax, eax
and eax, 3
cmp eax, 1
mov al, 0xfe
seta cl
not cl
and cl, 7
xor cl, 7
rol al, cl
and byte [0xbb2c63], al
mov eax, dword [esp + 4]
push dword [eax]
push 0xbb2c40
push dword [esp + 8]
call fcn.00782570
add esp, 0xc
mov eax, dword [esp]
mov dword [eax + 0x34], 0
mov ecx, dword [esp + 0x28]
xor ecx, esp
call fcn.00980459
add esp, 0x2c
pop esi
pop edi
pop ebx
pop ebp
ret