Sailfish OS
  • Info
  • User Experience
  • Cases
  • Community
  • Developers
  • Contact
  • Get Sailfish OS
Select Page
  • Info
  • User Experience
  • Cases
  • Community
  • Developers
  • Contact
  • Get Sailfish OS

Sailfish Crypto

API Documentation
  • API Documentation
  • Libsailfishapp
  • Sailfish Silica
    • Documentation
    • Icon Reference
  • Sailfish Components
    • Sailfish Accounts
    • Sailfish Bluetooth
    • Sailfish Contacts
    • Sailfish Crypto
    • Sailfish Gallery
    • Sailfish Media
    • Sailfish Pickers
    • Sailfish Secrets
    • Sailfish Share
    • Sailfish Telephony
    • Sailfish Webview
    • Amber Web Authorization
    • Amber MPRIS
  • Nemo QML Plugins
    • Configuration
    • Contacts
    • D-Bus
    • Keepalive
    • Notifications
    • Thumbnailer
  • Sailfish Middleware
    • MDM Framework
    • MDM Policy Framework
    • User Manager Daemon
  • API Documentation
  • Libsailfishapp
  • Sailfish Silica
    • Documentation
    • Icon Reference
  • Sailfish Components
    • Sailfish Accounts
    • Sailfish Bluetooth
    • Sailfish Contacts
    • Sailfish Crypto
    • Sailfish Gallery
    • Sailfish Media
    • Sailfish Pickers
    • Sailfish Secrets
    • Sailfish Share
    • Sailfish Telephony
    • Sailfish Webview
    • Amber Web Authorization
    • Amber MPRIS
  • Nemo QML Plugins
    • Configuration
    • Contacts
    • D-Bus
    • Keepalive
    • Notifications
    • Thumbnailer
  • Sailfish Middleware
    • MDM Framework
    • MDM Policy Framework
    • User Manager Daemon

Contents

  • Public Functions
  • Detailed Description

Identifier Class

(Sailfish::Crypto::Key::Identifier)

An identifier for a key More...

Header: #include <Crypto/key.h>
  • List of all members, including inherited members

Public Functions

Identifier()
Identifier(const QString &name, const QString &collectionName, const QString &storagePluginName)
Identifier(const Sailfish::Crypto::Key::Identifier &other)
~Identifier()
QString collectionName() const
bool isValid() const
QString name() const
void setCollectionName(const QString &collectionName)
void setName(const QString &name)
void setStoragePluginName(const QString &storagePluginName)
QString storagePluginName() const
Identifier &operator=(const Sailfish::Crypto::Key::Identifier &other)

Detailed Description

An identifier for a key

The identifier consists of the name (alias) of the key, along with the name of the collection in which the key is stored (note that the collection name can be empty if the key is stored as a standalone secret) and the plugin which stores that collection.

Together, the key name, collection name and storage plugin name uniquely identify the key as a specific secret in the secrets storage.

Member Function Documentation

Identifier::Identifier()

Constructs a new, empty identifier

Identifier::Identifier(const QString &name, const QString &collectionName, const QString &storagePluginName)

Constructs a new identifier from the given key name, collectionName and storagePluginName

Identifier::Identifier(const Sailfish::Crypto::Key::Identifier &other)

Copy constructor.

Identifier::~Identifier()

Destroys the identifier

QString Identifier::collectionName() const

Returns the collection name from the identifier

See also setCollectionName().

bool Identifier::isValid() const

Returns true if the key identifier consists of valid, non-empty components

Note that this doesn't mean that the identifier does in fact identify a valid key stored by the system secrets service; rather, it means that if a key with the name() specified in this identifier is stored in a collection with the collectionName() specified in this identifier by the storage (or crypto storage) plugin identified by the storagePluginName() specified in this identifier, then this identifier would identify it.

That is, if either name() or collectionName() or storagePluginName() is empty, the identifier is not considered valid.

QString Identifier::name() const

Returns the key name from the identifier

See also setName().

void Identifier::setCollectionName(const QString &collectionName)

Sets the collection name in the identifier to collectionName

See also collectionName().

void Identifier::setName(const QString &name)

Sets the key name in the identifier to name

See also name().

void Identifier::setStoragePluginName(const QString &storagePluginName)

Sets the storage plugin name in the identifier to storagePluginName

See also storagePluginName().

QString Identifier::storagePluginName() const

Returns the storage plugin name from the identifier

See also setStoragePluginName().

Identifier &Identifier::operator=(const Sailfish::Crypto::Key::Identifier &other)

Copy-assignment operator.

  • Legal
  • Contact Us
  • Jollyboys Ltd © 2024

  • Facebook
  • Twitter
  • Mastodon
  • YouTube
  • LinkedIn