5#ifndef AUTHENTICATIONREALM_H
6#define AUTHENTICATIONREALM_H
8#include <Cutelyst/Plugins/Authentication/authenticationuser.h>
9#include <Cutelyst/component.h>
43 std::shared_ptr<AuthenticationCredential>
credential,
51 [[nodiscard]] std::shared_ptr<AuthenticationStore>
store() const noexcept;
91 friend class Authentication;
92 friend class AuthenticationPrivate;
Abstract class to validate authentication credentials like user name and password.
std::shared_ptr< AuthenticationCredential > credential() const noexcept
std::shared_ptr< AuthenticationStore > store() const noexcept
void removePersistedUser(Context *c)
virtual AuthenticationUser authenticate(Context *c, const ParamsMultiMap &authinfo)
static char * defaultRealm
QVariant userIsRestorable(Context *c)
AuthenticationRealm(std::shared_ptr< AuthenticationStore > store, std::shared_ptr< AuthenticationCredential > credential, const QString &name=QLatin1String(defaultRealm), QObject *parent=nullptr)
AuthenticationUser persistUser(Context *c, const AuthenticationUser &user)
virtual AuthenticationUser findUser(Context *c, const ParamsMultiMap &userinfo)
AuthenticationUser restoreUser(Context *c, const QVariant &frozenUser)
Abstract class to retrieve user data from a store.
Container for user data retrieved from an AuthenticationStore.
Component(QObject *parent=nullptr)
QString name() const noexcept
QMultiMap< QString, QString > ParamsMultiMap
The Cutelyst namespace holds all public Cutelyst API.
QObject * parent() const const