sum256 calculate sha256sum for an input byte array, returns hex encoded.
(data []byte)
| 91 | |
| 92 | // sum256 calculate sha256sum for an input byte array, returns hex encoded. |
| 93 | func sum256Hex(data []byte) string { |
| 94 | hash := newSHA256Hasher() |
| 95 | defer hash.Close() |
| 96 | hash.Write(data) |
| 97 | return hex.EncodeToString(hash.Sum(nil)) |
| 98 | } |
| 99 | |
| 100 | // sumMD5Base64 calculate md5sum for an input byte array, returns base64 encoded. |
| 101 | func sumMD5Base64(data []byte) string { |
no test coverage detected