IRTCClient2::AllowedPorts (Windows CE 5.0)
This method sets or gets the ports the client uses to listen for incoming sessions.
HRESULT put_AllowedPorts( long lTransport, RTC_LISTEN_MODE penMode);HRESULT get_AllowedPorts( long lTransport, RTC_LISTEN_MODE* penMode);
Parameters
- lTransport
[in] Contains the transport type. - penMode
[in, out] An RTC_LISTEN_MODE enumeration that contains the listen mode.
Return Values
This method can return an RTC_E_ constant.
The following table shows additional information about a specific return value.
Value | Meaning |
---|---|
RTC_E_NOT_ALLOWED | The IRTCClient::ListenForIncomingSessions method has been called. |
Remarks
The RTC_LISTEN_MODE value in the penMode parameter can be used to open static and dynamic ports to listen for incoming sessions.
Unless required, it is best not to open static port 5060. As a well-known port, it is more susceptible to attack.
If put_AllowedPorts is called after the listen mode is set or retrieved using IRTCClient::ListenForIncomingSessions, the RTC Client API returns an RTC_E_NOT_ALLOWED error.
Incoming sessions are not secure if the application does not set the listen mode to disallow static and dynamic ports (RTCLM_NONE), and does not specify the TLS transport in the profile.
Requirements
OS Versions: Windows CE .NET 4.2 and later.
Header: Rtccore.h, Rtccore.idl.
Link Library: Uuid.lib.
See Also
IRTCClient2 | IRTCClient::ListenForIncomingSessions | RTC_LISTEN_MODE
Send Feedback on this topic to the authors