summaryrefslogtreecommitdiffstats
path: root/lib/web.go
diff options
context:
space:
mode:
Diffstat (limited to 'lib/web.go')
-rw-r--r--lib/web.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/web.go b/lib/web.go
index 191d2f2..814d016 100644
--- a/lib/web.go
+++ b/lib/web.go
@@ -3,16 +3,16 @@
package lib
-import "crypto/rand"
-
type Profile map[string]string
-var webSessionEncryptionKey []byte = make([]byte, 16)
+var webSessionEncryptionKey []byte
var webUidCounter int64
var webUserProfiles map[string]Profile = make(map[string]Profile, 0)
func init() {
- _, err := rand.Read(webSessionEncryptionKey)
+ var err error
+
+ webSessionEncryptionKey, err = RandomBytes(16)
if err != nil {
panic(err)
}