diff options
author | Andrew Bartlett <abartlet@samba.org> | 2005-12-18 21:44:43 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 13:47:28 -0500 |
commit | 46de306f13ec894c967a93121ac1b0847659cf01 (patch) | |
tree | 982685432acf9424f114b599707af040f12c9969 /source4/lib/cmdline/popt_common.c | |
parent | 97b54b007e0f8a44074fa570b06b7ff9d4f2489b (diff) | |
download | samba-46de306f13ec894c967a93121ac1b0847659cf01.tar.gz samba-46de306f13ec894c967a93121ac1b0847659cf01.tar.xz samba-46de306f13ec894c967a93121ac1b0847659cf01.zip |
r12320: Add command-line processing hooks for simple bind DN, and password callback.
We may change this in future.
Andrew Bartlett
(This used to be commit 5fec784d4795af0cf82d36766586ded134f62165)
Diffstat (limited to 'source4/lib/cmdline/popt_common.c')
-rw-r--r-- | source4/lib/cmdline/popt_common.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/source4/lib/cmdline/popt_common.c b/source4/lib/cmdline/popt_common.c index 43ea203b78..0aa4a634fc 100644 --- a/source4/lib/cmdline/popt_common.c +++ b/source4/lib/cmdline/popt_common.c @@ -37,7 +37,7 @@ * -i,--scope */ -enum {OPT_OPTION=1,OPT_LEAK_REPORT,OPT_LEAK_REPORT_FULL, OPT_DEBUG_STDERR}; +enum {OPT_OPTION=1,OPT_LEAK_REPORT,OPT_LEAK_REPORT_FULL, OPT_DEBUG_STDERR, OPT_SIMPLE_BIND_DN}; struct cli_credentials *cmdline_credentials = NULL; @@ -242,6 +242,9 @@ static void popt_common_credentials_callback(poptContext con, /* machine accounts only work with kerberos (fall though)*/ break; + case OPT_SIMPLE_BIND_DN: + cli_credentials_set_bind_dn(cmdline_credentials, arg); + break; } } @@ -254,5 +257,6 @@ struct poptOption popt_common_credentials[] = { { "authentication-file", 'A', POPT_ARG_STRING, NULL, 'A', "Get the credentials from a file", "FILE" }, { "signing", 'S', POPT_ARG_STRING, NULL, 'S', "Set the client signing state", "on|off|required" }, { "machine-pass", 'P', POPT_ARG_NONE, NULL, 'P', "Use stored machine account password (implies -k)" }, + { "simple-bind-dn", 0, POPT_ARG_STRING, NULL, OPT_SIMPLE_BIND_DN, "DN to use for a simple bind" }, POPT_TABLEEND }; |