# rpc_gss_seccreate(3) - man - phpman

[RPC_GSS_SECCREATE(3)](https://www.chedong.com/phpMan.php/man/RPCGSSSECCREATE/3/markdown)     BSD Library Functions Manual     [RPC_GSS_SECCREATE(3)](https://www.chedong.com/phpMan.php/man/RPCGSSSECCREATE/3/markdown)

## NAME
     **rpc**___**gss**___**seccreate** — create a security context using the RPCSEC_GSS protocol

## SYNOPSIS
     **#include** **<rpc/rpcsec**___**gss.h>**

     _AUTH_ _*_
     **rpc**___**gss**___**seccreate**(_CLIENT_ _*clnt_, _const_ _char_ _*principal_, _const_ _char_ _*mechanism_,
         _rpc_gss_service_t_ _service_, _const_ _char_ _*qop_, _rpc_gss_options_req_t_ _*options_req_,
         _rpc_gss_options_ret_t_ _*options_ret_);

## DESCRIPTION
     This function is used to establish a security context between an application and a remote peer
     using the RPSEC_GSS protocol.

## PARAMETERS
     clnt         An RPC handle which is connected to the remote peer

     principal    The name of the service principal on the remote peer.  For instance, a principal
                  such as "<nfs@server.example.com>" might be used by an application which needs to
                  contact an NFS server

     mechanism    The name of the GSS_API mechanism to use for the new security context.  "ker‐
                  beros_v5" is currently the only supported mechanism.

     service      Type of service requested.

                  rpc_gss_svc_default    The default - typically the same as rpc_gss_svc_none.

                  rpc_gss_svc_none       RPC headers only are integrity protected by a checksum.

                  rpc_gss_svc_integrity  RPC headers and data are integrity protected by a checksum.

                  rpc_gss_svc_privacy    RPC headers are integrity protected by a checksum and data
                                         is encrypted.

     qop          The name of the Quality of Protection to use for the new security context, or NULL
                  to use the default QOP.  "GSS_C_QOP_DEFAULT" is currently the only supported QOP.

     options_req  Extra security context options to be passed to the underlying GSS-API mechanism.
                  Pass NULL to supply default values.

     options_ret  Various values returned by the underlying GSS-API mechanism.  Pass NULL if these
                  values are not required.

## RETURN VALUES
     If the security context was created successfully, a pointer to an _AUTH_ structure that repre‐
     sents the context is returned.  To use this security context for subsequent RPC calls, set
     _clnt->cl_auth_ to this value.

## AVAILABILITY
     The **rpc**___**gss**___**seccreate**() function is part of libtirpc.

## SEE ALSO
     [rpc(3)](https://www.chedong.com/phpMan.php/man/rpc/3/markdown), [gssapi(3)](https://www.chedong.com/phpMan.php/man/gssapi/3/markdown), [mech(5)](https://www.chedong.com/phpMan.php/man/mech/5/markdown), [qop(5)](https://www.chedong.com/phpMan.php/man/qop/5/markdown), [rpcsec_gss(3)](https://www.chedong.com/phpMan.php/man/rpcsecgss/3/markdown)

## AUTHORS
     This manual page was written by Doug Rabson <<dfr@FreeBSD.org>>.

BSD                            January 26, 2010                            BSD
