xref: /freebsd/lib/librpcsec_gss/rpc_gss_seccreate.3 (revision 12613c1ae5807acb9b8199cdbfae497e7601c1d6)
18f55a568SDoug Rabson.\" Copyright (c) 2008 Isilon Inc http://www.isilon.com/
28f55a568SDoug Rabson.\" Authors: Doug Rabson <dfr@rabson.org>
38f55a568SDoug Rabson.\" Developed with Red Inc: Alfred Perlstein <alfred@freebsd.org>
48f55a568SDoug Rabson.\"
58f55a568SDoug Rabson.\" Redistribution and use in source and binary forms, with or without
68f55a568SDoug Rabson.\" modification, are permitted provided that the following conditions
78f55a568SDoug Rabson.\" are met:
88f55a568SDoug Rabson.\" 1. Redistributions of source code must retain the above copyright
98f55a568SDoug Rabson.\"    notice, this list of conditions and the following disclaimer.
108f55a568SDoug Rabson.\" 2. Redistributions in binary form must reproduce the above copyright
118f55a568SDoug Rabson.\"    notice, this list of conditions and the following disclaimer in the
128f55a568SDoug Rabson.\"    documentation and/or other materials provided with the distribution.
138f55a568SDoug Rabson.\"
148f55a568SDoug Rabson.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
158f55a568SDoug Rabson.\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
168f55a568SDoug Rabson.\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
178f55a568SDoug Rabson.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
188f55a568SDoug Rabson.\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
198f55a568SDoug Rabson.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
208f55a568SDoug Rabson.\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
218f55a568SDoug Rabson.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
228f55a568SDoug Rabson.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
238f55a568SDoug Rabson.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
248f55a568SDoug Rabson.\" SUCH DAMAGE.
258f55a568SDoug Rabson.\"
268f55a568SDoug Rabson.\" $FreeBSD$
27621d0bd3SGavin Atkinson.Dd January 26, 2010
288f55a568SDoug Rabson.Dt RPC_GSS_SECCREATE 3
298f55a568SDoug Rabson.Os
308f55a568SDoug Rabson.Sh NAME
318f55a568SDoug Rabson.Nm rpc_gss_seccreate
328f55a568SDoug Rabson.Nd "create a security context using the RPCSEC_GSS protocol"
338f55a568SDoug Rabson.Sh LIBRARY
348f55a568SDoug Rabson.Lb librpcsec_gss
358f55a568SDoug Rabson.Sh SYNOPSIS
368f55a568SDoug Rabson.In rpc/rpcsec_gss.h
378f55a568SDoug Rabson.Ft AUTH *
388f55a568SDoug Rabson.Fo rpc_gss_seccreate
398f55a568SDoug Rabson.Fa "CLIENT *clnt"
408f55a568SDoug Rabson.Fa "const char *principal"
418f55a568SDoug Rabson.Fa "const char  *mechanism"
428f55a568SDoug Rabson.Fa "rpc_gss_service_t service"
438f55a568SDoug Rabson.Fa "const char *qop"
448f55a568SDoug Rabson.Fa "rpc_gss_options_req_t *options_req"
458f55a568SDoug Rabson.Fa "rpc_gss_options_ret_t *options_ret"
468f55a568SDoug Rabson.Fc
478f55a568SDoug Rabson.Sh DESCRIPTION
488f55a568SDoug RabsonThis function is used to establish a security context between an
498f55a568SDoug Rabsonapplication and a remote peer using the RPSEC_GSS protocol.
508f55a568SDoug Rabson.Sh PARAMETERS
518f55a568SDoug Rabson.Bl -tag
528f55a568SDoug Rabson.It clnt
538f55a568SDoug RabsonAn RPC handle which is connected to the remote peer
548f55a568SDoug Rabson.It principal
558f55a568SDoug RabsonThe name of the service principal on the remote peer.
568f55a568SDoug RabsonFor instance, a principal such as
578f55a568SDoug Rabson.Qq nfs@server.example.com
588f55a568SDoug Rabsonmight be used by an application which needs to contact an NFS server
598f55a568SDoug Rabson.It mechanism
608f55a568SDoug RabsonThe desired mechanism for this security context.
618f55a568SDoug RabsonThe value of mechanism should be the name of one of the security
628f55a568SDoug Rabsonmechanisms listed in /etc/gss/mech.
638f55a568SDoug Rabson.It service
648f55a568SDoug RabsonType of service requested.
658f55a568SDoug Rabson.Bl -tag
668f55a568SDoug Rabson.It rpc_gss_svc_default
678f55a568SDoug RabsonThe default - typically the same as
688f55a568SDoug Rabson.Dv rpc_gss_svc_none .
698f55a568SDoug Rabson.It rpc_gss_svc_none
708f55a568SDoug RabsonRPC headers only are integrity protected by a checksum.
718f55a568SDoug Rabson.It rpc_gss_svc_integrity
728f55a568SDoug RabsonRPC headers and data are integrity protected by a checksum.
738f55a568SDoug Rabson.It rpc_gss_svc_privacy
748f55a568SDoug RabsonRPC headers are integrity protected by a checksum and data is encrypted.
758f55a568SDoug Rabson.El
768f55a568SDoug Rabson.It qop
778f55a568SDoug RabsonDesired	quality of protection or NULL for the default.
7812613c1aSJens SchweikhardtAvailable values are listed in /etc/gss/qop
798f55a568SDoug Rabson.It options_req
808f55a568SDoug RabsonExtra security context options to be passed to the underlying GSS-API
818f55a568SDoug Rabsonmechanism.
828f55a568SDoug RabsonPass
838f55a568SDoug Rabson.Dv NULL
848f55a568SDoug Rabsonto supply default values.
858f55a568SDoug Rabson.It options_ret
868f55a568SDoug RabsonVarious values returned by the underlying GSS-API mechanism.
878f55a568SDoug RabsonPass
888f55a568SDoug Rabson.Dv NULL
898f55a568SDoug Rabsonif these values are not required.
908f55a568SDoug Rabson.El
918f55a568SDoug Rabson.Sh RETURN VALUES
928f55a568SDoug RabsonIf the security context was created successfully, a pointer to an
938f55a568SDoug Rabson.Vt AUTH
948f55a568SDoug Rabsonstructure that represents the context is returned.
958f55a568SDoug RabsonTo use this security context for subsequent RPC calls, set
968f55a568SDoug Rabson.Va clnt->cl_auth
978f55a568SDoug Rabsonto this value.
988f55a568SDoug Rabson.Sh SEE ALSO
998f55a568SDoug Rabson.Xr rpc 3 ,
1008f55a568SDoug Rabson.Xr gssapi 3 ,
1018f55a568SDoug Rabson.Xr mech 5 ,
1028f55a568SDoug Rabson.Xr qop 5 ,
1038f55a568SDoug Rabson.Xr rpcset_gss 3
1048f55a568SDoug Rabson.Sh HISTORY
1058f55a568SDoug RabsonThe
1068f55a568SDoug Rabson.Nm
107ffae047bSGavin Atkinsonfunction first appeared in
1088f55a568SDoug Rabson.Fx 8.0 .
1098f55a568SDoug Rabson.Sh AUTHORS
1108f55a568SDoug RabsonThis
1118f55a568SDoug Rabsonmanual page was written by
1128f55a568SDoug Rabson.An Doug Rabson Aq dfr@FreeBSD.org .
113