From patchwork Fri Oct 19 21:08:10 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chuck Lever X-Patchwork-Id: 192809 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from rcsinet15.oracle.com (rcsinet15.oracle.com [148.87.113.117]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "rcsinet15.oracle.com", Issuer "VeriSign Class 3 International Server CA - G3" (not verified)) by ozlabs.org (Postfix) with ESMTPS id D51E62C0090 for ; Sat, 20 Oct 2012 08:08:20 +1100 (EST) Received: from acsinet21.oracle.com (acsinet21.oracle.com [141.146.126.237]) by rcsinet15.oracle.com (Sentrion-MTA-4.2.2/Sentrion-MTA-4.2.2) with ESMTP id q9JL8HuI001629 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 19 Oct 2012 21:08:17 GMT Received: from oss.oracle.com (oss-external.oracle.com [137.254.96.51]) by acsinet21.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id q9JL8G1V029981 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 19 Oct 2012 21:08:17 GMT Received: from localhost ([127.0.0.1] helo=oss.oracle.com) by oss.oracle.com with esmtp (Exim 4.63) (envelope-from ) id 1TPJnk-0007Gy-ME; Fri, 19 Oct 2012 14:08:16 -0700 Received: from ucsinet22.oracle.com ([156.151.31.94]) by oss.oracle.com with esmtp (Exim 4.63) (envelope-from ) id 1TPJnh-0007Go-Vh for fedfs-utils-devel@oss.oracle.com; Fri, 19 Oct 2012 14:08:14 -0700 Received: from acsinet11.oracle.com (acsinet11.oracle.com [141.146.126.233]) by ucsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id q9JL8Dnd026418 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Fri, 19 Oct 2012 21:08:13 GMT Received: from mail-ia0-f171.google.com (mail-ia0-f171.google.com [209.85.210.171]) by acsinet11.oracle.com (Sentrion-MTA-4.2.2/Sentrion-MTA-4.2.2) with ESMTP id q9JL7bV4005718 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=OK) for ; Fri, 19 Oct 2012 21:08:12 GMT Received: by mail-ia0-f171.google.com with SMTP id u21so674450ial.2 for ; Fri, 19 Oct 2012 14:08:12 -0700 (PDT) Received: by 10.50.6.225 with SMTP id e1mr2831681iga.68.1350680891928; Fri, 19 Oct 2012 14:08:11 -0700 (PDT) Received: from seurat.1015granger.net (adsl-99-26-161-222.dsl.sfldmi.sbcglobal.net. [99.26.161.222]) by mx.google.com with ESMTPS id 10sm16672208ign.5.2012.10.19.14.08.11 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 19 Oct 2012 14:08:11 -0700 (PDT) From: Chuck Lever To: fedfs-utils-devel@oss.oracle.com Date: Fri, 19 Oct 2012 17:08:10 -0400 Message-ID: <20121019210810.53119.10389.stgit@seurat.1015granger.net> In-Reply-To: <20121019210357.53119.28925.stgit@seurat.1015granger.net> References: <20121019210357.53119.28925.stgit@seurat.1015granger.net> User-Agent: StGIT/0.14.3 MIME-Version: 1.0 X-Flow-Control-Info: class=Default reputation=ipRepBelow100 ip=209.85.210.171 ct-class=G1 ct-vol1=0 ct-vol2=0 ct-vol3=0 ct-risk=0 ct-spam1=0 ct-spam2=0 ct-bulk=0 rcpts=1 size=20892 X-MM-CT-Classification: not spam X-MM-CT-RefID: str=0001.0A090203.5081C13C.0076,ss=1,re=-2.300,fgs=0 Subject: [fedfs-utils] [PATCH 04/11] Deprecate the FEDFS_NSDB_PASSWD environment variable X-BeenThere: fedfs-utils-devel@oss.oracle.com X-Mailman-Version: 2.1.9 Precedence: list Reply-To: fedfs-utils Developers List-Id: fedfs-utils Developers List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: fedfs-utils-devel-bounces@oss.oracle.com Errors-To: fedfs-utils-devel-bounces@oss.oracle.com X-Source-IP: acsinet21.oracle.com [141.146.126.237] Secure Coding Practice requires that clear-text passwords never be stored in environment variables. Signed-off-by: Chuck Lever --- doc/man/nfsref.8 | 9 --------- doc/man/nsdb-annotate.8 | 4 ---- doc/man/nsdb-create-fsl.8 | 4 ---- doc/man/nsdb-create-fsn.8 | 4 ---- doc/man/nsdb-delete-fsl.8 | 4 ---- doc/man/nsdb-delete-fsn.8 | 4 ---- doc/man/nsdb-delete-nsdb.8 | 4 ---- doc/man/nsdb-describe.8 | 4 ---- doc/man/nsdb-remove-nci.8 | 4 ---- doc/man/nsdb-update-fsl.8 | 4 ---- doc/man/nsdb-update-nci.8 | 4 ---- src/fedfsc/fedfs-create-junction.c | 2 +- src/fedfsc/fedfs-create-replication.c | 2 +- src/fedfsc/fedfs-get-limited-nsdb-params.c | 2 +- src/fedfsc/fedfs-get-nsdb-params.c | 2 +- src/fedfsc/fedfs-set-nsdb-params.c | 2 +- src/include/nsdb.h | 2 +- src/libnsdb/nsdb.c | 11 +---------- src/nfsref/add.c | 6 +++--- src/nfsref/remove.c | 6 +++--- src/nsdbc/nsdb-annotate.c | 3 ++- src/nsdbc/nsdb-create-fsl.c | 3 ++- src/nsdbc/nsdb-create-fsn.c | 3 ++- src/nsdbc/nsdb-delete-fsl.c | 3 ++- src/nsdbc/nsdb-delete-fsn.c | 3 ++- src/nsdbc/nsdb-delete-nsdb.c | 3 ++- src/nsdbc/nsdb-describe.c | 3 ++- src/nsdbc/nsdb-list.c | 2 +- src/nsdbc/nsdb-nces.c | 2 +- src/nsdbc/nsdb-remove-nci.c | 3 ++- src/nsdbc/nsdb-resolve-fsn.c | 2 +- src/nsdbc/nsdb-update-fsl.c | 3 ++- src/nsdbc/nsdb-update-nci.c | 3 ++- 33 files changed, 36 insertions(+), 84 deletions(-) diff --git a/doc/man/nfsref.8 b/doc/man/nfsref.8 index 8abfc8c..3db0b79 100644 --- a/doc/man/nfsref.8 +++ b/doc/man/nfsref.8 @@ -204,15 +204,6 @@ If neither of these is specified, or if this entity does not have permission to modify the LDAP server's DIT, the .BR nfsref (8) command fails. -.IP "\fBFEDFS_NSDB_PASSWD\fP" -Specifies the password used for simple authentication -to the LDAP server where new FedFS records should reside. -If this variable is not set, the -.BR nfsref (8) -command asks for a password on -.IR stdin . -Standard password blanking techniques are used to obscure the -password on the user's terminal. .SS Command line options .IP "\fB\-d, \-\-debug" Enables debugging messages during operation. diff --git a/doc/man/nsdb-annotate.8 b/doc/man/nsdb-annotate.8 index 4285073..31ca9da 100644 --- a/doc/man/nsdb-annotate.8 +++ b/doc/man/nsdb-annotate.8 @@ -209,10 +209,6 @@ Specifies the password used for simple authentication to the LDAP server where the NSDB resides. If the .B \-\-bindpw -option is not specified, -the value of the FEDFS_NSDB_PASSWD environment variable is consulted. -If the variable is not set and the -.B \-\-bindpw option is not specified, the .BR nsdb-annotate (8) command asks for a password on diff --git a/doc/man/nsdb-create-fsl.8 b/doc/man/nsdb-create-fsl.8 index 087149c..bab397e 100644 --- a/doc/man/nsdb-create-fsl.8 +++ b/doc/man/nsdb-create-fsl.8 @@ -173,10 +173,6 @@ Specifies the password used for simple authentication to the LDAP server where the NSDB resides. If the .B \-\-bindpw -option is not specified, -the value of the FEDFS_NSDB_PASSWD environment variable is consulted. -If the variable is not set and the -.B \-\-bindpw option is not specified, the .BR nsdb-create-fsl (8) command asks for a password on diff --git a/doc/man/nsdb-create-fsn.8 b/doc/man/nsdb-create-fsn.8 index accf493..e4fb8d8 100644 --- a/doc/man/nsdb-create-fsn.8 +++ b/doc/man/nsdb-create-fsn.8 @@ -153,10 +153,6 @@ Specifies the password used for simple authentication to the LDAP server where the NSDB resides. If the .B \-\-bindpw -option is not specified, -the value of the FEDFS_NSDB_PASSWD environment variable is consulted. -If the variable is not set and the -.B \-\-bindpw option is not specified, the .BR nsdb-create-fsn (8) command asks for a password on diff --git a/doc/man/nsdb-delete-fsl.8 b/doc/man/nsdb-delete-fsl.8 index 17c2dde..11a7921 100644 --- a/doc/man/nsdb-delete-fsl.8 +++ b/doc/man/nsdb-delete-fsl.8 @@ -157,10 +157,6 @@ Specifies the password used for simple authentication to the LDAP server where the NSDB resides. If the .B \-\-bindpw -option is not specified, -the value of the FEDFS_NSDB_PASSWD environment variable is consulted. -If the variable is not set and the -.B \-\-bindpw option is not specified, the .BR nsdb-delete-fsl (8) command asks for a password on diff --git a/doc/man/nsdb-delete-fsn.8 b/doc/man/nsdb-delete-fsn.8 index 2462964..0526d43 100644 --- a/doc/man/nsdb-delete-fsn.8 +++ b/doc/man/nsdb-delete-fsn.8 @@ -159,10 +159,6 @@ Specifies the password used for simple authentication to th LDAP server where the NSDB resides. If the .B \-\-bindpw -option is not specified, -the value of the FEDFS_NSDB_PASSWD environment variable is consulted. -If the variable is not set and the -.B \-\-bindpw option is not specified, the .BR nsdb-delete-fsn (8) command asks for a password on diff --git a/doc/man/nsdb-delete-nsdb.8 b/doc/man/nsdb-delete-nsdb.8 index 06a2538..f72760f 100644 --- a/doc/man/nsdb-delete-nsdb.8 +++ b/doc/man/nsdb-delete-nsdb.8 @@ -127,10 +127,6 @@ Specifies the password used for simple authentication to th LDAP server where the NSDB resides. If the .B \-\-bindpw -option is not specified, -the value of the FEDFS_NSDB_PASSWD environment variable is consulted. -If the variable is not set and the -.B \-\-bindpw option is not specified, the .BR nsdb-delete-nsdb (8) command asks for a password on diff --git a/doc/man/nsdb-describe.8 b/doc/man/nsdb-describe.8 index 254d443..59ca626 100644 --- a/doc/man/nsdb-describe.8 +++ b/doc/man/nsdb-describe.8 @@ -154,10 +154,6 @@ Specifies the password used for simple authentication to the LDAP server where the NSDB resides. If the .B \-\-bindpw -option is not specified, -the value of the FEDFS_NSDB_PASSWD environment variable is consulted. -If the variable is not set and the -.B \-\-bindpw option is not specified, the .BR nsdb-describe (8) command asks for a password on diff --git a/doc/man/nsdb-remove-nci.8 b/doc/man/nsdb-remove-nci.8 index 1d606e8..bebb027 100644 --- a/doc/man/nsdb-remove-nci.8 +++ b/doc/man/nsdb-remove-nci.8 @@ -150,10 +150,6 @@ Specifies the password used for simple authentication to the LDAP server where the NSDB resides If the .B \-\-bindpw -option is not specified, -the value of the FEDFS_NSDB_PASSWD environment variable is consulted. -If the variable is not set and the -.B \-\-bindpw option is not specified, the .BR nsdb-remove-nci (8) command asks for a password on diff --git a/doc/man/nsdb-update-fsl.8 b/doc/man/nsdb-update-fsl.8 index d1357c7..0df2d8b 100644 --- a/doc/man/nsdb-update-fsl.8 +++ b/doc/man/nsdb-update-fsl.8 @@ -176,10 +176,6 @@ Specifies the password used for simple authentication to the LDAP server where the NSDB resides. If the .B \-\-bindpw -option is not specified, -the value of the FEDFS_NSDB_PASSWD environment variable is consulted. -If the variable is not set and the -.B \-\-bindpw option is not specified, the .BR nsdb-update-fsl (8) command asks for a password on diff --git a/doc/man/nsdb-update-nci.8 b/doc/man/nsdb-update-nci.8 index 6c9b779..8149960 100644 --- a/doc/man/nsdb-update-nci.8 +++ b/doc/man/nsdb-update-nci.8 @@ -150,10 +150,6 @@ Specifies the password used for simple authentication to the LDAP server where the NSDB resides. If the .B \-\-bindpw -option is not specified, -the value of the FEDFS_NSDB_PASSWD environment variable is consulted. -If the variable is not set and the -.B \-\-bindpw option is not specified, the .BR nsdb-update-nci (8) command asks for a password on diff --git a/src/fedfsc/fedfs-create-junction.c b/src/fedfsc/fedfs-create-junction.c index 822f858..8eb4c15 100644 --- a/src/fedfsc/fedfs-create-junction.c +++ b/src/fedfsc/fedfs-create-junction.c @@ -205,7 +205,7 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, NULL, NULL, NULL); + nsdb_env(&nsdbname, &nsdbport, NULL, NULL); hostname = "localhost"; nettype = "netpath"; diff --git a/src/fedfsc/fedfs-create-replication.c b/src/fedfsc/fedfs-create-replication.c index f638ff1..6aef3ce 100644 --- a/src/fedfsc/fedfs-create-replication.c +++ b/src/fedfsc/fedfs-create-replication.c @@ -179,7 +179,7 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, NULL, NULL, NULL); + nsdb_env(&nsdbname, &nsdbport, NULL, NULL); hostname = "localhost"; nettype = "netpath"; diff --git a/src/fedfsc/fedfs-get-limited-nsdb-params.c b/src/fedfsc/fedfs-get-limited-nsdb-params.c index 5524635..7bda6eb 100644 --- a/src/fedfsc/fedfs-get-limited-nsdb-params.c +++ b/src/fedfsc/fedfs-get-limited-nsdb-params.c @@ -173,7 +173,7 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, NULL, NULL, NULL); + nsdb_env(&nsdbname, &nsdbport, NULL, NULL); hostname = "localhost"; nettype = "netpath"; diff --git a/src/fedfsc/fedfs-get-nsdb-params.c b/src/fedfsc/fedfs-get-nsdb-params.c index d2c58d3..786804d 100644 --- a/src/fedfsc/fedfs-get-nsdb-params.c +++ b/src/fedfsc/fedfs-get-nsdb-params.c @@ -175,7 +175,7 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, NULL, NULL, NULL); + nsdb_env(&nsdbname, &nsdbport, NULL, NULL); hostname = "localhost"; nettype = "netpath"; diff --git a/src/fedfsc/fedfs-set-nsdb-params.c b/src/fedfsc/fedfs-set-nsdb-params.c index 37e77d7..df53620 100644 --- a/src/fedfsc/fedfs-set-nsdb-params.c +++ b/src/fedfsc/fedfs-set-nsdb-params.c @@ -207,7 +207,7 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, NULL, NULL, NULL); + nsdb_env(&nsdbname, &nsdbport, NULL, NULL); hostname = "localhost"; nettype = "netpath"; diff --git a/src/include/nsdb.h b/src/include/nsdb.h index 10558c5..8afefaa 100644 --- a/src/include/nsdb.h +++ b/src/include/nsdb.h @@ -236,7 +236,7 @@ _Bool nsdb_is_hostname_utf8(const char *hostname); * Look for "default" values in environment variables */ void nsdb_env(char **nsdbname, unsigned short *nsdbport, - char **binddn, char **nce, char **passwd); + char **binddn, char **nce); /** diff --git a/src/libnsdb/nsdb.c b/src/libnsdb/nsdb.c index b2325fb..4b35544 100644 --- a/src/libnsdb/nsdb.c +++ b/src/libnsdb/nsdb.c @@ -69,11 +69,6 @@ */ #define NSDB_NCE_ENV "FEDFS_NSDB_NCE" -/** - * Environment variable containing default password for NSDB - */ -#define NSDB_PASSWORD_ENV "FEDFS_NSDB_PASSWD" - /** * Stores pathname of directory containing FedFS persistent state @@ -388,7 +383,6 @@ nsdb_follow_referrals(const nsdb_t host) * @param nsdbport OUT: pointer to unsigned short NSDB port number * @param binddn OUT: pointer to statically allocated NUL-terminated C string containing NSDB bind DN * @param nce OUT: pointer to statically allocated NUL-terminated C string containing NSDB container entry DN - * @param passwd OUT: pointer to statically allocated NUL-terminated C string containing NSDB bind passwd * * Any of the returned strings can be NULL pointers, if those * variables do not appear in this process's environment. @@ -396,8 +390,7 @@ nsdb_follow_referrals(const nsdb_t host) * variable specifies an NSDB port number. */ void -nsdb_env(char **nsdbname, unsigned short *nsdbport, char **binddn, - char **nce, char **passwd) +nsdb_env(char **nsdbname, unsigned short *nsdbport, char **binddn, char **nce) { if (nsdbname != NULL) *nsdbname = getenv(NSDB_NAME_ENV); @@ -410,8 +403,6 @@ nsdb_env(char **nsdbname, unsigned short *nsdbport, char **binddn, *binddn = getenv(NSDB_BINDDN_ENV); if (nce != NULL) *nce = getenv(NSDB_NCE_ENV); - if (passwd != NULL) - *passwd = getenv(NSDB_PASSWORD_ENV); } /** diff --git a/src/nfsref/add.c b/src/nfsref/add.c index c5caa34..e437c8b 100644 --- a/src/nfsref/add.c +++ b/src/nfsref/add.c @@ -524,7 +524,7 @@ nfsref_add_nfs_fedfs_junction(const char *junct_path, char **argv, int optind, static int nfsref_add_nfs_fedfs(const char *junct_path, char **argv, int optind) { - char *binddn, *bindpw, *nsdbname, *nce; + char *binddn, *nsdbname, *nce; unsigned short nsdbport; unsigned int ldap_err; FedFsStatus retval; @@ -534,7 +534,7 @@ nfsref_add_nfs_fedfs(const char *junct_path, char **argv, int optind) xlog(D_GENERAL, "%s: Adding FedFS junction to %s", __func__, junct_path); - nsdb_env(&nsdbname, &nsdbport, &binddn, &nce, &bindpw); + nsdb_env(&nsdbname, &nsdbport, &binddn, &nce); if (nsdbname == NULL) { xlog(L_ERROR, "Cannot determine NSDB hostname"); return FEDFS_ERR_INVAL; @@ -567,7 +567,7 @@ nfsref_add_nfs_fedfs(const char *junct_path, char **argv, int optind) goto out_free; } - retval = nsdb_open_nsdb(host, binddn, bindpw, &ldap_err); + retval = nsdb_open_nsdb(host, binddn, NULL, &ldap_err); switch (retval) { case FEDFS_OK: break; diff --git a/src/nfsref/remove.c b/src/nfsref/remove.c index 8736097..7dd5997 100644 --- a/src/nfsref/remove.c +++ b/src/nfsref/remove.c @@ -116,9 +116,9 @@ nfsref_remove_nfs_basic(const char *junct_path) static FedFsStatus nfsref_remove_delete_fsn(const char *junct_path) { - char *binddn, *nce, *bindpw; char *fsn_uuid = NULL; unsigned int ldap_err; + char *binddn, *nce; FedFsStatus retval; nsdb_t host; @@ -136,7 +136,7 @@ nfsref_remove_delete_fsn(const char *junct_path) goto out; } - nsdb_env(NULL, NULL, &binddn, &nce, &bindpw); + nsdb_env(NULL, NULL, &binddn, &nce); retval = FEDFS_ERR_INVAL; if (binddn == NULL) @@ -152,7 +152,7 @@ nfsref_remove_delete_fsn(const char *junct_path) goto out_free; } - retval = nsdb_open_nsdb(host, binddn, bindpw, &ldap_err); + retval = nsdb_open_nsdb(host, binddn, NULL, &ldap_err); switch (retval) { case FEDFS_OK: break; diff --git a/src/nsdbc/nsdb-annotate.c b/src/nsdbc/nsdb-annotate.c index f875721..234e99a 100644 --- a/src/nsdbc/nsdb-annotate.c +++ b/src/nsdbc/nsdb-annotate.c @@ -137,7 +137,8 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, &binddn, NULL, &bindpw); + bindpw = NULL; + nsdb_env(&nsdbname, &nsdbport, &binddn, NULL); delete = false; keyword = value = entry = annotation = NULL; diff --git a/src/nsdbc/nsdb-create-fsl.c b/src/nsdbc/nsdb-create-fsl.c index 7f9ad1e..a76277c 100644 --- a/src/nsdbc/nsdb-create-fsl.c +++ b/src/nsdbc/nsdb-create-fsl.c @@ -135,7 +135,8 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, &binddn, &nce, &bindpw); + bindpw = NULL; + nsdb_env(&nsdbname, &nsdbport, &binddn, &nce); serverport = 0; while ((arg = getopt_long(argc, argv, nsdb_create_fsl_opts, diff --git a/src/nsdbc/nsdb-create-fsn.c b/src/nsdbc/nsdb-create-fsn.c index e46f0b5..402be08 100644 --- a/src/nsdbc/nsdb-create-fsn.c +++ b/src/nsdbc/nsdb-create-fsn.c @@ -131,7 +131,8 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, &binddn, &nce, &bindpw); + bindpw = NULL; + nsdb_env(&nsdbname, &nsdbport, &binddn, &nce); while ((arg = getopt_long(argc, argv, nsdb_create_fsn_opts, nsdb_create_fsn_longopts, NULL)) != -1) { diff --git a/src/nsdbc/nsdb-delete-fsl.c b/src/nsdbc/nsdb-delete-fsl.c index cd9e189..74f555a 100644 --- a/src/nsdbc/nsdb-delete-fsl.c +++ b/src/nsdbc/nsdb-delete-fsl.c @@ -135,7 +135,8 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, &binddn, &nce, &bindpw); + bindpw = NULL; + nsdb_env(&nsdbname, &nsdbport, &binddn, &nce); while ((arg = getopt_long(argc, argv, nsdb_delete_fsl_opts, nsdb_delete_fsl_longopts, NULL)) != -1) { diff --git a/src/nsdbc/nsdb-delete-fsn.c b/src/nsdbc/nsdb-delete-fsn.c index 8fc5c7d..15988d5 100644 --- a/src/nsdbc/nsdb-delete-fsn.c +++ b/src/nsdbc/nsdb-delete-fsn.c @@ -133,7 +133,8 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, &binddn, &nce, &bindpw); + bindpw = NULL; + nsdb_env(&nsdbname, &nsdbport, &binddn, &nce); leave_fsn = false; while ((arg = getopt_long(argc, argv, nsdb_delete_fsn_opts, diff --git a/src/nsdbc/nsdb-delete-nsdb.c b/src/nsdbc/nsdb-delete-nsdb.c index f86941b..691c4ee 100644 --- a/src/nsdbc/nsdb-delete-nsdb.c +++ b/src/nsdbc/nsdb-delete-nsdb.c @@ -124,7 +124,8 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, &binddn, NULL, &bindpw); + bindpw = NULL; + nsdb_env(&nsdbname, &nsdbport, &binddn, NULL); while ((arg = getopt_long(argc, argv, nsdb_delete_nsdb_opts, nsdb_delete_nsdb_longopts, NULL)) != -1) { diff --git a/src/nsdbc/nsdb-describe.c b/src/nsdbc/nsdb-describe.c index a513e37..127ff45 100644 --- a/src/nsdbc/nsdb-describe.c +++ b/src/nsdbc/nsdb-describe.c @@ -132,7 +132,8 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, &binddn, NULL, &bindpw); + bindpw = NULL; + nsdb_env(&nsdbname, &nsdbport, &binddn, NULL); delete = false; entry = description = NULL; diff --git a/src/nsdbc/nsdb-list.c b/src/nsdbc/nsdb-list.c index 16b79a5..5f058b3 100644 --- a/src/nsdbc/nsdb-list.c +++ b/src/nsdbc/nsdb-list.c @@ -173,7 +173,7 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, NULL, &nce, NULL); + nsdb_env(&nsdbname, &nsdbport, NULL, &nce); while ((arg = getopt_long(argc, argv, nsdb_list_opts, nsdb_list_longopts, NULL)) != -1) { diff --git a/src/nsdbc/nsdb-nces.c b/src/nsdbc/nsdb-nces.c index fcdfc8e..edfdf67 100644 --- a/src/nsdbc/nsdb-nces.c +++ b/src/nsdbc/nsdb-nces.c @@ -122,7 +122,7 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, NULL, NULL, NULL); + nsdb_env(&nsdbname, &nsdbport, NULL, NULL); while ((arg = getopt_long(argc, argv, nsdb_nces_opts, nsdb_nces_longopts, NULL)) != -1) { diff --git a/src/nsdbc/nsdb-remove-nci.c b/src/nsdbc/nsdb-remove-nci.c index ee80140..b6d22c1 100644 --- a/src/nsdbc/nsdb-remove-nci.c +++ b/src/nsdbc/nsdb-remove-nci.c @@ -126,7 +126,8 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, &binddn, &nce, &bindpw); + bindpw = NULL; + nsdb_env(&nsdbname, &nsdbport, &binddn, &nce); if (nce == NULL) nce = NSDB_DEFAULT_NCE; diff --git a/src/nsdbc/nsdb-resolve-fsn.c b/src/nsdbc/nsdb-resolve-fsn.c index 8a9d5f8..e2a29ac 100644 --- a/src/nsdbc/nsdb-resolve-fsn.c +++ b/src/nsdbc/nsdb-resolve-fsn.c @@ -230,7 +230,7 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, NULL, &nce, NULL); + nsdb_env(&nsdbname, &nsdbport, NULL, &nce); fsn_uuid = NULL; while ((arg = getopt_long(argc, argv, nsdb_resolve_fsn_opts, diff --git a/src/nsdbc/nsdb-update-fsl.c b/src/nsdbc/nsdb-update-fsl.c index 185435d..abef5df 100644 --- a/src/nsdbc/nsdb-update-fsl.c +++ b/src/nsdbc/nsdb-update-fsl.c @@ -137,7 +137,8 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, &binddn, &nce, &bindpw); + bindpw = NULL; + nsdb_env(&nsdbname, &nsdbport, &binddn, &nce); value = NULL; while ((arg = getopt_long(argc, argv, nsdb_update_fsl_opts, diff --git a/src/nsdbc/nsdb-update-nci.c b/src/nsdbc/nsdb-update-nci.c index 5759796..c490c76 100644 --- a/src/nsdbc/nsdb-update-nci.c +++ b/src/nsdbc/nsdb-update-nci.c @@ -130,7 +130,8 @@ main(int argc, char **argv) xlog_syslog(0); xlog_open(progname); - nsdb_env(&nsdbname, &nsdbport, &binddn, &nce, &bindpw); + bindpw = NULL; + nsdb_env(&nsdbname, &nsdbport, &binddn, &nce); if (nce == NULL) nce = NSDB_DEFAULT_NCE;