Class DtlsSrtpTransport
Inheritance
System.Object
DtlsSrtpTransport
Implements
Org.BouncyCastle.Crypto.Tls.DatagramTransport
Org.BouncyCastle.Crypto.Tls.TlsCloseable
System.IDisposable
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Assembly: SIPSorcery.dll
Syntax
public class DtlsSrtpTransport : DatagramTransport, TlsCloseable, IDisposable
Constructors
|
Improve this Doc
View Source
DtlsSrtpTransport(IDtlsSrtpPeer, Int32)
Declaration
public DtlsSrtpTransport(IDtlsSrtpPeer connection, int mtu = 1500)
Parameters
Fields
|
Improve this Doc
View Source
DEFAULT_MTU
Declaration
public const int DEFAULT_MTU = 1500
Field Value
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
DEFAULT_RETRANSMISSION_WAIT_MILLIS
Declaration
public const int DEFAULT_RETRANSMISSION_WAIT_MILLIS = 100
Field Value
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
DEFAULT_TIMEOUT_MILLISECONDS
Declaration
public const int DEFAULT_TIMEOUT_MILLISECONDS = 20000
Field Value
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
DTLS_RECEIVE_ERROR_CODE
Declaration
public const int DTLS_RECEIVE_ERROR_CODE = -2
Field Value
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
DTLS_RETRANSMISSION_CODE
Declaration
public const int DTLS_RETRANSMISSION_CODE = -1
Field Value
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
MAX_IP_OVERHEAD
Declaration
public const int MAX_IP_OVERHEAD = 84
Field Value
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
MIN_IP_OVERHEAD
Declaration
public const int MIN_IP_OVERHEAD = 20
Field Value
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
OnDataReady
Declaration
public Action<byte[]> OnDataReady
Field Value
Type |
Description |
System.Action<System.Byte[]> |
|
|
Improve this Doc
View Source
RetransmissionMilliseconds
Sets the period in milliseconds that receive will wait before try retransmission
Declaration
public int RetransmissionMilliseconds
Field Value
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
TimeoutMilliseconds
Sets the period in milliseconds that the handshake attempt will timeout
after.
Declaration
public int TimeoutMilliseconds
Field Value
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
UDP_OVERHEAD
Declaration
public const int UDP_OVERHEAD = 8
Field Value
Type |
Description |
System.Int32 |
|
Properties
|
Improve this Doc
View Source
IsClient
Declaration
public bool IsClient { get; }
Property Value
Type |
Description |
System.Boolean |
|
|
Improve this Doc
View Source
SrtcpDecoder
Declaration
public IPacketTransformer SrtcpDecoder { get; }
Property Value
|
Improve this Doc
View Source
SrtcpEncoder
Declaration
public IPacketTransformer SrtcpEncoder { get; }
Property Value
|
Improve this Doc
View Source
SrtpDecoder
Declaration
public IPacketTransformer SrtpDecoder { get; }
Property Value
|
Improve this Doc
View Source
SrtpEncoder
Declaration
public IPacketTransformer SrtpEncoder { get; }
Property Value
|
Improve this Doc
View Source
Transport
Declaration
public DtlsTransport Transport { get; }
Property Value
Type |
Description |
Org.BouncyCastle.Crypto.Tls.DtlsTransport |
|
Methods
|
Improve this Doc
View Source
BackOff(Int32)
Handle retransmission time based in DTLS 1.3
Declaration
protected virtual int BackOff(int currentWaitMillis)
Parameters
Type |
Name |
Description |
System.Int32 |
currentWaitMillis |
|
Returns
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
Close()
Declaration
public virtual void Close()
|
Improve this Doc
View Source
Dispose()
Close the transport if the instance is out of scope.
Declaration
|
Improve this Doc
View Source
Dispose(Boolean)
Close the transport if the instance is out of scope.
Declaration
protected void Dispose(bool disposing)
Parameters
Type |
Name |
Description |
System.Boolean |
disposing |
|
|
Improve this Doc
View Source
DoHandshake(out String)
Declaration
public bool DoHandshake(out string handshakeError)
Parameters
Type |
Name |
Description |
System.String |
handshakeError |
|
Returns
Type |
Description |
System.Boolean |
|
|
Improve this Doc
View Source
GenerateRtcpDecoder()
Declaration
protected IPacketTransformer GenerateRtcpDecoder()
Returns
|
Improve this Doc
View Source
GenerateRtcpEncoder()
Declaration
protected IPacketTransformer GenerateRtcpEncoder()
Returns
|
Improve this Doc
View Source
GenerateRtpDecoder()
Declaration
protected IPacketTransformer GenerateRtpDecoder()
Returns
|
Improve this Doc
View Source
GenerateRtpEncoder()
Declaration
protected IPacketTransformer GenerateRtpEncoder()
Returns
|
Improve this Doc
View Source
Declaration
protected IPacketTransformer GenerateTransformer(bool isClient, bool isRtp)
Parameters
Type |
Name |
Description |
System.Boolean |
isClient |
|
System.Boolean |
isRtp |
|
Returns
|
Improve this Doc
View Source
GetMasterClientKey()
Declaration
protected byte[] GetMasterClientKey()
Returns
Type |
Description |
System.Byte[] |
|
|
Improve this Doc
View Source
GetMasterClientSalt()
Declaration
protected byte[] GetMasterClientSalt()
Returns
Type |
Description |
System.Byte[] |
|
|
Improve this Doc
View Source
GetMasterServerKey()
Declaration
protected byte[] GetMasterServerKey()
Returns
Type |
Description |
System.Byte[] |
|
|
Improve this Doc
View Source
GetMasterServerSalt()
Declaration
protected byte[] GetMasterServerSalt()
Returns
Type |
Description |
System.Byte[] |
|
|
Improve this Doc
View Source
GetReceiveLimit()
Declaration
public int GetReceiveLimit()
Returns
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
GetRemoteCertificate()
Declaration
public Certificate GetRemoteCertificate()
Returns
Type |
Description |
Org.BouncyCastle.Crypto.Tls.Certificate |
|
|
Improve this Doc
View Source
GetSendLimit()
Declaration
public int GetSendLimit()
Returns
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
GetSrtcpPolicy()
Declaration
protected SrtpPolicy GetSrtcpPolicy()
Returns
|
Improve this Doc
View Source
GetSrtpPolicy()
Declaration
protected SrtpPolicy GetSrtpPolicy()
Returns
|
Improve this Doc
View Source
IsHandshakeComplete()
Declaration
public bool IsHandshakeComplete()
Returns
Type |
Description |
System.Boolean |
|
|
Improve this Doc
View Source
IsHandshakeFailed()
Declaration
public bool IsHandshakeFailed()
Returns
Type |
Description |
System.Boolean |
|
|
Improve this Doc
View Source
IsHandshaking()
Declaration
public bool IsHandshaking()
Returns
Type |
Description |
System.Boolean |
|
|
Improve this Doc
View Source
ProtectRTCP(Byte[], Int32, Int32)
Declaration
public byte[] ProtectRTCP(byte[] packet, int offset, int length)
Parameters
Type |
Name |
Description |
System.Byte[] |
packet |
|
System.Int32 |
offset |
|
System.Int32 |
length |
|
Returns
Type |
Description |
System.Byte[] |
|
|
Improve this Doc
View Source
ProtectRTCP(Byte[], Int32, out Int32)
Declaration
public int ProtectRTCP(byte[] payload, int length, out int outLength)
Parameters
Type |
Name |
Description |
System.Byte[] |
payload |
|
System.Int32 |
length |
|
System.Int32 |
outLength |
|
Returns
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
ProtectRTP(Byte[], Int32, Int32)
Declaration
public byte[] ProtectRTP(byte[] packet, int offset, int length)
Parameters
Type |
Name |
Description |
System.Byte[] |
packet |
|
System.Int32 |
offset |
|
System.Int32 |
length |
|
Returns
Type |
Description |
System.Byte[] |
|
|
Improve this Doc
View Source
ProtectRTP(Byte[], Int32, out Int32)
Declaration
public int ProtectRTP(byte[] payload, int length, out int outLength)
Parameters
Type |
Name |
Description |
System.Byte[] |
payload |
|
System.Int32 |
length |
|
System.Int32 |
outLength |
|
Returns
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
Receive(Byte[], Int32, Int32, Int32)
Declaration
public int Receive(byte[] buf, int off, int len, int waitMillis)
Parameters
Type |
Name |
Description |
System.Byte[] |
buf |
|
System.Int32 |
off |
|
System.Int32 |
len |
|
System.Int32 |
waitMillis |
|
Returns
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
Send(Byte[], Int32, Int32)
Declaration
public void Send(byte[] buf, int off, int len)
Parameters
Type |
Name |
Description |
System.Byte[] |
buf |
|
System.Int32 |
off |
|
System.Int32 |
len |
|
|
Improve this Doc
View Source
UnprotectRTCP(Byte[], Int32, Int32)
Declaration
public byte[] UnprotectRTCP(byte[] packet, int offset, int length)
Parameters
Type |
Name |
Description |
System.Byte[] |
packet |
|
System.Int32 |
offset |
|
System.Int32 |
length |
|
Returns
Type |
Description |
System.Byte[] |
|
|
Improve this Doc
View Source
UnprotectRTCP(Byte[], Int32, out Int32)
Declaration
public int UnprotectRTCP(byte[] payload, int length, out int outLength)
Parameters
Type |
Name |
Description |
System.Byte[] |
payload |
|
System.Int32 |
length |
|
System.Int32 |
outLength |
|
Returns
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
UnprotectRTP(Byte[], Int32, Int32)
Declaration
public byte[] UnprotectRTP(byte[] packet, int offset, int length)
Parameters
Type |
Name |
Description |
System.Byte[] |
packet |
|
System.Int32 |
offset |
|
System.Int32 |
length |
|
Returns
Type |
Description |
System.Byte[] |
|
|
Improve this Doc
View Source
UnprotectRTP(Byte[], Int32, out Int32)
Declaration
public int UnprotectRTP(byte[] payload, int length, out int outLength)
Parameters
Type |
Name |
Description |
System.Byte[] |
payload |
|
System.Int32 |
length |
|
System.Int32 |
outLength |
|
Returns
Type |
Description |
System.Int32 |
|
|
Improve this Doc
View Source
WriteToRecvStream(Byte[])
Declaration
public void WriteToRecvStream(byte[] buf)
Parameters
Type |
Name |
Description |
System.Byte[] |
buf |
|
Events
|
Improve this Doc
View Source
OnAlert
Parameters:
- alert level,
- alert type,
- alert description.
Declaration
public event Action<AlertLevelsEnum, AlertTypesEnum, string> OnAlert
Event Type
Implements
Org.BouncyCastle.Crypto.Tls.DatagramTransport
Org.BouncyCastle.Crypto.Tls.TlsCloseable
System.IDisposable
Extension Methods