TrinityCore
Loading...
Searching...
No Matches
Trinity::Net Namespace Reference

Namespaces

namespace  Http
 
namespace  Impl
 
namespace  IpBanCheckHelpers
 
namespace  SslHandshakeHelpers
 

Classes

class  AsyncAcceptor
 
struct  InvokeReadHandlerCallback
 
struct  IpBanCheckConnectionInitializer
 
class  NetworkThread
 
struct  ReadConnectionInitializer
 
class  Resolver
 
class  Socket
 
struct  SocketConnectionInitializer
 
class  SocketMgr
 
struct  SslHandshakeConnectionInitializer
 
class  SslStream
 

Concepts

concept  AcceptCallback
 
concept  SelectIoContextForNewSocketFn
 

Typedefs

using IoContextTcpSocket = boost::asio::basic_stream_socket< boost::asio::ip::tcp, boost::asio::io_context::executor_type >
 

Enumerations

enum class  SocketReadCallbackResult { KeepReading , Stop }
 

Functions

uint32 address_to_uint (boost::asio::ip::address_v4 const &address)
 
bool IsInLocalNetwork (boost::asio::ip::address const &clientAddress)
 
bool IsInNetwork (boost::asio::ip::network_v4 const &network, boost::asio::ip::address_v4 const &clientAddress)
 
bool IsInNetwork (boost::asio::ip::network_v6 const &network, boost::asio::ip::address_v6 const &clientAddress)
 
Optional< std::size_t > SelectAddressForClient (boost::asio::ip::address const &clientAddress, std::span< boost::asio::ip::address const > const &addresses)
 
TC_NETWORK_API void ScanLocalNetworks ()
 
boost::asio::mutable_buffer PrepareReadBuffer (MessageBuffer &readBuffer)
 

Typedef Documentation

◆ IoContextTcpSocket

using Trinity::Net::IoContextTcpSocket = typedef boost::asio::basic_stream_socket<boost::asio::ip::tcp, boost::asio::io_context::executor_type>

Definition at line 40 of file Socket.h.

Enumeration Type Documentation

◆ SocketReadCallbackResult

Enumerator
KeepReading 
Stop 

Definition at line 48 of file Socket.h.

Function Documentation

◆ address_to_uint()

uint32 Trinity::Net::address_to_uint ( boost::asio::ip::address_v4 const &  address)
inline

Definition at line 31 of file IpAddress.h.

◆ IsInLocalNetwork()

TC_NETWORK_API bool Trinity::Net::IsInLocalNetwork ( boost::asio::ip::address const &  clientAddress)

Definition at line 32 of file IpNetwork.cpp.

+ Here is the caller graph for this function:

◆ IsInNetwork() [1/2]

TC_NETWORK_API bool Trinity::Net::IsInNetwork ( boost::asio::ip::network_v4 const &  network,
boost::asio::ip::address_v4 const &  clientAddress 
)

Definition at line 53 of file IpNetwork.cpp.

◆ IsInNetwork() [2/2]

TC_NETWORK_API bool Trinity::Net::IsInNetwork ( boost::asio::ip::network_v6 const &  network,
boost::asio::ip::address_v6 const &  clientAddress 
)

Definition at line 62 of file IpNetwork.cpp.

◆ PrepareReadBuffer()

boost::asio::mutable_buffer Trinity::Net::PrepareReadBuffer ( MessageBuffer readBuffer)
inline

Definition at line 54 of file Socket.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ ScanLocalNetworks()

void Trinity::Net::ScanLocalNetworks ( )

Definition at line 149 of file IpNetwork.cpp.

+ Here is the caller graph for this function:

◆ SelectAddressForClient()

TC_NETWORK_API Optional< std::size_t > Trinity::Net::SelectAddressForClient ( boost::asio::ip::address const &  clientAddress,
std::span< boost::asio::ip::address const > const &  addresses 
)

Definition at line 71 of file IpNetwork.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function: