You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
16 lines
487 B
16 lines
487 B
package crypto
|
|
|
|
import (
|
|
"fmt"
|
|
"testing"
|
|
)
|
|
|
|
func TestShaEncode(t *testing.T) {
|
|
fmt.Println(cryptoTool.Sha256Encode("hello world!"))
|
|
//7509e5bda0c762d2bac7f90d758b5b2263fa01ccbc542ab5e3df163be08e6ca9
|
|
fmt.Println(cryptoTool.Sha1Encode("hello world!"))
|
|
//430ce34d020724ed75a196dfc2ad67c77772d169
|
|
fmt.Println(cryptoTool.Sha512Encode("hello world!"))
|
|
//db9b1cd3262dee37756a09b9064973589847caa8e53d31a9d142ea2701b1b28abd97838bb9a27068ba305dc8d04a45a1fcf079de54d607666996b3cc54f6b67c
|
|
}
|