aboutsummaryrefslogtreecommitdiff
path: root/main.go
diff options
context:
space:
mode:
authorGrégoire Duchêne <gduchene@awhk.org>2022-01-02 00:44:00 +0000
committerGrégoire Duchêne <gduchene@awhk.org>2022-01-02 00:44:00 +0000
commit42a9881b6905ee5ffc044d1f3f77dac2389ed521 (patch)
tree4ef1d7d9dd29bdbbad5b157f8db285e4ecc39264 /main.go
parent092c3e150d3d12cdd4e80bb8482a372db04e9786 (diff)
Migrate off deprecated functions
Diffstat (limited to 'main.go')
-rw-r--r--main.go5
1 files changed, 2 insertions, 3 deletions
diff --git a/main.go b/main.go
index 48e9660..996b359 100644
--- a/main.go
+++ b/main.go
@@ -16,7 +16,6 @@ import (
"errors"
"flag"
"fmt"
- "io/ioutil"
"log"
"math/big"
"net"
@@ -198,7 +197,7 @@ func main() {
parentKey := key
parentCert := tmpl
if caName != "" {
- buf, err := ioutil.ReadFile(caName + ".key")
+ buf, err := os.ReadFile(caName + ".key")
if err != nil {
log.Fatalln("error: could not read the CA private key:", err)
}
@@ -210,7 +209,7 @@ func main() {
if err != nil {
log.Fatalln("error: could not parse the CA private key:", err)
}
- buf, err = ioutil.ReadFile(caName + ".crt")
+ buf, err = os.ReadFile(caName + ".crt")
if err != nil {
log.Fatalln("error: could not read the CA certificate:", err)
}