documentation

This commit is contained in:
Miek Gieben 2011-09-08 19:41:26 +02:00
parent e8b68c8621
commit 2de43f486f
2 changed files with 9 additions and 8 deletions

View File

@ -11,8 +11,9 @@ type saltWireFmt struct {
Salt string "size-hex"
}
// Hash a string/label according to RFC5155.
func hashName(label string, ha int, iterations int, salt string) string {
// HashName hashes a string or label according to RFC5155. It returns
// the hashed string.
func HashName(label string, ha int, iterations int, salt string) string {
saltwire := new(saltWireFmt)
saltwire.Salt = salt
wire := make([]byte, DefaultMsgSize)