Relativistic jets propagating through an ambient medium must produce some observational effects along their side boundaries because of interactions across the large velocity gradient. One possible effect of such an interaction would be a sheared magnetic field structure at the jet boundaries, leading to a characteristic radio polarization pattern. As proposed by Ostrowski, another effect can come from the generation of a high-energy cosmic ray component at the boundary, producing dynamic effects on the medium surrounding the jet and forming a cocoon dominated by cosmic rays with a decreased thermal gas emissivity. We selected this process for our first attempt to look for the effects of this type of interaction. We analysed the Chandra X-ray data for the radio galaxy M87 in order to verify if the expected regions of diminished emissivity may be present near the spectacular X-ray jet in this source. The detailed analysis of the data, merged from 42 separate observations, shows signatures of lower emissivity surrounding the jet. In particular we detect an intensity dip along the part of the jet, which would be approximately 1.5 × 0.15 kpc2 in size, if situated along the jet which is inclined towards us. Due to a highly non-uniform X-ray background in the central region, we are not able to claim the discovery of a cosmic ray cocoon around the M87 jet: we only have demonstrated that the data show morphological structures which could be accounted for if a cosmic ray cocoon exists.