wrapper class for managing encrypted Udp sockets.
More...
#include <DtlsSocket.h>
Inherits AzNetworking::UdpSocket.
|
| bool | IsEncrypted () const override |
| |
| DtlsEndpoint::ConnectResult | ConnectDtlsEndpoint (DtlsEndpoint &dtlsEndpoint, const IpAddress &address, UdpPacketEncodingBuffer &outDtlsData) const override |
| |
| DtlsEndpoint::ConnectResult | AcceptDtlsEndpoint (DtlsEndpoint &dtlsEndpoint, const IpAddress &address) const override |
| |
| bool | Open (uint16_t port, UdpSocket::CanAcceptConnections canAccept, TrustZone trustZone) override |
| |
|
void | Close () override |
| | Closes an open socket.
|
| |
| bool | IsOpen () const |
| |
| int32_t | Send (const IpAddress &address, const uint8_t *data, uint32_t size, bool encrypt, DtlsEndpoint &dtlsEndpoint, const ConnectionQuality &connectionQuality) const |
| |
| int32_t | Receive (IpAddress &outAddress, uint8_t *outData, uint32_t size) const |
| |
| SocketFd | GetSocketFd () const |
| |
| uint32_t | GetSentPackets () const |
| |
| uint32_t | GetSentBytes () const |
| |
| uint32_t | GetSentPacketsEncrypted () const |
| |
| uint32_t | GetSentBytesEncryptionInflation () const |
| |
| uint32_t | GetRecvPackets () const |
| |
| uint32_t | GetRecvBytes () const |
| |
|
| enum | CanAcceptConnections { False,
True
} |
| |
|
uint32_t | m_sentPacketsEncrypted = 0 |
| |
|
uint32_t | m_sentBytesEncryptionInflation = 0 |
| |
wrapper class for managing encrypted Udp sockets.
◆ AcceptDtlsEndpoint()
| DtlsEndpoint::ConnectResult AzNetworking::DtlsSocket::AcceptDtlsEndpoint |
( |
DtlsEndpoint & |
dtlsEndpoint, |
|
|
const IpAddress & |
address |
|
) |
| const |
|
overridevirtual |
Accepts an encryption socket wrapper.
- Parameters
-
| dtlsEndpoint | the encryption wrapper instance to create a connection over |
| address | the IP address of the endpoint to connect to |
- Returns
- a connect result specifying whether the connection is still pending, failed, or complete
Reimplemented from AzNetworking::UdpSocket.
◆ ConnectDtlsEndpoint()
Creates an encryption socket wrapper.
- Parameters
-
| dtlsEndpoint | the encryption wrapper instance to create a connection over |
| address | the IP address of the endpoint to connect to |
| outDtlsData | data buffer to store the dtls handshake packet |
- Returns
- a connect result specifying whether the connection is still pending, failed, or complete
Reimplemented from AzNetworking::UdpSocket.
◆ IsEncrypted()
| bool AzNetworking::DtlsSocket::IsEncrypted |
( |
| ) |
const |
|
overridevirtual |
Returns true if this is an encrypted socket, false if not.
- Returns
- boolean true if this is an encrypted socket, false if not
Reimplemented from AzNetworking::UdpSocket.
◆ Open()
| bool AzNetworking::DtlsSocket::Open |
( |
uint16_t |
port, |
|
|
UdpSocket::CanAcceptConnections |
canAccept, |
|
|
TrustZone |
trustZone |
|
) |
| |
|
overridevirtual |
Opens the UDP socket on the given port.
- Parameters
-
| port | the port number to open the UDP socket on, 0 will bind to any available port |
| canAccept | if true, the socket will be opened in a way that allows accepting incoming connections |
| trustZone | for encrypted connections, the level of trust we associate with this connection (internal or external) |
- Returns
- boolean true on success
Reimplemented from AzNetworking::UdpSocket.
The documentation for this class was generated from the following file:
- Code/Framework/AzNetworking/AzNetworking/UdpTransport/DtlsSocket.h