2 # This script generates a list of testsuites that should be run as part of
3 # the Samba 3 test suite.
5 # The output of this script is parsed by selftest.pl, which then decides
6 # which of the tests to actually run. It will, for example, skip all tests
7 # listed in selftest/skip or only run a subset during "make quicktest".
9 # The idea is that this script outputs all of the tests of Samba 3, not
10 # just those that are known to pass, and list those that should be skipped
11 # or are known to fail in selftest/skip or selftest/samba3-knownfail. This makes it
12 # very easy to see what functionality is still missing in Samba 3 and makes
13 # it possible to run the testsuite against other servers, such as Samba 4 or
14 # Windows that have a different set of features.
16 # The syntax for a testsuite is "-- TEST --" on a single line, followed
17 # by the name of the test, the environment it needs and the command to run, all
18 # three separated by newlines. All other lines in the output are considered
22 sys
.path
.insert(0, os
.path
.normpath(os
.path
.join(os
.path
.dirname(__file__
), "../../selftest")))
23 import selftesthelpers
24 from selftesthelpers
import *
25 smbtorture4_options
.extend([
26 '--option="torture:winbindd_netbios_name=$SERVER"',
27 '--option="torture:winbindd_netbios_domain=$DOMAIN"',
28 '--option=torture:sharedelay=100000',
29 '--option=torture:writetimeupdatedelay=500000',
32 smbtorture4_possible
= print_smbtorture4_version()
34 def plansmbtorture4testsuite(name
, env
, options
, description
=''):
36 modname
= "samba3.%s" % (name
, )
38 modname
= "samba3.%s %s" % (name
, description
)
40 if smbtorture4_possible
:
41 selftesthelpers
.plansmbtorture4testsuite(
42 name
, env
, options
, target
='samba3', modname
=modname
)
44 skiptestsuite(name
, "smbtorture4 is not available")
47 plantestsuite("samba3.blackbox.success", "s3dc:local", [os
.path
.join(samba3srcdir
, "script/tests/test_success.sh")])
48 plantestsuite("samba3.blackbox.failure", "s3dc:local", [os
.path
.join(samba3srcdir
, "script/tests/test_failure.sh")])
50 plantestsuite("samba3.local_s3", "s3dc:local", [os
.path
.join(samba3srcdir
, "script/tests/test_local_s3.sh")])
52 plantestsuite("samba3.blackbox.registry.upgrade", "s3dc:local", [os
.path
.join(samba3srcdir
, "script/tests/test_registry_upgrade.sh"), net
, dbwrap_tool
])
54 tests
= ["FDPASS", "LOCK1", "LOCK2", "LOCK3", "LOCK4", "LOCK5", "LOCK6", "LOCK7", "LOCK9",
55 "UNLINK", "BROWSE", "ATTR", "TRANS2", "TORTURE",
56 "OPLOCK1", "OPLOCK2", "OPLOCK4", "STREAMERROR",
57 "DIR", "DIR1", "DIR-CREATETIME", "TCON", "TCONDEV", "RW1", "RW2", "RW3", "LARGE_READX", "RW-SIGNING",
58 "OPEN", "XCOPY", "RENAME", "DELETE", "DELETE-LN", "PROPERTIES", "W2K",
59 "TCON2", "IOCTL", "CHKPATH", "FDSESS", "CHAIN1", "CHAIN2",
61 "GETADDRINFO", "UID-REGRESSION-TEST", "SHORTNAME-TEST",
62 "CASE-INSENSITIVE-CREATE", "SMB2-BASIC", "NTTRANS-FSCTL", "SMB2-NEGPROT",
63 "SMB2-SESSION-REAUTH", "SMB2-SESSION-RECONNECT",
70 plantestsuite("samba3.smbtorture_s3.plain(s3dc).%s" % t
, "s3dc", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/tmp', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
71 plantestsuite("samba3.smbtorture_s3.crypt_client(s3dc).%s" % t
, "s3dc", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/tmp', '$USERNAME', '$PASSWORD', smbtorture3
, "-e", "-l $LOCAL_PATH"])
73 # this is a negative test to verify that the server rejects
74 # access without encryption
75 plantestsuite("samba3.smbtorture_s3.crypt_server(s3dc).%s" % t
, "s3dc", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/tmpenc', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
76 plantestsuite("samba3.smbtorture_s3.plain(dc).%s" % t
, "dc", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/tmp', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
78 tests
= ["RW1", "RW2", "RW3"]
80 plantestsuite("samba3.smbtorture_s3.vfs_aio_fork(simpleserver).%s" % t
, "simpleserver", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/vfs_aio_fork', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
82 posix_tests
= ["POSIX", "POSIX-APPEND"]
85 plantestsuite("samba3.smbtorture_s3.plain(s3dc).%s" % t
, "s3dc", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/posix_share', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
86 plantestsuite("samba3.smbtorture_s3.crypt(s3dc).%s" % t
, "s3dc", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/posix_share', '$USERNAME', '$PASSWORD', smbtorture3
, "-e", "-l $LOCAL_PATH"])
87 plantestsuite("samba3.smbtorture_s3.plain(dc).%s" % t
, "dc", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/posix_share', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
91 plantestsuite("samba3.smbtorture_s3.plain(%s).%s" % (env
, t
), env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/tmp', '$USERNAME', '$PASSWORD', binpath('smbtorture3'), "", "-l $LOCAL_PATH"])
102 "LOCAL-string_to_sid",
103 "LOCAL-sid_to_string",
104 "LOCAL-binary_to_sid",
106 "LOCAL-TEVENT-SELECT",
107 "LOCAL-CONVERT-STRING",
108 "LOCAL-CONV-AUTH-INFO",
109 "LOCAL-IDMAP-TDB-COMMON",
110 "LOCAL-hex_encode_buf",
111 "LOCAL-sprintf_append",
112 "LOCAL-remove_duplicate_addrs2"]
114 for t
in local_tests
:
115 plantestsuite("samba3.smbtorture_s3.%s" % t
, "s3dc", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/tmp', '$USERNAME', '$PASSWORD', smbtorture3
, "-e"])
117 tests
= ["--ping", "--separator",
121 "--domain-info=BUILTIN",
122 "--domain-info=$DOMAIN",
124 "--online-status --domain=BUILTIN",
125 "--online-status --domain=$DOMAIN",
126 "--check-secret --domain=$DOMAIN",
127 "--change-secret --domain=$DOMAIN",
128 "--check-secret --domain=$DOMAIN",
129 "--online-status --domain=$DOMAIN",
130 #Didn't pass yet# "--domain-users",
132 "--name-to-sid=$DC_USERNAME",
133 "--name-to-sid=$DOMAIN\\\\$DC_USERNAME",
134 #Didn't pass yet# "--user-info=$USERNAME",
135 "--user-groups=$DOMAIN\\\\$DC_USERNAME",
136 "--authenticate=$DOMAIN\\\\$DC_USERNAME%$DC_PASSWORD",
140 plantestsuite("samba.vfstest.stream_depot", "s3dc:local", [os
.path
.join(samba3srcdir
, "script/tests/stream-depot/run.sh"), binpath("vfstest"), "$PREFIX", configuration
])
141 plantestsuite("samba.vfstest.xattr-tdb-1", "s3dc:local", [os
.path
.join(samba3srcdir
, "script/tests/xattr-tdb-1/run.sh"), binpath("vfstest"), "$PREFIX", configuration
])
142 plantestsuite("samba.vfstest.acl", "s3dc:local", [os
.path
.join(samba3srcdir
, "script/tests/vfstest-acl/run.sh"), binpath("vfstest"), "$PREFIX", configuration
])
143 plantestsuite("samba.vfstest.catia", "s3dc:local", [os
.path
.join(samba3srcdir
, "script/tests/vfstest-catia/run.sh"), binpath("vfstest"), "$PREFIX", configuration
])
145 for options
in ["--option=clientusespnego=no", " --option=clientntlmv2auth=no --option=clientlanmanauth=yes --max-protocol=LANMAN2", ""]:
147 plantestsuite("samba3.blackbox.smbclient_auth.plain (%s) %s" % (env
, options
), env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME', '$DC_PASSWORD', smbclient3
, configuration
, options
])
149 for env
in ["s3dc", "member", "s3member", "dc", "s4member"]:
150 plantestsuite("samba3.blackbox.smbclient_machine_auth.plain (%s:local)" % env
, "%s:local" % env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_machine_auth.sh"), '$SERVER', smbclient3
, configuration
])
152 for env
in ["s3dc", "member", "s3member"]:
153 plantestsuite("samba3.blackbox.smbclient_auth.plain (%s)" % env
, env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME', '$DC_PASSWORD', smbclient3
, configuration
])
154 plantestsuite("samba3.blackbox.smbclient_auth.plain (%s) member creds" % env
, env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', '$SERVER\\\\$USERNAME', '$PASSWORD', smbclient3
, configuration
])
157 plantestsuite("samba3.wbinfo_s3.(%s:local).%s" % (env
, t
), "%s:local" % env
, [os
.path
.join(samba3srcdir
, "script/tests/test_wbinfo_s3.sh"), t
])
160 "samba3.wbinfo_sids2xids.(%s:local)" % env
, "%s:local" % env
,
161 [os
.path
.join(samba3srcdir
, "script/tests/test_wbinfo_sids2xids.sh")])
164 "samba3.ntlm_auth.diagnostics(%s:local)" % env
, "%s:local" % env
,
165 [os
.path
.join(samba3srcdir
, "script/tests/test_ntlm_auth_diagnostics.sh"), ntlm_auth3
, '$DOMAIN', '$DC_USERNAME', '$DC_PASSWORD', configuration
])
167 plantestsuite("samba3.ntlm_auth.(%s:local)" % env
, "%s:local" % env
, [os
.path
.join(samba3srcdir
, "script/tests/test_ntlm_auth_s3.sh"), valgrindify(python
), samba3srcdir
, ntlm_auth3
, '$DOMAIN', '$DC_USERNAME', '$DC_PASSWORD', configuration
])
169 for env
in ["member", "s3member"]:
170 plantestsuite("samba3.blackbox.net_cred_change.(%s:local)" % env
, "%s:local" % env
, [os
.path
.join(samba3srcdir
, "script/tests/test_net_cred_change.sh"), configuration
])
173 t
= "--krb5auth=$DOMAIN\\\\$DC_USERNAME%$DC_PASSWORD"
174 plantestsuite("samba3.wbinfo_s3.(%s:local).%s" % (env
, t
), "%s:local" % env
, [os
.path
.join(samba3srcdir
, "script/tests/test_wbinfo_s3.sh"), t
])
176 plantestsuite("samba3.ntlm_auth.krb5(ktest:local) old ccache", "ktest:local", [os
.path
.join(samba3srcdir
, "script/tests/test_ntlm_auth_krb5.sh"), valgrindify(python
), samba3srcdir
, ntlm_auth3
, '$PREFIX/ktest/krb5_ccache-2', '$SERVER', configuration
])
178 plantestsuite("samba3.ntlm_auth.krb5(ktest:local)", "ktest:local", [os
.path
.join(samba3srcdir
, "script/tests/test_ntlm_auth_krb5.sh"), valgrindify(python
), samba3srcdir
, ntlm_auth3
, '$PREFIX/ktest/krb5_ccache-3', '$SERVER', configuration
])
181 for env
in ["maptoguest", "simpleserver"]:
182 plantestsuite("samba3.blackbox.smbclient_auth.plain (%s) local creds" % env
, env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', smbclient3
, configuration
+ " --option=clientntlmv2auth=no --option=clientlanmanauth=yes"])
185 plantestsuite("samba3.blackbox.smbclient_auth.plain (%s) bad username" % env
, env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', 'notmy$USERNAME', '$PASSWORD', smbclient3
, configuration
+ " --option=clientntlmv2auth=no --option=clientlanmanauth=yes"])
189 plantestsuite("samba3.blackbox.smbclient_s3.plain (%s)" % env
, env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$DC_USERNAME', '$DC_PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', smbclient3
, wbinfo
, net
, configuration
])
191 for env
in ["member", "s3member"]:
192 plantestsuite("samba3.blackbox.smbclient_s3.plain (%s) member creds" % env
, env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$SERVER', '$SERVER\\\\$USERNAME', '$PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', smbclient3
, wbinfo
, net
, configuration
])
195 plantestsuite("samba3.blackbox.smbclient_s3.sign (%s)" % env
, env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$DC_USERNAME', '$DC_PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', smbclient3
, wbinfo
, net
, configuration
, "--signing=required"])
197 for env
in ["member", "s3member"]:
198 plantestsuite("samba3.blackbox.smbclient_s3.sign (%s) member creds" % env
, env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$SERVER', '$SERVER\\\\$USERNAME', '$PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', smbclient3
, wbinfo
, net
, configuration
, "--signing=required"])
202 plantestsuite("samba3.blackbox.smbclient_s3.crypt (%s)" % env
, env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_s3.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$USERNAME', '$PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', smbclient3
, wbinfo
, net
, configuration
, "-e"])
211 config_h
= os
.environ
["CONFIG_H"]
213 config_h
= os
.path
.join(samba4bindir
, "default/include/config.h")
215 # see if libarchive is supported
216 f
= open(config_h
, 'r')
218 have_libarchive
= ("HAVE_LIBARCHIVE 1" in f
.read())
222 # tar command enabled only if built with libarchive
224 # Test smbclient/tarmode
225 plantestsuite("samba3.blackbox.smbclient_tarmode (%s)" % env
, env
,
226 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_tarmode.sh"),
227 '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD',
228 '$LOCAL_PATH', '$PREFIX', smbclient3
, configuration
])
230 # Test suite for new smbclient/tar with libarchive (GSoC 13)
231 plantestsuite("samba3.blackbox.smbclient_tar (%s)" % env
, env
,
232 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_tarmode.pl"),
233 '-n', '$SERVER', '-i', '$SERVER_IP', '-s', 'tmp',
234 '-u', '$USERNAME', '-p', '$PASSWORD', '-l', '$LOCAL_PATH',
235 '-d', '$PREFIX', '-b', smbclient3
,
236 '--subunit', '--', configuration
])
238 #TODO encrypted against member, with member creds, and with DC creds
239 plantestsuite("samba3.blackbox.net.misc", "s3dc:local",
240 [os
.path
.join(samba3srcdir
, "script/tests/test_net_misc.sh"),
241 scriptdir
, "$SMB_CONF_PATH", net
, configuration
])
242 plantestsuite("samba3.blackbox.net.local.registry", "s3dc:local",
243 [os
.path
.join(samba3srcdir
, "script/tests/test_net_registry.sh"),
244 scriptdir
, "$SMB_CONF_PATH", net
, configuration
])
245 plantestsuite("samba3.blackbox.net.registry.check", "s3dc:local",
246 [os
.path
.join(samba3srcdir
, "script/tests/test_net_registry_check.sh"),
247 scriptdir
, "$SMB_CONF_PATH", net
, configuration
, dbwrap_tool
])
248 plantestsuite("samba3.blackbox.net.rpc.registry", "s3dc",
249 [os
.path
.join(samba3srcdir
, "script/tests/test_net_registry.sh"),
250 scriptdir
, "$SMB_CONF_PATH", net
, configuration
, 'rpc'])
252 plantestsuite("samba3.blackbox.net.local.registry.roundtrip", "s3dc:local",
253 [os
.path
.join(samba3srcdir
, "script/tests/test_net_registry_roundtrip.sh"),
254 scriptdir
, "$SMB_CONF_PATH", net
, configuration
])
255 plantestsuite("samba3.blackbox.net.rpc.registry.roundtrip", "s3dc",
256 [os
.path
.join(samba3srcdir
, "script/tests/test_net_registry_roundtrip.sh"),
257 scriptdir
, "$SMB_CONF_PATH", net
, configuration
, 'rpc'])
259 plantestsuite("samba3.blackbox.net.local.conf", "s3dc:local",
260 [os
.path
.join(samba3srcdir
, "script/tests/test_net_conf.sh"),
261 scriptdir
, "$SMB_CONF_PATH", net
, configuration
])
262 plantestsuite("samba3.blackbox.net.rpc.conf", "s3dc",
263 [os
.path
.join(samba3srcdir
, "script/tests/test_net_conf.sh"),
264 scriptdir
, "$SMB_CONF_PATH", net
, configuration
, 'rpc'])
267 plantestsuite("samba3.blackbox.testparm", "s3dc:local",
268 [os
.path
.join(samba3srcdir
, "script/tests/test_testparm_s3.sh"),
272 "samba3.pthreadpool", "s3dc",
273 [os
.path
.join(samba3srcdir
, "script/tests/test_pthreadpool.sh")])
277 base
= ["base.attr", "base.charset", "base.chkpath", "base.defer_open", "base.delaywrite", "base.delete",
278 "base.deny1", "base.deny2", "base.deny3", "base.denydos", "base.dir1", "base.dir2",
279 "base.disconnect", "base.fdpass", "base.lock",
280 "base.mangle", "base.negnowait", "base.ntdeny1",
281 "base.ntdeny2", "base.open", "base.openattr", "base.properties", "base.rename", "base.rw1",
282 "base.secleak", "base.tcon", "base.tcondev", "base.trans2", "base.unlink", "base.vuid",
283 "base.xcopy", "base.samba3error"]
285 raw
= ["raw.acls", "raw.chkpath", "raw.close", "raw.composite", "raw.context", "raw.eas",
286 "raw.ioctl", "raw.lock", "raw.mkdir", "raw.mux", "raw.notify", "raw.open", "raw.oplock",
287 "raw.qfileinfo", "raw.qfsinfo", "raw.read", "raw.rename", "raw.search", "raw.seek",
288 "raw.sfileinfo.base", "raw.sfileinfo.bug", "raw.streams", "raw.unlink", "raw.write",
289 "raw.samba3hide", "raw.samba3badpath", "raw.sfileinfo.rename", "raw.session",
290 "raw.samba3caseinsensitive", "raw.samba3posixtimedlock",
291 "raw.samba3rootdirfid", "raw.sfileinfo.end-of-file",
292 "raw.bench-oplock", "raw.bench-lock", "raw.bench-open", "raw.bench-tcon",
293 "raw.samba3checkfsp", "raw.samba3closeerr", "raw.samba3oplocklogoff", "raw.samba3badnameblob"]
295 smb2
= smbtorture4_testsuites("smb2.")
297 rpc
= ["rpc.authcontext", "rpc.samba3.bind", "rpc.samba3.srvsvc", "rpc.samba3.sharesec",
298 "rpc.samba3.spoolss", "rpc.samba3.wkssvc", "rpc.samba3.winreg",
299 "rpc.samba3.getaliasmembership-0",
300 "rpc.samba3.netlogon", "rpc.samba3.sessionkey", "rpc.samba3.getusername",
301 "rpc.samba3.smb1-pipe-name", "rpc.samba3.smb2-pipe-name",
302 "rpc.samba3.smb-reauth1", "rpc.samba3.smb-reauth2",
303 "rpc.svcctl", "rpc.ntsvcs", "rpc.winreg", "rpc.eventlog",
304 "rpc.spoolss.printserver", "rpc.spoolss.win", "rpc.spoolss.notify", "rpc.spoolss.printer",
305 "rpc.spoolss.driver",
306 "rpc.lsa", "rpc.lsa-getuser", "rpc.lsa.lookupsids", "rpc.lsa.lookupnames",
307 "rpc.lsa.privileges", "rpc.lsa.secrets",
308 "rpc.samr", "rpc.samr.users", "rpc.samr.users.privileges", "rpc.samr.passwords",
309 "rpc.samr.passwords.pwdlastset", "rpc.samr.large-dc", "rpc.samr.machine.auth",
310 "rpc.samr.priv", "rpc.samr.passwords.validate",
311 "rpc.netlogon.admin",
312 "rpc.schannel", "rpc.schannel2", "rpc.bench-schannel1", "rpc.join", "rpc.bind"]
314 local
= ["local.nss-wrapper", "local.ndr"]
316 winbind
= ["winbind.struct", "winbind.wbclient", "winbind.pac"]
318 idmap
= [ "idmap.rfc2307" ]
320 rap
= ["rap.basic", "rap.rpc", "rap.printing", "rap.sam"]
322 unix
= ["unix.info2", "unix.whoami"]
326 libsmbclient
= ["libsmbclient"]
328 tests
= base
+ raw
+ smb2
+ rpc
+ unix
+ local
+ winbind
+ rap
+ nbt
+ libsmbclient
+ idmap
331 if t
== "base.delaywrite":
332 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD --maximum-runtime=900')
333 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD --maximum-runtime=900')
335 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD --option=doscharset=ISO-8859-1')
336 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD --option=doscharset=ISO-8859-1')
337 elif t
== "winbind.pac":
338 plansmbtorture4testsuite(t
, "s3member:local", '//$SERVER/tmp --realm=$REALM --machine-pass --option=torture:addc=$DC_SERVER', description
="machine account")
339 elif t
== "unix.whoami":
340 plansmbtorture4testsuite(t
, "member:local", '//$SERVER/tmp --machine-pass', description
="machine account")
341 plansmbtorture4testsuite(t
, "s3member:local", '//$SERVER/tmp --machine-pass --option=torture:addc=$DC_SERVER', description
="machine account")
342 for env
in ["s3dc", "member"]:
343 plansmbtorture4testsuite(t
, env
, '//$SERVER/tmp -U$DC_USERNAME%$DC_PASSWORD')
344 plansmbtorture4testsuite(t
, env
, '//$SERVER/tmpguest -U%', description
='anonymous connection')
345 for env
in ["plugin_s4_dc", "s3member"]:
346 plansmbtorture4testsuite(t
, env
, '//$SERVER/tmp -U$DC_USERNAME@$REALM%$DC_PASSWORD --option=torture:addc=$DC_SERVER')
347 plansmbtorture4testsuite(t
, env
, '//$SERVER/tmp -k yes -U$DC_USERNAME@$REALM%$DC_PASSWORD --option=torture:addc=$DC_SERVER', description
='kerberos connection')
348 plansmbtorture4testsuite(t
, env
, '//$SERVER/tmpguest -U% --option=torture:addc=$DC_SERVER', description
='anonymous connection')
349 elif t
== "raw.samba3posixtimedlock":
350 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmpguest -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/s3dc/share')
351 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER_IP/tmpguest -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/plugin_s4_dc/share')
352 elif t
== "raw.chkpath":
353 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmpcase -U$USERNAME%$PASSWORD')
354 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER_IP/tmpcase -U$USERNAME%$PASSWORD')
355 elif t
== "raw.samba3hide" or t
== "raw.samba3checkfsp" or t
== "raw.samba3closeerr":
356 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
357 plansmbtorture4testsuite(t
, "simpleserver", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
358 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
359 elif t
== "raw.session" or t
== "smb2.session":
360 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD', 'plain')
361 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmpenc -U$USERNAME%$PASSWORD', 'enc')
362 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER/tmp -k no -U$USERNAME%$PASSWORD', 'ntlm')
363 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER/tmp -k yes -U$USERNAME%$PASSWORD', 'krb5')
365 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD', 'over ncacn_np ')
366 plansmbtorture4testsuite(t
, "s3dc", 'ncacn_ip_tcp:$SERVER_IP -U$USERNAME%$PASSWORD', 'over ncacn_ip_tcp ')
367 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD', 'over ncacn_np ')
368 plansmbtorture4testsuite(t
, "plugin_s4_dc", 'ncacn_ip_tcp:$SERVER_IP -U$USERNAME%$PASSWORD', 'over ncacn_ip_tcp ')
369 elif t
== "rpc.samr.passwords.validate":
370 plansmbtorture4testsuite(t
, "s3dc", 'ncacn_ip_tcp:$SERVER_IP -U$USERNAME%$PASSWORD', 'over ncacn_ip_tcp ')
371 plansmbtorture4testsuite(t
, "plugin_s4_dc", 'ncacn_ip_tcp:$SERVER_IP -U$USERNAME%$PASSWORD', 'over ncacn_ip_tcp ')
372 elif t
== "smb2.durable-open" or t
== "smb2.durable-v2-open":
373 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/durable -U$USERNAME%$PASSWORD')
374 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER_IP/durable -U$USERNAME%$PASSWORD')
375 elif t
== "base.rw1":
376 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
377 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/valid-users-tmp -U$USERNAME%$PASSWORD')
378 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/write-list-tmp -U$USERNAME%$PASSWORD')
379 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
380 elif t
== "idmap.rfc2307":
381 plantestsuite(t
, "s3member_rfc2307", [os
.path
.join(samba3srcdir
, "../nsswitch/tests/test_idmap_rfc2307.sh"), '$DOMAIN', 'Administrator', '2000000', '"Domain Users"', '2000001', 'ou=idmap,dc=samba,dc=example,dc=com', '$DC_SERVER', '$DC_USERNAME', '$DC_PASSWORD'])
382 elif t
== "raw.acls":
383 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
384 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/nfs4acl_simple -U$USERNAME%$PASSWORD', description
='nfs4acl_xattr-simple')
385 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/nfs4acl_special -U$USERNAME%$PASSWORD', description
='nfs4acl_xattr-special')
386 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER_IP/tmpcase -U$USERNAME%$PASSWORD')
387 elif t
== "smb2.ioctl":
388 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/fs_specific -U$USERNAME%$PASSWORD', 'fs_specific')
389 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
390 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
391 elif t
== "smb2.lock":
392 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/aio -U$USERNAME%$PASSWORD', 'aio')
393 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
394 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
395 elif t
== "raw.search":
396 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
397 # test the dirsort module.
398 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmpsort -U$USERNAME%$PASSWORD')
399 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
401 plansmbtorture4testsuite(t
, "s3dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
402 plansmbtorture4testsuite(t
, "plugin_s4_dc", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
405 test
= 'rpc.lsa.lookupsids'
406 auth_options
= ["", "ntlm", "spnego", "spnego,ntlm" ]
407 signseal_options
= ["", ",connect", ",sign", ",seal"]
408 endianness_options
= ["", ",bigendian"]
409 for s
in signseal_options
:
410 for e
in endianness_options
:
411 for a
in auth_options
:
412 binding_string
= "ncacn_np:$SERVER[%s%s%s]" % (a
, s
, e
)
413 options
= binding_string
+ " -U$USERNAME%$PASSWORD"
414 plansmbtorture4testsuite(test
, "s3dc", options
, 'over ncacn_np with [%s%s%s] ' % (a
, s
, e
))
415 plantestsuite("samba3.blackbox.rpcclient over ncacn_np with [%s%s%s] " % (a
, s
, e
), "s3dc:local", [os
.path
.join(samba3srcdir
, "script/tests/test_rpcclient.sh"),
416 "none", options
, configuration
])
418 # We should try more combinations in future, but this is all
419 # the pre-calculated credentials cache supports at the moment
422 binding_string
= "ncacn_np:$SERVER[%s%s%s]" % (a
, s
, e
)
423 options
= binding_string
+ " -k yes --krb5-ccache=$PREFIX/ktest/krb5_ccache-2"
424 plansmbtorture4testsuite(test
, "ktest", options
, 'krb5 with old ccache ncacn_np with [%s%s%s] ' % (a
, s
, e
))
426 options
= binding_string
+ " -k yes --krb5-ccache=$PREFIX/ktest/krb5_ccache-3"
427 plansmbtorture4testsuite(test
, "ktest", options
, 'krb5 ncacn_np with [%s%s%s] ' % (a
, s
, e
))
429 auth_options2
= ["krb5", "spnego,krb5"]
430 for a
in auth_options2
:
431 binding_string
= "ncacn_np:$SERVER[%s%s%s]" % (a
, s
, e
)
433 plantestsuite("samba3.blackbox.rpcclient krb5 ncacn_np with [%s%s%s] " % (a
, s
, e
), "ktest:local", [os
.path
.join(samba3srcdir
, "script/tests/test_rpcclient.sh"),
434 "$PREFIX/ktest/krb5_ccache-3", binding_string
, "-k", configuration
])
436 plantestsuite("samba3.blackbox.rpcclient_samlogon", "s3member:local", [os
.path
.join(samba3srcdir
, "script/tests/test_rpcclient_samlogon.sh"),
437 "$DC_USERNAME", "$DC_PASSWORD", "ncacn_np:$DC_SERVER", configuration
])
439 options_list
= ["", "-e"]
440 for options
in options_list
:
441 plantestsuite("samba3.blackbox.smbclient_krb5 old ccache %s" % options
, "ktest:local",
442 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_krb5.sh"),
443 "$PREFIX/ktest/krb5_ccache-2",
444 smbclient3
, "$SERVER", options
, configuration
])
446 plantestsuite("samba3.blackbox.smbclient_krb5 old ccache %s" % options
, "ktest:local",
447 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_krb5.sh"),
448 "$PREFIX/ktest/krb5_ccache-2",
449 smbclient3
, "$SERVER", options
, configuration
])
451 plantestsuite("samba3.blackbox.smbclient_large_file %s" % options
, "ktest:local",
452 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_posix_large.sh"),
453 "$PREFIX/ktest/krb5_ccache-3",
454 smbclient3
, "$SERVER", "$PREFIX", options
, "-k " + configuration
])
456 plantestsuite("samba3.blackbox.smbclient_posix_large %s krb5" % options
, "ktest:local",
457 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_posix_large.sh"),
458 "$PREFIX/ktest/krb5_ccache-3",
459 smbclient3
, "$SERVER", "$PREFIX", options
, "-k " + configuration
])
461 plantestsuite("samba3.blackbox.smbclient_posix_large %s NTLM" % options
, "s3dc:local",
462 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_posix_large.sh"),
464 smbclient3
, "$SERVER", "$PREFIX", options
, "-U$USERNAME%$PASSWORD " + configuration
])
466 for e
in endianness_options
:
467 for a
in auth_options
:
468 for s
in signseal_options
:
469 binding_string
= "ncacn_ip_tcp:$SERVER_IP[%s%s%s]" % (a
, s
, e
)
470 options
= binding_string
+ " -U$USERNAME%$PASSWORD"
471 plansmbtorture4testsuite(test
, "s3dc", options
, 'over ncacn_ip_tcp with [%s%s%s] ' % (a
, s
, e
))
473 plansmbtorture4testsuite('rpc.epmapper', 's3dc:local', 'ncalrpc: -U$USERNAME%$PASSWORD', 'over ncalrpc')