![]() |
![]()
| ![]() |
![]()
NAMEvmod_unix - Utilities for Unix domain sockets SYNOPSISimport unix [as name] [from "path"] STRING user() STRING group() INT uid() INT gid() DESCRIPTIONThis VMOD provides information about the credentials of the peer process (user and group of the process owner) that is connected to a Varnish listener via a Unix domain socket, if the platform supports it. Examples: import unix; sub vcl_recv { Obtaining the peer credentials is possible on a platform that supports one of the following:
On SunOS and friends, the PRIV_PROC_INFO privilege set is added to the Varnish child process while the VMOD is loaded, see setppriv(2). On most platforms, the value returned is the effective user or group that was valid when the peer process initiated the connection. STRING user()Return the user name of the peer process owner. Restricted to: client, backend. STRING group()Return the group name of the peer process owner. Restricted to: client, backend. INT uid()Return the numeric user id of the peer process owner. Restricted to: client, backend. INT gid()Return the numeric group id of the peer process owner. Restricted to: client, backend. ERRORSAll functions in this VMOD are subject to the following constraints:
SEE ALSO
COPYRIGHTThis document is licensed under the same conditions as Varnish itself. See LICENSE for details. SPDX-License-Identifier: BSD-2-Clause Authors: Geoffrey Simmons <geoffrey.simmons@uplex.de>
|