Arthur de Jong

Open Source / Free Software developer

summaryrefslogtreecommitdiffstats
path: root/nss/networks.c
Commit message (Collapse)AuthorAgeFilesLines
* refactor the read_result() functions into a common macro ↵Arthur de Jong2012-10-281-34/+1
| | | | | | and move all the Solaris-specific definitions to solnss.h git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1812 ef36b2f9-881f-0410-afb5-c4e39611909c
* introduce ent2str() functions for each database (except ↵Arthur de Jong2012-10-261-44/+52
| | | | | | ether and netgroup) and make buffer handling consistent (for Solaris) git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1808 ef36b2f9-881f-0410-afb5-c4e39611909c
* clear the *ent structs before writing fields to avoid ↵Arthur de Jong2012-09-151-0/+1
| | | | | | problems with extra fields (fixes password field weirdness on Solaris 10) git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1767 ef36b2f9-881f-0410-afb5-c4e39611909c
* on Solaris store the errno value in NSS_ARGS(args)->erangeArthur de Jong2012-09-031-4/+4
| | | | git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1747 ef36b2f9-881f-0410-afb5-c4e39611909c
* remove unused variableArthur de Jong2011-08-141-4/+3
| | | | git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1505 ef36b2f9-881f-0410-afb5-c4e39611909c
* switch to a common back-end with a common constructor ↵Arthur de Jong2010-12-161-24/+10
| | | | | | and destructor and put file pointer shared between {set,get,end}ent() calls in there git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd-solaris@1333 ef36b2f9-881f-0410-afb5-c4e39611909c
* have a more consistent naming convention for static ↵Arthur de Jong2010-12-131-13/+13
| | | | | | lookup functions git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd-solaris@1331 ef36b2f9-881f-0410-afb5-c4e39611909c
* fix assignment in if statement (was broken in r1262)Arthur de Jong2010-12-131-2/+2
| | | | git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd-solaris@1330 ef36b2f9-881f-0410-afb5-c4e39611909c
* also try to support older Solaris releases that do not ↵Arthur de Jong2010-10-111-2/+13
| | | | | | have the returnlen member of struct nss_XbyY_args git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd-solaris@1262 ef36b2f9-881f-0410-afb5-c4e39611909c
* generate Solaris NSS functions using same macros that ↵Arthur de Jong2010-10-101-176/+52
| | | | | | are used for Glibc, splitting functionality to make a string representation into a single function per NSS map git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd-solaris@1258 ef36b2f9-881f-0410-afb5-c4e39611909c
* have one shared file handle per flavour instead of one ↵Arthur de Jong2010-10-091-5/+4
| | | | | | global one (for now) and re-introduce some other minor changes that got lost in r1247 git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd-solaris@1249 ef36b2f9-881f-0410-afb5-c4e39611909c
* nss-pam-ldapd fixes for solaris 10 buildTed Cheng2010-10-091-7/+13
| | | | git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd-solaris@1247 ef36b2f9-881f-0410-afb5-c4e39611909c
* re-introduce {set,get,end}**ent() file handle in Solaris ↵Arthur de Jong2010-10-081-3/+5
| | | | | | code path and some other miscellaneous small fixes git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd-solaris@1246 ef36b2f9-881f-0410-afb5-c4e39611909c
* merge changes from trunkArthur de Jong2010-10-041-5/+9
|\ | | | | | | git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd-solaris@1242 ef36b2f9-881f-0410-afb5-c4e39611909c
| * improve consistency of code layoutArthur de Jong2010-10-041-4/+14
| | | | | | | | git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1240 ef36b2f9-881f-0410-afb5-c4e39611909c
| * merge some of the changes for Solaris portability to ↵Arthur de Jong2010-10-041-8/+8
| | | | | | | | | | | | ease merging, adding --with-pam-seclib-dir, --with-pam-ldap-soname and --with-nss-flavour options and having some auto-detection for SONAMEs and NSS flavour git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1239 ef36b2f9-881f-0410-afb5-c4e39611909c
* | try to make use of UNUSED() consistentArthur de Jong2010-10-041-8/+8
| | | | | | | | git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd-solaris@1241 ef36b2f9-881f-0410-afb5-c4e39611909c
* | first attempt to split Solaris and Glibc code more and ↵Arthur de Jong2010-10-031-56/+85
| | | | | | | | | | | | determine NSS flavour in configure script git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd-solaris@1236 ef36b2f9-881f-0410-afb5-c4e39611909c
* | import Solaris support developed by Ted C. Cheng of ↵Arthur de Jong2010-09-301-4/+212
|/ | | | | | Symas Corporation merged against SVN head (parts remain to be cleaned up) git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd-solaris@1232 ef36b2f9-881f-0410-afb5-c4e39611909c
* switch to using nss_status_t throughout the code and ↵Arthur de Jong2010-09-241-7/+7
| | | | | | provide compatibility code to use whatever nss_status type is used on the system git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1214 ef36b2f9-881f-0410-afb5-c4e39611909c
* remove some unused include statementsArthur de Jong2010-06-141-1/+0
| | | | git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1139 ef36b2f9-881f-0410-afb5-c4e39611909c
* fix missing argument (problem in r1039)Arthur de Jong2009-12-281-1/+1
| | | | git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1040 ef36b2f9-881f-0410-afb5-c4e39611909c
* Glibc changed the addr parameter of getnetbyaddr_r() ↵Arthur de Jong2009-12-281-5/+7
| | | | | | from network-byte-order to host-byte-order git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@1039 ef36b2f9-881f-0410-afb5-c4e39611909c
* refactor protocol reading and writing macros to the ↵Arthur de Jong2009-05-211-2/+2
| | | | | | common directory, use more logical names and in the PAM module no longer use NSS status codes git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-pam-ldapd@887 ef36b2f9-881f-0410-afb5-c4e39611909c
* do not set errno (and h_errno) if we got the last entry ↵Arthur de Jong2008-02-011-8/+0
| | | | | | from get*ent() (this apparently is needed by coreutils' id and groups commands) git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-ldapd@601 ef36b2f9-881f-0410-afb5-c4e39611909c
* remove the nslcd2nss() function because it's not needed ↵Arthur de Jong2008-02-011-1/+1
| | | | | | with the current protocol git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-ldapd@597 ef36b2f9-881f-0410-afb5-c4e39611909c
* only start the NSLCD_ACTION_*_ALL requests with the ↵Arthur de Jong2008-01-031-8/+3
| | | | | | first call to getent() instead of with setent() to avoid unneeded requests if compat is used (except with netgroups) git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-ldapd@556 ef36b2f9-881f-0410-afb5-c4e39611909c
* correct calls to NSLCD_ACTION_NETWORK_BYNAME and ↵Arthur de Jong2007-10-211-3/+3
| | | | | | NSLCD_ACTION_NETWORK_BYADDR and get address in correct byte order with the last call git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-ldapd@449 ef36b2f9-881f-0410-afb5-c4e39611909c
* flag the address family parameter as unusedArthur de Jong2007-07-131-1/+1
| | | | git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-ldapd@300 ef36b2f9-881f-0410-afb5-c4e39611909c
* implement our own stdio-like library that handles IO ↵Arthur de Jong2007-06-091-5/+5
| | | | | | with a simple configurable timeout mechanism with buffering git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-ldapd@272 ef36b2f9-881f-0410-afb5-c4e39611909c
* code improvements by making type casts explicit, ↵Arthur de Jong2007-03-041-4/+4
| | | | | | flagging ignored return values, renames and flagging of parameters and some miscelanious improvements (thanks to gcc warnings, splint, rats and flawfinder) git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-ldapd@265 ef36b2f9-881f-0410-afb5-c4e39611909c
* add gcc attributes to some functions and parametersArthur de Jong2007-02-171-1/+2
| | | | git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-ldapd@250 ef36b2f9-881f-0410-afb5-c4e39611909c
* ensure that all NSS functions can be generated by the ↵Arthur de Jong2007-01-171-77/+42
| | | | | | marcos in common.h and spell out the read_..() function for every type git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-ldapd@227 ef36b2f9-881f-0410-afb5-c4e39611909c
* change license from GNU Library General Public License ↵Arthur de Jong2007-01-091-7/+7
| | | | | | v.2 to GNU Lesser General Public License v.2.1 with permission from Luke Howard git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/nss-ldapd@215 ef36b2f9-881f-0410-afb5-c4e39611909c
* implement network name lookups on server side plus some ↵Arthur de Jong2006-11-281-3/+6
| | | | | | fixes on the client side git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/libnss_ldapd@130 ef36b2f9-881f-0410-afb5-c4e39611909c
* get rid of nslcd-client.{c,h} and move it to ↵Arthur de Jong2006-11-271-1/+0
| | | | | | nss/common.{c,h}, this ensures that all code that is needed for the nss part is in the nss directory git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/libnss_ldapd@127 ef36b2f9-881f-0410-afb5-c4e39611909c
* do some refactoring in the generated code and add some ↵Arthur de Jong2006-11-171-6/+5
| | | | | | documentation on generated code in comments in common.h git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/libnss_ldapd@96 ef36b2f9-881f-0410-afb5-c4e39611909c
* switch to a simpler and more compact framework to ↵Arthur de Jong2006-11-161-2/+2
| | | | | | generate methods (one reader function to deserialize a struct from the stream and auto-generated functions) git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/libnss_ldapd@92 ef36b2f9-881f-0410-afb5-c4e39611909c
* implement network information lookups through NSSArthur de Jong2006-11-151-0/+188
git-svn-id: http://arthurdejong.org/svn/nss-pam-ldapd/libnss_ldapd@91 ef36b2f9-881f-0410-afb5-c4e39611909c