Moly (molybdenum disulfide) is an inert, dry sub micron size powder that has remarkable lubricating properties. It can handle incredible pressure and heat and because the partial size is so small, it can work itself into the microscopic pores of many materials like metals and plastics. That's why it's used extensively to treat metal surfaces subject to friction and is used in a vast array of oils, greases, pastes and other lubricants. It is even applied dry. And it is used by just about every engine manufacturer when an engine is first put together.
Because of these properties, it can be used for a wide variety of things. I wouldn't hesitate to use it when putting new shims in. It's perfect for the job and will treat the wear surfaces of the new shims (or old ones) to reduce wear. I'd also put a light smear on the cam lobes. Don't goop it up, just a light smear.
I also use a thick paste of moly applied with an old, short bristle artist's paint brush to the threads I screw into aluminum alloy. Yes, it will alter the torque required to secure the fastener but I almost always use my educated wrist rather than a torque wrench.
Even better than moly is tungsten disulfide. The only reason tungsten disulfide is not as popular as molybdenum disulfide is that when their lubricating properties were first discovered and they began to be used commercially, tungsten was much more expensive than molybdenum so the cheaper element was used. Now, tungsten disulfide is in the same price range as moly so that's why I recommend it over moly. Note, though, that the commercial market for tungsten disulfide hasn't caught up with the moly market and therefore there are fewer products available. You can mix your own, though, as both are easily available for purchase. You can even buy either on Amazon.
I have a can of this for spraying it on:
https://www.amazon.com/LOWER-FRICTI...647&sr=8-5&keywords=tungsten+disulfide+powder
And I have the raw powder as well.