A mother has revealed how her newborn narrowly survived an aggressive form of brain cancer after doctors investigated a tiny infection in his fingernail.