Take your time and use parafin (kerosene) with a brush (an old toothbrush or nail brush). It will be messy! DON'T use petrol or it will eat the O rings in the chain.
Once cleaned, let it dry for an hour or two, and give a good coating with proper chain oil or chain wax. The wax is thicker and 'sticks' to the chain, so less flings off when you're moving.
Depending on where you are, wax/oil it every 300-500 miles, and clean it every 600-1000 miles. Don't forget to check the chain tension everytime you wax/oil it.
If the chains too rusty, it's fucked, and may have a tight spot, where the links have seized on their rollers/rings. You can check this by feel. If it has tight spots, bite the bullet and get it replaced. You really ought to replace both front and rear sprockets at the same time. You can get a complete kit for about £100-120 in the UK, for example.
How many miles has it done? Chains are good fro about 7-12000 miles depending on use.
jb
Bringer of all things Joyful