Yep. And it must be done.
WD-40 and Hoppe's No. 9, and obviously mineral spirits (paint thinner), will work. Any universal solvent for oil based compounds will do the trick.
I used brake cleaner (NOT fluid) and had excellent, fast working results. Others have used carburetor cleaner or acetone.
Once that's done, be sure to clean out the solvent with hot, soapy water, then rinse with plain water and dry thoroughly. If you want to be sure all the water is gone, flush with alcohol, although just drying with cloth should be enough. Finish with a thin coat of Ballistol or Birchwood Casey's Barricade.