INetFwOpenPort::get_RemoteAddresses method (netfw.h)

[The Windows Firewall API is available for use in the operating systems specified in the Requirements section. It may be altered or unavailable in subsequent versions. For Windows Vista and later, use of the Windows Firewall with Advanced Security API is recommended.]

Specifies a set of remote addresses from which the port can listen for traffic.

This property is read/write.

Syntax

HRESULT get_RemoteAddresses(
  BSTR *remoteAddrs
);

Parameters

remoteAddrs

Return value

None

Remarks

The remoteAddrs parameter consists of one or more comma-delimited tokens specifying the remote addresses from which the application can listen for traffic. The default value is "*".

Valid tokens:

  • "*": any remote address; if present, it must be the only token.
  • "LocalSubnet": not case-sensitive; specifying more than once has no effect.
  • subnet: may be specified using either subnet mask or network prefix notation. If neither a subnet mask nor a network prefix is specified, the subnet mask defaults to 255.255.255.255. Examples of valid subnets: 10.0.0.2/255.0.0.0 10.0.0.2/8 10.0.0.2
  • Windows Vista: A valid IPv6 address.
  • Windows Vista: An IPv4 address range in the format "start address - end address."
  • Windows Vista: An IPv6 address range in the format "start address - end address."
For a predefined address range, use the Scope property.

Requirements

Requirement Value
Minimum supported client Windows Vista, Windows XP with SP2 [desktop apps only]
Minimum supported server Windows Server 2003 with SP1 [desktop apps only]
Target Platform Windows
Header netfw.h
DLL FirewallAPI.dll; Hnetcfg.dll on Windows XP with SP2

See also

INetFwOpenPort