from module import Module from runcmd import runProcess import tomb import os def getInstance(): return MFTModule() class MFTModule(Module): def __init__(self): self.name = "mft" self.description = "Extracts NTFS MFT" self.requiredVars = ["ntfsvol"] self.vars = {} def run(self): os.mkdir(tomb.getPath() + "mft/") for vol in self.vars['ntfsvol'].value: result = runProcess(["icat","/dev/" + vol,"0"]) mftbin = open(tomb.getPath() + "mft/" + vol + ".bin",'wb') mftbin.write(result[0]) mftbin.close()