Function at 0x10041f90
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0x10
push ebx
mov ebx, dword [esp + 0x1c]
test ebx, ebx
je 0x1004225d
cmp byte [ebx], 0
je 0x1004225d
mov ecx, ebx
lea edx, [ecx + 1]
mov edi, edi
mov al, byte [ecx]
inc ecx
test al, al
jne 0x10041fb0
sub ecx, edx
cmp ecx, 0xf
jle 0x10041fd4
mov eax, dword [esp + 0x18]
pop ebx
mov dword [eax], 0x7dc
mov eax, 0xfffffffc
add esp, 0x10
ret 0x10
push edi
push 0x100
call fcn.100342e0
mov edi, eax
test edi, edi
je 0x10042246
push ebp
push 0x100
call fcn.100342e0
mov ebp, eax
test ebp, ebp
jne 0x10042016
mov eax, dword [esp + 0x20]
push edi
mov dword [eax], 0x7dd
call fcn.10034320
lea eax, [ebp - 0xd]
pop ebp
pop edi
pop ebx
add esp, 0x10
ret 0x10
push esi
push 0x100
push 0
push edi
call fcn.10045310
push 0x100
push 0
push ebp
call fcn.10045310
mov esi, ebx
add esp, 0x18
mov edx, 0x100
mov ecx, edi
sub esi, edi
nop
lea eax, [edx + 0x7ffffefe]
test eax, eax
je 0x10042059
mov al, byte [esi + ecx]
test al, al
je 0x10042059
mov byte [ecx], al
inc ecx
dec edx
jne 0x10042040
jmp 0x1004205d
test edx, edx
jne 0x1004205e
dec ecx
mov byte [ecx], 0
mov ecx, edi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x10042066
sub ecx, edx
mov dword [esp + 0x18], ecx
cmp ecx, 1
jne 0x1004208c
movsx eax, byte [ebx]
push 0x100
push eax
push edi
call fcn.10045310
add esp, 0xc
jmp 0x100420a3
mov esi, 0x100
mov edx, edi
sub esi, ecx
je 0x100420a3
mov al, byte [edx]
lea edx, [edx + 1]
mov byte [edx + ecx - 1], al
dec esi
jne 0x10042097
mov al, byte [edi + 1]
lea esi, [edi + 1]
movsx ecx, byte [edi]
movsx eax, al
mov dword [esp + 0x1c], esi
mov esi, 0xff
add eax, esi
mov dword [esp + 0x14], ecx
mov dword [esp + 0x10], eax
movsx eax, byte [edi + 2]
mov ebx, dword [esp + 0x10]
add eax, esi
mov dword [esp + 0x24], eax
movsx eax, byte [edi + 3]
add eax, esi
mov dword [esp + 0x28], eax
lea ebx, [ebx]
movzx eax, al
movzx edx, byte [eax + 0x100579f0]
mov eax, dword [esp + 0x24]
add ecx, edx
dec dword [esp + 0x24]
and ecx, 0xff
movzx eax, al
mov cl, byte [ecx + 0x100578f0]
xor cl, byte [eax + 0x10057af0]
movzx eax, bl
dec ebx
xor cl, byte [eax + 0x100579f0]
xor cl, byte [edx + edi]
mov eax, dword [esp + 0x28]
mov byte [esi + ebp], cl
dec eax
dec esi
mov ecx, dword [esp + 0x14]
mov dword [esp + 0x28], eax
jns 0x100420e0
movsx ax, byte [ebp]
mov edx, 0xff
movsx cx, byte [ebp + 1]
mov ebx, dword [esp + 0x18]
push ebx
and ax, dx
shl cx, 8
or cx, ax
mov eax, dword [esp + 0x34]
push edi
push ebp
mov word [eax], cx
call fcn.10044b60
add esp, 0xc
cmp ebx, 0x100
jge 0x1004217c
mov ecx, ebp
sub ecx, ebx
movzx eax, byte [ecx + ebx]
mov al, byte [eax + 0x100578f0]
xor al, bl
mov byte [ebx + ebp], al
inc ebx
cmp ebx, 0x100
jl 0x10042164
movsx eax, byte [ebp + 0x14]
mov esi, 0xff
movsx ecx, byte [ebp]
add eax, esi
mov dword [esp + 0x30], eax
movsx eax, byte [ebp + 0x28]
mov ebx, dword [esp + 0x30]
add eax, esi
mov dword [esp + 0x24], eax
movsx eax, byte [ebp + 0xff]
add eax, esi
mov dword [esp + 0x18], ecx
mov dword [esp + 0x28], eax
mov edi, edi
movzx eax, al
movzx edx, byte [eax + 0x100579f0]
mov eax, dword [esp + 0x24]
add ecx, edx
dec dword [esp + 0x24]
and ecx, 0xff
movzx eax, al
mov cl, byte [ecx + 0x100578f0]
xor cl, byte [eax + 0x10057af0]
movzx eax, bl
dec ebx
xor cl, byte [eax + 0x100579f0]
xor cl, byte [edx + ebp]
mov eax, dword [esp + 0x28]
mov byte [esi + edi], cl
dec eax
dec esi
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x28], eax
jns 0x100421b0
mov esi, dword [esp + 0x1c]
xor al, al
xor cl, cl
mov edx, 0x80
xor cl, byte [esi - 1]
lea esi, [esi + 2]
xor al, byte [esi - 2]
dec edx
jne 0x10042206
movsx cx, cl
mov edx, 0xff
cbw
push ebp
shl ax, 8
and cx, dx
or cx, ax
mov eax, dword [esp + 0x30]
mov word [eax], cx
call fcn.10034320
push edi
call fcn.10034320
pop esi
pop ebp
pop edi
xor eax, eax
pop ebx
add esp, 0x10
ret 0x10
mov eax, dword [esp + 0x1c]
pop edi
pop ebx
mov dword [eax], 0x7de
mov eax, 0xfffffff3
add esp, 0x10
ret 0x10
mov eax, dword [esp + 0x18]
pop ebx
mov dword [eax], 0x7db
mov eax, 0xfffffff4
add esp, 0x10
ret 0x10