Namespaces | |
| namespace | framer |
Classes | |
| struct | Address |
| class | Bittorrent |
| class | ByteSpan |
| Non-owning view over a contiguous run of writable bytes. More... | |
| class | ByteView |
| Non-owning view over a contiguous run of bytes. More... | |
| class | CircuitService |
| class | DhtDiscovery |
| struct | DhtService |
| class | DialService |
| class | EventBus |
| class | ExternalAddressService |
| The read side, published in the node's ServiceRegistry so a NAT-traversal module can consult it without holding the Node: More... | |
| class | FileTransfer |
| struct | Frame |
A decoded inner message. payload is a non-owning view into the source bytes. More... | |
| struct | FrameHeader |
| Fixed header of an inner message. More... | |
| class | HolePunch |
| Published as HolePunchService, so a module that discovers a peer it cannot dial (PeerExchange) can hand the id over without depending on this class. More... | |
| struct | HolePunchService |
| class | Json |
| class | JsonError |
| Thrown by the throwing parse path and by type-mismatched accessors. More... | |
| class | MdnsDiscovery |
| class | MessageJson |
| class | NatStatus |
| class | Node |
| struct | NodeConfig |
| struct | NodeContext |
| class | Peer |
| class | PeerExchange |
| class | PeerId |
| struct | PeerInfo |
| class | PeerNetwork |
| class | PingService |
| struct | PortMappingConfig |
| Configuration for automatic port forwarding (see PortMappingService). More... | |
| class | PortMappingService |
| Maps the node's TCP listen port through the home router via UPnP and/or NAT-PMP. More... | |
| struct | PortMapResult |
| Result of a port mapping attempt. More... | |
| class | PubSub |
| class | ReconnectionService |
| class | Relay |
| struct | RelayService |
| class | ServiceRegistry |
| struct | StorageChangeEvent |
| Storage change event - passed to change callbacks. More... | |
| struct | StorageConfig |
| Storage configuration. More... | |
| struct | StorageEntry |
| Storage entry - represents a single key-value pair in the database. More... | |
| class | StorageManager |
| StorageManager - Distributed key-value storage with peer synchronization. More... | |
| struct | StorageStatistics |
| Storage statistics. More... | |
| class | Subsystem |
| A pluggable network subsystem. More... | |
Typedefs | |
| using | StorageChangeCallback = std::function< void(const StorageChangeEvent &)> |
| Callback function types for storage events. | |
| using | StorageSyncCompleteCallback = std::function< void(bool success, const std::string &error_message)> |
| using | Bytes = std::vector< uint8_t > |
| using | PortMapCallback = std::function< void(const PortMapResult &)> |
| Callback invoked whenever a mapping is established, refreshed, removed or fails. | |
Enumerations | |
| enum | PeerTransports : uint8_t { PeerTransportNone = 0 , PeerTransportTcp = 1 << 0 , PeerTransportUdp = 1 << 1 } |
| Transports a peer says it accepts, as a bitmask (see IdentifyMessage). More... | |
| enum class | MessageType : uint8_t { App = 1 , Control = 2 , Gossip = 3 , FileChunk = 4 , Ping = 5 , Storage = 6 , Typed = 7 , Pex = 8 , Punch = 9 , Relay = 10 } |
Inner-message kind. Application traffic uses App, addressed by channel. More... | |
| enum class | ValidationResult { Accept , Reject , Ignore } |
| Outcome of validating an inbound published message before it is delivered or forwarded. More... | |
| enum class | StorageValueType : uint8_t { BINARY = 0x01 , STRING = 0x02 , INT64 = 0x03 , DOUBLE = 0x04 , JSON = 0x05 } |
| Value types supported by the distributed storage. More... | |
| enum class | StorageOperation : uint8_t { OP_PUT = 0x01 , OP_DELETE = 0x02 } |
| Storage operation types for change events. More... | |
| enum class | StorageSyncStatus { NOT_STARTED , IN_PROGRESS , COMPLETED , FAILED } |
| Storage synchronization status. More... | |
| enum class | NatMapping : uint8_t { Unknown , Open , EndpointIndependent , EndpointDependent } |
| How the NAT in front of our shared datagram socket maps it, as far as the mesh has been able to show. More... | |
| enum class | PortMapProtocol : uint8_t { TCP , UDP } |
| Transport protocol of a port mapping. More... | |
| enum class | PortMapTransport : uint8_t { UPnP , NatPMP } |
| Which NAT traversal backend produced a result. More... | |
Functions | |
| uint32_t | storage_calculate_crc32 (const void *data, size_t length) |
| std::string | storage_value_type_to_string (StorageValueType type) |
| StorageValueType | string_to_storage_value_type (const std::string &str) |
| const char * | to_string (NatMapping) noexcept |
| std::istream & | operator>> (std::istream &is, Json &j) |
| std::ostream & | operator<< (std::ostream &os, const Json &j) |
| const char * | to_string (PortMapProtocol p) |
| Human readable protocol name ("TCP"/"UDP"). | |
| const char * | to_string (PortMapTransport t) |
| Human readable transport name ("UPnP"/"NAT-PMP"). | |
| using librats::Bytes = typedef std::vector<uint8_t> |
| using librats::PortMapCallback = typedef std::function<void(const PortMapResult&)> |
Callback invoked whenever a mapping is established, refreshed, removed or fails.
Always called from the backend's own worker thread.
Definition at line 64 of file port_mapping.h.
| using librats::StorageChangeCallback = typedef std::function<void(const StorageChangeEvent&)> |
| using librats::StorageSyncCompleteCallback = typedef std::function<void(bool success, const std::string& error_message)> |
|
strong |
Inner-message kind. Application traffic uses App, addressed by channel.
| Enumerator | |
|---|---|
| App | |
| Control | core control plane (peer exchange…) |
| Gossip | |
| FileChunk | |
| Ping | liveness / RTT (PingService) |
| Storage | distributed key-value store (StorageManager) |
| Typed | typed JSON message exchange (MessageJson) |
| Pex | peer exchange — gossip of known peer addresses (PeerExchange) |
| Punch | NAT hole-punch rendezvous, relayed peer→peer (HolePunch) |
| Relay | relayed circuits: a peer's connection carried through a third node (Relay) |
|
strong |
How the NAT in front of our shared datagram socket maps it, as far as the mesh has been able to show.
Definition at line 50 of file nat_status.h.
| enum librats::PeerTransports : uint8_t |
Transports a peer says it accepts, as a bitmask (see IdentifyMessage).
Kept separate from transport, which is the one this connection actually uses.
| Enumerator | |
|---|---|
| PeerTransportNone | |
| PeerTransportTcp | |
| PeerTransportUdp | |
Definition at line 22 of file peer_info.h.
|
strong |
Transport protocol of a port mapping.
| Enumerator | |
|---|---|
| TCP | |
| UDP | |
Definition at line 22 of file port_mapping.h.
|
strong |
Which NAT traversal backend produced a result.
| Enumerator | |
|---|---|
| UPnP | |
| NatPMP | |
Definition at line 28 of file port_mapping.h.
|
strong |
|
strong |
|
strong |
|
strong |
| std::ostream & librats::operator<< | ( | std::ostream & | os, |
| const Json & | j | ||
| ) |
| std::istream & librats::operator>> | ( | std::istream & | is, |
| Json & | j | ||
| ) |
| uint32_t librats::storage_calculate_crc32 | ( | const void * | data, |
| size_t | length | ||
| ) |
| std::string librats::storage_value_type_to_string | ( | StorageValueType | type | ) |
| StorageValueType librats::string_to_storage_value_type | ( | const std::string & | str | ) |
|
noexcept |
|
inline |
Human readable protocol name ("TCP"/"UDP").
Definition at line 34 of file port_mapping.h.
References TCP.
|
inline |
Human readable transport name ("UPnP"/"NAT-PMP").
Definition at line 39 of file port_mapping.h.
References UPnP.