def __init__(self, buffer, path=None, mode=None, cryptoType=-1, cryptoKey=-1, cryptoCounter=-1): super(Rom, self).__init__(buffer, path, mode, cryptoType, cryptoKey, cryptoCounter) if buffer: self.ivfc = Ivfc(MemoryFile(buffer[0x8:]), 'rb') self.magic = buffer[0x8:0xC] # Hex.dump(buffer) #self.sectionStart = self.ivfc.levels[5].offset else: self.ivfc = None
def __init__(self, buffer, path=None, mode=None, cryptoType=-1, cryptoKey=-1, cryptoCounter=-1): super(Rom, self).__init__(buffer, path, mode, cryptoType, cryptoKey, cryptoCounter) if buffer: self.ivfc = Ivfc(MemoryFile(buffer[0x8:]), 'rb') self.magic = buffer[0x8:0xC] else: self.ivfc = None