refactor: Switch to base64 as name fields are no longer encrypted

This commit is contained in:
Felicitas Pojtinger
2021-12-03 01:10:23 +01:00
parent e19e086d97
commit 67a027bc80
2 changed files with 4 additions and 4 deletions

View File

@@ -5,7 +5,7 @@ import (
"bytes"
"compress/gzip"
"context"
"encoding/base32"
"encoding/base64"
"encoding/json"
"errors"
"fmt"
@@ -525,7 +525,7 @@ func encryptString(
return "", err
}
return base32.StdEncoding.EncodeToString(out.Bytes()), nil
return base64.StdEncoding.EncodeToString(out.Bytes()), nil
case encryptionFormatNoneKey:
return src, nil
default:

View File

@@ -6,7 +6,7 @@ import (
"bytes"
"compress/gzip"
"context"
"encoding/base32"
"encoding/base64"
"encoding/json"
"errors"
"io"
@@ -284,7 +284,7 @@ func decryptString(
return "", err
}
decoded, err := base32.StdEncoding.DecodeString(src)
decoded, err := base64.StdEncoding.DecodeString(src)
if err != nil {
return "", err
}