Function at 0x402ce0
Capabilities:
Encode data using base64

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x6c
mov eax, dword [0x4c6018]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 8]
mov dword [ebp - 0x60], eax
push edi
mov edi, ecx
mov ebx, edx
mov eax, 0xaaaaaaab
mul edi
shr edx, 1
lea ecx, [edx + edx*2]
mov eax, edi
sub eax, ecx
mov dword [ebp - 0x6c], ebx
mov dword [ebp - 0x58], eax
jne 0x402d21
add edx, edx
add edx, edx
mov dword [ebp - 0x50], edx
jmp 0x402d2b
lea edx, [edx*4 + 4]
mov dword [ebp - 0x50], edx
test dl, 0x3f
jne 0x402d3b
mov eax, edx
shr eax, 6
lea eax, [eax + edx + 3]
jmp 0x402d47
mov ecx, edx
shr ecx, 6
lea eax, [ecx + edx + 4]
mov dword [ebp - 0x68], eax
add eax, 0x44
cmp dword [ebp - 0x60], 0
mov dword [ebp - 0x68], eax
je 0x403032
mov ecx, dword [ebx]
test ecx, ecx
je 0x403032
cmp ecx, eax
jae 0x402d7b
pop edi
pop esi
or eax, 0xffffffff
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00449013
mov esp, ebp
pop ebp
ret 8
push edx
call dword [sym.imp.MSVCR100.dll_void____cdecl_operator_new___unsigned_int_]
mov ecx, dword [ebp - 0x50]
push ecx
mov ebx, eax
push 0
push ebx
call sub.MSVCR100.dll_memset
sub edi, dword [ebp - 0x58]
add esp, 0x10
xor ecx, ecx
xor eax, eax
mov dword [ebp - 0x5c], edi
test edi, edi
jle 0x402e2f
jmp 0x402db0
movzx edx, byte [esi + ecx]
mov byte [ebp - 0x51], dl
movzx edx, byte [esi + ecx + 1]
mov byte [ebp - 0x52], dl
movzx edx, byte [esi + ecx + 2]
movzx esi, byte [ebp - 0x51]
movzx edi, byte [ebp - 0x52]
mov byte [ebp - 0x4b], dl
mov edx, esi
shr edx, 2
movzx edx, byte [edx + 0x4b9818]
mov byte [ebx + eax], dl
mov edx, edi
shr edx, 4
shl esi, 4
or edx, esi
movzx esi, byte [ebp - 0x4b]
and edx, 0x3f
movzx edx, byte [edx + 0x4b9818]
mov byte [ebx + eax + 1], dl
mov edx, esi
shr edx, 6
add edi, edi
add edi, edi
or edx, edi
and edx, 0x3f
movzx edx, byte [edx + 0x4b9818]
and esi, 0x3f
mov byte [ebx + eax + 2], dl
movzx edx, byte [esi + 0x4b9818]
mov esi, dword [ebp + 8]
mov byte [ebx + eax + 3], dl
add ecx, 3
add eax, 4
cmp ecx, dword [ebp - 0x5c]
jl 0x402db0
mov edx, dword [ebp - 0x58]
dec edx
je 0x402e82
dec edx
jne 0x402eb0
mov dl, byte [ecx + esi]
mov cl, byte [ecx + esi + 1]
movzx esi, dl
movzx edi, cl
mov edx, esi
shr edx, 2
movzx edx, byte [edx + 0x4b9818]
mov ecx, edi
shr ecx, 4
shl esi, 4
or ecx, esi
and ecx, 0x3f
mov byte [eax + ebx], dl
movzx edx, byte [ecx + 0x4b9818]
and edi, 0xf
mov byte [eax + ebx + 1], dl
movzx ecx, byte [edi*4 + 0x4b9818]
mov byte [eax + ebx + 2], cl
mov byte [eax + ebx + 3], 0x3d
jmp 0x402eb0
movzx esi, byte [ecx + esi]
mov edx, esi
shr edx, 2
mov cl, byte [edx + 0x4b9818]
and esi, 3
shl esi, 4
mov byte [eax + ebx], cl
mov dl, byte [esi + 0x4b9818]
mov byte [eax + ebx + 1], dl
mov word [eax + ebx + 2], 0x3d3d
jmp 0x402eb0
mov edi, dword [ebp - 0x60]
mov ecx, 9
mov esi, str._____BEGIN_CERTIFICATE_REQUEST_____
lea eax, [ebp - 0x4c]
mov word [ebp - 0x4c], 0xa
rep movsd dword es:[edi], dword [esi]
mov byte [ebp - 0x4b], 0
mov esi, eax
mov edi, edi
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402ed0
mov edi, dword [ebp - 0x60]
sub eax, esi
dec edi
lea ecx, [ecx]
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x402ee0
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, dword [ebp - 0x50]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
xor esi, esi
mov dword [ebp - 0x64], 0x40
mov dword [ebp - 0x5c], esi
mov dword [ebp - 0x58], eax
jmp 0x402f13
mov esi, dword [ebp - 0x5c]
push 0x41
lea ecx, [ebp - 0x48]
push 0
push ecx
call sub.MSVCR100.dll_memset
mov edx, dword [ebp - 0x64]
lea eax, [esi + edx]
add esp, 0xc
cmp eax, dword [ebp - 0x50]
jbe 0x402f34
mov ecx, dword [ebp - 0x58]
mov dword [ebp - 0x64], ecx
mov edx, dword [ebp - 0x64]
push edx
add esi, ebx
lea eax, [ebp - 0x48]
push esi
push eax
call sub.MSVCR100.dll_memcpy
lea eax, [ebp - 0x48]
add esp, 0xc
mov esi, eax
lea esp, [esp]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402f50
mov edx, dword [ebp - 0x60]
sub eax, esi
lea edi, [edx - 1]
nop
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x402f60
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
lea eax, [ebp - 0x4c]
rep movsb byte es:[edi], byte [esi]
mov esi, eax
jmp 0x402f80
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402f80
sub eax, esi
lea edi, [edx - 1]
lea esp, [esp]
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x402f90
sub dword [ebp - 0x58], 0x40
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, dword [ebp - 0x5c]
add eax, 0x40
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov dword [ebp - 0x5c], eax
cmp eax, dword [ebp - 0x50]
jbe 0x402f10
lea edi, [edx - 1]
nop
mov al, byte [edi + 1]
inc edi
test al, al
jne 0x402fc0
mov ecx, 8
mov esi, str._____END_CERTIFICATE_REQUEST_____
rep movsd dword es:[edi], dword [esi]
lea eax, [ebp - 0x4c]
movsw word es:[edi], word [esi]
mov esi, eax
jmp 0x402fe0
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x402fe0
sub eax, esi
lea edi, [edx - 1]
lea esp, [esp]
mov cl, byte [edi + 1]
inc edi
test cl, cl
jne 0x402ff0
mov edx, dword [ebp - 0x6c]
mov ecx, eax
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [ebp - 0x68]
mov dword [edx], ecx
test ebx, ebx
je 0x40301c
push ebx
call dword [sym.imp.MSVCR100.dll_void___cdecl_operator_delete___void__]
add esp, 4
mov eax, dword [ebp - 0x50]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00449013
mov esp, ebp
pop ebp
ret 8
mov ecx, dword [ebp - 4]
pop edi
pop esi
mov dword [ebx], eax
xor ecx, ebp
pop ebx
call fcn.00449013
mov esp, ebp
pop ebp
ret 8