mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2025-11-21 07:20:28 -05:00
Add basic support for WebAuthn (Passkeys) (#8825)
--------- Co-authored-by: varjolintu <sami.vanttinen@protonmail.com> Co-authored-by: droidmonkey <support@dmapps.us>
This commit is contained in:
parent
378c2992cd
commit
6f2354c0e9
66 changed files with 4464 additions and 144 deletions
|
|
@ -15,8 +15,8 @@
|
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
*/
|
||||
|
||||
#ifndef BROWSERMESSAGEBUILDER_H
|
||||
#define BROWSERMESSAGEBUILDER_H
|
||||
#ifndef KEEPASSXC_BROWSERMESSAGEBUILDER_H
|
||||
#define KEEPASSXC_BROWSERMESSAGEBUILDER_H
|
||||
|
||||
#include <QPair>
|
||||
#include <QString>
|
||||
|
|
@ -48,7 +48,13 @@ namespace
|
|||
ERROR_KEEPASS_NO_GROUPS_FOUND = 16,
|
||||
ERROR_KEEPASS_CANNOT_CREATE_NEW_GROUP = 17,
|
||||
ERROR_KEEPASS_NO_VALID_UUID_PROVIDED = 18,
|
||||
ERROR_KEEPASS_ACCESS_TO_ALL_ENTRIES_DENIED = 19
|
||||
ERROR_KEEPASS_ACCESS_TO_ALL_ENTRIES_DENIED = 19,
|
||||
ERROR_PASSKEYS_ATTESTATION_NOT_SUPPORTED = 20,
|
||||
ERROR_PASSKEYS_CREDENTIAL_IS_EXCLUDED = 21,
|
||||
ERROR_PASSKEYS_REQUEST_CANCELED = 22,
|
||||
ERROR_PASSKEYS_INVALID_USER_VERIFICATION = 23,
|
||||
ERROR_PASSKEYS_EMPTY_PUBLIC_KEY = 24,
|
||||
ERROR_PASSKEYS_INVALID_URL_PROVIDED = 25
|
||||
};
|
||||
}
|
||||
|
||||
|
|
@ -84,6 +90,14 @@ public:
|
|||
QJsonObject getJsonObject(const QByteArray& ba) const;
|
||||
QByteArray base64Decode(const QString& str);
|
||||
QString incrementNonce(const QString& nonce);
|
||||
QString getRandomBytesAsBase64(int bytes) const;
|
||||
QString getBase64FromArray(const char* arr, int len) const;
|
||||
QString getBase64FromArray(const QByteArray& byteArray) const;
|
||||
QString getBase64FromJson(const QJsonObject& jsonObject) const;
|
||||
QByteArray getArrayFromHexString(const QString& hexString) const;
|
||||
QByteArray getArrayFromBase64(const QString& base64str) const;
|
||||
QByteArray getSha256Hash(const QString& str) const;
|
||||
QString getSha256HashAsBase64(const QString& str) const;
|
||||
|
||||
private:
|
||||
Q_DISABLE_COPY(BrowserMessageBuilder);
|
||||
|
|
@ -96,4 +110,4 @@ static inline BrowserMessageBuilder* browserMessageBuilder()
|
|||
return BrowserMessageBuilder::instance();
|
||||
}
|
||||
|
||||
#endif // BROWSERMESSAGEBUILDER_H
|
||||
#endif // KEEPASSXC_BROWSERMESSAGEBUILDER_H
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue