Function at 0x4d1d40
Capabilities:
Decode data using base64 via dword translation table
Encode data using base64

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
push ebx
push esi
push edi
mov edi, ecx
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x18], edi
test edi, edi
je 0x4d1dda
mov ebx, dword [ebp + 8]
mov esi, dword [ebp + 0xc]
test ebx, ebx
jne 0x4d1d67
test esi, esi
jne 0x4d1dda
mov eax, dword [ebp + 0x10]
test eax, eax
je 0x4d1dda
mov dword [eax], 0
cmp edx, 0xffffffff
jne 0x4d1d92
mov edx, edi
lea ecx, [edx + 2]
mov edi, edi
mov ax, word [edx]
add edx, 2
test ax, ax
jne 0x4d1d80
sub edx, ecx
sar edx, 1
mov dword [ebp - 0x20], edx
lea ebx, [edi + edx*2]
cmp ebx, edi
jb 0x4d1dda
lea eax, [edx + 3]
shr eax, 2
lea edi, [eax + eax*2]
cmp esi, edi
jae 0x4d1de3
mov ecx, edx
test edx, edx
je 0x4d1dbc
lea eax, [ebx - 2]
nop
cmp word [eax], 0x3d
jne 0x4d1dbc
sub eax, 2
dec ecx
jne 0x4d1db0
mov eax, ecx
and eax, 3
jbe 0x4d1dd1
shr ecx, 2
lea edi, [ecx*2 - 1]
add edi, eax
add edi, ecx
cmp esi, edi
jae 0x4d1de3
mov eax, dword [ebp + 0x10]
mov dword [eax], edi
pop edi
pop esi
xor al, al
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp + 8]
test ecx, ecx
je 0x4d21e6
lea eax, [ecx + esi]
cmp eax, ecx
jbe 0x4d21e6
xor ecx, ecx
mov dword [ebp - 0x14], 0
mov dword [ebp - 8], 0
mov dword [ebp - 4], ecx
test edx, edx
je 0x4d1e2a
mov esi, dword [ebp - 0x18]
mov edi, 0xff
mov ax, word [esi + ecx*2]
inc ecx
cmp ax, di
ja 0x4d1ec2
cmp ecx, edx
jb 0x4d1e18
xor ecx, ecx
mov dword [ebp - 0xc], ecx
test edx, edx
je 0x4d21b9
jmp 0x4d1e40
xor ebx, ebx
mov dword [ebp - 0x10], 0
xor edi, edi
mov dword [ebp - 0x1c], ebx
xor esi, esi
cmp ecx, edx
jae 0x4d2028
mov eax, dword [ebp - 0x18]
jmp 0x4d1e60
movzx ebx, word [eax + ecx*2]
inc ecx
and ebx, 0xff
mov dword [ebp - 0xc], ecx
mov dword [ebp - 0x1c], ebx
cmp ebx, 0x41
jl 0x4d1e7b
cmp ebx, 0x5a
jle 0x4d1edb
cmp ebx, 0x61
jl 0x4d1e85
cmp ebx, 0x7a
jle 0x4d1edb
cmp ebx, 0x30
jl 0x4d1e8f
cmp ebx, 0x39
jle 0x4d1edb
cmp ebx, 0x2b
je 0x4d1edb
cmp ebx, 0x2f
je 0x4d1edb
cmp ebx, 0x3d
je 0x4d1ed4
cmp ebx, 0xd
je 0x4d1eb9
cmp ebx, 0xa
je 0x4d1eb9
cmp ebx, 0x20
je 0x4d1eb9
cmp ebx, 9
je 0x4d1eb9
mov dword [ebp - 0x14], 1
cmp ecx, edx
jb 0x4d1e60
jmp 0x4d2028
mov eax, dword [ebp + 0x10]
pop edi
pop esi
pop ebx
mov dword [eax], 0
xor al, al
mov esp, ebp
pop ebp
ret
mov dword [ebp - 8], 1
cmp ecx, edx
jae 0x4d2028
movzx esi, word [eax + ecx*2]
inc ecx
and esi, 0xff
mov dword [ebp - 0xc], ecx
cmp esi, 0x41
jl 0x4d1efb
cmp esi, 0x5a
jle 0x4d1f49
cmp esi, 0x61
jl 0x4d1f05
cmp esi, 0x7a
jle 0x4d1f49
cmp esi, 0x30
jl 0x4d1f0f
cmp esi, 0x39
jle 0x4d1f49
cmp esi, 0x2b
je 0x4d1f49
cmp esi, 0x2f
je 0x4d1f49
cmp esi, 0x3d
je 0x4d1f42
cmp esi, 0xd
je 0x4d1f39
cmp esi, 0xa
je 0x4d1f39
cmp esi, 0x20
je 0x4d1f39
cmp esi, 9
je 0x4d1f39
mov dword [ebp - 0x14], 1
cmp ecx, edx
jb 0x4d1ee3
jmp 0x4d2028
mov dword [ebp - 8], 1
cmp ecx, edx
jae 0x4d2028
movzx edi, word [eax + ecx*2]
inc ecx
and edi, 0xff
mov dword [ebp - 0xc], ecx
cmp edi, 0x41
jl 0x4d1f69
cmp edi, 0x5a
jle 0x4d1fb7
cmp edi, 0x61
jl 0x4d1f73
cmp edi, 0x7a
jle 0x4d1fb7
cmp edi, 0x30
jl 0x4d1f7d
cmp edi, 0x39
jle 0x4d1fb7
cmp edi, 0x2b
je 0x4d1fb7
cmp edi, 0x2f
je 0x4d1fb7
cmp edi, 0x3d
je 0x4d1fb0
cmp edi, 0xd
je 0x4d1fa7
cmp edi, 0xa
je 0x4d1fa7
cmp edi, 0x20
je 0x4d1fa7
cmp edi, 9
je 0x4d1fa7
mov dword [ebp - 0x14], 1
cmp ecx, edx
jb 0x4d1f51
jmp 0x4d2028
mov dword [ebp - 8], 1
cmp ecx, edx
jae 0x4d2028
nop
movzx eax, word [eax + ecx*2]
inc ecx
and eax, 0xff
mov dword [ebp - 0xc], ecx
mov dword [ebp - 0x10], eax
cmp eax, 0x41
jl 0x4d1fda
cmp eax, 0x5a
jle 0x4d2028
cmp eax, 0x61
jl 0x4d1fe4
cmp eax, 0x7a
jle 0x4d2028
cmp eax, 0x30
jl 0x4d1fee
cmp eax, 0x39
jle 0x4d2028
cmp eax, 0x2b
je 0x4d2028
cmp eax, 0x2f
je 0x4d2028
cmp eax, 0x3d
je 0x4d2021
cmp eax, 0xd
je 0x4d2018
cmp eax, 0xa
je 0x4d2018
cmp eax, 0x20
je 0x4d2018
cmp eax, 9
je 0x4d2018
mov dword [ebp - 0x14], 1
cmp ecx, edx
jae 0x4d2028
mov eax, dword [ebp - 0x18]
jmp 0x4d1fc0
mov dword [ebp - 8], 1
mov ecx, ebx
call fcn.004d1680
test eax, eax
je 0x4d20ea
mov ecx, esi
call fcn.004d1680
test eax, eax
je 0x4d20ea
mov ecx, edi
call fcn.004d1680
test eax, eax
je 0x4d20ea
mov ecx, dword [ebp - 0x10]
call fcn.004d1680
test eax, eax
je 0x4d20ea
movzx edx, byte [esi + 0x58b610]
mov eax, dword [ebp - 0x1c]
mov ecx, edx
movzx ebx, byte [edi + 0x58b610]
mov esi, dword [ebp - 4]
mov edi, dword [ebp + 8]
movzx eax, byte [eax + 0x58b610]
shl al, 2
sar ecx, 4
and cl, 3
shl dl, 4
or cl, al
mov eax, ebx
sar eax, 2
and al, 0xf
mov byte [esi + edi], cl
or al, dl
shl bl, 6
mov byte [esi + edi + 1], al
mov eax, dword [ebp - 0x10]
movzx eax, byte [eax + 0x58b610]
and al, 0x3f
or al, bl
mov byte [esi + edi + 2], al
add esi, 3
cmp dword [ebp - 8], 0
mov dword [ebp - 4], esi
jne 0x4d21d2
mov ecx, dword [ebp - 0xc]
mov edx, dword [ebp - 0x20]
cmp ecx, edx
jb 0x4d1e40
mov eax, dword [ebp + 0x10]
pop edi
mov dword [eax], esi
xor eax, eax
cmp dword [ebp - 0x14], eax
pop esi
sete al
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, ebx
call fcn.004d1680
mov dword [ebp - 0x18], eax
test eax, eax
je 0x4d21cf
mov ecx, esi
call fcn.004d1680
test eax, eax
je 0x4d2168
mov ecx, edi
call fcn.004d1680
test eax, eax
je 0x4d2168
cmp dword [ebp - 0x10], 0x3d
jne 0x4d2168
movzx edx, byte [esi + 0x58b610]
movzx eax, byte [ebx + 0x58b610]
mov ecx, edx
mov esi, dword [ebp - 4]
mov ebx, dword [ebp + 8]
shl al, 2
sar ecx, 4
and cl, 3
shl dl, 4
or cl, al
movzx eax, byte [edi + 0x58b610]
shr al, 2
and al, 0xf
mov byte [esi + ebx], cl
or al, dl
mov byte [esi + ebx + 1], al
add esi, 2
mov eax, dword [ebp + 0x10]
pop edi
mov dword [eax], esi
xor eax, eax
cmp dword [ebp - 0x14], eax
pop esi
sete al
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x4d21cf
mov ecx, esi
call fcn.004d1680
test eax, eax
je 0x4d21cf
cmp edi, 0x3d
jne 0x4d21cf
cmp dword [ebp - 0x10], edi
jne 0x4d21cf
mov cl, byte [esi + 0x58b610]
mov al, byte [ebx + 0x58b610]
mov esi, dword [ebp - 4]
mov ebx, dword [ebp + 8]
shr cl, 4
shl al, 2
and cl, 3
or cl, al
mov eax, dword [ebp + 0x10]
mov byte [esi + ebx], cl
inc esi
pop edi
mov dword [eax], esi
xor eax, eax
cmp dword [ebp - 0x14], eax
pop esi
sete al
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [ebp + 0x10]
xor esi, esi
pop edi
mov dword [eax], esi
xor eax, eax
cmp dword [ebp - 0x14], eax
pop esi
sete al
pop ebx
mov esp, ebp
pop ebp
ret
mov esi, dword [ebp - 4]
mov eax, dword [ebp + 0x10]
pop edi
mov dword [eax], esi
xor eax, eax
cmp dword [ebp - 0x14], eax
pop esi
sete al
pop ebx
mov esp, ebp
pop ebp
ret
pop edi
test esi, esi
pop esi
sete al
pop ebx
mov esp, ebp
pop ebp
ret