Function at 0x4a926a
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [ebp + 0xc]
push ebx
mov ebx, dword [ebp + 0x10]
push esi
mov esi, dword [sym.imp.MSVCR80.dll_iswspace]
mov dword [ebp - 0x10], eax
movzx eax, word [ebx]
push edi
mov edi, dword [ebp + 8]
push eax
mov dword [ebp - 0x14], ebx
call esi
test eax, eax
pop ecx
je 0x4a92a3
inc ebx
inc ebx
movzx eax, word [ebx]
push eax
call esi
test eax, eax
pop ecx
jne 0x4a9293
mov dword [ebp - 0x14], ebx
mov ebx, dword [ebp - 0x10]
movzx eax, word [ebx]
push eax
call esi
test eax, eax
pop ecx
je 0x4a92c1
inc ebx
inc ebx
movzx eax, word [ebx]
push eax
call esi
test eax, eax
pop ecx
jne 0x4a92b1
mov dword [ebp - 0x10], ebx
push ebx
mov ebx, dword [sym.imp.MSVCR80.dll_wcslen]
call ebx
push dword [ebp - 0x14]
mov dword [ebp - 0xc], eax
call ebx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 0xc]
test eax, eax
pop ecx
pop ecx
jbe 0x4a9303
mov ecx, dword [ebp - 0x10]
lea eax, [ecx + eax*2 - 2]
mov dword [ebp - 8], eax
mov eax, dword [ebp - 8]
movzx eax, word [eax]
push eax
call esi
test eax, eax
pop ecx
je 0x4a9303
dec dword [ebp - 0xc]
sub dword [ebp - 8], 2
cmp dword [ebp - 0xc], 0
ja 0x4a92e8
mov eax, dword [ebp - 4]
test eax, eax
jbe 0x4a932f
mov ecx, dword [ebp - 0x14]
lea eax, [ecx + eax*2 - 2]
mov dword [ebp - 8], eax
mov eax, dword [ebp - 8]
movzx eax, word [eax]
push eax
call esi
test eax, eax
pop ecx
je 0x4a932f
dec dword [ebp - 4]
sub dword [ebp - 8], 2
cmp dword [ebp - 4], 0
ja 0x4a9314
push dword [edi + 0x38]
call ebx
mov ecx, dword [edi + 0x18]
mov ebx, eax
mov eax, dword [ebp - 4]
add eax, ebx
add eax, dword [ebp - 0xc]
lea eax, [ecx + eax*2 + 9]
and eax, 0xfffffffc
add eax, 0xa8
push eax
mov dword [ebp - 8], eax
call dword [sym.imp.MSVCR80.dll_malloc]
mov esi, eax
test esi, esi
pop ecx
pop ecx
je 0x4a94fe
push 0x30
push edi
push esi
call sub.MSVCR80.dll_memcpy
mov eax, dword [ebp - 8]
mov dword [esi], eax
lea eax, [esi + 0xa8]
sub eax, esi
mov word [esi + 0x38], ax
add ebx, ebx
lea eax, [ebx + 2]
push eax
push dword [edi + 0x38]
lea eax, [esi + 0xa8]
push eax
call sub.MSVCR80.dll_memcpy
lea ebx, [esi + ebx + 0xaa]
mov eax, ebx
sub eax, esi
mov word [esi + 0x3a], ax
mov eax, dword [ebp - 0xc]
add eax, eax
push eax
push dword [ebp - 0x10]
push ebx
call sub.MSVCR80.dll_memcpy
mov eax, dword [ebp - 0xc]
mov ecx, dword [ebp - 0xc]
and ecx, 0x3f
mov cx, word [ecx*2 + 0x60fa08]
add eax, eax
add eax, ebx
mov word [eax], cx
xor ecx, ecx
add esp, 0x24
cmp dword [ebp - 0xc], ecx
mov dword [ebp - 8], ecx
jbe 0x4a93f2
lea edx, [ebx + ecx*2]
and ecx, 0x3f
mov cx, word [ecx*2 + 0x60fa08]
xor word [edx], cx
mov ecx, dword [ebp - 8]
inc ecx
cmp ecx, dword [ebp - 0xc]
mov dword [ebp - 8], ecx
jb 0x4a93d5
lea ebx, [eax + 2]
mov eax, ebx
sub eax, esi
mov word [esi + 0x3c], ax
mov eax, dword [ebp - 4]
add eax, eax
push eax
push dword [ebp - 0x14]
push ebx
call sub.MSVCR80.dll_memcpy
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 4]
add eax, eax
and ecx, 0x3f
mov cx, word [ecx*2 + 0x60fa08]
xor edx, edx
add eax, ebx
add esp, 0xc
cmp dword [ebp - 4], edx
mov word [eax], cx
mov dword [ebp - 8], edx
jbe 0x4a944e
lea ecx, [ebx + edx*2]
and edx, 0x3f
mov dx, word [edx*2 + 0x60fa08]
xor word [ecx], dx
mov edx, dword [ebp - 8]
inc edx
cmp edx, dword [ebp - 4]
mov dword [ebp - 8], edx
jb 0x4a9431
add eax, 2
mov ecx, eax
sub ecx, esi
mov word [esi + 0x3e], cx
push dword [edi + 0x18]
push dword [edi + 0x30]
push eax
call sub.MSVCR80.dll_memcpy
add esp, 0xc
cmp dword [edi + 4], 4
jge 0x4a949f
push 0x1c
lea eax, [ebp - 0x30]
push eax
push dword [edi + 0x3c]
call dword [sym.imp.KERNEL32.dll_VirtualQuery]
test eax, eax
je 0x4a949f
push dword [ebp - 0x2c]
lea eax, [esi + 0x40]
push str.0x_X
push 0x14
push eax
call dword [sym.imp.MSVCR80.dll__snwprintf]
add esp, 0x10
and word [esi + 0x66], 0
jmp 0x4a94a4
and word [esi + 0x40], 0
mov ebx, dword [sym.imp.MSVCR80.dll_wcsrchr]
push 0x5c
push dword [edi + 0x34]
call ebx
push 0x2f
push dword [edi + 0x34]
mov dword [ebp - 4], eax
call ebx
add esp, 0x10
cmp dword [ebp - 4], eax
ja 0x4a94c6
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
jne 0x4a94d4
mov eax, dword [edi + 0x34]
mov dword [ebp - 4], eax
jmp 0x4a94d8
add dword [ebp - 4], 2
push 0x20
push dword [ebp - 4]
lea eax, [esi + 0x68]
push eax
call dword [sym.imp.MSVCR80.dll_wcsncpy]
and word [esi + 0xa6], 0
mov ecx, dword [0x611488]
add esp, 0xc
push esi
call fcn.004a91b7
pop edi
pop esi
pop ebx
leave
ret