aboutsummaryrefslogtreecommitdiff
path: root/crypto.go
diff options
context:
space:
mode:
authorDimitri Sokolyuk <demon@dim13.org>2016-01-12 23:17:31 +0100
committerDimitri Sokolyuk <demon@dim13.org>2016-01-12 23:17:31 +0100
commit20650c97ee0a7195957ce8f30f87a901bda28e89 (patch)
tree22e44f456e87fe2b96a59558fb97a872722eecbc /crypto.go
parent14b97b923d25386e068612f94540dc37e21e09d9 (diff)
cleanup
Diffstat (limited to 'crypto.go')
-rw-r--r--crypto.go9
1 files changed, 0 insertions, 9 deletions
diff --git a/crypto.go b/crypto.go
index a9c8b4c..e275933 100644
--- a/crypto.go
+++ b/crypto.go
@@ -1,7 +1,6 @@
package acme
import (
- "crypto/rand"
"crypto/rsa"
"crypto/x509"
"encoding/pem"
@@ -29,14 +28,6 @@ func LoadKey(r io.Reader) (*rsa.PrivateKey, error) {
return x509.ParsePKCS1PrivateKey(block.Bytes)
}
-func NewKey(w io.Writer, size int) (*rsa.PrivateKey, error) {
- key, err := rsa.GenerateKey(rand.Reader, size)
- if err != nil {
- return nil, err
- }
- return key, SaveKey(w, key)
-}
-
func SaveKey(w io.Writer, key *rsa.PrivateKey) error {
block := &pem.Block{
Type: "RSA PRIVATE KEY",