summaryrefslogtreecommitdiff
path: root/source3/torture
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2012-03-01 17:44:48 +1100
committerAndrew Bartlett <abartlet@samba.org>2012-03-01 22:04:46 +1100
commit8ea795672d8063db2f474a4ac11a1b94f386096d (patch)
tree66c399744b92fbde8daf0e2206df9e6bf08dd16e /source3/torture
parenteca3a14870f6632957a0ffeba1309d5da67cb9a1 (diff)
downloadsamba-8ea795672d8063db2f474a4ac11a1b94f386096d.tar.gz
samba-8ea795672d8063db2f474a4ac11a1b94f386096d.tar.bz2
samba-8ea795672d8063db2f474a4ac11a1b94f386096d.zip
s3-selftest: make ntlm_auth test more robust to bad input
If we do not know the helper protocol, make sure to error. Andrew Bartlett
Diffstat (limited to 'source3/torture')
-rwxr-xr-xsource3/torture/test_ntlm_auth.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/source3/torture/test_ntlm_auth.py b/source3/torture/test_ntlm_auth.py
index 386bfb7f0c..1ee5b83bd7 100755
--- a/source3/torture/test_ntlm_auth.py
+++ b/source3/torture/test_ntlm_auth.py
@@ -212,7 +212,7 @@ def main():
sys.exit(4)
- if opts.client_helper == "ntlmssp-client-1" and opts.server_helper == "gss-spnego":
+ elif opts.client_helper == "ntlmssp-client-1" and opts.server_helper == "gss-spnego":
# We're in the parent
writeLine(client_out, "YR")
buf = readLine(client_in)
@@ -242,7 +242,7 @@ def main():
sys.exit(4)
- if opts.client_helper == "gss-spnego-client" and opts.server_helper == "gss-spnego":
+ elif opts.client_helper == "gss-spnego-client" and opts.server_helper == "gss-spnego":
# We're in the parent
writeLine(server_out, "YR")
buf = readLine(server_in)
@@ -266,6 +266,9 @@ def main():
if buf.count("AF * ", 0, 5) == 1:
break
+ else:
+ sys.exit(5)
+
if opts.client_helper == "ntlmssp-client-1":
writeLine(client_out, "GK")
buf = readLine(client_in)