2019-05-15 14:57:35 +02:00
|
|
|
// Package models provides structs containing message data.
|
2018-09-11 11:09:28 +02:00
|
|
|
package models
|
|
|
|
|
|
2019-05-15 14:57:35 +02:00
|
|
|
// EncryptedSplit contains a separate session key packet and symmetrically
|
|
|
|
|
// encrypted data packet.
|
2018-09-11 11:09:28 +02:00
|
|
|
type EncryptedSplit struct {
|
|
|
|
|
DataPacket []byte
|
|
|
|
|
KeyPacket []byte
|
|
|
|
|
Algo string
|
|
|
|
|
}
|
|
|
|
|
|
2019-05-15 14:57:35 +02:00
|
|
|
// EncryptedSigned contains an encrypted message and signature.
|
2018-09-11 11:09:28 +02:00
|
|
|
type EncryptedSigned struct {
|
|
|
|
|
Encrypted string
|
|
|
|
|
Signature string
|
|
|
|
|
}
|
|
|
|
|
|
2019-05-15 14:57:35 +02:00
|
|
|
// DecryptSignedVerify contains a decrypted message and verification result.
|
2018-09-11 11:09:28 +02:00
|
|
|
type DecryptSignedVerify struct {
|
|
|
|
|
//clear text
|
|
|
|
|
Plaintext string
|
|
|
|
|
//bitmask verify status : 0
|
|
|
|
|
Verify int
|
|
|
|
|
//error message if verify failed
|
|
|
|
|
Message string
|
|
|
|
|
}
|