error messages while restoring :
2014-05-07 23:22:05.583 [5828:dc4]: restore library built Feb 12 2014 at 16:27:17
2014-05-07 23:22:05.583 [5828:dc4]: iTunes: iTunes 11.1.5.5
2014-05-07 23:22:05.583 [5828:dc4]: iTunes: Software payload version: 11D201
2014-05-07 23:22:05.583 [5828:dc4]: iTunes: Using MobileRestore state machine
[17:53:36.0964] Changing state from 'Idle' to 'Restoring'
[17:53:37.0027] requested restore behavior: Erase
[17:53:37.0042] requested variant: Erase
[17:53:37.0058] amai: AMAuthInstallBundleCopyBuildIdentityForVariant: No baseband chipid reported. Will match Build Identity based on ap chipid and boardid only.
[17:53:38.0074] amai: _AMAuthInstallBundleCreateServerRequestDictionary: withApTicket is True
[17:53:38.0074] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "RestoreLogo" Digest = "<CFData 05DDFD10 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0074] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "RestoreDeviceTree" Digest = "<CFData 05DDF188 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0089] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "RestoreKernelCache" Digest = "<CFData 05DDE918 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0089] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "RestoreRamDisk" Digest = "<CFData 05DDE8D0 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0089] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "iBEC" Digest = "<CFData 05DDF530 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0089] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "iBSS" Digest = "<CFData 05DDFC38 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0089] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "KernelCache" Digest = "<CFData 05DDF968 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0089] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "BatteryLow1" Digest = "<CFData 05DDF920 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0089] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "BatteryLow0" Digest = "<CFData 05DDFB18 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0089] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "LLB" Digest = "<CFData 05DDF800 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0089] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "iBoot" Digest = "<CFData 05DDFA88 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0089] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "DeviceTree" Digest = "<CFData 05DDF890 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0089] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "BatteryCharging1" Digest = "<CFData 05DDF8D8 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0089] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "AppleLogo" Digest = "<CFData 05DDFBF0 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0089] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "BatteryPlugin" Digest = "<CFData 05DDEDE0 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0105] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "BatteryFull" Digest = "<CFData 05DDF698 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0105] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "BatteryCharging0" Digest = "<CFData 05DDFAD0 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0105] amai: _AMAuthInstallBundleCreateServerRequestDictionary: personalizing "RecoveryMode" Digest = "<CFData 05DE0388 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}"
[17:53:38.0105] amai: _AMAuthInstallBundleCreateServerRequestDictionary: using UniqueBuildID <CFData 05D9B848 [72A7907C]>{length = 20, capacity = 20, bytes = 0x<<<<<<<<<<<<<<<<<<UDID>>>>>>>>>>>>>>>>>>}
[17:53:38.0105] amai: AMAuthInstallRequestSendSync: SSO function returned NULL, SSO disabled.
[17:53:38.0105] amai: AMAuthInstallDebugWriteObject: debug object written: file://localhost/C:/Users/ADMIN/AppData/Local/Temp/Per23BE.tmp/amai/debug/tss-re quest.plist
[17:53:39.0808] amai: tss_submit_job: HttpQueryInfo returned 200
[17:53:40.0199] amai: AMAuthInstallRequestSendSync: received tss response (server version: 2.1.0)
[17:53:40.0214] amai: AMAuthInstallDebugWriteObject: debug object written: file://localhost/C:/Users/ADMIN/AppData/Local/Temp/Per23BE.tmp/amai/debug/tss-re sponse.plist
[17:53:40.0277] amai: _AMAuthInstallBundlePopulatePersonalizedBundle: no entry in manifest found for "Diags"
[17:53:40.0324] iBoot build-version = iBoot-1940.10.58
[17:53:40.0324] iBoot build-style = RELEASE
[17:53:40.0324] requested restore behavior: Erase
[17:53:40.0324] amai: AMAuthInstallBundleCopyBuildIdentityForVariant: No baseband chipid reported. Will match Build Identity based on ap chipid and boardid only.
[17:53:40.0324] requested restore behavior: Erase
[17:53:40.0324] amai: AMAuthInstallBundleCopyBuildIdentityForVariant: No baseband chipid reported. Will match Build Identity based on ap chipid and boardid only.
[17:53:40.0339] unable to open device_map.txt: No such file or directory
[17:53:40.0339] found device map entry for 0x00008950 0x00000002. boardConfig=n42ap platform=s5l8950x
[17:53:40.0339] _AMRestoreCopyDeviceMapPlistEntryForHardware: firmwareDirectory not in options
[17:53:40.0339] AMDeviceIoControl: GetOverlappedResult failed
[17:53:40.0339] AMDeviceIoControl: pipe stall
[17:53:40.0339] USBControlTransfer: error 31, usbd status c0000004
[17:53:40.0339] command device request for 'getenv radio-error' failed: 2008
[17:53:40.0339] radio-error not set
[17:53:40.0339] unable to open device_map.txt: No such file or directory
[17:53:40.0339] <Recovery Mode Device 04F45168>: production fused device
[17:53:40.0355] requested restore behavior: Erase
[17:53:40.0355] amai: AMAuthInstallBundleCopyBuildIdentityForVariant: No baseband chipid reported. Will match Build Identity based on ap chipid and boardid only.
[17:53:40.0355] requested restore behavior: Erase
[17:53:40.0355] amai: AMAuthInstallBundleCopyBuildIdentityForVariant: No baseband chipid reported. Will match Build Identity based on ap chipid and boardid only.
[17:53:40.0355] interface has 1 endpoints, file pipe = 1
[17:53:40.0355]
[17:53:40.0355] <Recovery Mode Device 04F45168>: operation 4 progress -1
[17:53:40.0402] bootstrapping restore with iBEC
[17:53:40.0402] requested restore behavior: Erase
[17:53:40.0417] amai: AMAuthInstallBundleCopyBuildIdentityForVariant: No baseband chipid reported. Will match Build Identity based on ap chipid and boardid only.
[17:53:40.0417] <Recovery Mode Device 04F45168>: operation 31 progress -1
[17:53:41.0418] <Recovery Mode Device 04F45168>: Recovery mode succeeded
[17:53:41.0418] Finished Recovery Restore Phase: Successful
[17:53:41.0637] Recovery mode device disconnected
[17:53:41.0637] Device removed when in state Restoring, moving device to transition state
[17:53:41.0637] Changing state from 'Restoring' to 'Transitioning'
[17:53:41.0637] Creating timer to monitor transition
[17:54:43.0774] Recovery mode device connected
[17:54:43.0774] Transitioning device returned, continuing restore.
[17:54:43.0774] Canceling timer
[17:54:43.0774] Changing state from 'Transitioning' to 'Restoring'
[17:54:43.0774] requested restore behavior: Erase
[17:54:43.0790] requested variant: Erase
[17:54:43.0805] amai: AMAuthInstallBundleCopyBuildIdentityForVariant: No baseband chipid reported. Will match Build Identity based on ap chipid and boardid only.
[17:54:45.0493] amai: _AMAuthInstallBundleCreateServerRequestDictionary: withApTicket is False
[17:54:45.0493] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "RestoreLogo"
[17:54:45.0493] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "RestoreDeviceTree"
[17:54:45.0493] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "RestoreKernelCache"
[17:54:45.0493] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "RestoreRamDisk"
[17:54:45.0493] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "iBEC"
[17:54:45.0493] amai: _AMAuthInstallBundleCreateServerRequestDictionary: entry "iBSS" has been previously personalized; skipping it
[17:54:45.0493] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "KernelCache"
[17:54:45.0493] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "BatteryLow1"
[17:54:45.0508] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "BatteryLow0"
[17:54:45.0508] amai: _AMAuthInstallBundleCreateServerRequestDictionary: entry "LLB" has been previously personalized; skipping it
[17:54:45.0508] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "iBoot"
[17:54:45.0508] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "DeviceTree"
[17:54:45.0508] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "BatteryCharging1"
[17:54:45.0508] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "AppleLogo"
[17:54:45.0508] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "BatteryPlugin"
[17:54:45.0508] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "BatteryFull"
[17:54:45.0508] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "BatteryCharging0"
[17:54:45.0508] amai: _AMAuthInstallBundleCreateServerRequestDictionary: not personalizing "RecoveryMode"
[17:54:45.0508] amai: _AMAuthInstallBundleCreateServerRequestDictionary: nothing to be done
[17:54:45.0508] iBoot build-version = iBoot-1940.10.58
[17:54:45.0508] iBoot build-style = RELEASE
[17:54:45.0508] requested restore behavior: Erase
[17:54:45.0524] amai: AMAuthInstallBundleCopyBuildIdentityForVariant: No baseband chipid reported. Will match Build Identity based on ap chipid and boardid only.
[17:54:45.0524] requested restore behavior: Erase
[17:54:45.0524] amai: AMAuthInstallBundleCopyBuildIdentityForVariant: No baseband chipid reported. Will match Build Identity based on ap chipid and boardid only.
[17:54:45.0524] unable to open device_map.txt: No such file or directory
[17:54:45.0540] found device map entry for 0x00008950 0x00000002. boardConfig=n42ap platform=s5l8950x
[17:54:45.0540] _AMRestoreCopyDeviceMapPlistEntryForHardware: firmwareDirectory not in options
[17:54:45.0540] AMDeviceIoControl: GetOverlappedResult failed
[17:54:45.0540] AMDeviceIoControl: pipe stall
[17:54:45.0540] USBControlTransfer: error 31, usbd status c0000004
[17:54:45.0540] command device request for 'getenv radio-error' failed: 2008
[17:54:45.0540] radio-error not set
[17:54:45.0540] unable to open device_map.txt: No such file or directory
[17:54:45.0540] <Recovery Mode Device 0099F7A0>: production fused device
[17:54:45.0540] requested restore behavior: Erase
[17:54:45.0555] amai: AMAuthInstallBundleCopyBuildIdentityForVariant: No baseband chipid reported. Will match Build Identity based on ap chipid and boardid only.
[17:54:45.0555] requested restore behavior: Erase
[17:54:45.0555] amai: AMAuthInstallBundleCopyBuildIdentityForVariant: No baseband chipid reported. Will match Build Identity based on ap chipid and boardid only.
[17:54:45.0555] interface has 1 endpoints, file pipe = 1
[17:54:45.0555]
[17:54:45.0555] <Recovery Mode Device 0099F7A0>: operation 4 progress -1
[17:54:45.0571] AMDeviceIoControl: GetOverlappedResult failed
[17:54:45.0571] AMDeviceIoControl: pipe stall
[17:54:45.0571] USBControlTransfer: error 31, usbd status c0000004
[17:54:45.0571] command device request for 'ticket' failed: 2008
[17:54:45.0571] device rejected ap ticket (21)
[17:54:45.0571] AMRAuthInstallDeletePersonalizedBundle
[17:54:45.0961] Restore completed, status:21
[17:54:45.0961] Failure Description:
[17:54:45.0961] Depth:0 Error:Failed to restore device in recovery mode, libusbrestore error:21