Date: Thu, 4 Mar 2010 19:35:22 +0000 (UTC) From: Brooks Davis <brooks@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org Subject: svn commit: r204724 - in stable/8/sys: conf rpc/rpcsec_gss Message-ID: <201003041935.o24JZMt5068022@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: brooks Date: Thu Mar 4 19:35:22 2010 New Revision: 204724 URL: http://svn.freebsd.org/changeset/base/204724 Log: MFC r201853: Make options KGSSAPI build and add it to NOTES. rpcsec_gss_prot.c: Use kernel printf and headers. vc_rpcsec_gss.c: Use a local RPCAUTH_UNIXGIDS definition for 16 instead of using NGROUPS. Modified: stable/8/sys/conf/NOTES stable/8/sys/rpc/rpcsec_gss/rpcsec_gss_prot.c stable/8/sys/rpc/rpcsec_gss/svc_rpcsec_gss.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/amd64/include/xen/ (props changed) stable/8/sys/cddl/contrib/opensolaris/ (props changed) stable/8/sys/contrib/dev/acpica/ (props changed) stable/8/sys/contrib/pf/ (props changed) stable/8/sys/dev/xen/xenpci/ (props changed) stable/8/sys/netinet/ (props changed) Modified: stable/8/sys/conf/NOTES ============================================================================== --- stable/8/sys/conf/NOTES Thu Mar 4 17:48:40 2010 (r204723) +++ stable/8/sys/conf/NOTES Thu Mar 4 19:35:22 2010 (r204724) @@ -978,6 +978,7 @@ options NFSSERVER #Network File System options NFSLOCKD #Network Lock Manager options NFSCL #experimental NFS client with NFSv4 options NFSD #experimental NFS server with NFSv4 +options KGSSAPI #Kernel GSSAPI implementaion # NT File System. Read-mostly, see mount_ntfs(8) for details. # For a full read-write NTFS support consider sysutils/fusefs-ntfs Modified: stable/8/sys/rpc/rpcsec_gss/rpcsec_gss_prot.c ============================================================================== --- stable/8/sys/rpc/rpcsec_gss/rpcsec_gss_prot.c Thu Mar 4 17:48:40 2010 (r204723) +++ stable/8/sys/rpc/rpcsec_gss/rpcsec_gss_prot.c Thu Mar 4 19:35:22 2010 (r204724) @@ -307,7 +307,7 @@ xdr_rpc_gss_unwrap_data(struct mbuf **re } #ifdef DEBUG -#include <ctype.h> +#include <machine/stdarg.h> void rpc_gss_log_debug(const char *fmt, ...) @@ -315,9 +315,9 @@ rpc_gss_log_debug(const char *fmt, ...) va_list ap; va_start(ap, fmt); - fprintf(stderr, "rpcsec_gss: "); - vfprintf(stderr, fmt, ap); - fprintf(stderr, "\n"); + printf("rpcsec_gss: "); + vprintf(fmt, ap); + printf("\n"); va_end(ap); } @@ -328,7 +328,7 @@ rpc_gss_log_status(const char *m, gss_OI gss_buffer_desc msg; int msg_ctx = 0; - fprintf(stderr, "rpcsec_gss: %s: ", m); + printf("rpcsec_gss: %s: ", m); gss_display_status(&min, maj_stat, GSS_C_GSS_CODE, GSS_C_NULL_OID, &msg_ctx, &msg); Modified: stable/8/sys/rpc/rpcsec_gss/svc_rpcsec_gss.c ============================================================================== --- stable/8/sys/rpc/rpcsec_gss/svc_rpcsec_gss.c Thu Mar 4 17:48:40 2010 (r204723) +++ stable/8/sys/rpc/rpcsec_gss/svc_rpcsec_gss.c Thu Mar 4 19:35:22 2010 (r204724) @@ -121,6 +121,9 @@ enum svc_rpc_gss_client_state { }; #define SVC_RPC_GSS_SEQWINDOW 128 +#ifndef RPCAUTH_UNIXGIDS +#define RPCAUTH_UNIXGIDS 16 +#endif struct svc_rpc_gss_clientid { unsigned long ci_hostid; @@ -147,7 +150,7 @@ struct svc_rpc_gss_client { int cl_rpcflavor; /* RPC pseudo sec flavor */ bool_t cl_done_callback; /* TRUE after call */ void *cl_cookie; /* user cookie from callback */ - gid_t cl_gid_storage[NGROUPS]; + gid_t cl_gid_storage[RPCAUTH_UNIXGIDS]; gss_OID cl_mech; /* mechanism */ gss_qop_t cl_qop; /* quality of protection */ uint32_t cl_seqlast; /* sequence window origin */ @@ -735,7 +738,7 @@ svc_rpc_gss_build_ucred(struct svc_rpc_g uc->gid = 65534; uc->gidlist = client->cl_gid_storage; - numgroups = NGROUPS; + numgroups = RPCAUTH_UNIXGIDS; maj_stat = gss_pname_to_unix_cred(&min_stat, name, client->cl_mech, &uc->uid, &uc->gid, &numgroups, &uc->gidlist[0]); if (GSS_ERROR(maj_stat)) @@ -932,7 +935,7 @@ svc_rpc_gss_accept_sec_context(struct sv "<mech %.*s, qop %d, svc %d>", client->cl_rawcred.client_principal->name, mechname.length, (char *)mechname.value, - client->cl_qop, client->rawcred.service); + client->cl_qop, client->cl_rawcred.service); gss_release_buffer(&min_stat, &mechname); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201003041935.o24JZMt5068022>