Example #1
0
File: Rom.py Project: yukun451/nut
	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
Example #2
0
File: Rom.py Project: pka4916/nut
 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