aboutsummaryrefslogtreecommitdiff
path: root/client
diff options
context:
space:
mode:
authorRasmus Dahlberg <rasmus.dahlberg@kau.se>2020-11-03 10:40:34 +0100
committerRasmus Dahlberg <rasmus.dahlberg@kau.se>2020-11-03 10:40:34 +0100
commit0b00ea0ab30503ccfab58f70586e10f74cee1bcb (patch)
treebb74288b10825242682428adb9df822208bdb3c8 /client
parente525c41ca9bec1c4772d9cd09904e971868d2daf (diff)
removed unused code
Diffstat (limited to 'client')
-rw-r--r--client/add-entry/main.go24
1 files changed, 0 insertions, 24 deletions
diff --git a/client/add-entry/main.go b/client/add-entry/main.go
index b4f9f65..56e0ec4 100644
--- a/client/add-entry/main.go
+++ b/client/add-entry/main.go
@@ -97,30 +97,6 @@ func setup() (*client.Client, error) {
return client.NewClient(log, &http.Client{}, c, &k), nil
}
-//func parseEd25519PrivateKey(data []byte) (ed25519.PrivateKey, error) {
-// block, rest := pem.Decode(data)
-// if block == nil {
-// return nil, fmt.Errorf("pem block: is empty")
-// }
-// if block.Type != "PRIVATE KEY" {
-// return nil, fmt.Errorf("bad pem block type: %v", block.Type)
-// }
-// if len(rest) != 0 {
-// return nil, fmt.Errorf("pem block: trailing data")
-// }
-//
-// key, err := x509.ParsePKCS8PrivateKey(block.Bytes)
-// if err != nil {
-// fmt.Errorf("x509 parser failed: %v", err)
-// }
-// switch t := key.(type) {
-// case ed25519.PrivateKey:
-// return key.(ed25519.PrivateKey), nil
-// default:
-// return nil, fmt.Errorf("unexpected signing key type: %v", t)
-// }
-//}
-
func parseChain(rest []byte) ([]*x509.Certificate, error) {
var chain []*x509.Certificate
for len(rest) > 0 {