Function at 0x1001ad70
Capabilities:
Encode data using base64

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10048f39
mov eax, dword fs:[0]
push eax
sub esp, 0x18
push ebx
push esi
push edi
mov eax, dword [0x100645d0]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x20], 0
mov esi, dword [ebp + 8]
mov ecx, esi
mov dword [ebp - 4], 0
call fcn.10012380
mov eax, dword [ebp + 0x10]
xor ebx, ebx
mov dword [ebp - 4], 0
mov dword [ebp - 0x20], 1
test eax, eax
je 0x1001b00b
mov ecx, dword [ebp + 0xc]
mov edi, edi
dec eax
mov dword [ebp + 0x10], eax
mov al, byte [ecx]
mov byte [ebp + ebx - 0x14], al
mov ah, byte [ebp - 0x12]
mov dl, byte [ebp - 0x13]
mov dh, byte [ebp - 0x14]
inc ebx
inc ecx
mov dword [ebp + 0xc], ecx
mov byte [ebp - 0xf], ah
mov byte [ebp - 0xd], dl
mov byte [ebp - 0xe], dh
cmp ebx, 3
jne 0x1001ae59
mov al, dh
shr al, 2
mov byte [ebp - 0x18], al
mov cl, dh
and cl, 3
shl cl, 4
mov al, dl
shr al, 4
add cl, al
mov byte [ebp - 0x17], cl
mov cl, dl
and cl, 0xf
mov al, ah
shr al, 6
shl cl, 2
add cl, al
mov al, ah
and al, 0x3f
mov byte [ebp - 0x16], cl
mov byte [ebp - 0x15], al
xor edi, edi
jmp 0x1001ae30
movzx ecx, byte [ebp + edi - 0x18]
mov eax, dword [str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
movzx eax, byte [ecx + eax]
push eax
push 1
mov ecx, esi
call fcn.1002da60
inc edi
cmp edi, 4
jb 0x1001ae30
mov ecx, dword [ebp + 0xc]
mov dl, byte [ebp - 0xd]
mov dh, byte [ebp - 0xe]
xor ebx, ebx
mov eax, dword [ebp + 0x10]
test eax, eax
jne 0x1001add0
mov dword [ebp - 0x1c], ebx
test ebx, ebx
je 0x1001b00b
mov eax, ebx
cmp ebx, 3
jae 0x1001ae96
cmp eax, 3
jae 0x1001ae91
mov byte [ebp + eax - 0x14], 0
inc eax
cmp eax, 3
jb 0x1001ae7b
mov cl, byte [ebp - 0x12]
mov dl, byte [ebp - 0x13]
mov dh, byte [ebp - 0x14]
jmp 0x1001ae99
call fcn.10042b10
mov cl, byte [ebp - 0xf]
mov al, dh
shr al, 2
mov byte [ebp - 0x18], al
mov al, dl
and dh, 3
shr al, 4
shl dh, 4
add dh, al
and dl, 0xf
mov al, cl
shl dl, 2
shr al, 6
add dl, al
mov byte [ebp - 0x17], dh
mov byte [ebp - 0x16], dl
and cl, 0x3f
xor edx, edx
lea eax, [ebx + 1]
mov byte [ebp - 0x15], cl
mov dword [ebp - 0x14], edx
test eax, eax
je 0x1001af82
jmp 0x1001aee0
movzx ecx, byte [ebp + edx - 0x18]
mov eax, dword [str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_]
mov al, byte [ecx + eax]
mov ecx, dword [esi + 0x14]
mov byte [ebp + 0x13], al
or eax, 0xffffffff
sub eax, ecx
cmp eax, 1
jbe 0x1001afca
lea edi, [ecx + 1]
cmp edi, 0xfffffffe
ja 0x1001afca
mov eax, dword [esi + 0x18]
cmp eax, edi
jae 0x1001af37
push ecx
push edi
mov ecx, esi
call fcn.10001c40
mov edx, dword [ebp - 0x14]
test edi, edi
je 0x1001af73
cmp dword [esi + 0x18], 0x10
mov eax, dword [esi + 0x14]
mov dword [ebp - 0x24], eax
lea eax, [esi + 4]
jb 0x1001af53
mov ecx, dword [eax]
jmp 0x1001af55
test edi, edi
jne 0x1001af24
mov dword [esi + 0x14], edi
cmp eax, 0x10
jb 0x1001af4b
mov eax, dword [esi + 4]
mov byte [eax], 0
jmp 0x1001af73
lea eax, [esi + 4]
mov byte [eax], 0
jmp 0x1001af73
mov ecx, eax
mov edx, dword [ebp - 0x24]
mov bl, byte [ebp + 0x13]
mov byte [ecx + edx], bl
cmp dword [esi + 0x18], 0x10
mov dword [esi + 0x14], edi
jb 0x1001af69
mov eax, dword [eax]
mov ebx, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x14]
mov byte [eax + edi], 0
inc edx
lea eax, [ebx + 1]
mov dword [ebp - 0x14], edx
cmp edx, eax
jb 0x1001aee0
cmp ebx, 3
jae 0x1001b00b
jmp 0x1001af90
mov ecx, dword [esi + 0x14]
or eax, 0xffffffff
sub eax, ecx
inc ebx
cmp eax, 1
jbe 0x1001afca
lea edi, [ecx + 1]
cmp edi, 0xfffffffe
ja 0x1001afca
mov eax, dword [esi + 0x18]
cmp eax, edi
jae 0x1001afd5
push ecx
push edi
mov ecx, esi
call fcn.10001c40
test edi, edi
je 0x1001b006
cmp dword [esi + 0x18], 0x10
mov edx, dword [esi + 0x14]
lea eax, [esi + 4]
jb 0x1001aff1
mov ecx, dword [eax]
jmp 0x1001aff3
push str.string_too_long
call dword [0x1004e300]
test edi, edi
jne 0x1001afba
mov dword [esi + 0x14], edi
cmp eax, 0x10
jb 0x1001afe9
mov eax, dword [esi + 4]
mov byte [eax], 0
jmp 0x1001b006
lea eax, [esi + 4]
mov byte [eax], 0
jmp 0x1001b006
mov ecx, eax
mov byte [ecx + edx], 0x3d
cmp dword [esi + 0x18], 0x10
mov dword [esi + 0x14], edi
jb 0x1001b002
mov eax, dword [eax]
mov byte [eax + edi], 0
cmp ebx, 3
jb 0x1001af90
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret