1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2024-12-22 10:08:15 -05:00
v2fly/proxy/vmess/protocol/hash.go
2016-01-12 10:52:40 +00:00

16 lines
190 B
Go

package protocol
import (
"crypto/hmac"
"crypto/md5"
"hash"
)
func TimestampHash() hash.Hash {
return md5.New()
}
func IDHash(key []byte) hash.Hash {
return hmac.New(md5.New, key)
}