Descriptioncrypto/hmac: Deprecate hmac.NewMD5, hmac.NewSHA1 and hmac.NewSHA256
Remove NewMD5, NewSHA1 and NewSHA256 in favor of using New and
explicitly importing the used hash-function. This way when using, for
example, HMAC with RIPEMD there's no md5, sha1 and sha256 linked in
through the hmac package.
A gofix rule is included, and applied to the standard library (3 files
altered).
This change is the result of a discussion at
http://codereview.appspot.com/5550043/ to pull the discussion about
deprecating these functions out of that issue.
Patch Set 1 #Patch Set 2 : diff -r ca2fc0db9471 https://go.googlecode.com/hg/ #Patch Set 3 : diff -r ca2fc0db9471 https://go.googlecode.com/hg/ #
MessagesTotal messages: 9
|