hyperledger/iroha
Iroha - A simple, decentralized ledger http://iroha.tech
channel_factory_tls.hpp
Go to the documentation of this file.
1 
6 #ifndef IROHA_CHANNEL_FACTORY_TLS_HPP
7 #define IROHA_CHANNEL_FACTORY_TLS_HPP
8 
10 
11 #include <memory>
12 
13 namespace iroha {
14  namespace network {
15 
16  class PeerTlsCertificatesProvider;
17  struct TlsCredentials;
18 
20  public:
22  std::shared_ptr<const GrpcChannelParams> params,
23  boost::optional<std::shared_ptr<const PeerTlsCertificatesProvider>>
24  peer_cert_provider,
25  boost::optional<std::shared_ptr<const TlsCredentials>> my_creds);
26 
27  protected:
28  iroha::expected::Result<std::shared_ptr<grpc::ChannelCredentials>,
29  std::string>
31  const shared_model::interface::Peer &peer) const override;
32 
33  private:
34  boost::optional<std::shared_ptr<const PeerTlsCertificatesProvider>>
35  peer_cert_provider_;
36  boost::optional<std::shared_ptr<const TlsCredentials>> my_creds_;
37  };
38 
39  } // namespace network
40 } // namespace iroha
41 
42 #endif
ChannelFactoryTls(std::shared_ptr< const GrpcChannelParams > params, boost::optional< std::shared_ptr< const PeerTlsCertificatesProvider >> peer_cert_provider, boost::optional< std::shared_ptr< const TlsCredentials >> my_creds)
Definition: channel_factory_tls.cpp:16
Definition: peer.hpp:20
Definition: channel_factory_tls.hpp:19
iroha::expected::Result< std::shared_ptr< grpc::ChannelCredentials >, std::string > getChannelCredentials(const shared_model::interface::Peer &peer) const override
Definition: channel_factory_tls.cpp:26
Definition: block_query.hpp:14
Definition: channel_factory.hpp:88