Documentation ¶
Index ¶
- type Storage
- func (s *Storage) Decrypt(owner, id string, key []byte) ([]byte, error)
- func (s *Storage) Encrypt(user string, document, key []byte) (string, error)
- func (s *Storage) Exists(user, id string) bool
- func (s *Storage) Get(user string) map[string][]byte
- func (s *Storage) Getid(user, id string) []byte
- func (s *Storage) ListIds(user string) []string
- func (s *Storage) Reencrypt(owner string, oldkey, newkey []byte) error
- func (s *Storage) RemoveUser(user string)
- func (s *Storage) Rename(user, id, newid string)
- func (s *Storage) Save(user string, document []byte) string
- func (s *Storage) Saveid(user, id string, document []byte)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Storage ¶
type Storage struct {
// contains filtered or unexported fields
}
func (*Storage) Encrypt ¶
Encrypt encrypts and saves document to user's storage using key returns ehrID if there is no error. Otherwise returns error
func (*Storage) Reencrypt ¶
Reencrypt reencrypts the whole storage it does NOT upload the data to the api
func (*Storage) RemoveUser ¶
Click to show internal directories.
Click to hide internal directories.