/src/botan/src/lib/tls/tls_external_psk.cpp
Line | Count | Source |
1 | | /* |
2 | | * TLS 1.3 Preshared Key Container |
3 | | * (C) 2023 Fabian Albert, René Meusel - Rohde & Schwarz Cybersecurity |
4 | | * 2025 Jack Lloyd |
5 | | * |
6 | | * Botan is released under the Simplified BSD License (see license.txt) |
7 | | */ |
8 | | |
9 | | #include <botan/tls_external_psk.h> |
10 | | |
11 | | #include <botan/assert.h> |
12 | | #include <utility> |
13 | | |
14 | | namespace Botan::TLS { |
15 | | |
16 | 5.32k | secure_vector<uint8_t> ExternalPSK::extract_master_secret() { |
17 | 5.32k | BOTAN_STATE_CHECK(!m_master_secret.empty()); |
18 | 5.32k | return std::exchange(m_master_secret, {}); |
19 | 5.32k | } |
20 | | |
21 | | } // namespace Botan::TLS |