Function at 0x4f151e
Capabilities:
Encode data using xor

Disassembly:
xor al, 0x85
in eax, dx
je 0x4f155f
test edx, edx
je 0x4f1548
mov cl, byte [edi]
dec edx
mov al, byte [esi + ebp + 0x10]
inc edi
xor al, cl
mov dword [esp + 0x3c], edx
mov byte [ebx], al
inc ebx
xor byte [esi + ebp + 0x40], cl
inc ebp
and ebp, 0xf
mov dword [esi + edi*4 + 0x14], ebp
jne 0x4f1523
jmp 0x4f1550
or ch, ch
jne 0x6a4f16de
lea eax, [esi + 0x60]
push eax
lea eax, [esi + 0x40]
push eax
call dword [esi + ebx*2 + 0x2c]
mov edi, dword [eax + ecx - 0x75]
inc esp
inc esp
cmp al, 0x3d
add byte [eax + eax], cl
push 0xf
adc byte [esi - 0x47960000], 0xab
stosb byte es:[edi], al
stosb byte es:[edi], al
stosb byte es:[edi], al
mov eax, dword [esp + eax*2 + 0x3c]
cmp eax, 0x6a000c00
jb 0x6a4f1604
mov eax, 0xaaaaaaab
lea ecx, [esi + 0x60]
mul dword [esp + 0x3c]
shr edx, 0xb
mov dword [esp + 0x24], edx
push 0x6a000c00
push edi
push ecx
lea eax, [esi + 0x40]
push eax
call dword [esi + ebx*2 + 0x38]
mov ebp, dword [ebx + esi + 0x20]
mov edi, dword [eax + edx - 0x39]
inc esp
and al, 0x20
rol byte [eax], 0
jns 0x4f159f
push dword [ebp + 5]
jne 0x4f15a7
sbb byte [ebp + 0x56501046], cl
push esi
call dword [esp + 0x28]
inc ebp
mov edi, dword [esp + ecx - 0x75]
lds ecx, [edi]
enter 0x4689, 0xc
mov eax, dword [esi + 0x10]
xor eax, dword [edi]
mov dword [ebx], eax
mov eax, dword [edi + 4]
xor eax, dword [esi + 0x14]
mov dword [ebx + 4], eax
mov eax, dword [edi + 8]
xor eax, dword [esi + 0x18]
mov dword [ebx + 8], eax
mov eax, dword [edi + 0xc]
add edi, 0x10
xor eax, dword [esi + 0x1c]
mov dword [ebx + 0xc], eax
add ebx, 0x10
sub dword [esp + 0x20], 1
jne 0x4f159f
sub dword [esi + edi*4 + 0x3c], 0x6a000c00
lea ecx, [esi + 0x60]
sub dword [esp + 0x24], 1
mov dword [ebx - 0x7a8aefbc], ecx
mov ebp, dword [esp + 0x14]
mov esi, dword [edx + 7]
cmp al, 0x8b
enter 0xffffffffffffe183, 0xfffffffffffffff0
je 0x541690
push ecx
push edi
lea eax, [esi + 0x60]
push eax
lea eax, [esi + 0x40]
push eax
call dword [esi + ebx*2 + 0x38]
mov eax, dword [esi + ebx*2 + 0x4c]
mov edi, dword [eax + edx - 0x7d]
clc
adc byte [edx + 0x67], dh
mov ebp, eax
lea ecx, [esi + 0x10]
shr eax, 4
mov dword [esp + 0x3c], eax
push dword [ebp + 5]
sbb byte [ecx + 0x56], dl
call dword [esp + 0x28]
mov eax, dword [esi + ebx*2 + 0x1c]
lea ecx, [esi + 0x10]
inc eax
mov edi, dword [esp + ecx - 0x77]
inc esp
and al, 0x10
sub ebp, 0x10
bswap eax
mov dword [esi + 0xc], eax
mov eax, dword [ecx]
xor eax, dword [edi]
mov dword [ebx], eax
mov eax, dword [edi + 4]
xor eax, dword [esi + 0x14]
mov dword [ebx + 4], eax
mov eax, dword [edi + 8]
xor eax, dword [esi + 0x18]
mov dword [ebx + 8], eax
mov eax, dword [edi + 0xc]
add edi, 0x10
xor eax, dword [esi + 0x1c]
mov dword [ebx + 0xc], eax
add ebx, 0x10
sub dword [esp + 0x3c], 1
jne 0x4f1635
mov dword [esp + 0x3c], ebp
mov ebp, dword [esp + 0x14]
mov esi, dword [edx + 7]
cmp al, 0x85
sal byte [edx + ecx*2 - 1], 0x75
add eax, 0x10468d18
push eax
push esi
call dword [esp + 0x28]
mov eax, dword [esi + ebx*2 + 0x1c]
mov edi, dword [esp + ecx - 0x75]
push esp
and al, 0x3c
inc eax
bswap eax
mov dword [esi + 0xc], eax
sub edi, ebx
lea eax, [ebx + ebp]
lea ebx, [esi + 0x40]
inc esp
sal dword [ebx], 0x28
mov esi, eax
mov cl, byte [edi + esi]
lea eax, [ebx + ebp]
xor byte [eax], cl
lea esi, [esi + 1]
mov al, byte [ebx + ebp - 0x30]
inc ebp
xor al, cl
mov byte [esi - 1], al
sub edx, 1
jne 0x4f16c0
mov esi, dword [ebp + eax + 0x30]
pop edi
mov dword [esi + 0x168], ebp
xor eax, eax
pop ebp
or byte [ebx - 0x7d], bl
jl 0x4f1709
ret
add byte [eax], al
sbb dword [ebx + esi], 0xffffffc9
push ebp
mov ebp, dword [esp + 0x2c]
mov eax, dword [ebx + 0x6a000174]
mov edx, dword [ebx + 0x160]
mov dword [esp + 0xc], eax
mov eax, dword [ebx + 0x164]
mov dword [esp + 0x14], eax
mov eax, ebp
add eax, dword [ebx + 0x38]
mov dword [esp + 0x18], edx
adc ecx, dword [ebx + 0x3c]
cmp ecx, 0xf
ja 0x6a4f191e
jb 0x4f174e
cmp eax, 0xffffffe0
ja 0x3aea51e
cmp dword [ebx + 0x400016c], 0
mov dword [ebx + 0x38], eax
mov dword [ebx + 0x3c], ecx
je 0x4f1774
lea eax, [ebx + 0x60]
push eax
lea eax, [ebx + 0x40]
push eax
call edx
mov edi, dword [eax + ecx - 0x39]
sub dword [ecx + eax], 4
add byte [eax], al
les ecx, [ecx + 0x560c438b]
mov eax, dword [ebx + 0xc]
push esi
mov edx, dword [edx + 1]
sub byte [edi - 0x75], dl
mov ebx, 0x168
mov dword [eax], eax
mov bl, byte [eax]
mov dword [edx + 1], edx
xor al, 0xf
enter 0x4489, 0x24
adc byte [ebp - 0x74a38b01], al
push esp
and al, 0x30
mov dword [esp + 0x28], edx
nop
test ebp, ebp
je 0x4f17d8
mov al, byte [edi + ebx + 0x10]
dec ebp
mov cl, byte [esi]
inc esi
xor al, cl
mov dword [edx + 1], edx
xor al, 0x88
add cl, byte [ebp + 0x48301f04]
inc eax
inc edx
inc edi
mov dword [esp + 0x28], edx
and edi, 0xf
mov dword [esp + eax*2 + 0x18], edi
jne 0x4f179e
lea eax, [ebx + 0x60]
push eax
lea eax, [ebx + 0x40]
push eax
call dword [esp + 0x28]
add esp, 8
jmp 0x4f17f9
test edi, edi
jne 0x6a4f190e
lea eax, [ebx + 0x60]
push eax
lea eax, [ebx + 0x40]
push eax
call dword [esp + 0x28]
add esp, 8
jmp 0x4f17f9
cmp ebp, 0x6a000c00
jb 0x4f1873
mov edi, dword [esp + 0x28]
lea ecx, [ebx + 0x60]
mov eax, 0xaaaaaaab
mul ebp
shr edx, 0xb
mov dword [esp + 0x34], edx
push 0x6a000c00
push esi
push ecx
lea eax, [ebx + 0x40]
push eax
call dword [esp + 0x2c]
push ebx
push dword [ebp + 5]
sub byte [eax - 0x40], ch
add ah, al
mov dword [edi + 0x56], edx
call dword [esp + 0x5c]
mov eax, dword [ebx + 0x7c8b34be]
and al, 0x81
rol eax, 0
les ecx, [ecx + 0xc00c781]
add byte [edx - 0x77], ch
dec esp
add eax, 0xc68110
or al, 0
push 0xf
leave
sub ebp, 0x6a000c00
mov dword [ebx + 0xc], ecx
sub dword [esp + 0x34], 1
lea ecx, [ebx + 0x60]
jne 0x4f1816
mov dword [esp + eax*2 + 0x28], edi
mov edi, dword [ebx + esi + 0x18]
mov dword [edx + 1], edx
xor al, 0x8b
lds ecx, [ebx + 0x4489f0e0]
and al, 0x20
je 0x4f18c8
mov eax, ebp
mov esp, eax
invalid
push eax
push dword [ebp + 5]
cmp byte [ebx + 0x60438df0], cl
push eax
lea eax, [ebx + 0x40]
shr esi, 4
push eax
call dword [esp + 0x2c]
push ebx
push dword [ebp + 5]
sub byte [esi - 1], dl
push edx
add dword [edi + edi*8 + 0x52], eax
add dword [edi + edi*8 + 0x54], edx
and al, 0x5c
mov eax, dword [esi + edi*4 + 0x34]
mov edi, dword [esp + 3]
invalid
test ebp, ebp
je 0x4f190e
push dword [ebp + 5]
adc al, 0x8d
inc ebx
adc byte [eax - 0x75], dl
xor dword [eax + 1], 0
push 0x53
call eax
mov eax, dword [esi + ebx*2 + 0x1c]
mov edi, dword [esp + ecx + 0x40]
bswap eax
mov dword [ebx + 0xc], eax
adc byte [esp + 0x28], al
sub esi, eax
lea edx, [edi + eax]
mov cl, byte [esi + edx]
lea eax, [ebx + edi]
xor byte [eax + 0x40], cl
lea edx, [edx + 1]
mov al, byte [ebx + edi + 0x10]
inc edi
xor al, cl
mov byte [edx - 1], al
sub ebp, 1
jne 0x4f18f3
mov dword [ebx + 0x168], edi
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
mov edi, dword [esp + edx - 0x3d]
pop ebp
or eax, 0xffffffff
pop ebx
cmp dword [esp + edx - 0x3d], 0xffffffcc
int3
dec ecx
cmp dword [ebp + 8], ecx
ja 0x54169b
or cl, byte [edi]
mov dh, 1
movzx eax, byte [ecx]
test byte [eax + edx + 0x19], 4
jne 0x54168b
mov eax, esi
sub eax, ecx
and eax, 1
sub esi, eax
dec esi
cmp byte [ebp - 4], 0
je 0x5416b5
mov ecx, dword [ebp - 0x10]
and dword [ecx + 0x6a000350], 0xfffffffd
mov eax, esi
dec dword [ebx - 0x173ca21b]
push ss
mov bl, 0xff
push dword [ebx]
leave
test al, al
sete cl
mov eax, ecx
ret