Add SSH-managed node registry with connection testing and reauth.

Register hosts under Containers/VMs/Docker with encrypted key storage, and require re-authentication for sensitive account changes.
This commit is contained in:
2026-07-18 16:39:10 +02:00
parent b93b7519ec
commit f4dc8f63d7
31 changed files with 4801 additions and 223 deletions
+24
View File
@@ -0,0 +1,24 @@
package auth
import (
"crypto/rand"
"fmt"
)
// NewUUID returns a random RFC 4122 version-4 UUID string.
func NewUUID() (string, error) {
buffer := make([]byte, 16)
if _, err := rand.Read(buffer); err != nil {
return "", fmt.Errorf("uuid: %w", err)
}
buffer[6] = (buffer[6] & 0x0f) | 0x40
buffer[8] = (buffer[8] & 0x3f) | 0x80
return fmt.Sprintf(
"%x-%x-%x-%x-%x",
buffer[0:4],
buffer[4:6],
buffer[6:8],
buffer[8:10],
buffer[10:16],
), nil
}