Function at 0x64d1a0
Capabilities:
Encode data using base64

Disassembly:
push ebp
push edi
push esi
push ebx
sub esp, 0x24
mov eax, dword [esp + 0x38]
mov esi, dword [esp + 0x44]
add eax, 8
mov dword [esp + 0x10], 0
mov edx, dword [eax - 8]
mov dword [esp + 0x18], eax
test edx, edx
jle 0x64d1d0
cmp byte [eax + edx - 1], 0x3d
je 0x64d2a0
xor eax, eax
cmp dword [esp + 0x48], 0
je 0x64d283
jle 0x64d52b
mov al, byte [esi]
test al, al
js 0x64d500
xor ecx, ecx
xor ebx, ebx
mov cl, al
mov cl, byte [ecx + 0x783d80]
mov bl, cl
cmp ebx, 0xff
je 0x64d5d2
mov edi, dword [esp + 0x48]
lea ebp, [esi + 1]
add esi, edi
mov dword [esp + 0x48], 0
mov dword [esp + 0x1c], esi
lea esi, [esi]
cmp al, 0x3d
je 0x64d2c0
mov esi, dword [esp + 0x10]
test esi, esi
je 0x64d2d2
or ecx, 0x13
cmp cl, 0xf3
jne 0x64d280
cmp ebx, 0xf2
je 0x64d558
cmp edx, 0x40
je 0x64d300
cmp ebp, dword [esp + 0x1c]
je 0x64d533
inc ebp
mov al, byte [ebp - 1]
test al, al
js 0x64d280
xor ecx, ecx
xor ebx, ebx
mov cl, al
mov cl, byte [ecx + 0x783d80]
mov bl, cl
cmp ebx, 0xff
jne 0x64d220
lea esi, [esi]
or eax, 0xffffffff
mov ecx, dword [esp + 0x40]
mov edi, dword [esp + 0x48]
mov dword [ecx], edi
mov edi, dword [esp + 0x38]
mov dword [edi], edx
add esp, 0x24
pop ebx
pop esi
pop edi
pop ebp
ret
cmp edx, 1
je 0x64d510
cmp byte [eax + edx - 2], 0x3d
sete al
and eax, 0xff
inc eax
mov dword [esp + 0x10], eax
jmp 0x64d1d0
mov edi, dword [esp + 0x10]
inc edi
mov dword [esp + 0x10], edi
mov edi, dword [esp + 0x10]
cmp edi, 3
je 0x64d280
cmp ebx, 0xf2
je 0x64d5df
or ecx, 0x13
cmp cl, 0xf3
je 0x64d248
cmp edx, 0x3f
jg 0x64d280
mov esi, dword [esp + 0x18]
mov byte [esi + edx], al
inc edx
cmp edx, 0x40
jne 0x64d251
mov eax, dword [esp + 0x38]
mov al, byte [eax + 8]
mov byte [esp + 0xf], al
xor eax, eax
mov al, byte [esp + 0xf]
cmp byte [esp + 0xf], 0
js 0x64d5b5
cmp byte [eax + 0x783d80], 0xe0
jne 0x64d5b5
mov eax, dword [esp + 0x18]
jmp 0x64d343
cmp byte [ecx + 0x783d80], 0xe0
jne 0x64d352
mov eax, esi
test edx, edx
je 0x64d4d0
xor ecx, ecx
dec edx
lea esi, [eax + 1]
mov cl, byte [eax + 1]
cmp byte [eax + 1], 0
jns 0x64d330
mov ecx, edx
cmp edx, 3
jle 0x64d4c1
mov al, byte [eax + edx]
test al, al
js 0x64d386
and eax, 0xff
mov al, byte [eax + 0x783d80]
or eax, 0x13
cmp al, 0xf3
jne 0x64d386
dec edx
mov ecx, edx
cmp edx, 3
je 0x64d386
mov al, byte [esi + edx - 1]
test al, al
jns 0x64d364
and ecx, 3
jne 0x64d4b7
dec edx
mov edi, dword [esp + 0x3c]
shr edx, 2
mov dword [esp + 0x20], ebp
lea eax, [edx + edx*2 + 3]
mov edx, dword [esp + 0x3c]
add eax, edx
mov dword [esp + 0x14], eax
jmp 0x64d46f
and eax, 0xff
mov al, byte [eax + 0x783d80]
mov byte [esp + 0xf], al
mov ebp, eax
mov al, byte [esi + 1]
test al, al
js 0x64d48e
and eax, 0xff
mov dl, byte [esi + 2]
test dl, dl
mov al, byte [eax + 0x783d80]
js 0x64d49b
add esi, 4
and edx, 0xff
mov cl, byte [esi - 1]
mov dl, byte [edx + 0x783d80]
test cl, cl
js 0x64d4ab
and ecx, 0xff
mov ebx, ebp
test bl, bl
mov cl, byte [ecx + 0x783d80]
js 0x64d4b7
test al, al
js 0x64d4b7
test dl, dl
js 0x64d4b7
test cl, cl
js 0x64d4b7
xor ebx, ebx
and eax, 0xff
mov bl, byte [esp + 0xf]
add edi, 3
shl eax, 0xc
shl ebx, 0x12
or ebx, eax
xor eax, eax
mov al, dl
shl eax, 6
or ebx, eax
xor eax, eax
mov al, cl
or eax, ebx
mov edx, eax
mov byte [edi - 2], ah
shr edx, 0x10
mov byte [edi - 3], dl
mov edx, edi
mov byte [edi - 1], al
mov eax, dword [esp + 0x3c]
sub edx, eax
cmp edi, dword [esp + 0x14]
je 0x64d520
mov al, byte [esi]
test al, al
jns 0x64d3b0
mov al, byte [esi + 1]
mov ebp, 0xffffffff
mov byte [esp + 0xf], 0xff
test al, al
jns 0x64d3cc
mov dl, byte [esi + 2]
mov al, 0xff
test dl, dl
jns 0x64d3e2
add esi, 4
mov cl, byte [esi - 1]
mov dl, 0xff
test cl, cl
jns 0x64d3fc
mov ebx, ebp
mov cl, 0xff
test bl, bl
jns 0x64d412
xor edx, edx
or eax, 0xffffffff
jmp 0x64d283
test dl, 3
jne 0x64d4b7
test edx, edx
jne 0x64d38f
nop
xor eax, eax
mov esi, dword [esp + 0x10]
cmp edx, esi
jl 0x64d4b7
test al, al
jne 0x64d4b7
sub edx, esi
mov edi, dword [esp + 0x48]
mov eax, dword [esp + 0x3c]
add edi, edx
add eax, edx
mov dword [esp + 0x48], edi
mov dword [esp + 0x3c], eax
xor edx, edx
jmp 0x64d251
mov dword [esp + 0x48], 0
or eax, 0xffffffff
jmp 0x64d283
mov dword [esp + 0x10], 1
jmp 0x64d1d0
mov eax, edx
mov ebp, dword [esp + 0x20]
shr eax, 0x1f
jmp 0x64d4d2
mov dword [esp + 0x48], 0
test edx, edx
jle 0x64d53e
mov ebx, edx
and ebx, 3
je 0x64d570
mov ecx, dword [esp + 0x10]
test edx, edx
setne al
test ecx, ecx
sete cl
or eax, ecx
and eax, 0xff
jmp 0x64d283
xor eax, eax
test edx, edx
jle 0x64d283
test dl, 3
jne 0x64d280
mov ebx, 1
mov eax, dword [esp + 0x18]
mov dword [esp + 8], edx
mov dword [esp + 4], eax
mov eax, dword [esp + 0x3c]
mov dword [esp], eax
call fcn.0064cff0
test eax, eax
js 0x64d4b7
mov edi, dword [esp + 0x10]
cmp eax, edi
jl 0x64d4b7
sub eax, edi
mov esi, dword [esp + 0x48]
add esi, eax
xor edx, edx
mov dword [esp + 0x48], esi
test ebx, ebx
je 0x64d53e
xor eax, eax
jmp 0x64d283
mov eax, dword [esp + 0x38]
mov esi, dword [esp + 0x18]
mov al, byte [eax + 0x47]
test al, al
js 0x64d38f
mov ecx, 0x40
jmp 0x64d364
mov dword [esp + 0x48], 0
jmp 0x64d280
test edx, edx
jg 0x64d562
xor eax, eax
jmp 0x64d283