From 68594d15c56a21e3d4d8cd12fefbc5bbf0af002f Mon Sep 17 00:00:00 2001 From: Laurent Bercot Date: Thu, 2 Aug 2018 22:17:55 +0000 Subject: Complete libnsssd and libnsss documentation --- doc/libnsssd/index.html | 45 ++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 44 insertions(+), 1 deletion(-) (limited to 'doc/libnsssd') diff --git a/doc/libnsssd/index.html b/doc/libnsssd/index.html index ec2c5d4..76eb7df 100644 --- a/doc/libnsssd/index.html +++ b/doc/libnsssd/index.html @@ -94,8 +94,51 @@ This function must deinitialize the handle and free all related resources: close connections to external processes, etc.

+

int nsssd_pwd_start (void *handle)

- TODO: to be completed. +This function will be called at the start of a passwd enumeration. +It must return nonzero on success and 0 on error. +

+ +

int nsssd_pwd_rewind (void *handle)

+

+This function will be called on a setpwent() call. +It must rewind the current enumeration to the start of the +database. +It must return nonzero on success and 0 on error. +

+ +

int nsssd_pwd_get (void *handle, struct passwd *pw)

+

+This function will be called on every getpwent() call, i.e. +on every iteration of an enumeration. On error, it must return 0; on +success, it must return nonzero and store the obtained passwd structure +into *pw. +

+ +

void nsssd_pwd_end (void *handle)

+

+This function will be called at the end of a passwd enumeration. +

+ +

int nsssd_pwd_getbyuid (void *handle, struct passwd *pw, uid_t uid)

+

+This function must implement a getpwuid(uid) call. On error, it must +return 0; on success, it must return nonzero and store the result into +*pw. +

+ +

int nsssd_pwd_getbyname (void *handle, struct passwd *pw, char const *name)

+

+This function must implement a getpwnam(name) call. On error, it must +return 0; on success, it must return nonzero and store the result into +*pw. +

+ +

+ Similar functions for the group and shadow databases must also be implemented. +The full list can be found in the +nsss/nsssd.h header.

-- cgit v1.3.1