Botan 2.13.0 Crypto and TLS for C++11

- Main Page
- Namespaces
- Classes
- Files

- File List
- File Members

psk_db_sql.h
Go to the documentation of this file.
1 /*
2 * (C) 2017 Jack Lloyd
3 *
4 * Botan is released under the Simplified BSD License (see license.txt)
5 */
6
7 #ifndef BOTAN_PSK_DB_SQL_H_
8 #define BOTAN_PSK_DB_SQL_H_
9
10 #include <botan/psk_db.h>
11 #include <botan/database.h>
12
13 namespace Botan {
14
15 class BOTAN_PUBLIC_API(2,4) Encrypted_PSK_Database_SQL : public Encrypted_PSK_Database
16 {
17 public:
18 Encrypted_PSK_Database_SQL(const secure_vector<uint8_t>& master_key,
19 std::shared_ptr<SQL_Database> db,
20 const std::string& table_name);
21
22 private:
23 void kv_set(const std::string& index, const std::string& value) override;
24 std::string kv_get(const std::string& index) const override;
25 void kv_del(const std::string& index) override;
26 std::set<std::string> kv_get_all() const override;
27
28 std::shared_ptr<SQL_Database> m_db;
29 const std::string m_table_name;
30 };
31
32 }
33
34 #endif
Botan::Encrypted_PSK_Database
Definition: psk_db.h:90
BOTAN_PUBLIC_API
#define BOTAN_PUBLIC_API(maj, min)
Definition: compiler.h:31
Botan::secure_vector
std::vector< T, secure_allocator< T >> secure_vector
Definition: secmem.h:65
Botan
Definition: alg_id.cpp:13
Botan::Encrypted_PSK_Database_SQL
Definition: psk_db_sql.h:15