Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrInvalidSignature = errors.New("invalid signature")
)
Functions ¶
This section is empty.
Types ¶
type GenericSigner ¶
type GenericSigner struct {
// contains filtered or unexported fields
}
GenericSigner is the first and simple signer that is sufficient for simple applications. This signer takes a key of sufficient length. It will generate the signature based on HMAC+SHA1.
func (*GenericSigner) Sign ¶
func (gs *GenericSigner) Sign(message string) string
Sign will compute the HMAC-SHA1 signature of the given message. The message and signature are then individually base64 encoded and concatenated by a period.
Click to show internal directories.
Click to hide internal directories.