summaryrefslogtreecommitdiffstats
path: root/tools/secret-key/secret-key.go
blob: 969828a6dd6c8991edc1ff25ea648eb378a914f8 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
package main

import (
	"crypto/rand"
	"crypto/sha256"
	"encoding/base64"
	"fmt"
)

func main() {
	buf := make([]byte, sha256.BlockSize)
	rand.Read(buf)
	fmt.Printf("secret-key=%s\n", base64.RawURLEncoding.EncodeToString(buf))
}