diff --git a/src/api/KWallet/kwallet.h b/src/api/KWallet/kwallet.h index 837be3e..2b56123 100644 --- a/src/api/KWallet/kwallet.h +++ b/src/api/KWallet/kwallet.h @@ -1,559 +1,559 @@ /* This file is part of the KDE project * * Copyright (C) 2002-2004 George Staikos * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Library General Public * License as published by the Free Software Foundation; either * version 2 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Library General Public License for more details. * * You should have received a copy of the GNU Library General Public License * along with this library; see the file COPYING.LIB. If not, write to * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, * Boston, MA 02110-1301, USA. */ #ifndef _KWALLET_H #define _KWALLET_H #include #include #include // krazy:exclude=includes (for WId) #include /** * NOTE: KSecretsService folder semantics * The KWallet API uses folders for organising items. KSecretsService does not * have this notion. But it uses attributes that can be applied arbitrarily on * all the items. The KWallet code that maps to KSecretsService applies an special * attribute KSS_ATTR_ENTRYFOLDER to all items with the currentFolder() value. * The KWallet folder API's calls will always succeed and they'll only change the * current folder value. The folderList() call will scan all the collection * items and collect the KSS_ATTR_ENTRYFOLDER attributes into a list. */ /** * NOTE: KWalet API distinguish KSecretsService collection items by attaching * them some specific attributes, defined below */ #define KSS_ATTR_ENTRYFOLDER "kwallet.folderName" #define KSS_ATTR_WALLETTYPE "kwallet.type" namespace KWallet { /** * KDE Wallet * * This class implements a generic system-wide Wallet for KDE. This is the * ONLY public interface. * * @author George Staikos * @short KDE Wallet Class */ class KWALLET_EXPORT Wallet : public QObject { Q_OBJECT protected: /** * Construct a KWallet object. * @internal * @param handle The handle for the wallet. * @param name The name of the wallet. */ Wallet(int handle, const QString &name); /** * Copy a KWallet object. * @internal */ Wallet(const Wallet &); public: enum EntryType { Unknown = 0, Password, Stream, Map, Unused = 0xffff }; /** * Destroy a KWallet object. Closes the wallet. */ - virtual ~Wallet(); + ~Wallet() override; /** * List all the wallets available. * @return Returns a list of the names of all wallets that are * open. */ static QStringList walletList(); /** * Determine if the KDE wallet is enabled. Normally you do * not need to use this because openWallet() will just fail. * @return Returns true if the wallet enabled, else false. */ static bool isEnabled(); /** * Determine if the wallet @p name is open by any application. * @param name The name of the wallet to check. * @return Returns true if the wallet is open, else false. */ static bool isOpen(const QString &name); /** * Close the wallet @p name. The wallet will only be closed * if it is open but not in use (rare), or if it is forced * closed. * @param name The name of the wallet to close. * @param force Set true to force the wallet closed even if it * is in use by others. * @return Returns 0 on success, non-zero on error. */ static int closeWallet(const QString &name, bool force); /** * Delete the wallet @p name. The wallet will be forced closed * first. * @param name The name of the wallet to delete. * @return Returns 0 on success, non-zero on error. */ static int deleteWallet(const QString &name); /** * Disconnect the application @p app from @p wallet. * @param wallet The name of the wallet to disconnect. * @param app The name of the application to disconnect. * @return Returns true on success, false on error. */ static bool disconnectApplication(const QString &wallet, const QString &app); enum OpenType { Synchronous = 0, Asynchronous, Path, OpenTypeUnused = 0xff }; /** * Open the wallet @p name. The user will be prompted to * allow your application to open the wallet, and may be * prompted for a password. You are responsible for deleting * this object when you are done with it. * @param name The name of the wallet to open. * @param ot If Asynchronous, the call will return * immediately with a non-null pointer to an * invalid wallet. You must immediately connect * the walletOpened() signal to a slot so that * you will know when it is opened, or when it * fails. * @param w The window id to associate any dialogs with. You can pass * 0 if you don't have a window the password dialog should * associate with. * @return Returns a pointer to the wallet if successful, * or a null pointer on error or if rejected. * A null pointer can also be returned if user choose to * deactivate the wallet system. */ static Wallet *openWallet(const QString &name, WId w, OpenType ot = Synchronous); /** * List the applications that are using the wallet @p wallet. * @param wallet The wallet to query. * @return Returns a list of all DCOP application IDs using * the wallet. */ static QStringList users(const QString &wallet); /** * The name of the wallet used to store local passwords. */ static const QString LocalWallet(); /** * The name of the wallet used to store network passwords. */ static const QString NetworkWallet(); /** * The standardized name of the password folder. * It is automatically created when a wallet is created, but * the user may still delete it so you should check for its * existence and recreate it if necessary and desired. */ static const QString PasswordFolder(); /** * The standardized name of the form data folder. * It is automatically created when a wallet is created, but * the user may still delete it so you should check for its * existence and recreate it if necessary and desired. */ static const QString FormDataFolder(); /** * Request to the wallet service to change the password of * the wallet @p name. * @param name The wallet to change the password of. * @param w The window id to associate any dialogs with. You can pass * 0 if you don't have a window the password dialog should * associate with. */ static void changePassword(const QString &name, WId w); /** * This syncs the wallet file on disk with what is in memory. * You don't normally need to use this. It happens * automatically on close. * @return Returns 0 on success, non-zero on error. */ virtual int sync(); /** * This closes and locks the current wallet. It will * disconnect all applications using the wallet. * @return Returns 0 on success, non-zero on error. */ virtual int lockWallet(); /** * The name of the current wallet. */ virtual const QString &walletName() const; /** * Determine if the current wallet is open, and is a valid * wallet handle. * @return Returns true if the wallet handle is valid and open. */ virtual bool isOpen() const; /** * Request to the wallet service to change the password of * the current wallet. * @param w The window id to associate any dialogs with. You can pass * 0 if you don't have a window the password dialog should * associate with. */ virtual void requestChangePassword(WId w); /** * Obtain the list of all folders contained in the wallet. * @return Returns an empty list if the wallet is not open. */ virtual QStringList folderList(); /** * Determine if the folder @p f exists in the wallet. * @param f the name of the folder to check for * @return Returns true if the folder exists in the wallet. */ virtual bool hasFolder(const QString &f); /** * Set the current working folder to @p f. The folder must * exist, or this call will fail. Create a folder with * createFolder(). * @param f the name of the folder to make the working folder * @return Returns true if the folder was successfully set. */ virtual bool setFolder(const QString &f); /** * Remove the folder @p f and all its entries from the wallet. * @param f the name of the folder to remove * @return Returns true if the folder was successfully removed. */ virtual bool removeFolder(const QString &f); /** * Created the folder @p f. * @param f the name of the folder to create * @return Returns true if the folder was successfully created. */ virtual bool createFolder(const QString &f); /** * Determine the current working folder in the wallet. * If the folder name is empty, it is working in the global * folder, which is valid but discouraged. * @return Returns the current working folder. */ virtual const QString ¤tFolder() const; /** * Return the list of keys of all entries in this folder. * @return Returns an empty list if the wallet is not open, or * if the folder is empty. */ virtual QStringList entryList(); // TODO KDE5: a entryList(folder) so that kwalletmanager can list a folder without // having to call setFolder before and after (which calls contains() in each) /** * Rename the entry @p oldName to @p newName. * @param oldName The original key of the entry. * @param newName The new key of the entry. * @return Returns 0 on success, non-zero on error. */ virtual int renameEntry(const QString &oldName, const QString &newName); /** * Read the entry @p key from the current folder. * The entry format is unknown except that it is either a * QByteArray or a QDataStream, which effectively means that * it is anything. * @param key The key of the entry to read. * @param value A buffer to fill with the value. * @return Returns 0 on success, non-zero on error. */ virtual int readEntry(const QString &key, QByteArray &value); /** * Read the map entry @p key from the current folder. * @param key The key of the entry to read. * @param value A map buffer to fill with the value. * @return Returns 0 on success, non-zero on error. Will * return an error if the key was not originally * written as a map. */ virtual int readMap(const QString &key, QMap &value); /** * Read the password entry @p key from the current folder. * @param key The key of the entry to read. * @param value A password buffer to fill with the value. * @return Returns 0 on success, non-zero on error. Will * return an error if the key was not originally * written as a password. */ virtual int readPassword(const QString &key, QString &value); /** * Read the entries matching @p key from the current folder. * The entry format is unknown except that it is either a * QByteArray or a QDataStream, which effectively means that * it is anything. * @param key The key of the entry to read. Wildcards * are supported. * @param value A buffer to fill with the value. The key in * the map is the entry key. * @return Returns 0 on success, non-zero on error. */ int readEntryList(const QString &key, QMap &value); /** * Read the map entry @p key from the current folder. * @param key The key of the entry to read. Wildcards * are supported. * @param value A buffer to fill with the value. The key in * the map is the entry key. * @return Returns 0 on success, non-zero on error. Will * return an error if the key was not originally * written as a map. */ int readMapList(const QString &key, QMap > &value); /** * Read the password entry @p key from the current folder. * @param key The key of the entry to read. Wildcards * are supported. * @param value A buffer to fill with the value. The key in * the map is the entry key. * @return Returns 0 on success, non-zero on error. Will * return an error if the key was not originally * written as a password. */ int readPasswordList(const QString &key, QMap &value); /** * Write @p key = @p value as a binary entry to the current * folder. Be careful with this, it could cause inconsistency * in the future since you can put an arbitrary entry type in * place. * @param key The key of the new entry. * @param value The value of the entry. * @param entryType The type of the entry. * @return Returns 0 on success, non-zero on error. */ virtual int writeEntry(const QString &key, const QByteArray &value, EntryType entryType); /** * Write @p key = @p value as a binary entry to the current * folder. * @param key The key of the new entry. * @param value The value of the entry. * @return Returns 0 on success, non-zero on error. */ virtual int writeEntry(const QString &key, const QByteArray &value); /** * Write @p key = @p value as a map to the current folder. * @param key The key of the new entry. * @param value The value of the map. * @return Returns 0 on success, non-zero on error. */ virtual int writeMap(const QString &key, const QMap &value); /** * Write @p key = @p value as a password to the current folder. * @param key The key of the new entry. * @param value The value of the password. * @return Returns 0 on success, non-zero on error. */ virtual int writePassword(const QString &key, const QString &value); /** * Determine if the current folder has they entry @p key. * @param key The key to search for. * @return Returns true if the folder contains @p key. */ virtual bool hasEntry(const QString &key); /** * Remove the entry @p key from the current folder. * @param key The key to remove. * @return Returns 0 on success, non-zero on error. */ virtual int removeEntry(const QString &key); /** * Determine the type of the entry @p key in this folder. * @param key The key to look up. * @return Returns an enumerated type representing the type * of the entry. */ virtual EntryType entryType(const QString &key); /** * Determine if a folder does not exist in a wallet. This * does not require decryption of the wallet. * This is a handy optimization to avoid prompting the user * if your data is certainly not in the wallet. * @param wallet The wallet to look in. * @param folder The folder to look up. * @return Returns true if the folder does NOT exist in the * wallet, or the wallet does not exist. */ static bool folderDoesNotExist(const QString &wallet, const QString &folder); /** * Determine if an entry in a folder does not exist in a * wallet. This does not require decryption of the wallet. * This is a handy optimization to avoid prompting the user * if your data is certainly not in the wallet. * @param wallet The wallet to look in. * @param folder The folder to look in. * @param key The key to look up. * @return Returns true if the key does NOT exist in the * wallet, or the folder or wallet does not exist. */ static bool keyDoesNotExist(const QString &wallet, const QString &folder, const QString &key); /** * Determine if the KWallet API is using the KSecretsService infrastructure * This can ben changed in system settings * @return Returns true if the KSecretsService infrastructure is active */ static bool isUsingKSecretsService(); Q_SIGNALS: /** * Emitted when this wallet is closed. */ void walletClosed(); /** * Emitted when a folder in this wallet is updated. * @param folder The folder that was updated. */ void folderUpdated(const QString &folder); /** * Emitted when the folder list is changed in this wallet. */ void folderListUpdated(); /** * Emitted when a folder in this wallet is removed. * @param folder The folder that was removed. */ void folderRemoved(const QString &folder); /** * Emitted when a wallet is opened in asynchronous mode. * @param success True if the wallet was opened successfully. */ void walletOpened(bool success); private Q_SLOTS: /** * @internal * D-Bus slot for signals emitted by the wallet service. */ void slotWalletClosed(int handle); /** * @internal * D-Bus slot for signals emitted by the wallet service. */ void slotFolderUpdated(const QString &wallet, const QString &folder); /** * @internal * D-Bus slot for signals emitted by the wallet service. */ void slotFolderListUpdated(const QString &wallet); /** * @internal * D-Bus slot for signals emitted by the wallet service. */ void slotApplicationDisconnected(const QString &wallet, const QString &application); /** * @internal * Callback for kwalletd * @param tId identifer for the open transaction * @param handle the wallet's handle */ void walletAsyncOpened(int tId, int handle); /** * @internal * D-Bus error slot. */ void emitWalletAsyncOpenError(); /** * @internal * Emits wallet opening success. */ void emitWalletOpened(); /** * @internal * Receives status changed notifications from KSecretsService infrastructure */ void slotCollectionStatusChanged(int); /** * @internal * Received delete notification from KSecretsService infrastructure */ void slotCollectionDeleted(); private: class WalletPrivate; WalletPrivate *const d; Q_PRIVATE_SLOT(d, void walletServiceUnregistered()) protected: /** * @internal */ virtual void virtual_hook(int id, void *data); }; } #endif //_KWALLET_H diff --git a/src/runtime/kwalletd/backend/blowfish.h b/src/runtime/kwalletd/backend/blowfish.h index d23dc1c..7f7c0e8 100644 --- a/src/runtime/kwalletd/backend/blowfish.h +++ b/src/runtime/kwalletd/backend/blowfish.h @@ -1,72 +1,72 @@ /* This file is part of the KDE project Copyright (C) 2001 George Staikos This library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more details. You should have received a copy of the GNU Library General Public License along with this library; see the file COPYING.LIB. If not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ #ifndef _BLOWFISH_H #define _BLOWFISH_H #include #ifdef HAVE_STDINT_H #include #endif #include #ifdef HAVE_SYS_BITYPES_H #include /* For uintXX_t on Tru64 */ #endif #include "blockcipher.h" #include "kwalletbackend5_export.h" /* @internal */ class KWALLETBACKEND5_EXPORT BlowFish : public BlockCipher { public: BlowFish(); - virtual ~BlowFish(); + ~BlowFish() override; - virtual bool setKey(void *key, int bitlength); + bool setKey(void *key, int bitlength) override; - virtual int keyLen() const; + int keyLen() const override; - virtual bool variableKeyLen() const; + bool variableKeyLen() const override; - virtual bool readyToGo() const; + bool readyToGo() const override; - virtual int encrypt(void *block, int len); + int encrypt(void *block, int len) override; - virtual int decrypt(void *block, int len); + int decrypt(void *block, int len) override; private: uint32_t _S[4][256]; uint32_t _P[18]; void *_key; int _keylen; // in bits bool _init; bool init(); uint32_t F(uint32_t x); void encipher(uint32_t *xl, uint32_t *xr); void decipher(uint32_t *xl, uint32_t *xr); }; #endif diff --git a/src/runtime/kwalletd/backend/cbc.h b/src/runtime/kwalletd/backend/cbc.h index 8750785..3df039a 100644 --- a/src/runtime/kwalletd/backend/cbc.h +++ b/src/runtime/kwalletd/backend/cbc.h @@ -1,64 +1,64 @@ /* This file is part of the KDE project Copyright (C) 2001 George Staikos This library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more details. You should have received a copy of the GNU Library General Public License along with this library; see the file COPYING.LIB. If not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ #ifndef __CBC__KO__H #define __CBC__KO__H #include "blockcipher.h" /* @internal * Initialize this class with a pointer to a valid, uninitialized BlockCipher * and it will apply that cipher using CBC. You may want to make the * initial block a full block of random data. Do not change the block size * at any time!! You must pad it yourself. Also, you can only encrypt or * decrypt. You can't do both with a given instance. After you call one, * calls to the other will fail in this instance. */ class CipherBlockChain : public BlockCipher { public: CipherBlockChain(BlockCipher *cipher, bool useECBforReading =false); - virtual ~CipherBlockChain(); + ~CipherBlockChain() override; - virtual bool setKey(void *key, int bitlength); + bool setKey(void *key, int bitlength) override; - virtual int keyLen() const; + int keyLen() const override; - virtual bool variableKeyLen() const; + bool variableKeyLen() const override; - virtual bool readyToGo() const; + bool readyToGo() const override; - virtual int encrypt(void *block, int len); + int encrypt(void *block, int len) override; - virtual int decrypt(void *block, int len); + int decrypt(void *block, int len) override; private: void initRegister(); int decryptECB(void *block, int len); BlockCipher *_cipher; void *_register; void *_next; int _len; int _reader, _writer; bool _useECBforReading; }; #endif diff --git a/src/runtime/kwalletd/kwalletd.h b/src/runtime/kwalletd/kwalletd.h index 8b24944..16486dd 100644 --- a/src/runtime/kwalletd/kwalletd.h +++ b/src/runtime/kwalletd/kwalletd.h @@ -1,252 +1,252 @@ /* This file is part of the KDE libraries Copyright (c) 2002-2004 George Staikos Copyright (c) 2008 Michael Leupold This library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more details. You should have received a copy of the GNU Library General Public License along with this library; see the file COPYING.LIB. If not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ #ifndef _KWALLETD_H_ #define _KWALLETD_H_ #include #include #include #include "kwalletbackend.h" #include #include #include #include #include #include "ktimeout.h" #include "kwalletsessionstore.h" class KDirWatch; class KTimeout; // @Private class KWalletTransaction; class KWalletSessionStore; class KWalletD : public QObject, protected QDBusContext { Q_OBJECT public: KWalletD(); - virtual ~KWalletD(); + ~KWalletD() override; public Q_SLOTS: // Is the wallet enabled? If not, all open() calls fail. bool isEnabled() const; // Open and unlock the wallet int open(const QString &wallet, qlonglong wId, const QString &appid); // Open and unlock the wallet with this path int openPath(const QString &path, qlonglong wId, const QString &appid); // Open the wallet asynchronously int openAsync(const QString &wallet, qlonglong wId, const QString &appid, bool handleSession); // Open and unlock the wallet with this path asynchronously int openPathAsync(const QString &path, qlonglong wId, const QString &appid, bool handleSession); // Close and lock the wallet // If force = true, will close it for all users. Behave. This // can break applications, and is generally intended for use by // the wallet manager app only. int close(const QString &wallet, bool force); int close(int handle, bool force, const QString &appid); // Save to disk but leave open Q_NOREPLY void sync(int handle, const QString &appid); // Physically deletes the wallet from disk. int deleteWallet(const QString &wallet); // Returns true if the wallet is open bool isOpen(const QString &wallet); bool isOpen(int handle); // List the users of this wallet QStringList users(const QString &wallet) const; // Change the password of this wallet void changePassword(const QString &wallet, qlonglong wId, const QString &appid); // A list of all wallets QStringList wallets() const; // A list of all folders in this wallet QStringList folderList(int handle, const QString &appid); // Does this wallet have this folder? bool hasFolder(int handle, const QString &folder, const QString &appid); // Create this folder bool createFolder(int handle, const QString &folder, const QString &appid); // Remove this folder bool removeFolder(int handle, const QString &folder, const QString &appid); // List of entries in this folder QStringList entryList(int handle, const QString &folder, const QString &appid); // Read an entry. If the entry does not exist, it just // returns an empty result. It is your responsibility to check // hasEntry() first. QByteArray readEntry(int handle, const QString &folder, const QString &key, const QString &appid); QByteArray readMap(int handle, const QString &folder, const QString &key, const QString &appid); QString readPassword(int handle, const QString &folder, const QString &key, const QString &appid); QVariantMap readEntryList(int handle, const QString &folder, const QString &key, const QString &appid); QVariantMap readMapList(int handle, const QString &folder, const QString &key, const QString &appid); QVariantMap readPasswordList(int handle, const QString &folder, const QString &key, const QString &appid); // Rename an entry. rc=0 on success. int renameEntry(int handle, const QString &folder, const QString &oldName, const QString &newName, const QString &appid); // Write an entry. rc=0 on success. int writeEntry(int handle, const QString &folder, const QString &key, const QByteArray &value, int entryType, const QString &appid); int writeEntry(int handle, const QString &folder, const QString &key, const QByteArray &value, const QString &appid); int writeMap(int handle, const QString &folder, const QString &key, const QByteArray &value, const QString &appid); int writePassword(int handle, const QString &folder, const QString &key, const QString &value, const QString &appid); // Does the entry exist? bool hasEntry(int handle, const QString &folder, const QString &key, const QString &appid); // What type is the entry? int entryType(int handle, const QString &folder, const QString &key, const QString &appid); // Remove an entry. rc=0 on success. int removeEntry(int handle, const QString &folder, const QString &key, const QString &appid); // Disconnect an app from a wallet bool disconnectApplication(const QString &wallet, const QString &application); void reconfigure(); // Determine bool folderDoesNotExist(const QString &wallet, const QString &folder); bool keyDoesNotExist(const QString &wallet, const QString &folder, const QString &key); void closeAllWallets(); QString networkWallet(); QString localWallet(); void screenSaverChanged(bool); // Open a wallet using a pre-hashed password. This is only useful in cooperation // with the kwallet PAM module. It's also less secure than manually entering the // password as the password hash is transmitted using D-Bus. int pamOpen(const QString &wallet, const QByteArray &passwordHash, int sessionTimeout); Q_SIGNALS: void walletAsyncOpened(int id, int handle); // used to notify KWallet::Wallet void walletListDirty(); void walletCreated(const QString &wallet); void walletOpened(const QString &wallet); void walletDeleted(const QString &wallet); void walletClosed(const QString &wallet); void walletClosed(int handle); void allWalletsClosed(); void folderListUpdated(const QString &wallet); void folderUpdated(const QString &, const QString &); void applicationDisconnected(const QString &wallet, const QString &application); private Q_SLOTS: void slotServiceOwnerChanged(const QString &name, const QString &oldOwner, const QString &newOwner); void emitWalletListDirty(); void timedOutClose(int handle); void timedOutSync(int handle); void notifyFailures(); void processTransactions(); void activatePasswordDialog(); void registerKWalletd4Service(); #ifdef Q_WS_X11 void connectToScreenSaver(); #endif private: friend class MigrationAgent; // Internal - open a wallet int internalOpen(const QString &appid, const QString &wallet, bool isPath, WId w, bool modal, const QString &service); // Internal - close this wallet. int internalClose(KWallet::Backend * const w, const int handle, const bool force, const bool saveBeforeClose = true); bool isAuthorizedApp(const QString &appid, const QString &wallet, WId w); // This also validates the handle. May return NULL. KWallet::Backend *getWallet(const QString &appid, int handle); // Generate a new unique handle. int generateHandle(); // Emit signals about closing wallets void doCloseSignals(int, const QString &); void emitFolderUpdated(const QString &, const QString &); // Implicitly allow access for this application bool implicitAllow(const QString &wallet, const QString &app); bool implicitDeny(const QString &wallet, const QString &app); void doTransactionChangePassword(const QString &appid, const QString &wallet, qlonglong wId); void doTransactionOpenCancelled(const QString &appid, const QString &wallet, const QString &service); int doTransactionOpen(const QString &appid, const QString &wallet, bool isPath, qlonglong wId, bool modal, const QString &service); void initiateSync(int handle); void setupDialog(QWidget *dialog, WId wId, const QString &appid, bool modal); void checkActiveDialog(); QPair findWallet(const QString &walletName) const; typedef QHash Wallets; Wallets _wallets; KDirWatch *_dw; int _failed; // configuration values bool _leaveOpen, _closeIdle, _launchManager, _enabled; bool _openPrompt, _firstUse, _showingFailureNotify; int _idleTime; QMap _implicitAllowMap, _implicitDenyMap; KTimeout _closeTimers; KTimeout _syncTimers; const int _syncTime; static bool _processing; KWalletTransaction *_curtrans; // current transaction QList _transactions; QPointer< QWidget > activeDialog; #ifdef Q_WS_X11 QDBusInterface *screensaver; #endif // sessions KWalletSessionStore _sessions; QDBusServiceWatcher _serviceWatcher; bool _useGpg; }; #endif diff --git a/src/runtime/kwalletd/migrationwizard.h b/src/runtime/kwalletd/migrationwizard.h index dcbb343..8796997 100644 --- a/src/runtime/kwalletd/migrationwizard.h +++ b/src/runtime/kwalletd/migrationwizard.h @@ -1,44 +1,44 @@ /* * This file is part of the KDE Frameworks * * Copyright (c) 2014 Valentin Rusu * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Library General Public * License as published by the Free Software Foundation; either * version 2 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Library General Public License for more details. * * You should have received a copy of the GNU Library General Public License * along with this library; see the file COPYING.LIB. If not, write to * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, * Boston, MA 02110-1301, USA. * */ #ifndef _MIGRATIONWIZARD_H_ #define _MIGRATIONWIZARD_H_ #include class MigrationAgent; class MigrationWizard : public QWizard { Q_OBJECT public: explicit MigrationWizard(MigrationAgent *agent); - ~MigrationWizard(); + ~MigrationWizard() override; MigrationAgent *agent() const { return _agent; } public Q_SLOTS: void page1Updated(); private: MigrationAgent *_agent; }; #endif // _MIGRATIONWIZARD_H_ diff --git a/tests/kwalletd/kwalletmany.h b/tests/kwalletd/kwalletmany.h index 8a6fd40..4bbd6a7 100644 --- a/tests/kwalletd/kwalletmany.h +++ b/tests/kwalletd/kwalletmany.h @@ -1,56 +1,56 @@ /* This file is part of the KDE libraries Copyright (c) 2008 Michael Leupold This library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more details. You should have received a copy of the GNU Library General Public License along with this library; see the file COPYING.LIB. If not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ #ifndef KWALLETMANY_H #define KWALLETMANY_H #include #include #include #include namespace KWallet { class Wallet; } class KWalletMany : public QObject { Q_OBJECT public: KWalletMany(); - ~KWalletMany(); + ~KWalletMany() override; public Q_SLOTS: void walletOpened(bool open); private Q_SLOTS: void init(); void openWallet(); private: QList _wallets; int _pending; }; #endif // KWALLETMANY_H