The latest version will be released on Friday and you will be able to jailbreak your iPhone, plus unlock it from the carrier as well do you can use it with any mobile provider, check out the video below for more details.
Make sure you skip to at least 2 minutes into the video as there is nothing before this.
It is not clear as yet whether ultrasn0w will be able to unlock the iPhone 3GS.
Update 23rd June 2009
Update 22nd January 2010
Details have been leaked of the latest version of Apple’s iPhone OS 4.0, you can find out more at the following link.