9 #include <gtest/gtest.h> 15 using namespace folly;
24 auto kd = std::make_unique<MockKeyDerivation>();
29 ks_ = std::make_unique<KeyScheduler>(
std::move(kd));
35 std::unique_ptr<KeyScheduler>
ks_;
41 ks_->deriveEarlySecret(psk);
43 ks_->getSecret(EarlySecrets::ExternalPskBinder, transcript_);
44 ks_->getSecret(EarlySecrets::ResumptionPskBinder, transcript_);
45 ks_->getSecret(EarlySecrets::ResumptionPskBinder, transcript_);
46 ks_->getSecret(EarlySecrets::EarlyExporter, transcript_);
50 ks_->deriveHandshakeSecret();
52 ks_->getSecret(HandshakeSecrets::ClientHandshakeTraffic, transcript_);
53 ks_->getSecret(HandshakeSecrets::ServerHandshakeTraffic, transcript_);
57 ks_->deriveMasterSecret();
59 ks_->getSecret(MasterSecrets::ExporterMaster, transcript_);
60 ks_->getSecret(MasterSecrets::ResumptionMaster, transcript_);
63 ks_->deriveAppTrafficSecrets(transcript_);
64 ks_->getSecret(AppTrafficSecrets::ClientAppTraffic);
65 ks_->getSecret(AppTrafficSecrets::ServerAppTraffic);
71 ks_->deriveEarlySecret(psk);
73 ks_->getSecret(EarlySecrets::ExternalPskBinder, transcript_);
74 ks_->getSecret(EarlySecrets::ResumptionPskBinder, transcript_);
75 ks_->getSecret(EarlySecrets::ResumptionPskBinder, transcript_);
76 ks_->getSecret(EarlySecrets::EarlyExporter, transcript_);
81 ks_->deriveHandshakeSecret(ecdhe);
83 ks_->getSecret(HandshakeSecrets::ClientHandshakeTraffic, transcript_);
84 ks_->getSecret(HandshakeSecrets::ServerHandshakeTraffic, transcript_);
88 ks_->deriveMasterSecret();
90 ks_->getSecret(MasterSecrets::ExporterMaster, transcript_);
91 ks_->getSecret(MasterSecrets::ResumptionMaster, transcript_);
94 ks_->deriveAppTrafficSecrets(transcript_);
95 ks_->getSecret(AppTrafficSecrets::ClientAppTraffic);
96 ks_->getSecret(AppTrafficSecrets::ServerAppTraffic);
103 ks_->deriveHandshakeSecret(ecdhe);
105 ks_->getSecret(HandshakeSecrets::ClientHandshakeTraffic, transcript_);
106 ks_->getSecret(HandshakeSecrets::ServerHandshakeTraffic, transcript_);
110 ks_->deriveMasterSecret();
112 ks_->getSecret(MasterSecrets::ExporterMaster, transcript_);
113 ks_->getSecret(MasterSecrets::ResumptionMaster, transcript_);
116 ks_->deriveAppTrafficSecrets(transcript_);
117 ks_->getSecret(AppTrafficSecrets::ClientAppTraffic);
118 ks_->getSecret(AppTrafficSecrets::ServerAppTraffic);
123 ks_->deriveHandshakeSecret(ecdhe);
124 ks_->deriveMasterSecret();
125 ks_->deriveAppTrafficSecrets(transcript_);
141 ks_->getTrafficKey(trafficSecret, 10, 10);
static std::unique_ptr< IOBuf > create(std::size_t capacity)
#define EXPECT_EQ(val1, val2)
constexpr detail::Map< Move > move
—— Concurrent Priority Queue Implementation ——
PolymorphicAction< internal::InvokeWithoutArgsAction< FunctionImpl > > InvokeWithoutArgs(FunctionImpl function_impl)
std::unique_ptr< KeyScheduler > ks_
TEST_F(AsyncSSLSocketWriteTest, write_coalescing1)
#define ON_CALL(obj, call)
#define EXPECT_CALL(obj, call)
const internal::AnythingMatcher _
internal::ReturnAction< R > Return(R value)