diff options
author | Jeremy Allison <jra@samba.org> | 2001-07-06 21:53:32 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 2001-07-06 21:53:32 +0000 |
commit | da9fb5ba388a16f7adeb7403fee74e1981735d1e (patch) | |
tree | d317ae0f7f33e8aab6c1ece7cda4833a3c82e746 | |
parent | 9df203f876c617f67304fe436a339289dbbaf814 (diff) | |
download | samba-da9fb5ba388a16f7adeb7403fee74e1981735d1e.tar.gz samba-da9fb5ba388a16f7adeb7403fee74e1981735d1e.tar.bz2 samba-da9fb5ba388a16f7adeb7403fee74e1981735d1e.zip |
Don't try and open tdb secrets file in non-root/local mode.
Jeremy.
(This used to be commit e78a114425129d980f79db812dbea368123913ed)
-rw-r--r-- | source3/utils/smbpasswd.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/source3/utils/smbpasswd.c b/source3/utils/smbpasswd.c index a10e757910..cfc8ac6aa1 100644 --- a/source3/utils/smbpasswd.c +++ b/source3/utils/smbpasswd.c @@ -925,8 +925,6 @@ int main(int argc, char **argv) } strupper(global_myname); - secrets_init(); - /* Check the effective uid - make sure we are not setuid */ if ((geteuid() == (uid_t)0) && (getuid() != (uid_t)0)) { fprintf(stderr, "smbpasswd must *NOT* be setuid root.\n"); @@ -941,6 +939,7 @@ int main(int argc, char **argv) } if (local_mode || getuid() == 0) { + secrets_init(); return process_root(argc, argv); } |