Class holding common message bus utility objects. More...
#include <eagine/message_bus/context.hpp>
Public Member Functions | |
context (context &&)=delete | |
Not move constructible. | |
context (const context &)=delete | |
Not copy constructible. | |
auto | operator= (context &&)=delete |
Not move assignable. | |
auto | operator= (const context &)=delete |
Not copy assignable. | |
auto | ssl () noexcept -> sslp::ssl_api & |
Returns a reference to the SSL API wrapper. | |
auto | next_sequence_no (message_id) noexcept -> message_sequence_t |
Returns the next sequence number value for the specified message type. | |
auto | verify_certificate (sslp::x509 cert) -> bool |
Verifies the specified x509 certificate. | |
auto | add_own_certificate_pem (memory::const_block) -> bool |
Sets this bus node certificate encoded in PEM format. More... | |
auto | add_ca_certificate_pem (memory::const_block) -> bool |
Sets a CA certificate encoded in PEM format. More... | |
auto | add_remote_certificate_pem (identifier_t node_id, memory::const_block) -> bool |
Sets remote bus node certificate encoded in PEM format. More... | |
auto | add_router_certificate_pem (memory::const_block blk) -> bool |
Sets the router certificate encoded in PEM format. More... | |
auto | get_own_certificate_pem () const noexcept -> memory::const_block |
Gets this bus node certificate encoded in PEM format. More... | |
auto | get_ca_certificate_pem () const noexcept -> memory::const_block |
Gets the CA certificate encoded in PEM format. More... | |
auto | get_remote_certificate_pem (identifier_t) const noexcept -> memory::const_block |
Gets remote bus node certificate encoded in PEM format. More... | |
auto | get_router_certificate_pem () const noexcept -> memory::const_block |
Gets the router certificate encoded in PEM format. More... | |
auto | verified_remote_key (identifier_t) const noexcept -> bool |
Indicates if the private key of a remote node was verified. | |
auto | default_message_digest () noexcept -> decltype(ssl().message_digest_sha256()) |
Returns the default message digest type. | |
auto | get_own_signature (memory::const_block) -> memory::const_block |
Signs the specified memory block and returns the signature. | |
auto | verify_remote_signature (memory::const_block sig, identifier_t) -> bool |
Verifies the signature on a data block from a remote node. | |
Class holding common message bus utility objects.
auto eagine::msgbus::context::add_ca_certificate_pem | ( | memory::const_block | ) | -> bool |
Sets a CA certificate encoded in PEM format.
auto eagine::msgbus::context::add_own_certificate_pem | ( | memory::const_block | ) | -> bool |
Sets this bus node certificate encoded in PEM format.
auto eagine::msgbus::context::add_remote_certificate_pem | ( | identifier_t | node_id, |
memory::const_block | |||
) | -> bool |
Sets remote bus node certificate encoded in PEM format.
Referenced by add_router_certificate_pem().
|
inline |
Sets the router certificate encoded in PEM format.
|
inlinenoexcept |
Gets the CA certificate encoded in PEM format.
|
inlinenoexcept |
Gets this bus node certificate encoded in PEM format.
|
noexcept |
Gets remote bus node certificate encoded in PEM format.
Referenced by get_router_certificate_pem().
|
inlinenoexcept |
Gets the router certificate encoded in PEM format.