Downgrading IOS from IOS 5 to 4.2
Restoring to 4.2 is not possible unless you had your iPhone jailbroken when 4.2 was the current version and saved Apples signature with this.

But if you only want back to iOS 4 you might still have a chance, because as far as I know 4.3.5 images are still being authenticated by Apple.

So you can try and download the 4.3.5 image (just google for it), and hold alt while clicking restore in iTunes. It will ask you with which file you want to restore. 

Select the downloaded file and unless an error pops up (which might be the case if Apple decided not to allow installations of 4.3.5 anymore) you should be running iOS 4.

(Also if you do this, you should do it soon, Apple won't authenticate 4.3.5 images forever.)