change the default key type to Ed25519 (#1576)

This commit is contained in:
Marten Seemann 2022-08-09 17:03:55 +02:00 committed by GitHub
parent 61f0605279
commit 24b27cc71b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -56,7 +56,7 @@ var DefaultPeerstore Option = func(cfg *Config) error {
// RandomIdentity generates a random identity. (default behaviour) // RandomIdentity generates a random identity. (default behaviour)
var RandomIdentity = func(cfg *Config) error { var RandomIdentity = func(cfg *Config) error {
priv, _, err := crypto.GenerateKeyPairWithReader(crypto.RSA, 2048, rand.Reader) priv, _, err := crypto.GenerateEd25519Key(rand.Reader)
if err != nil { if err != nil {
return err return err
} }