WasiHostNetworkOptions Class

The rules of a WasiHostNetwork: what the component can do on the network of the machine.

public sealed class WasiHostNetworkOptions

Remarks

By default, the component cannot use any address and cannot look up the names: give it only the access it needs.

Constructors

NameDescription
WasiHostNetworkOptions()

WasiHostNetworkOptions()

WasiHostNetwork.cs
public WasiHostNetworkOptions()

No documentation is available.

Properties

NameDescription
AddressCheckGets the check of the addresses that the component binds to, connects to and sends datagrams to, or null to deny every address.
AllowAllGets a check that allows every address.
AllowLoopbackGets a check that allows the loopback addresses only (127.0.0.0/8 and ::1): the component cannot reach the other machines.
AllowNameLookupGets whether the component can look up host names (ip-name-lookup). The IP addresses written as names are always allowed: they are not looked up.
AllowTcpGets whether the component can create TCP sockets. The default is true.
AllowUdpGets whether the component can create UDP sockets. The default is true.

AddressCheck

WasiHostNetwork.cs

Gets the check of the addresses that the component binds to, connects to and sends datagrams to, or null to deny every address.

public WasiSocketAddressCheck? AddressCheck { get; init; }

Gets a check that allows every address.

public static WasiSocketAddressCheck AllowAll { get; }

AllowLoopback

WasiHostNetwork.cs

Gets a check that allows the loopback addresses only (127.0.0.0/8 and ::1): the component cannot reach the other machines.

public static WasiSocketAddressCheck AllowLoopback { get; }

AllowNameLookup

WasiHostNetwork.cs

Gets whether the component can look up host names (ip-name-lookup). The IP addresses written as names are always allowed: they are not looked up.

public bool AllowNameLookup { get; init; }

Property value

bool

Gets whether the component can create TCP sockets. The default is true.

public bool AllowTcp { get; init; }

Property value

bool

Gets whether the component can create UDP sockets. The default is true.

public bool AllowUdp { get; init; }

Property value

bool