Function at 0x10007320
Capabilities:
Encode data using base64

Disassembly:
push ebp
push ebx
push edi
push esi
sub esp, 0x10
mov edi, dword [esp + 0x24]
mov eax, edx
mov dword [esp + 4], ecx
xor ecx, ecx
mov ebp, edx
mov ebx, 0
mov dword [esp + 0xc], edx
sub eax, 0x1a
cmovb eax, ecx
cmp edx, 0x1b
mov dword [esp + 8], eax
jb 0x10007612
xor ecx, ecx
mov eax, 0x20
nop dword [eax + eax]
mov ebx, eax
lea eax, [ecx + 0x1a]
cmp eax, ebp
ja 0x10007848
test ebx, ebx
je 0x10007853
cmp ebx, dword [esp + 0x28]
ja 0x10007861
mov eax, dword [esp + 4]
mov edx, dword [eax + ecx]
mov ebp, dword [eax + ecx + 4]
bswap edx
bswap ebp
mov esi, edx
shr esi, 0x1a
movzx eax, byte [esi + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x20], al
mov eax, edx
shr eax, 0x14
and eax, 0x3f
movzx eax, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x1f], al
mov eax, edx
shr eax, 0xe
and eax, 0x3f
movzx eax, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x1e], al
mov eax, edx
shr eax, 8
and eax, 0x3f
movzx eax, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x1d], al
mov eax, edx
shld edx, ebp, 4
shr eax, 2
and edx, 0x3f
and eax, 0x3f
movzx eax, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x1c], al
movzx eax, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x1b], al
mov eax, ebp
shr ebp, 0x10
shr eax, 0x16
and ebp, 0x3f
and eax, 0x3f
movzx eax, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x1a], al
movzx eax, byte [ebp + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov ebp, dword [esp + 4]
mov byte [edi + ebx - 0x19], al
mov esi, dword [ebp + ecx + 6]
mov eax, dword [ebp + ecx + 0xa]
bswap esi
bswap eax
mov edx, esi
shr edx, 0x1a
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x18], dl
mov edx, esi
shr edx, 0x14
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x17], dl
mov edx, esi
shr edx, 0xe
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x16], dl
mov edx, esi
shr edx, 8
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x15], dl
mov edx, esi
shld esi, eax, 4
shr edx, 2
and esi, 0x3f
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x14], dl
movzx edx, byte [esi + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x13], dl
mov edx, eax
shr eax, 0x10
shr edx, 0x16
and eax, 0x3f
and edx, 0x3f
movzx eax, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x12], dl
mov byte [edi + ebx - 0x11], al
mov esi, dword [ebp + ecx + 0xc]
mov eax, dword [ebp + ecx + 0x10]
bswap esi
bswap eax
mov edx, esi
shr edx, 0x1a
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0x10], dl
mov edx, esi
shr edx, 0x14
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0xf], dl
mov edx, esi
shr edx, 0xe
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0xe], dl
mov edx, esi
shr edx, 8
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0xd], dl
mov edx, esi
shld esi, eax, 4
shr edx, 2
and esi, 0x3f
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0xc], dl
movzx edx, byte [esi + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0xb], dl
mov edx, eax
shr eax, 0x10
shr edx, 0x16
and eax, 0x3f
and edx, 0x3f
movzx eax, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 0xa], dl
mov byte [edi + ebx - 9], al
mov esi, dword [ebp + ecx + 0x12]
mov eax, dword [ebp + ecx + 0x16]
add ecx, 0x18
mov ebp, dword [esp + 0xc]
bswap esi
bswap eax
mov edx, esi
shr edx, 0x1a
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 8], dl
mov edx, esi
shr edx, 0x14
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 7], dl
mov edx, esi
shr edx, 0xe
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 6], dl
mov edx, esi
shr edx, 8
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 5], dl
mov edx, esi
shld esi, eax, 4
shr edx, 2
and esi, 0x3f
and edx, 0x3f
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 4], dl
movzx edx, byte [esi + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 3], dl
mov edx, eax
shr eax, 0x10
shr edx, 0x16
and eax, 0x3f
and edx, 0x3f
movzx eax, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
cmp ecx, dword [esp + 8]
movzx edx, byte [edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx - 2], dl
mov byte [edi + ebx - 1], al
lea eax, [ebx + 0x20]
jbe 0x10007360
mov edx, 0xaaaaaaab
mov eax, ebp
mul edx
shr edx, 1
lea edx, [edx + edx*2]
cmp ecx, edx
mov eax, edx
mov dword [esp], edx
jae 0x100076d9
nop dword [eax]
cmp ecx, 0xfffffffc
ja 0x1000786e
mov eax, ecx
add ecx, 3
cmp ecx, ebp
ja 0x10007878
cmp ebx, 0xfffffffc
je 0x10007886
lea esi, [ebx + 4]
mov dword [esp + 8], ecx
cmp esi, dword [esp + 0x28]
ja 0x1000789f
mov ecx, eax
mov eax, dword [esp + 4]
movzx eax, byte [eax + ecx]
mov ebp, eax
shl eax, 4
shr ebp, 2
and eax, 0x30
movzx edx, byte [ebp + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx], dl
mov edx, dword [esp + 4]
movzx edx, byte [edx + ecx + 1]
mov ebp, edx
and edx, 0xf
shr ebp, 4
movzx eax, byte [eax + ebp + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebx + 1], al
mov eax, dword [esp + 4]
movzx eax, byte [eax + ecx + 2]
mov ecx, dword [esp + 8]
mov ebp, eax
and eax, 0x3f
shr ebp, 6
movzx eax, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
cmp ecx, dword [esp]
movzx edx, byte [ebp + edx*4 + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov ebp, dword [esp + 0xc]
mov byte [edi + ebx + 2], dl
mov byte [edi + ebx + 3], al
mov ebx, esi
jb 0x10007630
jmp 0x100076db
mov esi, ebx
mov ebx, ebp
sub ebx, dword [esp]
cmp ebx, 1
je 0x1000777b
mov ecx, dword [esp + 0x28]
cmp ebx, 2
jne 0x100077cc
cmp dword [esp], ebp
jae 0x100078cc
cmp esi, ecx
jae 0x100078db
mov eax, dword [esp + 4]
mov ebp, dword [esp]
movzx edx, byte [eax + ebp]
inc ebp
mov dword [esp], ebp
mov eax, edx
shr eax, 2
mov al, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + esi], al
mov eax, dword [esp + 0xc]
cmp ebp, eax
jae 0x100078e9
mov ebp, esi
or ebp, 1
cmp ebp, ecx
jae 0x100078f8
mov eax, dword [esp + 4]
mov ecx, dword [esp]
shl edx, 4
and edx, 0x30
movzx eax, byte [eax + ecx]
mov ecx, eax
shr ecx, 4
mov cl, byte [ecx + edx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ebp], cl
mov ecx, esi
or ecx, 2
cmp ecx, dword [esp + 0x28]
jae 0x10007908
and eax, 0xf
or esi, 3
mov al, byte [eax*4 + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
jmp 0x100077c5
cmp dword [esp], ebp
mov edx, dword [esp + 0x28]
jae 0x10007916
cmp esi, edx
jae 0x10007925
mov eax, dword [esp + 4]
mov ecx, dword [esp]
movzx eax, byte [eax + ecx]
mov ecx, eax
shr ecx, 2
mov cl, byte [ecx + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + esi], cl
mov ecx, esi
or ecx, 1
cmp ecx, edx
jae 0x10007931
shl eax, 4
or esi, 2
and eax, 0x30
mov al, byte [eax + str.ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789_9]
mov byte [edi + ecx], al
mov ecx, dword [esp + 0x28]
cmp esi, ecx
ja 0x100078b7
xor ebx, 3
mov ecx, 0xaaaaaaab
mov eax, ebx
mul ecx
shr edx, 1
lea eax, [edx + edx*2]
sub ebx, eax
je 0x10007818
mov eax, dword [esp + 0x28]
add edi, esi
mov ecx, ebx
sub eax, esi
mov edx, eax
nop dword [eax]
test eax, eax
je 0x10007837
mov byte [edi], 0x3d
inc edi
dec eax
dec ecx
jne 0x10007800
add esi, ebx
jb 0x1000781e
add esp, 0x10
pop esi
pop edi
pop ebx
pop ebp
ret
xor ebx, ebx
add esi, ebx
jae 0x10007810
mov ecx, str.usize_overflow_when_calculating_b64_length
mov edx, 0x2a
push 0x10365988
call fcn.1000a9c0
add esp, 4
ud2
mov ecx, edx
push 0x1036587c
call fcn.10008590
add esp, 4
ud2
mov ecx, eax
mov edx, ebp
push 0x1036588c
jmp 0x100078ad
mov ecx, 0xffffffe0
xor edx, edx
push 0x1036589c
jmp 0x10007895
mov edx, dword [esp + 0x28]
mov ecx, ebx
push 0x1036589c
jmp 0x100078ad
lea edx, [ecx + 3]
push 0x103658ac
jmp 0x10007895
mov ecx, eax
mov edx, ebp
add ecx, 3
push 0x103658ac
jmp 0x100078ad
add ebx, 4
mov ecx, 0xfffffffc
mov edx, ebx
push 0x103658bc
call fcn.10009f50
add esp, 4
ud2
mov edx, dword [esp + 0x28]
add ebx, 4
mov ecx, ebx
push 0x103658bc
call fcn.10008b80
add esp, 4
ud2
mov edx, dword [esp + 0x28]
mov ecx, esi
push 0x1036594c
call fcn.10009b70
add esp, 4
ud2
mov ecx, dword [esp]
mov edx, ebp
push 0x103658fc
jmp 0x1000783e
mov edx, ecx
mov ecx, esi
push 0x1036590c
jmp 0x1000783e
mov ecx, dword [esp]
mov edx, eax
push 0x1036591c
jmp 0x1000783e
mov edx, dword [esp + 0x28]
mov ecx, ebp
push 0x1036592c
jmp 0x1000783e
mov edx, dword [esp + 0x28]
push 0x1036593c
jmp 0x1000783e
mov ecx, dword [esp]
mov edx, ebp
push 0x103658cc
jmp 0x1000783e
mov ecx, esi
push 0x103658dc
jmp 0x1000783e
mov edx, dword [esp + 0x28]
push 0x103658ec
jmp 0x1000783e