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

Commit

Permalink
Merge pull request #64 from libp2p/fix/remove-sha1
Browse files Browse the repository at this point in the history
feat: remove sha1 hmac
  • Loading branch information
Stebalien committed Feb 8, 2020
2 parents cf5f8d2 + e5b5458 commit 702833a
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions al.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import (
"crypto/aes"
"crypto/cipher"
"crypto/hmac"
"crypto/sha1"
"crypto/sha512"
"hash"

Expand Down Expand Up @@ -72,8 +71,6 @@ func (e *encParams) makeMacAndCipher() error {

func newMac(hashType string, key []byte) (HMAC, error) {
switch hashType {
case "SHA1":
return HMAC{hmac.New(sha1.New, key), sha1.Size}, nil
case "SHA512":
return HMAC{hmac.New(sha512.New, key), sha512.Size}, nil
case "SHA256":
Expand Down

0 comments on commit 702833a

Please sign in to comment.