mirror of
https://github.com/dograh-hq/dograh.git
synced 2026-07-04 10:52:17 +02:00
fix: Windows PowerShell 5.1 start_docker crash and paste-safe docs snippets
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
a850d18767
commit
dc98298b66
5 changed files with 12 additions and 17 deletions
|
|
@ -7,7 +7,12 @@ $Utf8NoBom = [System.Text.UTF8Encoding]::new($false)
|
|||
|
||||
function New-HexSecret {
|
||||
$bytes = [byte[]]::new(32)
|
||||
[System.Security.Cryptography.RandomNumberGenerator]::Fill($bytes)
|
||||
$rng = [System.Security.Cryptography.RandomNumberGenerator]::Create()
|
||||
try {
|
||||
$rng.GetBytes($bytes)
|
||||
} finally {
|
||||
$rng.Dispose()
|
||||
}
|
||||
return -join ($bytes | ForEach-Object { $_.ToString('x2') })
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue