xref: /illumos-gate/usr/src/man/man3nsl/rpc_gss_set_svc_name.3nsl (revision 66582b606a8194f7f3ba5b3a3a6dca5b0d346361)
te
Copyright (C) 2002, Sun Microsystems, Inc. All Rights Reserved
The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
RPC_GSS_SET_SVC_NAME 3NSL "Feb 5, 2002"
NAME
rpc_gss_set_svc_name - send a principal name to a server
SYNOPSIS

#include <rpc/rpcsec_gss.h>

bool_t rpc_gss_set_svc_name(char *principal, char *mechanism,
 u_int req_time,u_int program, u_int version);
DESCRIPTION

rpc_gss_set_svc_name() sets the name of a principal the server is to represent. If a server is going to act as more than one principal, this procedure can be invoked for every such principal.

PARAMETERS

Information on RPCSEC_GSS data types for parameters may be found on the rpcsec_gss(3NSL) man page. principal

An ASCII string representing the server's principal name, given in the form of service@host.

mech

An ASCII string representing the security mechanism in use. Valid strings may be found in the /etc/gss/mech file, or by using rpc_gss_get_mechanisms().

req_time

The time, in seconds, for which a credential should be valid. Note that the req_time is a hint to the underlying mechanism. The actual time that the credential will remain valid is mechanism dependent. In the case of kerberos the actual time will be GSS_C_INDEFINITE.

program

The RPC program number for this service.

version

The RPC version number for this service.

RETURN VALUES

rpc_gss_set_svc_name() returns TRUE if it is successful; otherwise, use rpc_gss_get_error() to get the error associated with the failure.

FILES
/etc/gss/mech

File containing valid security mechanisms

ATTRIBUTES

See attributes(5) for descriptions of the following attributes:

ATTRIBUTE TYPE ATTRIBUTE VALUE
MT-Level MT-Safe
SEE ALSO

rpc(3NSL), rpc_gss_get_mechanisms(3NSL), rpc_gss_get_principal_name(3NSL), rpcsec_gss(3NSL), mech(4), attributes(5)

ONC+ Developer's Guide