summaryrefslogtreecommitdiffstats
path: root/source4/scripting/python/samba/netcmd/machinepw.py
diff options
context:
space:
mode:
authorAndrew Tridgell <tridge@samba.org>2010-12-08 08:20:54 +1100
committerAndrew Tridgell <tridge@samba.org>2010-12-08 05:26:05 +0100
commit545932fda590d4c888c0f60fed7a36c1659f0018 (patch)
tree18bd10e6237e1c2489f25b4527cbd5bb260381ef /source4/scripting/python/samba/netcmd/machinepw.py
parent249afc8906bc33ed1e23f50f5c28a8ba0b8354c9 (diff)
downloadsamba-545932fda590d4c888c0f60fed7a36c1659f0018.tar.gz
samba-545932fda590d4c888c0f60fed7a36c1659f0018.tar.xz
samba-545932fda590d4c888c0f60fed7a36c1659f0018.zip
samba-tools: more reasonable defaults for samba-tool commands
- fallback to machine account where possible - default to local hostname where this is reasonable
Diffstat (limited to 'source4/scripting/python/samba/netcmd/machinepw.py')
-rw-r--r--source4/scripting/python/samba/netcmd/machinepw.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/source4/scripting/python/samba/netcmd/machinepw.py b/source4/scripting/python/samba/netcmd/machinepw.py
index 9951dd7c37d..d822b227940 100644
--- a/source4/scripting/python/samba/netcmd/machinepw.py
+++ b/source4/scripting/python/samba/netcmd/machinepw.py
@@ -39,7 +39,7 @@ class cmd_machinepw(Command):
def run(self, secret, sambaopts=None, credopts=None, versionopts=None):
lp = sambaopts.get_loadparm()
- creds = credopts.get_credentials(lp)
+ creds = credopts.get_credentials(lp, fallback_machine=True)
url = lp.get("secrets database")
secretsdb = Ldb(url=url, session_info=system_session(),
credentials=creds, lp=lp)