mirror of
https://github.com/heygen-com/hyperframes.git
synced 2026-11-25 16:37:32 +00:00
* fix(cli): make the cache folder private before a pinned download writes into it (SECOPS-2745) The measuring tools' pinned-file downloader (measure/pinnedFiles.ts, for the MediaPipe hand landmarker) made its folder with a plain mkdir, downloaded into it, and only checked the folder was private in the seal afterwards. A folder another account owned, a group/world-writable one, or a link out of the cache received the bytes before the refusal. The model downloaders were worse: the TTS and background-removal models (utils/pinnedFile.ts) and the whisper models never checked at all, and trusted a cached copy from such a folder. Every pinned download into the HyperFrames cache now runs ensurePrivateCacheDir first: a new folder is made 0700, the person's own group/world-writable folder loses those bits, and a link, a foreign owner or a folder another account can change is refused before any partial or final file is written or any cached copy is used. Temp files stay inside the verified folder and are renamed into place. opencv.ts, which already did this, now shares ensurePinnedFiles instead of its own copy of the loop. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * fix(cli): keep the pinned downloaders' comment share at the base (SECOPS-2745) Cuts the comment lines the private-cache fix added to pinnedFiles.ts, pinnedFile.ts and whisper/manager.ts so each file's comment share is back at or under its merge-base share, and names ensurePinnedFile's root cacheRoot so the call reads without the comment. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>