|
Ring Daemon
|
#include <server_account_manager.h>


Classes | |
| struct | ServerAccountCredentials |
Public Member Functions | |
| bool | changePassword (const std::string &, const std::string &) override |
| void | initAuthentication (PrivateKey request, std::string deviceName, std::unique_ptr< AccountCredentials > credentials, AuthSuccessCallback onSuccess, AuthFailureCallback onFailure, const OnChangeCallback &onChange) override |
| void | onNeedsMigration (std::function< void()> cb) |
| void | registerName (const std::string &name, std::string_view scheme, const std::string &password, RegistrationCallback cb) override |
| bool | revokeDevice (const std::string &device, std::string_view scheme, const std::string &password, RevokeDeviceCallback cb) override |
| bool | searchUser (const std::string &query, SearchCallback cb) override |
| ServerAccountManager (const std::string &accountId, const std::filesystem::path &path, const std::string &managerHostname, const std::string &nameServer) | |
| void | syncBlueprintConfig (SyncBlueprintCallback onSuccess) |
| void | syncDevices () override |
Public Member Functions inherited from jami::AccountManager | |
| bool | acceptTrustRequest (const std::string &from, bool includeConversation=true) |
| AccountManager (const std::string &accountId, const std::filesystem::path &path, const std::string &nameServer) | |
| bool | addContact (const dht::InfoHash &uri, bool confirmed=false, const std::string &conversationId="") |
| Add contact to the account contact list. | |
| virtual int32_t | addDevice (const std::string &, std::string_view, AuthChannelHandler *) |
| Initiates the process of adding a new device to the account. | |
| CertRequest | buildRequest (PrivateKey fDeviceKey) |
| virtual bool | cancelAddDevice (uint32_t) |
| dhtnet::tls::CertificateStore & | certStore () const |
| virtual bool | confirmAddDevice (uint32_t) |
| bool | discardTrustRequest (const std::string &from) |
| virtual bool | findCertificate (const dht::InfoHash &h, std::function< void(const std::shared_ptr< dht::crypto::Certificate > &)> &&cb={}) |
| virtual bool | findCertificate (const dht::PkId &h, std::function< void(const std::shared_ptr< dht::crypto::Certificate > &)> &&cb={}) |
| void | forEachDevice (const dht::InfoHash &to, std::function< void(const std::shared_ptr< dht::crypto::PublicKey > &)> &&op, std::function< void(bool)> &&end={}) |
| bool | foundAccountDevice (const std::shared_ptr< dht::crypto::Certificate > &crt, const std::string &name={}, const time_point &last_sync=time_point::min()) |
| std::string | getAccountDeviceName () const |
| std::vector< std::string > | getCertificatesByStatus (dhtnet::tls::TrustStore::PermissionStatus status) |
| dhtnet::tls::TrustStore::PermissionStatus | getCertificateStatus (const std::string &cert_id) const |
| std::map< std::string, std::string > | getContactDetails (const std::string &uri) const |
| Obtain details about one account contact in serializable form. | |
| std::optional< Contact > | getContactInfo (const std::string &uri) const |
| std::map< dht::InfoHash, Contact > | getContacts (bool includeRemoved=false) const |
| const AccountInfo * | getInfo () const |
| const std::map< dht::PkId, KnownDevice > & | getKnownDevices () const |
| virtual std::vector< uint8_t > | getPasswordKey (const std::string &) |
| std::vector< std::map< std::string, std::string > > | getTrustRequests () const |
| bool | isAllowed (const crypto::Certificate &crt, bool allowPublic=false) |
| virtual bool | isPasswordValid (const std::string &) |
| dht::crypto::Identity | loadIdentity (const std::string &crt_path, const std::string &key_path, const std::string &key_pwd) const |
| virtual void | lookupAddress (const std::string &address, LookupCallback cb) |
| virtual void | lookupUri (const std::string &name, const std::string &defaultServer, LookupCallback cb) |
| bool | onPeerCertificate (const std::shared_ptr< dht::crypto::Certificate > &crt, bool allowPublic, dht::InfoHash &account_id) |
| void | onPeerMessage (const dht::crypto::PublicKey &peer_device, bool allowPublic, PeerCertificateCb &&cb) |
| virtual void | onSyncData (DeviceSync &&device, bool checkDevice=true) |
| void | reloadContacts () |
| void | removeContact (const std::string &uri, bool banned=true) |
| void | removeContactConversation (const std::string &uri) |
| void | sendTrustRequest (const std::string &to, const std::string &convId, const std::vector< uint8_t > &payload) |
| void | sendTrustRequestConfirm (const dht::InfoHash &to, const std::string &conversationId) |
| void | setAccountDeviceName (const std::string &name) |
| bool | setCertificateStatus (const std::shared_ptr< crypto::Certificate > &cert, dhtnet::tls::TrustStore::PermissionStatus status, bool local=true) |
| bool | setCertificateStatus (const std::string &cert_id, dhtnet::tls::TrustStore::PermissionStatus status) |
| void | setDht (const std::shared_ptr< dht::DhtRunner > &dht) |
| virtual void | startSync (const OnNewDeviceCb &cb, const OnDeviceAnnouncedCb &dcb, bool publishPresence=true) |
| void | updateContactConversation (const std::string &uri, const std::string &convId, bool added=false) |
| const AccountInfo * | useIdentity (const dht::crypto::Identity &id, const std::string &receipt, const std::vector< uint8_t > &receiptSignature, const std::string &username, const OnChangeCallback &onChange) |
| virtual | ~AccountManager () |
Additional Inherited Members | |
Static Public Member Functions inherited from jami::AccountManager | |
| static bool | foundPeerDevice (const std::string &accoundId, const std::shared_ptr< dht::crypto::Certificate > &crt, dht::InfoHash &account_id) |
| Inform that a potential peer device have been found. | |
| static std::shared_ptr< dht::Value > | parseAnnounce (const std::string &announceBase64, const std::string &accountId, const std::string &deviceSha1, const std::string &deviceSha256) |
Static Public Attributes inherited from jami::AccountManager | |
| static constexpr const char *const | DHT_TYPE_NS = "cx.ring" |
Protected Attributes inherited from jami::AccountManager | |
| const std::string | accountId_ |
| std::shared_ptr< dht::DhtRunner > | dht_ |
| std::unique_ptr< AccountInfo > | info_ |
| std::reference_wrapper< NameDirectory > | nameDir_ |
| OnChangeCallback | onChange_ |
| const std::filesystem::path | path_ |
Definition at line 27 of file server_account_manager.h.
| using jami::ServerAccountManager::SyncBlueprintCallback = std::function<void(const std::map<std::string, std::string>& config)> |
Definition at line 55 of file server_account_manager.h.
| jami::ServerAccountManager::ServerAccountManager | ( | const std::string & | accountId, |
| const std::filesystem::path & | path, | ||
| const std::string & | managerHostname, | ||
| const std::string & | nameServer | ||
| ) |
Definition at line 50 of file server_account_manager.cpp.
|
inlineoverridevirtual |
Implements jami::AccountManager.
Definition at line 48 of file server_account_manager.h.
|
overridevirtual |
Implements jami::AccountManager.
Definition at line 66 of file server_account_manager.cpp.
References jami::AccountManager::accountId_, jami::AccountManager::buildRequest(), jami::base64::decode(), libjami::Account::ConfProperties::DISPLAYNAME, jami::emitSignal(), jami::NameDirectory::instance(), jami::Manager::instance(), jami::AccountManager::INVALID_ARGUMENTS, JAMI_DEBUG, JAMI_ERROR, JAMI_WARNING, jami::AccountManager::NETWORK, jami::AccountManager::onChange_, jami::AccountManager::parseAnnounce(), jami::PATH_DEVICE, jami::AccountManager::SERVER_ERROR, and libjami::Account::ConfProperties::Nameserver::URI.

