Difference between pages "Ddrescue" and "JTAG Huawei TracFone M865C"

From Forensics Wiki
(Difference between pages)
Jump to: navigation, search
m
 
(Created page with "== JTAG Huawei TracFone M865C (Ascend II) == This phone is supported by the Cricket Network and Tracfone. This uses a Qualcomm 7627 600 MHz (S1) Processo and comes standard...")
 
Line 1: Line 1:
{{Infobox_Software |
+
== JTAG Huawei TracFone M865C (Ascend II) ==
  name = ddrescure |
+
  maintainer = [[Antonio Diaz Diaz]]|
+
  os = {{Linux}}|
+
  genre = {{Disk imaging}} |
+
  license = {{GPL}} |
+
  website = [http://www.gnu.org/software/ddrescue/ddrescue.html http://www.gnu.org/software/ddrescue/ddrescue.html] |
+
}}
+
  
'''ddrescue''' is a raw disk imaging tool that "copies data from one file or block device to another, trying hard to rescue data in case of read errors."  The application is developed as part of the GNU project and has written with UNIX/Linux in mind.
 
  
'''ddrescue''' and '''[[dd_rescue]]''' are completely different programs which share no development between them.  The two projects are not related in any way except that they both attempt to enhance the standard [[dd]] tool and coincidentally chose similar names for their new programs.
 
  
From the [[ddrescue]] info pages:
+
This phone is supported by the Cricket Network and Tracfone. This uses a Qualcomm 7627 600 MHz (S1) Processo and comes standard with Android version 2.3. This phone is unsupported by RIFF Box for the JTAG process for resurrector.  
<blockquote>
+
GNU ddrescue is a data recovery tool. It copies data from one file or block device (hard disc, cdrom, etc) to another, trying hard to rescue data in case of read errors.<br><br>
+
  
Ddrescue does not truncate the output file if not asked to. So, every time you run it on the same output file, it tries to fill in the gaps.<br><br>
 
  
The basic operation of ddrescue is fully automatic. That is, you don't have to wait for an error, stop the program, read the log, run it in reverse mode, etc.<br><br>
+
{| border="1" cellpadding="2"
 +
|-
 +
| [[ File:huawei-tracfone-m865c-front.png | 400px ]]
 +
| [[ File:huawei-tracfone-m865c-back.png | 400px ]]
 +
|-
 +
|}
  
If you use the logfile feature of ddrescue, the data is rescued very efficiently (only the needed blocks are read). Also you can interrupt the rescue at any time and resume it later at the same point.<br><br>
 
  
Automatic merging of backups: If you have two or more damaged copies of a file, cdrom, etc, and run ddrescue on all of them, one at a time, with the same output file, you will probably obtain a complete and error-free file. This is so because the probability of having damaged areas at the same places on different input files is very low. Using
 
the logfile, only the needed blocks are read from the second and successive copies.
 
</blockquote>
 
  
== Installation ==
+
=== Getting Started ===
  
=== Bootable CD ===
 
ddrescue is available on bootable rescue cds such as SystemRescueCd http://www.sysresccd.org/Main_Page.
 
=== Debian and Ubuntu ===
 
The package 'ddrescue' in Debian and Ubuntu is actually [[dd_rescue]], another dd-like program which does not maintain a recovery log.  The correct package is gddrescue.
 
  
Debian
+
What you need:
<blockquote>
+
aptitude install gddrescue
+
</blockquote>
+
Ubuntu
+
<blockquote>
+
sudo apt-get install gddrescue
+
</blockquote>
+
=== Gentoo ===
+
<blockquote>
+
emerge ddrescue
+
</blockquote>
+
== Partition recovery ==
+
  
=== Kernel 2.6.3+ & ddrescue 1.4+ ===
 
'ddrescue --direct' will open the input with the O_DIRECT option for uncached reads. 'raw devices' are not needed on newer kernels. For older kernels see below.
 
  
First you copy as much data as possible, without retrying or splitting sectors:
+
# Riff Box
<blockquote>
+
ddrescue --no-split /dev/hda1 imagefile logfile
+
</blockquote>
+
  
Now let it retry previous errors 3 times, using uncached reads:
+
# USB to Micro USB cord
<blockquote>
+
ddrescue --direct --max-retries=3 /dev/hda1 imagefile logfile
+
</blockquote>
+
  
If that fails you can try again but retrimmed, so it tries to reread full sectors:
 
<blockquote>
 
ddrescue --direct --retrim  --max-retries=3 /dev/hda1 imagefile logfile
 
</blockquote>
 
  
You can now use ddrescue (or normal dd) to copy the imagefile to a new partition on a new disk. Use the appropriate filesystem checkers (fsck, CHKDSK) to try to fix errors caused by the bad blocks. Be sure to keep the imagefile around. Just in case the filesystem is severely broken, and datacarving tools like testdisk need to to be used on the original image.
 
  
=== Before linux kernel 2.6.3 / 2.4.x ===
+
=== NAND Dump Procedure ===
In 2.6.3 the 'raw device' has been marked obsolete. On later kernels ddrescue will use O_DIRECT on the input to do uncached reads.
+
  
First you copy as much data as possible, without retrying or splitting sectors:
+
# Disassemble the phone down to the PCB.
<blockquote>
+
# Connect the RIFF box to the PC via USB.
ddrescue --no-split /dev/hda1 imagefile logfile
+
# Connect the RIFF box to the PCB via the JTAG pins.
</blockquote>
+
# Connect the PCB to a Micro USB cord and power via a power supply.
 +
# Start the "RIFF box" software.
 +
# Power the PCB.
 +
# Dump the NAND.
  
Now change over to raw device access. Let it retry previous errors 3 times, don't read past last block in logfile:
+
The TAPS are located under the battery, behind the Huawei phone label.  The phone will be powered by a Micro USB cord from an AC battery charger.
<blockquote>
+
modprobe raw<br>
+
raw /dev/raw/raw1 /dev/hda1<br>
+
ddrescue --max-retries=3 --complete-only /dev/raw/raw1 imagefile logfile
+
</blockquote>
+
  
If that fails you can try again (still using raw) but retrimmed, so it tries to reread full sectors:
+
The TAPS order is as follows:
<blockquote>
+
ddrescue --retrim --max-retries=3 --complete-only /dev/raw/raw1 imagefile logfile
+
</blockquote>
+
  
You can now use ddrescue (or normal dd) to copy the imagefile to a new partition on a new disk. Use the appropriate filesystem checkers (fsck, CHKDSK) to try to fix errors caused by the bad blocks. Be sure to keep the imagefile around. Just in case the filesystem is severely broken, and datacarving tools like testdisk need to to be used on the original image.
+
# 1=Not Used
 +
# 2=TCK
 +
# 3=GND
 +
# 4=TMS
 +
# 5=TDI
 +
# 6=TDO
 +
# 7=RTCK
 +
# 8=TRST
 +
# 9=NRST
  
At the end you may want to unbind the raw device:
 
<blockquote>
 
raw /dev/raw/raw1 0 0
 
</blockquote>
 
  
== Examples ==
 
  
These two examples are taken directly from the [[ddrescue]] info pages.
+
{| border="1" cellpadding="2"
 +
|-
 +
| [[ File:huawei-tracfone-m865c-taps.png | 400px ]]
 +
|-
 +
|}
  
Example 1: Rescue an ext2 partition in /dev/hda2 to /dev/hdb2
 
<blockquote>
 
ddrescue -r3 /dev/hda2 /dev/hdb2 logfile<br>
 
e2fsck -v -f /dev/hdb2<br>
 
mount -t ext2 -o ro /dev/hdb2 /mnt<br>
 
</blockquote>
 
  
Example 2: Rescue a CD-ROM in /dev/cdrom
 
<blockquote>
 
ddrescue -b 2048 /dev/cdrom cdimage logfile
 
</blockquote>
 
write cdimage to a blank CD-ROM
 
  
 +
For the TAPs, the Huawei-8650 was utilized, pictured above. The TAPS on the M865C are located in the same location as the 8650. See below for TAPS locations.
  
This example is derived from the ddrescue manual.
 
  
Example 3: Rescue an entire hard disk /dev/sda to another disk /dev/sdb
 
  
copy the error free areas first
+
{| border="1" cellpadding="2"
ddrescue -n /dev/sda /dev/sdb rescue.log
+
|-
attempt to recover any bad sectors
+
| [[ File:huawei-tracfone-m865c-soldered-taps.png | 400px ]]
ddrescue -r 1 /dev/sda /dev/sdb rescue.log
+
|-
 +
|}
  
  
== Cygwin ==
 
  
As of release 1.4-rc1, it can be compiled directly in [[Cygwin]] [http://en.wikipedia.org/wiki/Out_of_the_box Out of the Box]. Precompiled packages are available in the [http://cygwin.com/packages/ Cygwin distribution]. This makes it usable natively on [[Windows]] systems.
+
After the wires are connected to the board, the phone is powered by the USB connection. Plug the Micro USB into the USB connection on the device and then plug the phone into a wall outlet. The phone should respond with the vibrator switch activating for less than a second.
  
== See also ==
+
Launch the Riff Box JTAG Manager and use the following settings:
  
* [[aimage]]
+
* JTAG TCK Speed = RTCK
* [[Blackbag]]
+
* Resurrector Settings= Huawei U8650
* [[dcfldd]]
+
* Auto FullFlash size
* [[dd]]
+
 
* [[dd_rescue]]
+
 
* [[sdd]]
+
 
 +
{| border="1" cellpadding="2"
 +
|-
 +
| [[ File:huawei-tracfone-m865c-riff-settings.png | 400px ]]
 +
|-
 +
|}
 +
 
 +
 
 +
 
 +
Advanced Settings:
 +
 
 +
* Ignore Target IDCODE during Resurrection and DCC Loader operations
 +
 
 +
 
 +
 
 +
{| border="1" cellpadding="2"
 +
|-
 +
| [[ File:huawei-tracfone-m865c-riff-advanced-settings.png | 400px ]]
 +
|-
 +
|}
 +
 
 +
 
 +
 
 +
Then connect and get the ID, you should receive the dead body signal. Then read the memory.  JTAG complete.
 +
 
 +
 
 +
=== Notes ===
 +
 
 +
 
 +
 
 +
The phone has a 512 MB NAND flash memory chip which should take approximately 30 minutes to download.

Revision as of 19:29, 11 September 2013

Contents

JTAG Huawei TracFone M865C (Ascend II)

This phone is supported by the Cricket Network and Tracfone. This uses a Qualcomm 7627 600 MHz (S1) Processo and comes standard with Android version 2.3. This phone is unsupported by RIFF Box for the JTAG process for resurrector.


400px 400px


Getting Started

What you need:


  1. Riff Box
  1. USB to Micro USB cord


NAND Dump Procedure

  1. Disassemble the phone down to the PCB.
  2. Connect the RIFF box to the PC via USB.
  3. Connect the RIFF box to the PCB via the JTAG pins.
  4. Connect the PCB to a Micro USB cord and power via a power supply.
  5. Start the "RIFF box" software.
  6. Power the PCB.
  7. Dump the NAND.

The TAPS are located under the battery, behind the Huawei phone label. The phone will be powered by a Micro USB cord from an AC battery charger.

The TAPS order is as follows:

  1. 1=Not Used
  2. 2=TCK
  3. 3=GND
  4. 4=TMS
  5. 5=TDI
  6. 6=TDO
  7. 7=RTCK
  8. 8=TRST
  9. 9=NRST


400px


For the TAPs, the Huawei-8650 was utilized, pictured above. The TAPS on the M865C are located in the same location as the 8650. See below for TAPS locations.


Huawei-tracfone-m865c-soldered-taps.png


After the wires are connected to the board, the phone is powered by the USB connection. Plug the Micro USB into the USB connection on the device and then plug the phone into a wall outlet. The phone should respond with the vibrator switch activating for less than a second.

Launch the Riff Box JTAG Manager and use the following settings:

  • JTAG TCK Speed = RTCK
  • Resurrector Settings= Huawei U8650
  • Auto FullFlash size


400px


Advanced Settings:

  • Ignore Target IDCODE during Resurrection and DCC Loader operations


400px


Then connect and get the ID, you should receive the dead body signal. Then read the memory. JTAG complete.


Notes

The phone has a 512 MB NAND flash memory chip which should take approximately 30 minutes to download.