Skip to content
This repository has been archived by the owner on Feb 24, 2021. It is now read-only.

Remove support for blowfish #52

Merged
merged 1 commit into from
Jul 12, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 1 addition & 4 deletions al.go
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import (

ci "github.com/libp2p/go-libp2p-core/crypto"
sha256 "github.com/minio/sha256-simd"
bfish "golang.org/x/crypto/blowfish"
)

// SupportedExchanges is the list of supported ECDH curves
Expand All @@ -25,7 +24,7 @@ const DefaultSupportedExchanges = "P-256,P-384,P-521"
// SupportedCiphers is the list of supported Ciphers
var SupportedCiphers = DefaultSupportedCiphers

const DefaultSupportedCiphers = "AES-256,AES-128,Blowfish"
const DefaultSupportedCiphers = "AES-256,AES-128"

// SupportedHashes is the list of supported Hashes
var SupportedHashes = DefaultSupportedHashes
Expand Down Expand Up @@ -88,8 +87,6 @@ func newBlockCipher(cipherT string, key []byte) (cipher.Block, error) {
switch cipherT {
case "AES-128", "AES-256":
return aes.NewCipher(key)
case "Blowfish":
return bfish.NewCipher(key)
default:
return nil, fmt.Errorf("Unrecognized cipher type: %s", cipherT)
}
Expand Down