Function at 0x81f1e0
Capabilities:
Encode data using xor

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x30
mov eax, dword [ecx + 4]
mov edx, dword [ecx + 8]
mov dword [esp + 0x24], ecx
cmp dword [eax + 0x58], 0
mov dword [esp + 0x10], edx
je 0x81f205
call fcn.0081ffd0
jmp 0x81f951
test eax, eax
mov dword [esp + 0x1c], eax
je 0x81f951
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x1c]
mov edi, fcn.007828a0
mov edx, fcn.0083ada0
mov ebx, 3
imul edi, edi
sub ebx, edx
and edi, 3
mov dword [esp + 4], ebx
mov dword [esp + 0x2c], edi
mov ebp, dword [eax]
mov dword [esp], ecx
mov dword [esp + 8], ebp
cmp edi, 1
movzx ecx, byte [0xbb22d3]
seta al
or al, 2
movzx eax, al
bt ecx, eax
jb 0x81f334
mov al, byte [0xbb22d3]
cmp edi, 1
mov dl, 1
seta cl
or cl, 2
xor cl, 7
shl dl, cl
or dl, al
lock cmpxchg byte [0xbb22d3], dl
jne 0x81f261
cmp edi, 1
movzx eax, al
seta cl
or cl, 2
xor cl, 7
movzx ecx, cl
bt eax, ecx
jae 0x81f2b0
cmp edi, 1
movzx ecx, byte [0xbb22d3]
seta al
or al, 2
movzx eax, al
bt ecx, eax
jae 0x81f294
jmp 0x81f334
cmp edi, 1
movzx ecx, byte [0xbb22d3]
seta al
or al, 2
movzx eax, al
bt ecx, eax
jb 0x81f31e
xor ecx, ecx
cmp edi, 1
mov eax, dword [0xbb22c4]
seta cl
or ecx, 0x2b14ad6a
add ecx, 0x408
xor eax, ecx
mov dword [0xbb22c4], eax
not eax
mov edx, dword [0xbb22c8]
imul eax, ecx
and cl, 7
lea ebp, [eax + eax]
xor edx, eax
shr eax, 0x1e
mov dword [0xbb22c8], edx
or ebp, eax
not edx
mov al, 1
imul edx, ebp
mov ebp, dword [esp + 8]
shl al, cl
xor dword [0xbb22cc], edx
or byte [0xbb22d3], al
cmp edi, 1
mov al, 0xfe
seta cl
or cl, 2
xor cl, 7
rol al, cl
and byte [0xbb22d3], al
mov edx, fcn.007d98e0
mov eax, fcn.007d98e0
movzx esi, byte [0xbb22f3]
and edx, 1
xor edx, eax
xor eax, eax
cmp edx, 0xffffffff
sete al
mov ecx, eax
xor ecx, 1
lea eax, [eax + ecx*2 + 2]
bt esi, eax
jb 0x81f492
mov al, byte [0xbb22f3]
xor ebx, ebx
cmp edx, 0xffffffff
mov ah, 1
sete bl
mov ecx, ebx
xor ecx, 1
lea ecx, [ebx + ecx*2 + 2]
xor cl, 7
shl ah, cl
or ah, al
lock cmpxchg byte [0xbb22f3], ah
jne 0x81f369
xor ecx, ecx
cmp edx, 0xffffffff
movzx eax, al
sete cl
mov ebx, ecx
xor ebx, 1
lea ecx, [ecx + ebx*2 + 2]
mov ebx, dword [esp + 4]
xor cl, 7
movzx ecx, cl
bt eax, ecx
jae 0x81f3d2
xor eax, eax
cmp edx, 0xffffffff
movzx esi, byte [0xbb22f3]
sete al
mov ecx, eax
xor ecx, 1
lea eax, [eax + ecx*2 + 2]
bt esi, eax
jae 0x81f3b0
jmp 0x81f492
xor eax, eax
cmp edx, 0xffffffff
movzx esi, byte [0xbb22f3]
sete al
mov ecx, eax
xor ecx, 1
lea eax, [eax + ecx*2 + 2]
bt esi, eax
jb 0x81f474
xor eax, eax
cmp edx, 0xffffffff
sete al
mov ecx, eax
not ecx
and ecx, 0x15
lea ecx, [eax + ecx*2 - 0x2ec18896]
mov eax, dword [0xbb22e0]
mov ebx, ecx
shr ebx, 0x1f
or ebx, ecx
xor eax, ecx
and cl, 7
mov dword [0xbb22e0], eax
not eax
imul ebx, eax
mov eax, dword [0xbb22e4]
lea ebp, [ebx + ebx]
xor eax, ebx
shr ebx, 0x1e
mov dword [0xbb22e4], eax
or ebp, ebx
not eax
mov ebx, dword [0xbb22e8]
imul eax, ebp
lea ebp, [eax*4]
xor ebx, eax
shr eax, 0x1d
mov dword [0xbb22e8], ebx
or ebp, eax
not ebx
mov al, 1
imul ebx, ebp
mov ebp, dword [esp + 8]
shl al, cl
xor dword [0xbb22ec], ebx
mov ebx, dword [esp + 4]
or byte [0xbb22f3], al
xor eax, eax
cmp edx, 0xffffffff
sete al
mov ecx, eax
xor ecx, 1
lea ecx, [eax + ecx*2 + 2]
mov al, 0xfe
xor cl, 7
rol al, cl
and byte [0xbb22f3], al
mov eax, dword [esp]
mov esi, dword [eax + 0x2c]
mov edx, dword [esi + 0x20]
cmp edx, 0xbb22c4
je 0x81f4af
cmp edx, 0xbb22e0
jne 0x81f5b9
mov edi, dword [esp]
mov ecx, dword [edi + 0x3c]
mov dword [esp + 0x14], ecx
mov ecx, ebp
call fcn.007efdc0
mov ecx, ebp
mov dword [esp + 0xc], eax
call fcn.007f1720
mov ebx, dword [esp + 0x10]
mov ebp, eax
mov edx, 0x48
mov dword [esp], edi
mov ecx, ebx
push dword [edi + 0x38]
push 0
call fcn.007c57e0
add esp, 8
cmp dword [esi + 0x20], 0xbb22c4
jne 0x81f522
mov eax, dword [esp]
mov ecx, ebx
mov edx, 0x59
mov eax, dword [eax + 0x50]
inc eax
push ebp
push eax
mov eax, dword [esp + 0x24]
push dword [eax + 0x30]
call fcn.007c5800
add esp, 0xc
mov ecx, dword [esp + 8]
mov edx, ebp
push 2
call fcn.0081ee90
add esp, 4
jmp 0x81f534
mov ecx, ebx
mov edx, 0x45
push ebp
push 1
call fcn.007c57e0
add esp, 8
mov ecx, ebx
mov edx, 0x69
push ebp
mov esi, dword [esp + 4]
push dword [esi + 0x40]
push ebp
call fcn.007c5800
add esp, 0xc
mov eax, dword [esi + 0x40]
mov ecx, ebx
mov edx, 0x36
inc eax
push ebp
push dword [esp + 0x10]
push eax
call fcn.007c5800
add esp, 0xc
mov ecx, ebx
mov edx, 0x1f
push ebp
push 0
mov edi, dword [esp + 0x1c]
push edi
call fcn.007c5800
add esp, 0xc
mov ecx, ebx
mov edx, 0x59
push dword [esi + 0x38]
push dword [esi + 0x50]
push edi
call fcn.007c5800
add esp, 0xc
mov edx, dword [esp + 0xc]
mov ecx, ebx
call fcn.007f04f0
mov esi, dword [esp + 8]
mov edx, ebp
mov ecx, esi
call fcn.007f0bc0
mov ebx, dword [esp + 4]
mov edi, dword [esp + 0x2c]
mov ebp, esi
jmp 0x81f940
mov ebp, fcn.0082a070
mov dword [esp + 0xc], esi
imul ebp, ebp
movzx ecx, byte [0xbb0e8b]
and ebp, 3
cmp ebp, 1
seta al
or al, 4
add al, 0x84
and al, 7
movzx eax, al
bt ecx, eax
jb 0x81f6c2
mov al, byte [0xbb0e8b]
cmp ebp, 1
mov ah, 1
seta cl
or cl, 4
add cl, 0x84
and cl, 7
xor cl, 7
shl ah, cl
or ah, al
lock cmpxchg byte [0xbb0e8b], ah
jne 0x81f5ec
cmp ebp, 1
movzx eax, al
seta cl
or cl, 4
add cl, 0x84
and cl, 7
xor cl, 7
movzx ecx, cl
bt eax, ecx
jae 0x81f648
cmp ebp, 1
movzx ecx, byte [0xbb0e8b]
seta al
or al, 4
add al, 0x84
and al, 7
movzx eax, al
bt ecx, eax
jae 0x81f62b
jmp 0x81f6c2
cmp ebp, 1
movzx ecx, byte [0xbb0e8b]
seta al
or al, 4
add al, 0x84
and al, 7
movzx eax, al
bt ecx, eax
jb 0x81f6a6
xor ecx, ecx
cmp ebp, 1
mov eax, dword [0xbb0e80]
seta cl
or ecx, 0x59d04c8c
add ecx, 0x684
mov ebx, ecx
xor eax, ecx
shr ebx, 0x1f
mov dword [0xbb0e80], eax
not eax
or ebx, ecx
and cl, 7
imul ebx, eax
mov ah, 1
xor dword [0xbb0e84], ebx
mov ebx, dword [esp + 4]
shl ah, cl
or byte [0xbb0e8b], ah
cmp ebp, 1
mov al, 0xfe
seta cl
or cl, 4
add cl, 0x84
and cl, 7
xor cl, 7
rol al, cl
and byte [0xbb0e8b], al
mov eax, ebx
movzx ecx, byte [0xbb0e97]
mov ebp, dword [esp + 8]
xor eax, fcn.0083ada0
sete al
or al, 2
movzx eax, al
bt ecx, eax
jb 0x81f7be
mov al, byte [0xbb0e97]
mov ecx, ebx
mov ah, 1
xor ecx, fcn.0083ada0
sete cl
or cl, 2
xor cl, 7
shl ah, cl
or ah, al
lock cmpxchg byte [0xbb0e97], ah
jne 0x81f6ea
mov ecx, ebx
movzx eax, al
xor ecx, fcn.0083ada0
sete cl
or cl, 2
xor cl, 7
movzx ecx, cl
bt eax, ecx
jae 0x81f744
mov eax, ebx
movzx ecx, byte [0xbb0e97]
xor eax, fcn.0083ada0
sete al
or al, 2
movzx eax, al
bt ecx, eax
jae 0x81f727
jmp 0x81f7be
mov eax, ebx
movzx ecx, byte [0xbb0e97]
xor eax, fcn.0083ada0
sete al
or al, 2
movzx eax, al
bt ecx, eax
jb 0x81f7a4
mov ebx, dword [esp + 4]
mov eax, dword [0xbb0e8c]
xor ecx, ecx
xor ebx, fcn.0083ada0
mov ebx, eax
sete cl
xor ebx, ecx
or ecx, 0x2e80b792
xor ebx, 0xd17f486d
xor eax, ecx
mov dword [0xbb0e8c], eax
imul ebx, ecx
mov ah, 1
and cl, 3
xor dword [0xbb0e90], ebx
mov ebx, dword [esp + 4]
shl ah, cl
or byte [0xbb0e97], ah
mov eax, ebx
xor eax, fcn.0083ada0
mov al, 0xfe
sete cl
or cl, 2
xor cl, 7
rol al, cl
and byte [0xbb0e97], al
cmp edx, 0xbb0e80
je 0x81f7d2
cmp edx, 0xbb0e8c
jne 0x81f940
mov esi, dword [esp]
mov ebx, ebp
mov ecx, ebx
mov eax, dword [esi + 0x3c]
mov dword [esp + 0x28], eax
mov eax, dword [esi + 0x48]
mov eax, dword [eax + 0x14]
mov ebp, dword [eax]
call fcn.007efdc0
mov ecx, ebx
mov dword [esp + 0x14], eax
call fcn.007f1720
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x1c]
cmp ebp, 2
mov dword [esp + 0x18], ebp
mov ecx, dword [eax + 0x30]
mov eax, dword [esi + 0x38]
jg 0x81f829
mov ebx, dword [esp + 0x10]
mov ebp, ecx
mov edx, 0x48
mov ecx, ebx
push eax
push 0
call fcn.007c57e0
add esp, 8
jmp 0x81f84c
mov ebp, ecx
mov ecx, dword [esp]
mov edx, 0x59
mov ebx, dword [ecx + 0x50]
mov ecx, dword [esp + 0x10]
add ebx, 2
push eax
push ebx
mov ebx, dword [esp + 0x18]
push ebp
call fcn.007c5800
add esp, 0xc
mov esi, dword [esp + 0x20]
mov ecx, ebx
mov edx, 0x7f
push esi
push ebp
call fcn.007c57e0
add esp, 8
mov eax, dword [esp + 0xc]
cmp dword [esp + 0x18], 1
mov eax, dword [eax + 0x20]
jg 0x81f892
xor ecx, ecx
cmp eax, 0xbb0e80
mov edx, 0x52
sete cl
lea eax, [ecx + ecx - 1]
mov ecx, ebx
push eax
push esi
call fcn.007c57e0
add esp, 8
mov ebp, ebx
jmp 0x81f8f0
xor ecx, ecx
cmp eax, 0xbb0e80
mov eax, 0x6a
mov dword [esp + 0x18], ebp
mov ebp, ebx
sete cl
sub eax, ecx
mov ecx, dword [esp + 8]
mov dword [esp + 0xc], eax
call fcn.007f1720
mov ebx, eax
mov eax, dword [esp]
mov ecx, ebp
mov edx, 0x59
mov eax, dword [eax + 0x50]
inc eax
push ebx
push eax
push dword [esp + 0x20]
call fcn.007c5800
add esp, 0xc
mov edx, dword [esp + 0xc]
mov ecx, ebp
push esi
push esi
push ebx
call fcn.007c5800
add esp, 0xc
mov ecx, dword [esp + 8]
mov edx, ebx
call fcn.007f0bc0
mov ebx, dword [esp + 4]
mov ecx, ebp
mov edx, 0x1f
push esi
push dword [esp + 0x18]
mov esi, dword [esp + 0x30]
push esi
call fcn.007c5800
add esp, 0xc
mov eax, dword [esp]
mov ecx, ebp
mov edx, 0x59
push dword [eax + 0x38]
push dword [eax + 0x50]
push esi
call fcn.007c5800
add esp, 0xc
mov edx, dword [esp + 0x14]
mov ecx, ebp
call fcn.007f04f0
mov ebp, dword [esp + 8]
mov edx, dword [esp + 0x20]
mov ecx, ebp
call fcn.007f0bc0
mov eax, dword [esp]
mov eax, dword [eax + 0x24]
test eax, eax
mov dword [esp], eax
jne 0x81f241
mov eax, dword [esp + 0x24]
mov ecx, dword [esp + 0x10]
mov edx, 0xc
push dword [eax + 0xc]
push dword [eax + 0x10]
call fcn.007c57e0
add esp, 0x38
pop esi
pop edi
pop ebx
pop ebp
ret