diff options
-rw-r--r-- | nsswitch/wb_common.c | 2 | ||||
-rw-r--r-- | nsswitch/winbind_struct_protocol.h | 7 | ||||
-rwxr-xr-x | selftest/selftest.pl | 2 | ||||
-rwxr-xr-x | selftest/target/Samba3.pm | 14 | ||||
-rw-r--r-- | selftest/target/Samba4.pm | 4 | ||||
-rw-r--r-- | source3/torture/wbc_async.c | 2 | ||||
-rw-r--r-- | source4/libcli/wbclient/wbclient.c | 2 | ||||
-rw-r--r-- | source4/scripting/devel/selftest-vars.sh | 2 |
8 files changed, 14 insertions, 21 deletions
diff --git a/nsswitch/wb_common.c b/nsswitch/wb_common.c index 291e9c7824b..f4a31a95fee 100644 --- a/nsswitch/wb_common.c +++ b/nsswitch/wb_common.c @@ -320,7 +320,7 @@ static const char *winbindd_socket_dir(void) if (nss_wrapper_enabled()) { const char *env_dir; - env_dir = getenv(WINBINDD_SOCKET_DIR_ENVVAR); + env_dir = getenv("SELFTEST_WINBINDD_SOCKET_DIR"); if (env_dir != NULL) { return env_dir; } diff --git a/nsswitch/winbind_struct_protocol.h b/nsswitch/winbind_struct_protocol.h index fc7aa6c93dd..0dffa4be528 100644 --- a/nsswitch/winbind_struct_protocol.h +++ b/nsswitch/winbind_struct_protocol.h @@ -36,13 +36,6 @@ typedef char fstring[FSTRING_LEN]; * mechanism. */ -/* - * when compiled with socket_wrapper support - * the location of the WINBINDD_SOCKET_DIR - * can be overwritten via an environment variable - */ -#define WINBINDD_SOCKET_DIR_ENVVAR "WINBINDD_SOCKET_DIR" - #define WINBINDD_PRIV_SOCKET_SUBDIR "winbindd_privileged" /* name of subdirectory of lp_lock_directory() to hold the 'privileged' pipe */ #define WINBINDD_DOMAIN_ENV "WINBINDD_DOMAIN" /* Environment variables */ #define WINBINDD_DONT_ENV "_NO_WINBINDD" diff --git a/selftest/selftest.pl b/selftest/selftest.pl index 5c35d893552..3c07841a7bb 100755 --- a/selftest/selftest.pl +++ b/selftest/selftest.pl @@ -744,7 +744,7 @@ my @exported_envvars = ( # misc stuff "KRB5_CONFIG", - "WINBINDD_SOCKET_DIR", + "SELFTEST_WINBINDD_SOCKET_DIR", "WINBINDD_PRIV_PIPE_DIR", "NMBD_SOCKET_DIR", "LOCAL_PATH", diff --git a/selftest/target/Samba3.pm b/selftest/target/Samba3.pm index ed8faf9f74c..9606d5b09a5 100755 --- a/selftest/target/Samba3.pm +++ b/selftest/target/Samba3.pm @@ -636,7 +636,7 @@ sub check_or_start($$$$$) { SocketWrapper::set_default_iface($env_vars->{SOCKET_WRAPPER_DEFAULT_IFACE}); $ENV{KRB5_CONFIG} = $env_vars->{KRB5_CONFIG}; - $ENV{WINBINDD_SOCKET_DIR} = $env_vars->{WINBINDD_SOCKET_DIR}; + $ENV{SELFTEST_WINBINDD_SOCKET_DIR} = $env_vars->{SELFTEST_WINBINDD_SOCKET_DIR}; $ENV{NMBD_SOCKET_DIR} = $env_vars->{NMBD_SOCKET_DIR}; $ENV{NSS_WRAPPER_PASSWD} = $env_vars->{NSS_WRAPPER_PASSWD}; @@ -693,7 +693,7 @@ sub check_or_start($$$$$) { SocketWrapper::set_default_iface($env_vars->{SOCKET_WRAPPER_DEFAULT_IFACE}); $ENV{KRB5_CONFIG} = $env_vars->{KRB5_CONFIG}; - $ENV{WINBINDD_SOCKET_DIR} = $env_vars->{WINBINDD_SOCKET_DIR}; + $ENV{SELFTEST_WINBINDD_SOCKET_DIR} = $env_vars->{SELFTEST_WINBINDD_SOCKET_DIR}; $ENV{NMBD_SOCKET_DIR} = $env_vars->{NMBD_SOCKET_DIR}; $ENV{NSS_WRAPPER_PASSWD} = $env_vars->{NSS_WRAPPER_PASSWD}; @@ -750,7 +750,7 @@ sub check_or_start($$$$$) { SocketWrapper::set_default_iface($env_vars->{SOCKET_WRAPPER_DEFAULT_IFACE}); $ENV{KRB5_CONFIG} = $env_vars->{KRB5_CONFIG}; - $ENV{WINBINDD_SOCKET_DIR} = $env_vars->{WINBINDD_SOCKET_DIR}; + $ENV{SELFTEST_WINBINDD_SOCKET_DIR} = $env_vars->{SELFTEST_WINBINDD_SOCKET_DIR}; $ENV{NMBD_SOCKET_DIR} = $env_vars->{NMBD_SOCKET_DIR}; $ENV{NSS_WRAPPER_PASSWD} = $env_vars->{NSS_WRAPPER_PASSWD}; @@ -1261,7 +1261,7 @@ domadmins:X:$gid_domadmins: $ret{NETBIOSNAME} = $server; $ret{PASSWORD} = $password; $ret{PIDDIR} = $piddir; - $ret{WINBINDD_SOCKET_DIR} = $wbsockdir; + $ret{SELFTEST_WINBINDD_SOCKET_DIR} = $wbsockdir; $ret{WINBINDD_PRIV_PIPE_DIR} = $wbsockprivdir; $ret{NMBD_SOCKET_DIR} = $nmbdsockdir; $ret{SOCKET_WRAPPER_DEFAULT_IFACE} = $swiface; @@ -1298,7 +1298,7 @@ sub wait_for_start($$$$$) print "checking for winbindd\n"; my $count = 0; do { - $ret = system("WINBINDD_SOCKET_DIR=" . $envvars->{WINBINDD_SOCKET_DIR} . " " . Samba::bindir_path($self, "wbinfo") . " -p"); + $ret = system("SELFTEST_WINBINDD_SOCKET_DIR=" . $envvars->{SELFTEST_WINBINDD_SOCKET_DIR} . " " . Samba::bindir_path($self, "wbinfo") . " -p"); if ($ret != 0) { sleep(2); } @@ -1343,7 +1343,7 @@ sub wait_for_start($$$$$) if ($winbindd eq "yes") { # note: creating builtin groups requires winbindd for the # unix id allocator - $ret = system("WINBINDD_SOCKET_DIR=" . $envvars->{WINBINDD_SOCKET_DIR} . " " . Samba::bindir_path($self, "net") ." $envvars->{CONFIGURATION} sam createbuiltingroup Users"); + $ret = system("SELFTEST_WINBINDD_SOCKET_DIR=" . $envvars->{SELFTEST_WINBINDD_SOCKET_DIR} . " " . Samba::bindir_path($self, "net") ." $envvars->{CONFIGURATION} sam createbuiltingroup Users"); if ($ret != 0) { print "Failed to create BUILTIN\\Users group\n"; return 0; @@ -1351,7 +1351,7 @@ sub wait_for_start($$$$$) my $count = 0; do { system(Samba::bindir_path($self, "net") . " $envvars->{CONFIGURATION} cache flush"); - $ret = system("WINBINDD_SOCKET_DIR=" . $envvars->{WINBINDD_SOCKET_DIR} . " " . Samba::bindir_path($self, "wbinfo") . " --sid-to-gid=S-1-5-32-545"); + $ret = system("SELFTEST_WINBINDD_SOCKET_DIR=" . $envvars->{SELFTEST_WINBINDD_SOCKET_DIR} . " " . Samba::bindir_path($self, "wbinfo") . " --sid-to-gid=S-1-5-32-545"); if ($ret != 0) { sleep(2); } diff --git a/selftest/target/Samba4.pm b/selftest/target/Samba4.pm index 8408b334d5b..86ee4fe1b38 100644 --- a/selftest/target/Samba4.pm +++ b/selftest/target/Samba4.pm @@ -117,7 +117,7 @@ sub check_or_start($$$) SocketWrapper::set_default_iface($env_vars->{SOCKET_WRAPPER_DEFAULT_IFACE}); $ENV{KRB5_CONFIG} = $env_vars->{KRB5_CONFIG}; - $ENV{WINBINDD_SOCKET_DIR} = $env_vars->{WINBINDD_SOCKET_DIR}; + $ENV{SELFTEST_WINBINDD_SOCKET_DIR} = $env_vars->{SELFTEST_WINBINDD_SOCKET_DIR}; $ENV{NMBD_SOCKET_DIR} = $env_vars->{NMBD_SOCKET_DIR}; $ENV{NSS_WRAPPER_PASSWD} = $env_vars->{NSS_WRAPPER_PASSWD}; @@ -724,7 +724,7 @@ nogroup:x:65534:nobody PASSWORD => $ctx->{password}, LDAPDIR => $ctx->{ldapdir}, LDAP_INSTANCE => $ctx->{ldap_instance}, - WINBINDD_SOCKET_DIR => $ctx->{winbindd_socket_dir}, + SELFTEST_WINBINDD_SOCKET_DIR => $ctx->{winbindd_socket_dir}, NCALRPCDIR => $ctx->{ncalrpcdir}, LOCKDIR => $ctx->{lockdir}, STATEDIR => $ctx->{statedir}, diff --git a/source3/torture/wbc_async.c b/source3/torture/wbc_async.c index 8af95951eec..1a7495acad8 100644 --- a/source3/torture/wbc_async.c +++ b/source3/torture/wbc_async.c @@ -328,7 +328,7 @@ static const char *winbindd_socket_dir(void) if (nss_wrapper_enabled()) { const char *env_dir; - env_dir = getenv(WINBINDD_SOCKET_DIR_ENVVAR); + env_dir = getenv("SELFTEST_WINBINDD_SOCKET_DIR"); if (env_dir != NULL) { return env_dir; } diff --git a/source4/libcli/wbclient/wbclient.c b/source4/libcli/wbclient/wbclient.c index 61566233ec5..bb894356843 100644 --- a/source4/libcli/wbclient/wbclient.c +++ b/source4/libcli/wbclient/wbclient.c @@ -61,7 +61,7 @@ static const char *winbindd_socket_dir(void) #ifdef SOCKET_WRAPPER const char *env_dir; - env_dir = getenv(WINBINDD_SOCKET_DIR_ENVVAR); + env_dir = getenv("SELFTEST_WINBINDD_SOCKET_DIR"); if (env_dir) { return env_dir; } diff --git a/source4/scripting/devel/selftest-vars.sh b/source4/scripting/devel/selftest-vars.sh index a8f323dbda8..b093099f2d6 100644 --- a/source4/scripting/devel/selftest-vars.sh +++ b/source4/scripting/devel/selftest-vars.sh @@ -22,7 +22,7 @@ export NETBIOSNAME=localdc1 export REALM=SAMBA.EXAMPLE.COM export SOCKET_WRAPPER_DEFAULT_IFACE=21 export SERVER=localdc1 -export WINBINDD_SOCKET_DIR=$PWD/st/dc/winbindd_socket +export SELFTEST_WINBINDD_SOCKET_DIR=$PWD/st/dc/winbindd_socket export SELFTEST_PREFIX=$PWD/st export DOMAIN=SAMBADOMAIN export BINDIR=./bin |