libnick 2024.9.2
A cross-platform base for native Nickvision applications.
Loading...
Searching...
No Matches
systemcredentials.h
Go to the documentation of this file.
1
23#ifndef SYSTEMCREDENTIALS_H
24#define SYSTEMCREDENTIALS_H
25
26#include <optional>
27#include <string>
28#include "credential.h"
29
31{
37 std::optional<Credential> getCredential(const std::string& name);
43 std::optional<Credential> addCredential(const std::string& name);
52 bool addCredential(const Credential& credential);
61 bool updateCredential(const Credential& credential);
67 bool deleteCredential(const std::string& name);
68}
69
70#endif //SYSTEMCREDENTIALS_H
A model of a credential stored in a keyring.
Definition credential.h:35
Definition systemcredentials.h:31
std::optional< Credential > addCredential(const std::string &name)
Adds a new credential with a random password to the system's credential manager.
std::optional< Credential > getCredential(const std::string &name)
Gets a credential from the system's credential manager.
bool deleteCredential(const std::string &name)
Deletes a credential from the system's credential manager.
bool updateCredential(const Credential &credential)
Updates a credential in the system's credential manager.