The 5e Beast Master ranger's animal companion has a rather significant drawback in some mid- or high-level campaigns. Because animal companions never gain the magical attack feature and due to the lack of a Magic Fang-type spell in 5e, there are particularly deadly fights in which an animal companion may not able to contribute much damage, if any.
Is there any way, as a dedicated Beast Master, to bypass this deficiency and grant a magical attack to your animal companion, even briefly?