public KeyNodeCell(string name, int parentCellIndex) : this(-1) { Flags = RegistryKeyFlags.Normal; Timestamp = DateTime.UtcNow; ParentIndex = parentCellIndex; SubKeysIndex = -1; ValueListIndex = -1; SecurityIndex = -1; ClassNameIndex = -1; Name = name; }
public KeyNodeCell(string name, int parentCellIndex) : this(-1) { Flags = RegistryKeyFlags.Normal; Timestamp = DateTime.UtcNow; ParentIndex = parentCellIndex; SubKeysIndex = -1; ValueListIndex = -1; SecurityIndex = -1; ClassNameIndex = -1; Name = name; }
public override int ReadFrom(byte[] buffer, int offset) { Flags = (RegistryKeyFlags)Utilities.ToUInt16LittleEndian(buffer, offset + 0x02); Timestamp = DateTime.FromFileTimeUtc(Utilities.ToInt64LittleEndian(buffer, offset + 0x04)); ParentIndex = Utilities.ToInt32LittleEndian(buffer, offset + 0x10); NumSubKeys = Utilities.ToInt32LittleEndian(buffer, offset + 0x14); SubKeysIndex = Utilities.ToInt32LittleEndian(buffer, offset + 0x1C); NumValues = Utilities.ToInt32LittleEndian(buffer, offset + 0x24); ValueListIndex = Utilities.ToInt32LittleEndian(buffer, offset + 0x28); SecurityIndex = Utilities.ToInt32LittleEndian(buffer, offset + 0x2C); ClassNameIndex = Utilities.ToInt32LittleEndian(buffer, offset + 0x30); MaxSubKeyNameBytes = Utilities.ToInt32LittleEndian(buffer, offset + 0x34); MaxValNameBytes = Utilities.ToInt32LittleEndian(buffer, offset + 0x3C); MaxValDataBytes = Utilities.ToInt32LittleEndian(buffer, offset + 0x40); IndexInParent = Utilities.ToInt32LittleEndian(buffer, offset + 0x44); int nameLength = Utilities.ToInt16LittleEndian(buffer, offset + 0x48); ClassNameLength = Utilities.ToInt16LittleEndian(buffer, offset + 0x4A); Name = Utilities.BytesToString(buffer, offset + 0x4C, nameLength); return 0x4C + nameLength; }
public override int ReadFrom(byte[] buffer, int offset) { Flags = (RegistryKeyFlags)Utilities.ToUInt16LittleEndian(buffer, offset + 0x02); Timestamp = DateTime.FromFileTimeUtc(Utilities.ToInt64LittleEndian(buffer, offset + 0x04)); ParentIndex = Utilities.ToInt32LittleEndian(buffer, offset + 0x10); NumSubKeys = Utilities.ToInt32LittleEndian(buffer, offset + 0x14); SubKeysIndex = Utilities.ToInt32LittleEndian(buffer, offset + 0x1C); NumValues = Utilities.ToInt32LittleEndian(buffer, offset + 0x24); ValueListIndex = Utilities.ToInt32LittleEndian(buffer, offset + 0x28); SecurityIndex = Utilities.ToInt32LittleEndian(buffer, offset + 0x2C); ClassNameIndex = Utilities.ToInt32LittleEndian(buffer, offset + 0x30); MaxSubKeyNameBytes = Utilities.ToInt32LittleEndian(buffer, offset + 0x34); MaxValNameBytes = Utilities.ToInt32LittleEndian(buffer, offset + 0x3C); MaxValDataBytes = Utilities.ToInt32LittleEndian(buffer, offset + 0x40); IndexInParent = Utilities.ToInt32LittleEndian(buffer, offset + 0x44); int nameLength = Utilities.ToInt16LittleEndian(buffer, offset + 0x48); ClassNameLength = Utilities.ToInt16LittleEndian(buffer, offset + 0x4A); Name = Utilities.BytesToString(buffer, offset + 0x4C, nameLength); return(0x4C + nameLength); }