Add NO_LOCALNAME

The pname to uid functionality at present assumes there is
an implementation of getpwnam() and that the local user
identifier is an integer.  On Windows, the local user identifier
is a SId.  Add NO_LOCALNAME as a build option so that Windows
(for now) can build without providing a getpwnam() implementation.

Change-Id: I04cfd6d2cd52e6228733f1da1dab420b453e6566
This commit is contained in:
Jeffrey Altman
2011-05-17 13:56:37 -04:00
parent dbbf89bccf
commit 87aad6a13a
4 changed files with 13 additions and 0 deletions

View File

@@ -59,6 +59,9 @@ attr_pname_to_uid(OM_uint32 *minor_status,
struct _gss_mechanism_name *mn,
uid_t *uidp)
{
#ifdef NO_LOCALNAME
return GSS_S_UNAVAILABLE;
#else
OM_uint32 major_status = GSS_S_UNAVAILABLE;
OM_uint32 tmpMinor;
int more = -1;
@@ -124,6 +127,7 @@ attr_pname_to_uid(OM_uint32 *minor_status,
}
return major_status;
#endif /* NO_LOCALNAME */
}
OM_uint32