PolkitQt-1
polkitqt1-authority.cpp
85 void setError(Authority::ErrorCode code, const QString &details = QString(), bool recover = false);
88 void dbusSignalAdd(const QString &service, const QString &path, const QString &interface, const QString &name);
121 static void checkAuthorizationCallback(GObject *object, GAsyncResult *result, gpointer user_data);
122 static void enumerateActionsCallback(GObject *object, GAsyncResult *result, gpointer user_data);
123 static void registerAuthenticationAgentCallback(GObject *object, GAsyncResult *result, gpointer user_data);
124 static void unregisterAuthenticationAgentCallback(GObject *object, GAsyncResult *result, gpointer user_data);
125 static void authenticationAgentResponseCallback(GObject *object, GAsyncResult *result, gpointer user_data);
126 static void enumerateTemporaryAuthorizationsCallback(GObject *object, GAsyncResult *result, gpointer user_data);
127 static void revokeTemporaryAuthorizationsCallback(GObject *object, GAsyncResult *result, gpointer user_data);
128 static void revokeTemporaryAuthorizationCallback(GObject *object, GAsyncResult *result, gpointer user_data);
221 dbusSignalAdd(consoleKitService, consoleKitManagerPath, consoleKitManagerInterface, "SeatAdded");
222 dbusSignalAdd(consoleKitService, consoleKitManagerPath, consoleKitManagerInterface, "SeatRemoved");
225 QDBusMessage msg = QDBusMessage::createMethodCall(consoleKitService, consoleKitManagerPath, consoleKitManagerInterface, "GetSeats");
244void Authority::Private::setError(Authority::ErrorCode code, const QString &details, bool recover)
266void Authority::Private::dbusSignalAdd(const QString &service, const QString &path, const QString &interface, const QString &name)
336Authority::Result Authority::checkAuthorizationSyncWithDetails(const QString &actionId, const Subject &subject, AuthorizationFlags flags, const DetailsMap &details)
380Authority::Result Authority::checkAuthorizationSync(const QString &actionId, const Subject &subject, AuthorizationFlags flags)
385void Authority::checkAuthorizationWithDetails(const QString &actionId, const Subject &subject, AuthorizationFlags flags, const DetailsMap &details)
411void Authority::checkAuthorization(const QString &actionId, const Subject &subject, AuthorizationFlags flags)
416void Authority::Private::checkAuthorizationCallback(GObject *object, GAsyncResult *result, gpointer user_data)
423 PolkitAuthorizationResult *pkResult = polkit_authority_check_authorization_finish((PolkitAuthority *) object, result, &error);
481void Authority::Private::enumerateActionsCallback(GObject *object, GAsyncResult *result, gpointer user_data)
486 GList *list = polkit_authority_enumerate_actions_finish((PolkitAuthority *) object, result, &error);
506bool Authority::registerAuthenticationAgentSync(const Subject &subject, const QString &locale, const QString &objectPath)
533void Authority::registerAuthenticationAgent(const Subject &subject, const QString &locale, const QString &objectPath)
553void Authority::Private::registerAuthenticationAgentCallback(GObject *object, GAsyncResult *result, gpointer user_data)
558 bool res = polkit_authority_register_authentication_agent_finish((PolkitAuthority *) object, result, &error);
578bool Authority::unregisterAuthenticationAgentSync(const Subject &subject, const QString &objectPath)
625void Authority::Private::unregisterAuthenticationAgentCallback(GObject *object, GAsyncResult *result, gpointer user_data)
630 bool res = polkit_authority_unregister_authentication_agent_finish((PolkitAuthority *) object, result, &error);
696void Authority::Private::authenticationAgentResponseCallback(GObject *object, GAsyncResult *result, gpointer user_data)
701 bool res = polkit_authority_authentication_agent_response_finish((PolkitAuthority *) object, result, &error);
747void Authority::Private::enumerateTemporaryAuthorizationsCallback(GObject *object, GAsyncResult *result, gpointer user_data)
753 GList *glist = polkit_authority_enumerate_temporary_authorizations_finish((PolkitAuthority *) object, result, &error);
815void Authority::Private::revokeTemporaryAuthorizationsCallback(GObject *object, GAsyncResult *result, gpointer user_data)
821 bool res = polkit_authority_revoke_temporary_authorizations_finish((PolkitAuthority *) object, result, &error);
875void Authority::Private::revokeTemporaryAuthorizationCallback(GObject *object, GAsyncResult *result, gpointer user_data)
881 bool res = polkit_authority_revoke_temporary_authorization_by_id_finish((PolkitAuthority *) object, result, &error);
bool authenticationAgentResponseSync(const QString &cookie, const PolkitQt1::Identity &identity)
Provide response that identity successfully authenticated for the authentication request identified b...
Definition polkitqt1-authority.cpp:650
bool unregisterAuthenticationAgentSync(const Subject &subject, const QString &objectPath)
Unregisters an Authentication agent.
Definition polkitqt1-authority.cpp:578
@ Challenge
The subject is authorized if more information is provided.
Definition polkitqt1-authority.h:68
TemporaryAuthorization::List enumerateTemporaryAuthorizationsSync(const Subject &subject)
Retrieves all temporary action that applies to subject.
Definition polkitqt1-authority.cpp:721
void authenticationAgentResponse(const QString &cookie, const Identity &identity)
Provide response that identity successfully authenticated for the authentication request identified b...
Definition polkitqt1-authority.cpp:677
void unregisterAuthenticationAgent(const Subject &subject, const QString &objectPath)
Unregisters an Authentication agent.
Definition polkitqt1-authority.cpp:606
void unregisterAuthenticationAgentCancel()
This method can be used to cancel the unregistration of the authentication agent.
Definition polkitqt1-authority.cpp:643
void registerAuthenticationAgentFinished(bool)
This signal is emitted when asynchronous method registerAuthenticationAgent finishes.
void registerAuthenticationAgentCancel()
This method can be used to cancel the registration of the authentication agent.
Definition polkitqt1-authority.cpp:571
Result checkAuthorizationSyncWithDetails(const QString &actionId, const Subject &subject, AuthorizationFlags flags, const DetailsMap &details)
This function does the same as checkAuthorizationSync(const QString&,const Subject&,...
Definition polkitqt1-authority.cpp:336
void revokeTemporaryAuthorizationsFinished(bool)
This signal is emitted when asynchronous method revokeTemporaryAuthorizations finishes.
PolkitAuthority * polkitAuthority() const
Returns the current instance of PolkitAuthority.
Definition polkitqt1-authority.cpp:331
bool revokeTemporaryAuthorizationSync(const QString &id)
Revokes temporary authorization by id.
Definition polkitqt1-authority.cpp:842
void enumerateActionsCancel()
This method can be used to cancel enumeration of actions.
Definition polkitqt1-authority.cpp:499
void enumerateActions()
Asynchronously retrieves all registered actions.
Definition polkitqt1-authority.cpp:469
void configChanged()
This signal will be emitted when a configuration file gets changed (e.g.
void checkAuthorizationCancel()
This method can be used to cancel last authorization check.
Definition polkitqt1-authority.cpp:441
Result checkAuthorizationSync(const QString &actionId, const Subject &subject, AuthorizationFlags flags)
Synchronous version of the checkAuthorization method.
Definition polkitqt1-authority.cpp:380
void revokeTemporaryAuthorizationCancel()
This method can be used to cancel the method revokeTemporaryAuthorizationAsync.
Definition polkitqt1-authority.cpp:895
void enumerateTemporaryAuthorizationsFinished(PolkitQt1::TemporaryAuthorization::List)
This signal is emitted when asynchronous method enumerateTemporaryAuthorizations finishes.
static Authority * instance(PolkitAuthority *authority=nullptr)
Returns the instance of Authority.
Definition polkitqt1-authority.cpp:34
void unregisterAuthenticationAgentFinished(bool)
This signal is emitted when asynchronous method unregisterAuthenticationAgent finishes.
const QString errorDetails() const
Get detail information about error that occurred.
Definition polkitqt1-authority.cpp:294
void enumerateActionsFinished(PolkitQt1::ActionDescription::List)
This signal is emitted when asynchronous method enumerateActions finishes.
void revokeTemporaryAuthorizationFinished(bool)
This signal is emitted when asynchronous method revokeTemporaryAuthorization finishes.
void checkAuthorizationWithDetails(const QString &actionId, const Subject &subject, AuthorizationFlags flags, const DetailsMap &details)
This function does the same as checkAuthorization(const QString&, constSubject&, AuthorizationFlags),...
Definition polkitqt1-authority.cpp:385
bool revokeTemporaryAuthorizationsSync(const Subject &subject)
Revokes all temporary authorizations that applies to subject.
Definition polkitqt1-authority.cpp:782
void revokeTemporaryAuthorizationsCancel()
This method can be used to cancel the method revokeTemporaryAuthorizationsAsync.
Definition polkitqt1-authority.cpp:835
void checkAuthorization(const QString &actionId, const Subject &subject, AuthorizationFlags flags)
This function should be used by mechanisms (e.g.: helper applications).
Definition polkitqt1-authority.cpp:411
void revokeTemporaryAuthorization(const QString &id)
Revokes temporary authorization by id.
Definition polkitqt1-authority.cpp:862
void authenticationAgentResponseFinished(bool)
This signal is emitted when asynchronous method authenticationAgentResponse finishes.
void authenticationAgentResponseCancel()
This method can be used to cancel the authenticationAgentResponseAsync method.
Definition polkitqt1-authority.cpp:714
void registerAuthenticationAgent(const Subject &subject, const QString &locale, const QString &objectPath)
Registers an authentication agent.
Definition polkitqt1-authority.cpp:533
bool hasError() const
You should always call this method after every action.
Definition polkitqt1-authority.cpp:284
void revokeTemporaryAuthorizations(const Subject &subject)
Revokes all temporary authorizations that applies to subject.
Definition polkitqt1-authority.cpp:802
void enumerateTemporaryAuthorizationsCancel()
This method can be used to cancel the enumerateTemporaryAuthorizationsAsync method.
Definition polkitqt1-authority.cpp:775
@ E_CookieOrIdentityEmpty
Cookie or polkitqt1-identity.handled to the action is empty.
Definition polkitqt1-authority.h:103
@ E_UnregisterFailed
Unregistration of authentication agent failed.
Definition polkitqt1-authority.h:101
void checkAuthorizationFinished(PolkitQt1::Authority::Result)
This signal is emitted when asynchronous method checkAuthorization finishes.
ActionDescription::List enumerateActionsSync()
Synchronously retrieves all registered actions.
Definition polkitqt1-authority.cpp:448
bool registerAuthenticationAgentSync(const Subject &subject, const QString &locale, const QString &objectPath)
Registers an authentication agent.
Definition polkitqt1-authority.cpp:506
This class represents PolicyKit temporary authorization.
Definition polkitqt1-temporaryauthorization.h:39
void init(KXmlGuiWindow *window, KGameDifficulty *difficulty=nullptr)
void error(QWidget *parent, const QString &text, const QString &title, const KGuiItem &buttonOk, Options options=Notify)
char * data()
SystemBus
QDBusMessage call(const QDBusMessage &message, QDBus::CallMode mode, int timeout) const const
QDBusConnection connectToBus(BusType type, const QString &name)
ErrorMessage
QList< QVariant > arguments() const const
QDBusMessage createMethodCall(const QString &service, const QString &path, const QString &interface, const QString &method)
QString member() const const
MessageType type() const const
QString path() const const
void append(QList< T > &&value)
bool empty() const const
std::map< Key, T > toStdMap() &&
Q_EMITQ_EMIT
QObject * parent() const const
bool isEmpty() const const
QByteArray toLatin1() const const
QByteArray toUtf8() const const
Type type() const const
QStringList toStringList() const const
T value() const const
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 29 2024 11:47:59 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2024 The KDE developers.
Generated on Fri Nov 29 2024 11:47:59 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.