My own non-professional opinion is that it's the asphalt that is the primary cause. I've been told that when your foot strike is the same km after km it puts too much pressure on the same parts of the body. When the terrain is uneven, it mixes it up more. That makes sense to me. And as the caminos (particularly the francés) becomes more and more paved, this is an inevitable result. So whenever I hit a stage of paving, I go to great lengths (some would say ridiculous lengths) to walk alongside on dirt, in weeds, whatever it takes to avoid the asphalt.
Though I know there have been some contrary findings in the press recently, what works for me is -- wearing silicone, never hard plastic, orthotics; icing my shins regularly after walking, whether they hurt or not. (I also ice my heels, but for another issue); elevating when I can. There's the RICE acronym, so I've got the rest, ice, elevation, but not sure what the C is or whether any of this works.
And if you're wondering about how to get ice, I always carry a small plastic bag at the ready. When I stop walking, I go to a bar for a drink and ask if I could have some ice in the bag. I've done this hundreds and hundreds of times and the only time I got a "no" was at a bar in Logroño in the square next to the cathedral in 2002 or 2003. Of course I have to sit outside since it's not very nice to have melting ice dripping all over the floor.
Buen camino, Laurie