Function at 0x47878d
Capabilities:
Encode data using xor

Disassembly:
push 0xc4
mov eax, 0x4b1bdf
call fcn.004afd5b
lea eax, [ebp - 0xac]
push eax
call fcn.004786b2
xor ebx, ebx
mov dword [ebp - 4], ebx
cmp dword [ebp - 0x94], 8
mov eax, dword [ebp - 0xa8]
jae 0x4787c2
lea eax, [ebp - 0xa8]
push eax
lea ecx, [ebp - 0x90]
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::constructor_wchar_t_const__]
push 7
pop ecx
mov byte [ebp - 4], 1
push str.NtQuerySystemInformation
xor eax, eax
mov dword [ebp - 0xd0], ebx
lea edi, [ebp - 0xcc]
push str.ntdll
rep stosd dword es:[edi], eax
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, ebx
je 0x47880f
push ebx
push 0x20
lea ecx, [ebp - 0xd0]
push ecx
push 3
call eax
push ebx
lea ecx, [ebp - 0x90]
call dword [sym.imp.MSVCP80.dll_public:_wchar_t____thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::operator___unsigned_int_]
push ebx
lea ecx, [ebp - 0x90]
mov esi, eax
call dword [sym.imp.MSVCP80.dll_public:_wchar_t____thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::operator___unsigned_int_]
cmp eax, ebx
je 0x47884d
jmp 0x478848
movzx ecx, word [eax]
cmp cx, 0x41
jb 0x478846
cmp cx, 0x5a
ja 0x478846
add ecx, 0x20
mov word [eax], cx
inc eax
inc eax
cmp word [eax], bx
jne 0x478831
mov ecx, dword [ebp - 0x7c]
xor eax, eax
cmp ecx, ebx
mov dword [ebp - 0x24], ecx
jbe 0x47886f
mov edx, eax
and edx, 3
mov dx, word [ebp + edx*2 - 0xd0]
xor word [esi + eax*2], dx
inc eax
cmp eax, ecx
jb 0x478859
xor eax, eax
mov word [ebp - 0x20], bx
lea edi, [ebp - 0x1e]
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosd dword es:[edi], eax
stosw word es:[edi], ax
lea edi, [ecx + ecx]
cmp edi, 0x10
mov dword [ebp - 0xb0], edi
jae 0x47889b
push edi
lea eax, [ebp - 0x20]
push esi
push eax
call sub.MSVCR80.dll_memcpy
add esp, 0xc
jmp 0x4788d9
shr edi, 3
cmp ebx, 7
jne 0x4788be
mov ecx, dword [ebp - 0xb0]
mov eax, edi
imul eax, eax, 7
sub ecx, eax
push ecx
add eax, esi
call fcn.00478733
mov word [ebp - 0x12], ax
jmp 0x4788d0
mov eax, ebx
imul eax, edi
push edi
add eax, esi
call fcn.00478733
mov word [ebp + ebx*2 - 0x20], ax
inc ebx
cmp ebx, 8
pop ecx
jb 0x47889e
xor ebx, ebx
push 0x48
lea eax, [ebp - 0x72]
push ebx
push eax
mov word [ebp - 0x74], bx
call sub.MSVCR80.dll_memset
lea eax, [ebp - 0x74]
add esp, 0xc
test eax, eax
je 0x47893c
movzx eax, byte [ebp - 0x11]
push eax
movzx eax, byte [ebp - 0x12]
push eax
movzx eax, byte [ebp - 0x13]
push eax
movzx eax, byte [ebp - 0x14]
push eax
movzx eax, byte [ebp - 0x15]
push eax
movzx eax, byte [ebp - 0x16]
push eax
movzx eax, byte [ebp - 0x17]
push eax
movzx eax, byte [ebp - 0x18]
push eax
movzx eax, word [ebp - 0x1a]
push eax
movzx eax, word [ebp - 0x1c]
push eax
push dword [ebp - 0x20]
lea eax, [ebp - 0x74]
push str._08x__04x__04x__02x_02x__02x_02x_02x_02x_02x_02x
push 0x25
push eax
call dword [sym.imp.MSVCR80.dll__snwprintf]
add esp, 0x38
lea eax, [ebp - 0x74]
mov ebx, 0x4fa144
push eax
mov ecx, ebx
call dword [0x4be314]
cmp dword [ebp - 0x24], 3
jb 0x478993
xor eax, eax
lea edi, [ebp - 0x26]
stosd dword es:[edi], eax
stosw word es:[edi], ax
movzx eax, word [esi]
cdq
push 0x1a
pop ecx
idiv ecx
movzx eax, word [esi + 2]
add edx, 0x61
mov word [ebp - 0x28], dx
cdq
idiv ecx
movzx eax, word [esi + 4]
add edx, 0x61
mov word [ebp - 0x26], dx
cdq
idiv ecx
lea eax, [ebp - 0x28]
push eax
mov ecx, ebx
add edx, 0x61
mov word [ebp - 0x24], dx
call dword [sym.imp.MSVCP80.dll_public:_class_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t______thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::operator_wchar_t_const__]
lea ecx, [ebp - 0x90]
mov byte [ebp - 4], 0
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0xac]
call dword [sym.imp.MSVCP80.dll_public:_void___thiscall_std::basic_string_wchar_t__struct_std::char_traits_wchar_t___class_std::allocator_wchar_t__::destructor_void_]
xor eax, eax
inc eax
call fcn.004afdde
ret