Secure Transacted File System (STFS) Support (#78)

* Initial STFS support

* Fix build errors

* Fix more build errors

* Final fix

* Cleanup printer

* Fix indent
This commit is contained in:
Deterous
2026-04-08 11:14:39 +09:00
committed by GitHub
parent adedc502e3
commit 7485a43364
23 changed files with 1475 additions and 2 deletions

View File

@@ -0,0 +1,33 @@
using System.Collections.Generic;
using SabreTools.Numerics;
namespace SabreTools.Data.Models.STFS
{
/// <summary>
/// STFS Hash Table Entry in a Hash Block's Hash Table
/// </summary>
/// <see href="https://free60.org/System-Software/Formats/STFS/"/>
public class HashTableEntry
{
/// <summary>
/// SHA-1 hash of the block
/// </summary>
public byte[] Hash { get; set; } = new byte[20];
/// <summary>
/// Status of the block
/// 0x00 = Unused block
/// 0x40 = Free block (previously used, now freed)
/// 0x80 = Used block
/// 0xC0 = Newly allocated block
/// </summary>
public byte Status { get; set; }
/// <summary>
/// Block number corresponding to the hash
/// FFFFFF = Block 1 (starting 0xB000)
/// </summary>
/// <remarks>Big-endian, 3-byte uint24</remarks>
public UInt24 BlockNumber { get; set; } = new();
}
}