fix: verify territorial recovery manifest with canonical Git line endings
tests / ci (push) Canceled after 0s

This commit is contained in:
2026-10-23 19:20:25 +02:00
parent 3fd5128c62
commit cf2ddf21a1
+4 -1
View File
@@ -8,13 +8,16 @@ use RuntimeException;
/** Exact replay of the 28 accepted links into the transported project identities. */
final class ApprovedAnchorTerritories
{
public const HASH = 'dc3ae2014da51005d95780e2e4ae87e55e000e66e0765f0671c6e44a958026a0';
public const HASH = 'd2893d0a638d630435aca1890f79a8094dc58eb65bbdd65a470bb685fa075190';
/** @return array{manifest_sha256:string,projects:list<array<string,mixed>>,links:list<array<string,mixed>>} */
public function plan(): array
{
$file = base_path('docs/investmoz/unification/approved-anchor-territories-20261023.json');
$contents = is_file($file) ? file_get_contents($file) : false;
if ($contents !== false) {
$contents = str_replace("\r\n", "\n", $contents);
}
if ($contents === false || ! hash_equals(self::HASH, hash('sha256', $contents))) {
throw new RuntimeException('Reviewed territorial manifest changed.');
}