IFWXNetworkSocket interface
Applies to: desktop apps only
The IFWXNetworkSocket interface is a Microsoft Firewall service socket interface, and is derived from the IFWXSocket interface. The implementation uses the dynamic packet filtering functionality of Forefront TMG to automatically open a packet filter port when necessary, and to close it when the socket is closed.
Note Before releasing this interface, you must call the Close or Shutdown method on it.
Members
The IFWXNetworkSocket interface inherits from IFWXSocket and IUnknown. IFWXNetworkSocket also has these types of members:
- Methods
Methods
The IFWXNetworkSocket interface has these methods.
Method | Description |
---|---|
Accept | Asynchronously permits a connection on a listening socket. This method is similar to the Winsock accept function. |
Bind | Associates a local address with a socket. This method is similar to the Winsock bind function. |
Close | Closes the socket. (Inherited from IFWXSocket) |
Connect | Establishes a connection to a specified socket. This method is similar to the Winsock connect function. |
GetIpFilter | Gets a copy of the IP filter object for the socket. Returns NULL if the connection is not limited to a range of IP addresses. |
GetPeerName | Gets the remote name of a socket. This method is similar to the Winsock getpeername function. |
GetSockName | Gets the local name of a socket. This method is similar to the Winsock getsockname function. |
GetSockOpt | Gets a socket option. This method is similar to the Winsock getsockopt function. |
Listen | Listens on a TCP socket. |
Recv | Receives a buffer asynchronously. It performs an overlapped receive (or receive from operation, depending on the socket type). (Inherited from IFWXSocket) |
Send | Sends a buffer asynchronously. It performs an overlapped send operation. (Inherited from IFWXSocket) |
SendTo | Sends a buffer asynchronously on UDP sockets to a specific address. It performs an overlapped sendto operation. (Inherited from IFWXSocket) |
SetIpFilter | Sets the IP filter for the socket. It sets a new IP filter if there was not one, or replaces the current IP filter with a new one. |
SetSockOpt | Sets a socket option. This method is similar to the Winsock setsockopt function. |
Shutdown | Starts transport shutdown on the socket. (Inherited from IFWXSocket) |
Remarks
A socket object that implements this interface can be created by calling IFWXFirewall::CreateNetworkSocket, IFWXSession::CreateNetworkSocket, or IFWXFirewall2::CreateSSLNetworkSocket.
The nature of the socket is determined by which of these three methods is used to create the object. A socket created by calling IFWXFirewall::CreateNetworkSocket is not user-specific. An example of a socket that should not be user-specific is a listening socket. To create a user-specific socket object, use IFWXSession::CreateNetworkSocket. Finally, a socket object created by calling IFWXFirewall2::CreateSSLNetworkSocket represents an SSL socket for secured communication.
An SSL socket does not implement the Accept, Connect, and SendTo methods. For more information, see Socket Implementation in Forefront TMG.
Implementation
This interface is implemented in the Firewall service.
Requirements
Minimum supported client |
None supported |
Minimum supported server |
Windows Server 2008 R2, Windows Server 2008 with SP2 (64-bit only) |
Version |
Forefront Threat Management Gateway (TMG) 2010 |
Header |
Wspfwext.idl |
See also
Build date: 7/12/2010