openldap/include
Kurt Zeilenga 8de258d2e2 Patch: 'ldapmodify -y file' reads password from file (ITS#2031)
================
Written by Hallvard B. Furuseth and placed into the public domain.
This software is not subject to any license of the University of Oslo.
            ================
Adapted by Kurt Zeilenga for inclusion in OpenLDAP.  My comments are
marked with enclosed with square brackets (e.g. [Kurt's comment] below.
            ================

If I run ldapmodify & co from a script, I don't want to use '-W password'
because the password shows up in the output of 'ps' for everyone,
and I can't pipe the password to 'ldapmodify -w' because -w uses
getpassphrase() which reads from the tty instead of stdin.
So I added '-y file' which reads the password from file.  The programs
exit if the file cannot be read.

[Complete contents of file is used as password.  Use:
	echo -n "secret" > password
to create a file with "secret" as the password.  The -n avoids
adding a newline (which would invalidate the password).  Note
that echo is a builtin and hence its arguments are not visible
to 'ps'.]

I changed ldapmodify, ldapmodrdn, ldapdelete, ldapsearch, ldapcompare.
I did not bother to change ldappasswd and ldapwhoami, because they
prompt for many passwords.  [I fixed up ldapwhoami.]

Rerun autoconf after applying this patch. [Done.]

Note:  I do not know if Windows NT has fstat(), so I set HAVE_FSTAT to
undef in portable.nt.  (fstat() is used to warn if the file is publicly
readable or writeable.)  [I used fstat() to set the buffer size to
read.]

[Note: using the contents of a file extends the tools to support
passwords which could not normally be provided using getpassphrase()
or via the command line.]

Hallvard B. Furuseth <h.b.furuseth@usit.uio.no>, Aug 2002.
[Kurt D. Zeilenga <kurt@openldap.org>, Aug 2002.]
2002-08-24 05:47:17 +00:00
..
ac Revert previous commit, too much broken 2002-07-26 14:22:45 +00:00
avl.h Update copyright notices 2002-01-04 20:40:29 +00:00
getopt-compat.h Update copyright notices 2002-01-04 20:40:29 +00:00
lber_pvt.h use BVC() macro (changed in BER_BVC) to initialize constant bervals 2002-04-08 18:37:37 +00:00
lber_types.h.in Update copyright notices 2002-01-04 20:40:29 +00:00
lber_types.nt Update copyright notices 2002-01-04 20:40:29 +00:00
lber.h For ITS#1601, add ber_init2() using given buffer in-place instead of 2002-02-14 13:32:40 +00:00
ldap_cdefs.h Update copyright notices 2002-01-04 20:40:29 +00:00
ldap_config.h.in Delete defs for FINGER 2002-05-18 02:12:04 +00:00
ldap_config.nt Delete defs for FINGER 2002-05-18 02:12:04 +00:00
ldap_defaults.h remove cruft 2002-05-15 06:09:17 +00:00
ldap_features.h.in Update copyright notices 2002-01-04 20:40:29 +00:00
ldap_features.nt Update copyright notices 2002-01-04 20:40:29 +00:00
ldap_int_thread.h Update copyright notices 2002-01-04 20:40:29 +00:00
ldap_log.h Coverted LDAP_LOG macro to use subsystem ID int values instead of string values 2002-07-11 20:33:24 +00:00
ldap_pvt_thread.h Added thread-pool getkey/setkey functions 2002-08-24 05:39:43 +00:00
ldap_pvt_uc.h include actual ucdata.h, not the symlink. liblutil/passwd.c needs this 2002-08-22 11:44:27 +00:00
ldap_pvt.h add upper/lower funcs that also compute the length of the string (not used yet) 2002-08-23 08:45:17 +00:00
ldap_queue.h Update copyright notices 2002-01-04 20:40:29 +00:00
ldap_schema.h Update copyright notices 2002-01-04 20:40:29 +00:00
ldap_utf8.h Update copyright notices 2002-01-04 20:40:29 +00:00
ldap.h paged results uses one OID for both request and response 2002-08-12 19:49:20 +00:00
ldbm.h Update copyright notices 2002-01-04 20:40:29 +00:00
ldif.h Update copyright notices 2002-01-04 20:40:29 +00:00
lutil_hash.h Update copyright notices 2002-01-04 20:40:29 +00:00
lutil_ldap.h Update copyright notices 2002-01-04 20:40:29 +00:00
lutil_lockf.h Update copyright notices 2002-01-04 20:40:29 +00:00
lutil_md5.h Update copyright notices 2002-01-04 20:40:29 +00:00
lutil_sha1.h Update copyright notices 2002-01-04 20:40:29 +00:00
lutil.h Patch: 'ldapmodify -y file' reads password from file (ITS#2031) 2002-08-24 05:47:17 +00:00
Makefile.in Delete defs for FINGER 2002-05-18 02:12:04 +00:00
portable.h.in Patch: 'ldapmodify -y file' reads password from file (ITS#2031) 2002-08-24 05:47:17 +00:00
portable.nt Patch: 'ldapmodify -y file' reads password from file (ITS#2031) 2002-08-24 05:47:17 +00:00
rewrite.h cleanup 2002-01-12 16:11:40 +00:00
setup.dsp
setup.dsw
setup.mak Update copyright notices 2002-01-04 20:40:29 +00:00
sysexits-compat.h Update copyright notices 2002-01-04 20:40:29 +00:00