Repository navigation
Recover deleted media from YAFFS2, JFFS2 and UBIFS volumes - #197
Merged
Merged
Conversation
recover_deleted() now reaches flash volumes as well as NTFS, FAT32 and
exFAT, through qnxprobe 1.36's recover_deleted(). A recovered flash file
is named the way a walk names a live one ("<volume>/<folder>/<name>"),
keeps its Unix modified time as an instant, and is staged under a name
keyed by its object id or inode number and a count, because YAFFS reuses
object ids and one id and name can belong to several deleted files. A
file qnxprobe refuses because some of its pages were erased is not
registered.
A YAFFS2 file, and a JFFS2 file on flash with no spare bytes, hands the
carve the offset of its first byte, so a carve alongside does not add a
nameless twin. UBIFS and JFFS2 on NAND place data through a mapped or
spare-stripped view, so their files add no offset.
tests/test_flash_deleted.py builds a JFFS2 volume with a live picture, a
deleted picture whose nodes are marked obsolete as NOR flash marks them,
a deleted text file and a deleted picture with part of its data gone.
The manual, the in-app help, the carve option's tooltip and the CLI
message list the flash filesystems.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Recovers deleted media from YAFFS2, JFFS2 and UBIFS volumes, through qnxprobe 1.36's
recover_deleted().<volume>/<folder>/<name>) and keeps its Unix modified time as an instant.tests/test_flash_deleted.pybuilds a JFFS2 volume (live picture, deleted picture with NOR-obsolete nodes, deleted text file, partly erased deleted picture). The old code fails 3 of its 7 tests, and four mutants (no count, no carve offset, no modified time, bare name) each fail one.On the DFRWS 2011 Case 2 /data dump (a real Android YAFFS2 NAND dump), 34 deleted media files come back (25 images, 9 zips), each byte-identical to qnxprobe's reading of the same file.
🤖 Generated with Claude Code