Insert non accepted SIM card (foreign SIM card) into iPhone and connect with iTunes. Take backup of your phone, do a clean re-store and activate it with iTunes. Now your iPhone will be permanently unlocked! You may now proceed to re-store from iTunes back-up to get all of your data back.
This service does NOT remove iCloud activation (Find my iPhone) if it is turned on, make sure you know the Apple ID and password attached to the phone. Also, this service does NOT remove the blacklist on the network in the case its reported lost or stolen.