Hacker News new | ask | show | jobs
by dataflow 1855 days ago
> I once wrote some code to recover degraded CD/DVD(+/-R) sectors by disabling the ECC of the drive

How did you do this? Is there some SCSI/ATAPI command for this?

3 comments

I found out how to use a vendor-specific command to read the raw data from the buffer of the drive before descrambling and ECC. Look up the "FriiDump" project for some more background information. I then patched the firmware in memory (that took a lot of work...) to cause regular read commands to return the raw data.

(Contrary to some of the other comments in this thread, the drive was actually an LG.)

Wow! It does sound extremely painful haha. Thanks for sharing, that's pretty useful info.
What data you can get depends on the disc drive. DiscImageCreator [0] or the redump.org wiki [1] are good starting points.

[0] https://github.com/saramibreak/DiscImageCreator

[1] http://wiki.redump.org/index.php?title=Dumping_Guides

I'd also like to know. I tried to send those commands (SCSI I think?) to the drive, but it seemed to just ignore them. Heck, it seemed to ignore a huge portion of the different commands I tried to send it.
Sounds like "READ RAW". From memory it only works on certain drives - I want to say LiteOn but my memory is hazy.
That matches with my recollection too. I remember getting a specific model of a LiteOn drive specifically to ensure that I had the ability to do this, both for data recovery and because some forms of copy protection abused disc read errors and made reading your own CDs a (kernel blocking) pain under linux. I think the source of `cdparanoia` [1] has some good examples.

[1] https://xiph.org/paranoia/faq.html