Changeset View
Changeset View
Standalone View
Standalone View
lib/libcasper/services/cap_net/cap_net.3
Show First 20 Lines • Show All 85 Lines • ▼ Show 20 Lines | |||||
The functions | The functions | ||||
.Fn cap_bind , | .Fn cap_bind , | ||||
.Fn cap_connect , | .Fn cap_connect , | ||||
.Fn cap_gethostbyname , | .Fn cap_gethostbyname , | ||||
.Fn cap_gethostbyname2 , | .Fn cap_gethostbyname2 , | ||||
.Fn cap_gethostbyaddr | .Fn cap_gethostbyaddr | ||||
and | and | ||||
.Fn cap_getnameinfo | .Fn cap_getnameinfo | ||||
are respectively equivalent to | provide a set of APIs equivalent to | ||||
.Xr bind 2 , | .Xr bind 2 , | ||||
.Xr connect 2 , | .Xr connect 2 , | ||||
.Xr gethostbyname 3 , | .Xr gethostbyname 3 , | ||||
.Xr gethostbyname2 3 , | .Xr gethostbyname2 3 , | ||||
.Xr gethostbyaddr 3 | .Xr gethostbyaddr 3 | ||||
and | and | ||||
.Xr getnameinfo 3 | .Xr getnameinfo 3 | ||||
except that the connection to the | except that a connection to the | ||||
.Nm system.net | .Nm system.net | ||||
service needs to be provided. | service needs to be provided. | ||||
.Sh LIMITS | .Sh LIMITS | ||||
By default, the cap_net capability provides unrestricted access to the network | By default, the cap_net capability provides unrestricted access to the network | ||||
namespace. | namespace. | ||||
Applications typically only require access to a small portion of the network | Applications typically only require access to a small portion of the network | ||||
namespace: | namespace: | ||||
The | |||||
.Fn cap_net_limit | .Fn cap_net_limit | ||||
interface can be used to restrict access to the network. | function can be used to restrict access to the network. | ||||
The | |||||
.Fn cap_net_limit_init | .Fn cap_net_limit_init | ||||
returns an opaque limit handle used to store a list of capabilities. | returns an opaque limit handle used to store a list of capabilities. | ||||
The | The | ||||
.Fv mode | .Fv mode | ||||
restricts the functionality of the service. | restricts the functionality of the service. | ||||
Modes are encoded using the following flags: | Modes are encoded using the following flags: | ||||
.Pp | .Pp | ||||
.Bd -literal -offset indent -compact | .Bd -literal -offset indent -compact | ||||
▲ Show 20 Lines • Show All 167 Lines • Show Last 20 Lines |