in reply to Re: Perl Script for searching an Image
in thread Perl Script for searching an Image

Hi Marshall, Well the idea is to take a dd image of a 1GB USB drive in Ubuntu and then mount it. Once mounted, I would like the script to be able to search for particular strings of data. Hope that helps.
  • Comment on Re^2: Perl Script for searching an Image

Replies are listed 'Best First'.
Re^3: Perl Script for searching an Image
by roboticus (Chancellor) on May 13, 2010 at 17:36 UTC

    Nathan_84:

    If you're going to mount it, you needn't worry about the fact that it's an image--once mounted it will just be a tree of files like any other. If you just want to directly scan the image file, you don't even need perl, try:

    grep -a your_image_file_name

    ...roboticus

Re^3: Perl Script for searching an Image
by Marshall (Canon) on May 13, 2010 at 18:03 UTC
    Ok. It appears that you can take this dd image and create a mount point with all the files, e.g. a file system structure at a Linux file system mount point.

    Look at http://perldoc.perl.org/File/Find.html and take a stab at it. It is tricky to get this "right", but try it with a good explanation of what you are trying do and you will get lot's of help.