-
Notifications
You must be signed in to change notification settings - Fork 158
/
OpenSSLFactory.h
45 lines (37 loc) · 1.33 KB
/
OpenSSLFactory.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
/*
* Copyright (c) 2018-present, Facebook, Inc.
* All rights reserved.
*
* This source code is licensed under the BSD-style license found in the
* LICENSE file in the root directory of this source tree.
*/
#pragma once
#include <fizz/crypto/Sha256.h>
#include <fizz/crypto/Sha384.h>
#include <fizz/crypto/Sha512.h>
#include <fizz/crypto/aead/AEGISCipher.h>
#include <fizz/crypto/aead/AESGCM128.h>
#include <fizz/crypto/aead/AESGCM256.h>
#include <fizz/crypto/aead/AESOCB128.h>
#include <fizz/crypto/aead/ChaCha20Poly1305.h>
#include <fizz/crypto/aead/OpenSSLEVPCipher.h>
#include <fizz/crypto/exchange/ECCurveKeyExchange.h>
#include <fizz/crypto/exchange/X25519.h>
#include <fizz/protocol/DefaultFactory.h>
namespace fizz {
class OpenSSLFactory : public DefaultFactory {
public:
[[nodiscard]] std::unique_ptr<KeyExchange> makeKeyExchange(
NamedGroup group,
KeyExchangeMode mode) const override;
[[nodiscard]] std::unique_ptr<Aead> makeAead(
CipherSuite cipher) const override;
std::unique_ptr<KeyDerivation> makeKeyDeriver(
CipherSuite cipher) const override;
std::unique_ptr<HandshakeContext> makeHandshakeContext(
CipherSuite cipher) const override;
[[nodiscard]] std::unique_ptr<PeerCert> makePeerCert(
CertificateEntry certEntry,
bool /*leaf*/) const override;
};
} // namespace fizz