If you were not aware that the stainless steel used in firearms can rust or if you have wondered why they rust have a read of this article.
Once, after making an offhand comment about finding a speck of what looked like rust on a brand new stainless rifle, I ended up in a lengthly debate with a non-shooter who was convinced that stainless steel does not rust.
Some folks feel that they don’t have to worry about rust and corrosion on stainless steel barrels, actions, and other components. That’s not really true. “Stainless” is a bit of a misnomer. First, there are different types of stainless steel alloys, with different degrees of rust resistance. 300 series stainless is more corrosion resistant than the 416 stainless commonly used in barrels. The composition (by percentage weight) of 416 stainless is 0.15% carbon, 12-14% chromium and the rest iron. 416 stainless steel lacks the roughly 10% nickel content that makes the 300 series more corrosion resistant in atmospheric conditions
Read more here.