I just spray the inside of soft gun cases with silicone.
Never had a problem.
For handguns, wrapping them with a rag of tee shirt, sprayed down with silicone, seems to keep them rust free.
Walt Kelly, alias Pogo, sez:
“Don't take life so serious, son, it ain't nohow permanent.”