diff options
author | Black Hat <bhat@encom.eu.org> | 2019-09-26 22:22:36 -0700 |
---|---|---|
committer | Black Hat <bhat@encom.eu.org> | 2019-09-26 22:22:36 -0700 |
commit | 363cf452bcdbaf6ff1cf94a83ca66cbb31122346 (patch) | |
tree | c64c8fda885e4e1785130e8ee3e7c47fd18cbf67 /lib/e2ee.h | |
parent | 412e2cf19449e73aa7da729e9c5de6502687aade (diff) | |
parent | 944653463fe4134c82d85e2d01e2bc0fa43fd727 (diff) | |
download | libquotient-363cf452bcdbaf6ff1cf94a83ca66cbb31122346.tar.gz libquotient-363cf452bcdbaf6ff1cf94a83ca66cbb31122346.zip |
Merge branch 'master' of https://github.com/quotient-im/libQuotient into
bhat-libqtolm-update
Diffstat (limited to 'lib/e2ee.h')
-rw-r--r-- | lib/e2ee.h | 43 |
1 files changed, 24 insertions, 19 deletions
@@ -1,26 +1,31 @@ #pragma once +#include "util.h" + #include <QtCore/QStringList> -namespace QMatrixClient -{ - static const auto CiphertextKeyL = "ciphertext"_ls; - static const auto SenderKeyKeyL = "sender_key"_ls; - static const auto DeviceIdKeyL = "device_id"_ls; - static const auto SessionIdKeyL = "session_id"_ls; +namespace Quotient { +inline const auto CiphertextKeyL = "ciphertext"_ls; +inline const auto SenderKeyKeyL = "sender_key"_ls; +inline const auto DeviceIdKeyL = "device_id"_ls; +inline const auto SessionIdKeyL = "session_id"_ls; - static const auto AlgorithmKeyL = "algorithm"_ls; - static const auto RotationPeriodMsKeyL = "rotation_period_ms"_ls; - static const auto RotationPeriodMsgsKeyL = "rotation_period_msgs"_ls; +inline const auto AlgorithmKeyL = "algorithm"_ls; +inline const auto RotationPeriodMsKeyL = "rotation_period_ms"_ls; +inline const auto RotationPeriodMsgsKeyL = "rotation_period_msgs"_ls; - static const auto AlgorithmKey = QStringLiteral("algorithm"); - static const auto RotationPeriodMsKey = QStringLiteral("rotation_period_ms"); - static const auto RotationPeriodMsgsKey = QStringLiteral("rotation_period_msgs"); +inline const auto AlgorithmKey = QStringLiteral("algorithm"); +inline const auto RotationPeriodMsKey = QStringLiteral("rotation_period_ms"); +inline const auto RotationPeriodMsgsKey = + QStringLiteral("rotation_period_msgs"); - static const auto Ed25519Key = QStringLiteral("ed25519"); - static const auto Curve25519Key = QStringLiteral("curve25519"); - static const auto SignedCurve25519Key = QStringLiteral("signed_curve25519"); - static const auto OlmV1Curve25519AesSha2AlgoKey = QStringLiteral("m.olm.v1.curve25519-aes-sha2"); - static const auto MegolmV1AesSha2AlgoKey = QStringLiteral("m.megolm.v1.aes-sha2"); - static const QStringList SupportedAlgorithms = { OlmV1Curve25519AesSha2AlgoKey, MegolmV1AesSha2AlgoKey }; -} // namespace QMatrixClient +inline const auto Ed25519Key = QStringLiteral("ed25519"); +inline const auto Curve25519Key = QStringLiteral("curve25519"); +inline const auto SignedCurve25519Key = QStringLiteral("signed_curve25519"); +inline const auto OlmV1Curve25519AesSha2AlgoKey = + QStringLiteral("m.olm.v1.curve25519-aes-sha2"); +inline const auto MegolmV1AesSha2AlgoKey = + QStringLiteral("m.megolm.v1.aes-sha2"); +inline const QStringList SupportedAlgorithms = { OlmV1Curve25519AesSha2AlgoKey, + MegolmV1AesSha2AlgoKey }; +} // namespace Quotient |