Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Post ¶
type Post struct { Author User `json:"author" msgpack:"author"` Salt []byte `json:"salt" msgpack:"salt"` CW string `json:"cw" msgpack:"cw"` Body string `json:"body" msgpack:"body"` Created time.Time `json:"created" msgpack:"created"` LastUpdated time.Time `json:"last_updated" msgpack:"last_updated"` }
type SignatureKey ¶
type SignatureKey struct { PrivateKey *rsa.PrivateKey // !!! THIS CAN BE A NIL POINTER, BE CAREFUL !!! PublicKey *rsa.PublicKey }
func CreateSignatureKey ¶
func CreateSignatureKey() (*SignatureKey, error)
func LoadKeypair ¶
func LoadKeypair(privateKeyData string) (*SignatureKey, error)
func (*SignatureKey) Export ¶
func (s *SignatureKey) Export() (string, error)
func (SignatureKey) GetID ¶
func (k SignatureKey) GetID() string
func (SignatureKey) MarshalJSON ¶
func (k SignatureKey) MarshalJSON() ([]byte, error)
func (*SignatureKey) UnmarshalJSON ¶
func (k *SignatureKey) UnmarshalJSON([]byte) error
type User ¶
type User struct { DisplayName string `json:"display_name" msgpack:"display_name"` Description string `json:"description" msgpack:"description"` SignatureKey any `json:"signature_key" msgpack:"signature_key"` Mailboxes []Mailbox `json:"mailboxes" msgpack:"mailboxes"` Created time.Time `json:"created" msgpack:"created"` LastUpdated time.Time `json:"last_updated" msgpack:"last_updated"` }
func CreateUser ¶
Click to show internal directories.
Click to hide internal directories.