namespace SabreTools.Models.IRD { /// /// public class IRD { /// /// "3IRD" /// #if NET48 public byte[] Magic { get; set; } #else public byte[]? Magic { get; set; } #endif /// /// Version /// /// Versions 6 - 9 are accepted public byte Version { get; set; } /// /// The same value stored in PARAM.SFO / TITLE_ID /// /// 9 bytes, ASCII, stored without dashes #if NET48 public string TitleID { get; set; } #else public string? TitleID { get; set; } #endif /// /// Number of bytes that follow containing the title /// public byte TitleLength { get; set; } /// /// The same value stored in PARAM.SFO / TITLE /// /// bytes, ASCII #if NET48 public string Title { get; set; } #else public string? Title { get; set; } #endif /// /// The same value stored in PARAM.SFO / PS3_SYSTEM_VER /// /// 4 bytes, ASCII, missing uses "0000" #if NET48 public string SystemVersion { get; set; } #else public string? SystemVersion { get; set; } #endif /// /// The same value stored in PARAM.SFO / VERSION /// /// 5 bytes, ASCII #if NET48 public string GameVersion { get; set; } #else public string? GameVersion { get; set; } #endif /// /// The same value stored in PARAM.SFO / APP_VER /// /// 5 bytes, ASCII #if NET48 public string AppVersion { get; set; } #else public string? AppVersion { get; set; } #endif /// /// Length of the gzip-compressed header data /// public uint HeaderLength { get; set; } /// /// Gzip-compressed header data /// #if NET48 public byte[] Header { get; set; } #else public byte[]? Header { get; set; } #endif /// /// Length of the gzip-compressed footer data /// public uint FooterLength { get; set; } /// /// Gzip-compressed footer data /// #if NET48 public byte[] Footer { get; set; } #else public byte[]? Footer { get; set; } #endif /// /// Number of complete regions in the image /// public byte RegionCount { get; set; } /// /// MD5 hashes for all complete regions in the image /// /// regions, 16-bytes per hash #if NET48 public byte[][] RegionHashes { get; set; } #else public byte[][]? RegionHashes { get; set; } #endif /// /// Number of decrypted files in the image /// public uint FileCount { get; set; } /// /// Starting sector for each decrypted file /// /// files, alternating with each entry #if NET48 public ulong[] FileKeys { get; set; } #else public ulong[]? FileKeys { get; set; } #endif /// /// MD5 hashes for all decrypted files in the image /// /// files, 16-bytes per hash, alternating with each entry #if NET48 public byte[][] FileHashes { get; set; } #else public byte[][]? FileHashes { get; set; } #endif /// /// Extra Config, usually 0x0000 /// public ushort ExtraConfig { get; set; } /// /// Attachments, usually 0x0000 /// public ushort Attachments { get; set; } /// /// D1 key /// /// 16 bytes #if NET48 public byte[] Data1Key { get; set; } #else public byte[]? Data1Key { get; set; } #endif /// /// D2 key /// /// 16 bytes #if NET48 public byte[] Data2Key { get; set; } #else public byte[]? Data2Key { get; set; } #endif /// /// Uncompressed PIC data /// /// 115 bytes, before D1/D2 keys on version 9 #if NET48 public byte[] PIC { get; set; } #else public byte[]? PIC { get; set; } #endif /// /// Unique Identifier /// /// Not present on version 6 and prior, after AppVersion on version 7 public uint UID { get; set; } /// /// IRD content CRC /// public uint CRC { get; set; } } }