예제 #1
0
파일: packet.go 프로젝트: h2so5/murcott
func (p *Packet) Sign(key *utils.PrivateKey) error {
	sign := key.Sign(p.Serialize())
	if sign == nil {
		return errors.New("cannot sign packet")
	}
	p.S = *sign
	return nil
}