AT&T recently began unlocking iPhones for customers who have either purchased their devices off-contract or have fulfilled their contract terms. However, MacRumors has learned that the carrier has quietly begun extending the iPhone unlocking service to active-duty military personnel even if they are still under contract.
US law only requires that carriers allow military personnel to suspend their wireless service without penalty while they're deployed. AT&T has taken its service a step further now by letting deployed military personnel unlock their iPhones even under contract so that their devices can be used abroad with a SIM card from overseas carriers.
The unlocking service is offered upon request along with proof of military order. Although AT&T hasn't responded with any official statements regarding the unlocking service for deployed military personnel, some user reports from their own experiences dealing with customer service seem to confirm the new policy. If you're in active duty, it certainly wouldn't hurt to give AT&T a call to see if your situation qualifies.