See bug # 188396 - NSPR should not use ftime on windows.
This fixes a potential Year 2038 issue.
git-svn-id: svn://10.0.0.236/trunk@139942 18797224-902f-48f8-a5cc-f745e15eee43
The LDAP tools code no longer has any knowledge of the NSS
file names; the certpath2keypath() function has been deleted
and we now simply use the certdbpath as keydbpath when it is
provided (it makes no difference in the end). But note that
because we need to maintain backwards compatibility, the
libssldap code used by the ldapssl_.*_init() functions still
knows the default name of the NSS module file (secmod.db),
and the code also relies on the fact that the suffix for the
key and cert files is ".db" and that the first letter in the
main part of the name is either 'c' or 'k'.
Also fixed a bug that caused the module file name specified on
the LDAP tools command line (-m name) to be ignored.
The ldapsearch and ldapcmp tools now exit with LDAP_NO_MEMORY
if an LDIF fragment can't be constructed.
Also fixed some issues reported by lint:
Return values that were ignored.
Make more functions and global variables static.
Add /*ARGSUSED*/ and similar lint-friendly comments.
git-svn-id: svn://10.0.0.236/trunk@139935 18797224-902f-48f8-a5cc-f745e15eee43
If HAVE_LIBNLS is not defined, OS functions (iconv and Win32
native APIs) are used for character set conversion of command
line arguments.
Fix bug # 177766 - LDAP tools should reject second -h argument.
A second -p argument is also rejected.
Fix bug # 159139 - HP/UX: LDAP command line tools do no charset conversion.
Removed special case makefile rules for convutf8.cpp on HP/UX.
git-svn-id: svn://10.0.0.236/trunk@134797 18797224-902f-48f8-a5cc-f745e15eee43
If a NULL keypasswd value is passed to ldapssl_enable_clientauth()
then it is assumed that the application has already unlocked
the key DB or has installed its own GetPassword callback.
Also improved some error reporting.
git-svn-id: svn://10.0.0.236/trunk@134796 18797224-902f-48f8-a5cc-f745e15eee43
Define 32-bit integral types in portable.h (nsldapi_int_32 and
nsldapi_uint_32) and use them in the memcache crc32_convert()
function.
git-svn-id: svn://10.0.0.236/trunk@133919 18797224-902f-48f8-a5cc-f745e15eee43
The prldap_tsd_destroy() function (which is called when a
thread exits) was not freeing the information contained within
the PRLDAP_ErrorInfo structure. Added prldap_free_errorinfo()
and a way to determine if that thread-private data looks like
error information (the plei_magic field). At the moment, only
one kind of thread-private data is stored anyway (the error
information).
The prldap_allocate_map() function, which is called when a new
LDAP session is created, was blindly setting the thread-private
error information pointer to NULL. But if a different thread
created or used an LDAP session than called ldap_unbind(), old
error information may have been left in memory. Now the error
info. pointer is reset and reused, which was the original goal.
git-svn-id: svn://10.0.0.236/trunk@133859 18797224-902f-48f8-a5cc-f745e15eee43
Check that a sequence of set has been created before using
it inside ber_put_seqorset().
git-svn-id: svn://10.0.0.236/trunk@132819 18797224-902f-48f8-a5cc-f745e15eee43
[@nsAboutProtocolHandler:122]] This is a regression fix from the fix
for bug 163225. The assertions never made sense and now they are
exposed. r=bzbarsky, sr=darin
git-svn-id: svn://10.0.0.236/trunk@128681 18797224-902f-48f8-a5cc-f745e15eee43