Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConstructEncryptionJwt ¶
func ConstructEncryptionJwt(key *ecdsa.PrivateKey, token []byte) string
func DecodeJwtPayload ¶
func DecodeJwtPayload(v string, t interface{})
Types ¶
type EncryptionData ¶
type EncryptionData struct { ClientPublicKey *ecdsa.PublicKey ServerPrivateKey *ecdsa.PrivateKey ServerToken []byte DecryptSecretKeyBytes [32]byte EncryptSecretKeyBytes [32]byte DecryptIV []byte EncryptIV []byte DecryptCipher cipher.Block EncryptCipher cipher.Block SendCounter int64 }
func (*EncryptionData) ComputeSecretKeyBytes ¶
func (data *EncryptionData) ComputeSecretKeyBytes()
func (*EncryptionData) ComputeSharedSecret ¶
func (data *EncryptionData) ComputeSharedSecret()
type EncryptionHandler ¶
type EncryptionHandler struct {
Data *EncryptionData
}
func NewEncryptionHandler ¶
func NewEncryptionHandler() *EncryptionHandler
func (*EncryptionHandler) ComputeSendChecksum ¶
func (handler *EncryptionHandler) ComputeSendChecksum(d []byte) []byte
type EncryptionHeader ¶
type EncryptionPayload ¶
type EncryptionPayload struct {
Token string `json:"salt"`
}
Click to show internal directories.
Click to hide internal directories.