Since their formation in the protosolar nebula some similar to 4.5 billion years ago, comets are in storage in cold distant regions of the solar system, the Kuiper Belt/scattered disk or Oort Cloud. Therefore, they have been considered as mostly unaltered samples of the protosolar nebula. However, a significant dose of energy is deposited by galactic cosmic rays (GCRs) into the outermost tens of meters of cometary nuclei during their stay in the Oort Cloud or Kuiper Belt. We investigate the impact of energy deposition by GCRs on cometary nuclei. We use experimental results from laboratory experiments and the energy deposition by GCRs estimated by Gronoff et al. (2020), to discuss the depth down to which the cometary nucleus is altered by GCRs. We show that GCRs do not significantly change the isotopic composition of cometary material but modify the chemical composition and the ice structure in the outer layers of the nucleus, which cannot be considered as pristine solar nebula material. We discuss the effect of the collisional history of comets on the distribution of processed material inside the nucleus and its implication on the observation of comets.