Skip to content

Commit

Permalink
Merge pull request #4019 from MaxMcAdam/update-hash-algo
Browse files Browse the repository at this point in the history
Issue 4018 - Use sha256 instead of sha1 to hash service during servic…
  • Loading branch information
LiilyZhang authored Mar 19, 2024
2 parents 3907d26 + 90a65ea commit b8b7283
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions container/container.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package container

import (
"bytes"
"crypto/sha1"
"crypto/sha256"
"encoding/base64"
"encoding/json"
"errors"
Expand Down Expand Up @@ -190,7 +190,7 @@ func hashService(service *containermessage.Service) (string, error) {

glog.V(5).Infof("Hashing Service: %v", string(b))

h := sha1.New()
h := sha256.New()
if _, err := io.Copy(h, bytes.NewBuffer(b)); err != nil {
return "", err
}
Expand Down

0 comments on commit b8b7283

Please sign in to comment.