Definition at line 70 of file server_account_manager.h.
References jami::emitSignal().

|
overridevirtual |
Implements jami::AccountManager.
Definition at line 656 of file server_account_manager.cpp.
|
overridevirtual |
Reimplemented from jami::AccountManager.
Definition at line 614 of file server_account_manager.cpp.
References JAMI_DEBUG, JAMI_ERROR, JAMI_WARNING, and jami::PATH_DEVICE.
|
overridevirtual |
Reimplemented from jami::AccountManager.
Definition at line 665 of file server_account_manager.cpp.
References JAMI_DEBUG, JAMI_ERROR, JAMI_WARNING, and jami::PATH_SEARCH.
| void jami::ServerAccountManager::syncBlueprintConfig | ( | SyncBlueprintCallback | onSuccess | ) |
Definition at line 582 of file server_account_manager.cpp.
References JAMI_DEBUG, JAMI_ERROR, and jami::PATH_BLUEPRINT.
|
overridevirtual |
Implements jami::AccountManager.
Definition at line 389 of file server_account_manager.cpp.
References jami::SyncMsg::c, JAMI_DEBUG, JAMI_ERROR, JAMI_WARNING, jami::PATH_CONTACTS, jami::PATH_CONVERSATIONS, jami::PATH_CONVERSATIONS_REQUESTS, and jami::PATH_DEVICES.