Go to the source code of this file.
|
int | nfs41_idmap_create (nfs41_idmapper **context_out) |
|
void | nfs41_idmap_free (nfs41_idmapper *context) |
|
int | nfs41_idmap_name_to_ids (nfs41_idmapper *context, const char *username, uid_t *uid_out, gid_t *gid_out) |
|
int | nfs41_idmap_uid_to_name (nfs41_idmapper *context, uid_t uid, char *name_out, size_t len) |
|
int | nfs41_idmap_principal_to_ids (nfs41_idmapper *context, const char *principal, uid_t *uid_out, gid_t *gid_out) |
|
int | nfs41_idmap_group_to_gid (nfs41_idmapper *context, const char *name, gid_t *gid_out) |
|
int | nfs41_idmap_gid_to_group (nfs41_idmapper *context, gid_t gid, char *name_out, size_t len) |
|
◆ nfs41_idmapper
◆ nfs41_idmap_create()
Definition at line 805 of file idmap.c.
832 eprintf(
"ldap_init(%s) failed with %d: %s\n",
839 (
void *)&
context->config.version);
841 eprintf(
"ldap_set_option(version=%d) failed with %d\n",
849 (
void *)&
context->config.timeout);
851 eprintf(
"ldap_set_option(timeout=%d) failed with %d\n",
static const struct cache_ops group_cache_ops
DWORD WINAPI GetLastError(VOID)
void eprintf(LPCSTR format,...)
PCHAR CDECL ldap_err2stringA(ULONG err)
#define LDAP_OPT_PROTOCOL_VERSION
#define LDAP_OPT_TIMELIMIT
ULONG CDECL LdapMapErrorToWin32(ULONG err)
static const struct cache_ops user_cache_ops
_In_opt_ PVOID _In_ ULONG _In_ PVOID context
ULONG CDECL LdapGetLastError(void)
static int config_init(struct idmap_config *config)
static void cache_init(struct idmap_cache *cache, const struct cache_ops *ops)
static SERVICE_STATUS status
void nfs41_idmap_free(struct idmap_context *context)
Referenced by ServiceStart().
◆ nfs41_idmap_free()
◆ nfs41_idmap_gid_to_group()
Definition at line 1055 of file idmap.c.
1068 lookup.value = (
const void*)gidp;
1080 eprintf(
"group name buffer overflow: '%s' > %u\n",
1086 "returning '%s'\n",
gid,
name);
#define ERROR_BUFFER_OVERFLOW
void eprintf(LPCSTR format,...)
static int idmap_lookup_group(struct idmap_context *context, const struct idmap_lookup *lookup, struct idmap_group *group)
unsigned __int3264 UINT_PTR
static int gid_cmp(const struct list_entry *list, const void *value)
STRSAFEAPI StringCchCopyA(STRSAFE_LPSTR pszDest, size_t cchDest, STRSAFE_LPCSTR pszSrc)
static SERVICE_STATUS status
◆ nfs41_idmap_group_to_gid()
Definition at line 1017 of file idmap.c.
1039 *gid_out =
group.gid;
static int group_cmp(const struct list_entry *list, const void *value)
static int idmap_lookup_group(struct idmap_context *context, const struct idmap_lookup *lookup, struct idmap_group *group)
static SERVICE_STATUS status
GLuint const GLchar * name
◆ nfs41_idmap_name_to_ids()
Definition at line 889 of file idmap.c.
static int idmap_lookup_user(struct idmap_context *context, const struct idmap_lookup *lookup, struct idmap_user *user)
static int username_cmp(const struct list_entry *list, const void *value)
#define ERROR_FILE_NOT_FOUND
static SERVICE_STATUS status
void user(int argc, const char *argv[])
Referenced by map_user_to_ids().
◆ nfs41_idmap_principal_to_ids()
Definition at line 977 of file idmap.c.
995 dprintf(
IDLVL,
"<-- nfs41_idmap_principal_to_ids('%s') " 1000 *uid_out =
user.uid;
1001 *gid_out =
user.gid;
1002 dprintf(
IDLVL,
"<-- nfs41_idmap_principal_to_ids('%s') "
static int idmap_lookup_user(struct idmap_context *context, const struct idmap_lookup *lookup, struct idmap_user *user)
static int principal_cmp(const struct list_entry *list, const void *value)
static SERVICE_STATUS status
void user(int argc, const char *argv[])
◆ nfs41_idmap_uid_to_name()
Definition at line 932 of file idmap.c.
945 lookup.value = (
const void*)uidp;
957 eprintf(
"username buffer overflow: '%s' > %u\n",
963 "returning '%s'\n",
uid,
name);
#define ERROR_BUFFER_OVERFLOW
static int uid_cmp(const struct list_entry *list, const void *value)
void eprintf(LPCSTR format,...)
static int idmap_lookup_user(struct idmap_context *context, const struct idmap_lookup *lookup, struct idmap_user *user)
unsigned __int3264 UINT_PTR
STRSAFEAPI StringCchCopyA(STRSAFE_LPSTR pszDest, size_t cchDest, STRSAFE_LPCSTR pszSrc)
static SERVICE_STATUS status
void user(int argc, const char *argv[])