Yesterday at WWDC 2010 we saw Steve Jobs announcing iOS 4.0 (renamed from iPhone OS 4.0) and availability of iOS 4.0 GM Candidate build to the developers of iPhone Developer program for testing purpose. The final iOS 4.0 will be available from June 21st for Update to iPhone 3G/3GS & iPod Touch 2G & 3G.
Well this is was just the matter of time for iOS 4.0 Golden Master Build leak and it has been already leaked on internet. iOS 4.0 GM for all iDevice has been leaked and available for download instantlyi.com. the following iOS 4.0 firmware files are available for download.
iPhone 3G :- iPhone1,2_4.0_8A293_Restore.ipsw
iPhone 3GS :- iPhone2,1_4.0_8A293_Restore.ipsw
iPod Touch 2G :- iPod2,1_4.0_8A293_Restore.ipsw
iPod Touch 3G :- iPod3,1_4.0_8A293_Restore.ipsw
Please keep in mind your iDevices UDID needs to be registered with a dev account in order to activate iOS 4.0. Also if you planning to jailbreak & unlock your iPhone & iPod Touch then you should not update to stock firmware until iPhone dev team releases their tools.