Fourth root script converted, same mechanical approach as
Test-ElysiumPasswordQuality (AST line ranges, then a line-by-line
comparison ignoring indentation that shows only these differences):
- Script body -> src/Elysium/Public/Send-ElysiumHashExport.ps1
(exported, [CmdletBinding()], comment-based help).
- Protect-FileWithAES -> Private/Crypto.ps1 (the ELY2 format in one
place). tests/test_decrypt.py now dot-sources that file instead of
pulling the function out of the script's AST.
- S3 put/get/delete, Get-FileSha256Hex and Get-FileChecksum ->
Private/Storage.ps1; Normalize-ReportPath -> Private/Settings.ps1.
- The script's own Domain<N> loop -> the shared
Get-DomainDetailsFromSettings; the only difference was a
Domain<N>DA value that nothing read.
- The hash export's Out-File gets an explicit -Encoding utf8 (the
value the script-level $PSDefaultParameterValues default supplied),
so that session-global default and $OutputEncoding are dropped.
- Transcript via the shared helper (same extract-hashes-*.log name),
$scriptRoot -> $InstallRoot; the completion message moves to the
wrapper.
Extract-NTHashes.ps1 is now a thin wrapper (relaunch under
powershell.exe, import module, call the cmdlet).
Verified on macOS: decrypt round trip passes against Crypto.ps1, 22/22
Pester tests pass, and the cmdlet runs through settings to its
passphrase check and writes its transcript. The AD extraction and
upload need a Windows run.