Skip to main content

NetworkInterfaceSettings Class

Package: GHIElectronics.Endpoint.Devices.Network
Namespace: GHIElectronics.Endpoint.Devices.Network

Settings for an Ethernet or PC-shared network interface (IP, routing, DNS, MAC pinning). Read with NetworkController.GetInterfaceSettings and apply with NetworkController.SetInterfaceSettings. For WiFi use Network.WiFiNetworkInterfaceSettings.

class NetworkInterfaceSettings: ...

Constructors​

NetworkInterfaceSettings()​

def __init__(self):

Properties​

Address​

Address: IPAddress # @property / @setter

Static IPv4 address. Ignored when NetworkInterfaceSettings.IsDhcpEnabled is true.

Returns IPAddress

DnsAddresses​

DnsAddresses: list[IPAddress] # @property / @setter

Static DNS servers. Null or empty leaves the system default.

Returns IPAddress[]

GatewayAddress​

GatewayAddress: IPAddress # @property / @setter

Static IPv4 default gateway.

Returns IPAddress

IsDhcpEnabled​

IsDhcpEnabled: bool # @property / @setter

True = ask the network for an address (DHCP). False = use the static fields below.

Returns bool

MacAddress​

MacAddress: PhysicalAddress # @property / @setter

When set, these settings apply only to the adapter with this MAC address. Null (default) means any adapter of this type.

Returns PhysicalAddress

SubnetMask​

SubnetMask: IPAddress # @property / @setter

Static IPv4 subnet mask (e.g. 255.255.255.0).

Returns IPAddress