Ejemplo n.º 1
0
    def main(self):
      options, args = self.parser.parse_args()
      self.img = images.SelectImage(options.type, args)
      self.offset = parse_int(options.offset)

      self.fs = pytsk3.FS_Info(self.img, offset = self.offset)

      ## Prepare the file class - this will be used to read specific
      ## files:
      self.file_class = self.TSKFuseFile
      self.file_class.fs = self.fs

      return Fuse.main(self)
Ejemplo n.º 2
0
 def open_image(self, image_type, filenames):
     self._img_info = images.SelectImage(image_type, filenames)
Ejemplo n.º 3
0
 def open_image(self, image_type, filenames):
     # List the actual files (any of these can raise for any reason).
     self._img_info = images.SelectImage(image_type, filenames)
Ejemplo n.º 4
0
            try:
                d = f.as_directory()
                inode = f.info.meta.addr

                # This ensures that we dont recurse into a directory
                # above the current level to avoid circular loops:
                if inode not in stack:
                    list_directory(d, stack, indent + 1)
            except RuntimeError, IOError:
                print 'Error!'

    stack.pop(-1)


# Open img file
img = images.SelectImage(options.type, args)

# Open the filesystem
fs = pytsk3.FS_Info(img, offset=(options.offset * 512))

# Open the directory node
if options.inode is not None:
    directory = fs.open_dir(inode=options.inode)
else:
    directory = fs.open_dir(path=options.path)

# Get the blocksize
blocksize = fs.info.block_size

# Get listing the
if options.mode == 'list':