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
25 sys
.path
.insert(0, os
.path
.normpath(os
.path
.join(os
.path
.dirname(__file__
), "../../selftest")))
26 import selftesthelpers
27 from selftesthelpers
import bindir
, srcdir
, scriptdir
, binpath
28 from selftesthelpers
import plantestsuite
, samba3srcdir
29 from selftesthelpers
import planpythontestsuite
30 from selftesthelpers
import smbtorture3
, configuration
, smbclient3
, smbtorture4
31 from selftesthelpers
import net
, wbinfo
, dbwrap_tool
, rpcclient
, python
32 from selftesthelpers
import smbget
, smbcacls
, smbcquotas
, ntlm_auth3
33 from selftesthelpers
import valgrindify
, smbtorture4_testsuites
34 from selftesthelpers
import smbtorture4_options
35 from selftesthelpers
import smbcontrol
36 from selftesthelpers
import smbstatus
37 smbtorture4_options
.extend([
38 '--option=torture:sharedelay=100000',
39 '--option=torture:writetimeupdatedelay=500000',
43 def plansmbtorture4testsuite(name
, env
, options
, description
=''):
45 modname
= "samba3.%s" % (name
, )
47 modname
= "samba3.%s %s" % (name
, description
)
49 selftesthelpers
.plansmbtorture4testsuite(
50 name
, env
, options
, target
='samba3', modname
=modname
)
52 def compare_versions(version1
, version2
):
53 for i
in range(max(len(version1
),len(version2
))):
54 v1
= version1
[i
] if i
< len(version1
) else 0
55 v2
= version2
[i
] if i
< len(version2
) else 0
64 config_h
= os
.environ
["CONFIG_H"]
66 samba4bindir
= bindir()
67 config_h
= os
.path
.join(samba4bindir
, "default/include/config.h")
69 # check available features
71 f
= open(config_h
, 'r')
74 config_hash
= dict((x
[0], ' '.join(x
[1:]))
75 for x
in map(lambda line
: line
.strip().split(' ')[1:],
76 filter(lambda line
: (line
[0:7] == '#define') and (len(line
.split(' ')) > 2), lines
)))
80 linux_kernel_version
= None
81 if platform
.system() == 'Linux':
82 m
= re
.search(r
'(\d+).(\d+).(\d+)', platform
.release())
84 linux_kernel_version
= [int(m
.group(1)), int(m
.group(2)), int(m
.group(3))]
86 have_linux_kernel_oplocks
= False
87 if "HAVE_KERNEL_OPLOCKS_LINUX" in config_hash
:
88 if compare_versions(linux_kernel_version
, [5,3,1]) >= 0:
89 have_linux_kernel_oplocks
= True
91 have_inotify
= ("HAVE_INOTIFY" in config_hash
)
92 have_ldwrap
= ("HAVE_LDWRAP" in config_hash
)
93 with_pthreadpool
= ("WITH_PTHREADPOOL" in config_hash
)
95 have_smb3_unix_extensions
= ("HAVE_SMB3_UNIX_EXTENSIONS" in config_hash
)
97 def is_module_enabled(module
):
98 if module
in config_hash
["STRING_SHARED_MODULES"]:
100 if module
in config_hash
["STRING_STATIC_MODULES"]:
104 plantestsuite("samba3.blackbox.success", "nt4_dc:local", [os
.path
.join(samba3srcdir
, "script/tests/test_success.sh")])
105 plantestsuite("samba3.blackbox.failure", "nt4_dc:local", [os
.path
.join(samba3srcdir
, "script/tests/test_failure.sh")])
107 plantestsuite("samba3.local_s3", "nt4_dc:local", [os
.path
.join(samba3srcdir
, "script/tests/test_local_s3.sh")])
109 plantestsuite("samba3.blackbox.registry.upgrade", "nt4_dc:local", [os
.path
.join(samba3srcdir
, "script/tests/test_registry_upgrade.sh"), net
, dbwrap_tool
])
112 "FDPASS", "LOCK1", "LOCK2", "LOCK3", "LOCK4", "LOCK5", "LOCK6", "LOCK7",
118 "UNLINK", "BROWSE", "ATTR", "TRANS2", "TORTURE",
119 "OPLOCK1", "OPLOCK2", "OPLOCK4", "STREAMERROR",
120 "DIR", "DIR1", "DIR-CREATETIME", "TCON", "TCONDEV", "RW1", "RW2", "RW3", "LARGE_READX", "RW-SIGNING",
121 "OPEN", "XCOPY", "RENAME", "DELETE", "DELETE-LN", "PROPERTIES", "W2K",
122 "TCON2", "IOCTL", "CHKPATH", "FDSESS", "CHAIN1", "CHAIN2", "OWNER-RIGHTS",
123 "CHAIN3", "PIDHIGH", "CLI_SPLICE",
124 "UID-REGRESSION-TEST", "SHORTNAME-TEST",
125 "CASE-INSENSITIVE-CREATE", "SMB2-BASIC", "NTTRANS-FSCTL", "SMB2-NEGPROT",
126 "SMB2-SESSION-REAUTH", "SMB2-SESSION-RECONNECT", "SMB2-FTRUNCATE",
127 "SMB2-ANONYMOUS", "SMB2-DIR-FSYNC",
135 "SMB1-WILD-MANGLE-UNLINK",
136 "SMB1-WILD-MANGLE-RENAME"]
138 for t
in fileserver_tests
:
139 fileserver_env
= "fileserver_smb1"
141 fileserver_env
= "fileserver"
142 plantestsuite("samba3.smbtorture_s3.plain.%s" % t
, fileserver_env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/tmp', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
143 plantestsuite("samba3.smbtorture_s3.crypt_client.%s" % t
, "nt4_dc_smb1", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/tmp', '$USERNAME', '$PASSWORD', smbtorture3
, "-e", "-l $LOCAL_PATH"])
145 # this is a negative test to verify that the server rejects
146 # access without encryption
147 plantestsuite("samba3.smbtorture_s3.crypt_server.%s" % t
, "nt4_dc_smb1", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/tmpenc', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
148 if t
== "CLI_SPLICE":
149 # We must test this against the SMB1 fallback.
150 plantestsuite("samba3.smbtorture_s3.plain.%s" % t
, "fileserver_smb1", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/tmp', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH", "-mNT1"])
151 plantestsuite("samba3.smbtorture_s3.plain.%s" % t
, "ad_dc_ntvfs", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/tmp', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
154 plantestsuite("samba3.smbtorture_s3.plain.%s" % t
, "ad_dc", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER/tmp', '$DC_USERNAME', '$DC_PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
156 if have_linux_kernel_oplocks
:
158 plantestsuite("samba3.smbtorture_s3.plain.%s" % t
,
160 [os
.path
.join(samba3srcdir
,
161 "script/tests/test_smbtorture_s3.sh"),
171 # RENAME-ACCESS needs to run against a special share - acl_xattr_ign_sysacl_windows
173 plantestsuite("samba3.smbtorture_s3.plain.%s" % "RENAME-ACCESS", "nt4_dc_smb1", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), "RENAME-ACCESS", '//$SERVER_IP/acl_xattr_ign_sysacl_windows', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
174 plantestsuite("samba3.smbtorture_s3.crypt_client.%s" % "RENAME-ACCESS", "nt4_dc_smb1", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), "RENAME-ACCESS", '//$SERVER_IP/acl_xattr_ign_sysacl_windows', '$USERNAME', '$PASSWORD', smbtorture3
, "-e", "-l $LOCAL_PATH"])
177 tests
= ["OPLOCK-CANCEL"]
179 plantestsuite("samba3.smbtorture_s3.plain.%s" % t
, "nt4_dc", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/tmp', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
182 tests
= ["MANGLE-ILLEGAL"]
184 plantestsuite("samba3.smbtorture_s3.plain.%s" % t
, env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/mangle_illegal', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
186 tests
= ["RW1", "RW2", "RW3", "SMB2-BASIC"]
188 if t
== "SMB2-BASIC":
191 env
= "fileserver_smb1"
193 plantestsuite("samba3.smbtorture_s3.vfs_aio_pthread(%s).%s" % (env
, t
), env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/vfs_aio_pthread', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
194 plantestsuite("samba3.smbtorture_s3.vfs_aio_fork(%s).%s" % (env
, t
), env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/vfs_aio_fork', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
196 plantestsuite("samba3.smbtorture_s3.hidenewfiles",
198 [os
.path
.join(samba3srcdir
,
199 "script/tests/test_smbtorture_s3.sh"),
200 'hide-new-files-timeout',
201 '//$SERVER_IP/hidenewfiles',
207 plantestsuite("samba3.smbtorture_s3.hidenewfiles_showdirs",
209 [os
.path
.join(samba3srcdir
,
210 "script/tests/test_smbtorture_s3.sh"),
211 'hide-new-files-timeout-showdirs',
212 '//$SERVER_IP/hidenewfiles',
220 # MSDFS attribute tests.
222 plantestsuite("samba3.smbtorture_s3.smb2.MSDFS-ATTRIBUTE",
224 [os
.path
.join(samba3srcdir
,
225 "script/tests/test_smbtorture_s3.sh"),
227 '//$SERVER_IP/msdfs-share',
234 plantestsuite("samba3.smbtorture_s3.smb1.MSDFS-ATTRIBUTE",
236 [os
.path
.join(samba3srcdir
,
237 "script/tests/test_smbtorture_s3.sh"),
239 '//$SERVER_IP/msdfs-share',
247 # SMB2-DFS-PATHS needs to run against a special share msdfs-pathname-share
248 # This is an empty DFS share with no links, used merely to test
249 # incoming DFS pathnames and how they map to local paths.
251 plantestsuite("samba3.smbtorture_s3.smb2.SMB2-DFS-PATHS",
253 [os
.path
.join(samba3srcdir
,
254 "script/tests/test_smbtorture_s3.sh"),
256 '//$SERVER_IP/msdfs-pathname-share',
262 # BUG: https://bugzilla.samba.org/show_bug.cgi?id=15277
263 # MacOSX clients send a leading '\\' character for DFS paths.
265 plantestsuite("samba3.smbtorture_s3.smb2.SMB2-DFS-FILENAME-LEADING-BACKSLASH",
267 [os
.path
.join(samba3srcdir
,
268 "script/tests/test_smbtorture_s3.sh"),
269 'SMB2-DFS-FILENAME-LEADING-BACKSLASH',
270 '//$SERVER_IP/msdfs-pathname-share',
277 # SMB2-NON-DFS-SHARE needs to run against a special share non-msdfs-pathname-share
278 # This is an empty non-DFS share with no links, used merely to test
279 # incoming DFS pathnames and how they map to local paths. We are testing
280 # what happens if we set the FLAGS2_DFS_PATHNAMES and send DFS paths
281 # on a non-DFS share.
283 plantestsuite("samba3.smbtorture_s3.smb2.SMB2-NON-DFS-SHARE",
285 [os
.path
.join(samba3srcdir
,
286 "script/tests/test_smbtorture_s3.sh"),
287 'SMB2-NON-DFS-SHARE',
288 '//$SERVER_IP/non-msdfs-pathname-share',
295 # SMB2-DFS-SHARE-NON-DFS-PATH needs to run against a special share msdfs-pathname-share
296 # This is an empty DFS share with no links, used merely to test
297 # incoming non-DFS pathnames and how they map to local paths.
299 plantestsuite("samba3.smbtorture_s3.smb2.SMB2-DFS-SHARE-NON-DFS-PATH",
301 [os
.path
.join(samba3srcdir
,
302 "script/tests/test_smbtorture_s3.sh"),
303 'SMB2-DFS-SHARE-NON-DFS-PATH',
304 '//$SERVER_IP/msdfs-pathname-share',
311 # SMB1-DFS-PATHS needs to run against a special share msdfs-pathname-share
312 # This is an empty DFS share with no links, used merely to test
313 # incoming DFS pathnames and how they map to local paths.
315 plantestsuite("samba3.smbtorture_s3.smb1.SMB1-DFS-PATHS",
317 [os
.path
.join(samba3srcdir
,
318 "script/tests/test_smbtorture_s3.sh"),
320 '//$SERVER_IP/msdfs-pathname-share',
327 # SMB1-DFS-SEARCH-PATHS needs to run against a special share msdfs-pathname-share
328 # This is an empty DFS share with no links, used merely to test
329 # incoming DFS pathnames and how they map to local paths.
331 plantestsuite("samba3.smbtorture_s3.smb1.SMB1-DFS-SEARCH-PATHS",
333 [os
.path
.join(samba3srcdir
,
334 "script/tests/test_smbtorture_s3.sh"),
335 'SMB1-DFS-SEARCH-PATHS',
336 '//$SERVER_IP/msdfs-pathname-share',
343 # SMB1-DFS-OPERATIONS needs to run against a special share msdfs-pathname-share
344 # This is an empty DFS share with no links, used merely to test
345 # incoming DFS pathnames and how they map to local paths.
347 plantestsuite("samba3.smbtorture_s3.smb1.SMB1-DFS-OPERATIONS",
349 [os
.path
.join(samba3srcdir
,
350 "script/tests/test_smbtorture_s3.sh"),
351 'SMB1-DFS-OPERATIONS',
352 '//$SERVER_IP/msdfs-pathname-share',
359 # SMB2-STREAM-ACL needs to run against a special share - vfs_wo_fruit
361 plantestsuite("samba3.smbtorture_s3.plain.%s" % "SMB2-STREAM-ACL",
363 [os
.path
.join(samba3srcdir
,
364 "script/tests/test_smbtorture_s3.sh"),
366 '//$SERVER_IP/vfs_wo_fruit',
374 # SMB2-LIST-DIR-ASYNC needs to run against a special share vfs_aio_pthread_async_dosmode_default1
376 plantestsuite("samba3.smbtorture_s3.plain.%s" % "SMB2-LIST-DIR-ASYNC",
378 [os
.path
.join(samba3srcdir
,
379 "script/tests/test_smbtorture_s3.sh"),
380 'SMB2-LIST-DIR-ASYNC',
381 '//$SERVER_IP/vfs_aio_pthread_async_dosmode_default1',
388 # SMB2-DEL-ON-CLOSE-NONEMPTY needs to run against a special fileserver share veto_files_delete
390 plantestsuite("samba3.smbtorture_s3.plain.%s" % "SMB2-DEL-ON-CLOSE-NONEMPTY",
392 [os
.path
.join(samba3srcdir
,
393 "script/tests/test_smbtorture_s3.sh"),
394 'SMB2-DEL-ON-CLOSE-NONEMPTY',
395 '//$SERVER_IP/veto_files_delete',
403 # SMB2-DEL-ON-CLOSE-NONWRITE-DELETE-YES needs to run against a special fileserver share delete_yes_unwrite
405 plantestsuite("samba3.smbtorture_s3.plain.%s" % "SMB2-DEL-ON-CLOSE-NONWRITE-DELETE-YES",
407 [os
.path
.join(samba3srcdir
,
408 "script/tests/test_smbtorture_s3.sh"),
409 'SMB2-DEL-ON-CLOSE-NONWRITE-DELETE-YES',
410 '//$SERVER_IP/delete_yes_unwrite',
418 # SMB2-DEL-ON-CLOSE-NONWRITE-DELETE-NO needs to run against a special fileserver share delete_no_unwrite
420 plantestsuite("samba3.smbtorture_s3.plain.%s" % "SMB2-DEL-ON-CLOSE-NONWRITE-DELETE-NO",
422 [os
.path
.join(samba3srcdir
,
423 "script/tests/test_smbtorture_s3.sh"),
424 'SMB2-DEL-ON-CLOSE-NONWRITE-DELETE-NO',
425 '//$SERVER_IP/delete_no_unwrite',
433 "vfs_aio_pthread_async_dosmode_default1",
434 "vfs_aio_pthread_async_dosmode_default2"
437 plantestsuite("samba3.smbtorture_s3.%s(simpleserver).SMB2-BASIC" % s
, "simpleserver", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), 'SMB2-BASIC', '//$SERVER_IP/' + s
, '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
438 t
= "smb2.compound_find"
439 plansmbtorture4testsuite(t
, "simpleserver", "//%s/%s %s" % ('$SERVER_IP', s
, ' -U$USERNAME%$PASSWORD'), description
=s
)
441 posix_tests
= ["POSIX", "POSIX-APPEND", "POSIX-SYMLINK-ACL", "POSIX-SYMLINK-EA", "POSIX-OFD-LOCK",
442 "POSIX-STREAM-DELETE", "WINDOWS-BAD-SYMLINK", "POSIX-MKDIR",
443 "POSIX-BLOCKING-LOCK",
445 "POSIX-ACL-SHAREROOT",
450 "POSIX-SYMLINK-PARENT",
451 "POSIX-SYMLINK-CHMOD",
452 "POSIX-DIR-DEFAULT-ACL",
453 "POSIX-SYMLINK-RENAME",
454 "POSIX-SYMLINK-GETPATHINFO",
455 "POSIX-SYMLINK-SETPATHINFO",
458 for t
in posix_tests
:
459 plantestsuite("samba3.smbtorture_s3.plain.%s" % t
, "nt4_dc_smb1", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/posix_share', '$USERNAME', '$PASSWORD', smbtorture3
, "", "-l $LOCAL_PATH"])
460 plantestsuite("samba3.smbtorture_s3.crypt.%s" % t
, "nt4_dc_smb1", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//$SERVER_IP/posix_share', '$USERNAME', '$PASSWORD', smbtorture3
, "-e", "-l $LOCAL_PATH"])
469 "LOCAL-STR-MATCH-MSWILD",
470 "LOCAL-STR-MATCH-REGEX-SUB1",
471 "LOCAL-string_to_sid",
472 "LOCAL-sid_to_string",
473 "LOCAL-binary_to_sid",
476 "LOCAL-CONVERT-STRING",
477 "LOCAL-CONV-AUTH-INFO",
478 "LOCAL-IDMAP-TDB-COMMON",
479 "LOCAL-MESSAGING-READ1",
480 "LOCAL-MESSAGING-READ2",
481 "LOCAL-MESSAGING-READ3",
482 "LOCAL-MESSAGING-READ4",
483 "LOCAL-MESSAGING-FDPASS1",
484 "LOCAL-MESSAGING-FDPASS2",
485 "LOCAL-MESSAGING-FDPASS2a",
486 "LOCAL-MESSAGING-FDPASS2b",
487 "LOCAL-MESSAGING-SEND-ALL",
488 "LOCAL-PTHREADPOOL-TEVENT",
489 "LOCAL-CANONICALIZE-PATH",
490 "LOCAL-DBWRAP-WATCH1",
491 "LOCAL-DBWRAP-WATCH2",
492 "LOCAL-DBWRAP-WATCH3",
493 "LOCAL-DBWRAP-WATCH4",
494 "LOCAL-DBWRAP-DO-LOCKED1",
504 "LOCAL-NAMEMAP-CACHE1",
505 "LOCAL-IDMAP-CACHE1",
506 "LOCAL-hex_encode_buf",
507 "LOCAL-remove_duplicate_addrs2"]
509 for t
in local_tests
:
510 plantestsuite("samba3.smbtorture_s3.%s" % t
, "none", [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//foo/bar', '""', '""', smbtorture3
, ""])
512 plantestsuite("samba.vfstest.stream_depot", "nt4_dc:local", [os
.path
.join(samba3srcdir
, "script/tests/stream-depot/run.sh"), binpath("vfstest"), "$PREFIX", configuration
])
513 plantestsuite("samba.vfstest.xattr-tdb-1", "nt4_dc:local", [os
.path
.join(samba3srcdir
, "script/tests/xattr-tdb-1/run.sh"), binpath("vfstest"), "$PREFIX", configuration
])
514 plantestsuite("samba.vfstest.acl", "nt4_dc:local", [os
.path
.join(samba3srcdir
, "script/tests/vfstest-acl/run.sh"), binpath("vfstest"), "$PREFIX", configuration
])
515 plantestsuite("samba.vfstest.catia", "nt4_dc:local", [os
.path
.join(samba3srcdir
, "script/tests/vfstest-catia/run.sh"), binpath("vfstest"), "$PREFIX", configuration
])
517 "samba.vfstest.full_audit_segfault",
519 [os
.path
.join(samba3srcdir
,
520 "script/tests/full_audit_segfault/run.sh"),
525 plantestsuite("samba3.blackbox.smbclient_basic.NT1", "nt4_dc_schannel", [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_basic.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME', '$DC_PASSWORD', smbclient3
, configuration
, "-mNT1"])
526 plantestsuite("samba3.blackbox.smbclient_basic.NT1", "nt4_dc_smb1", [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_basic.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME', '$DC_PASSWORD', smbclient3
, configuration
, "-mNT1"])
527 plantestsuite("samba3.blackbox.smbclient_basic.SMB2_02", "nt4_dc_schannel", [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_basic.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME', '$DC_PASSWORD', smbclient3
, configuration
, "-mSMB2_02"])
528 plantestsuite("samba3.blackbox.smbclient_basic.SMB2_10", "nt4_dc_schannel", [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_basic.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME', '$DC_PASSWORD', smbclient3
, configuration
, "-mSMB2_10"])
529 plantestsuite("samba3.blackbox.smbclient_basic.SMB3_02", "nt4_dc_schannel", [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_basic.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME', '$DC_PASSWORD', smbclient3
, configuration
, "-mSMB3_02"])
530 plantestsuite("samba3.blackbox.smbclient_basic.SMB3_11", "nt4_dc_schannel", [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_basic.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME', '$DC_PASSWORD', smbclient3
, configuration
, "-mSMB3_11"])
532 plantestsuite("samba3.blackbox.smbclient_usernamemap", "ad_member_idmap_nss:local", [os
.path
.join(samba3srcdir
, "script/tests/test_usernamemap.sh"), '$SERVER', smbclient3
])
534 plantestsuite("samba3.blackbox.smbclient_basic", "ad_member", [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_basic.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME', '$DC_PASSWORD', smbclient3
, configuration
])
535 for options
in ["", "--option=clientntlmv2auth=no", "--option=clientusespnego=no", "--option=clientusespnego=no --option=clientntlmv2auth=no", "--option=clientntlmv2auth=no --option=clientlanmanauth=yes --max-protocol=LANMAN2", "--option=clientntlmv2auth=no --option=clientlanmanauth=yes --option=clientmaxprotocol=NT1"]:
536 if "NT1" in options
or "LANMAN2" in options
:
537 env
= "nt4_dc_smb1_done"
540 plantestsuite("samba3.blackbox.smbclient_auth.plain.%s" % (options
), env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME', '$DC_PASSWORD', smbclient3
, configuration
, options
])
542 for env
in ["nt4_dc", "nt4_member", "ad_member", "ad_dc", "ad_dc_ntvfs", "s4member", "fl2000dc"]:
543 plantestsuite("samba3.blackbox.smbclient_machine_auth.plain", "%s:local" % env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_machine_auth.sh"), '$SERVER', smbclient3
, configuration
])
545 if smb1_env
== "ad_dc" or smb1_env
== "nt4_dc":
546 smb1_env
= smb1_env
+ "_smb1_done"
547 plantestsuite("samba3.blackbox.smbclient_ntlm.plain NT1", smb1_env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_ntlm.sh"), '$SERVER', '$DC_USERNAME', '$DC_PASSWORD', "never", smbclient3
, "NT1", configuration
])
548 plantestsuite("samba3.blackbox.smbclient_ntlm.plain SMB3", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_ntlm.sh"), '$SERVER', '$DC_USERNAME', '$DC_PASSWORD', "never", smbclient3
, "SMB3", configuration
])
551 plantestsuite("samba3.blackbox.smbclient_log_basename", "ad_dc", [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_log_basename.sh"), '$SERVER', smbclient3
, '$PREFIX', configuration
])
553 for options
in ["--option=clientntlmv2auth=no", "--option=clientusespnego=no --option=clientntlmv2auth=no", "--option=clientusespnego=no --option=clientntlmv2auth=no -mNT1", ""]:
554 # don't attempt to run SMB1 tests in nt4_member or ad_member
555 # as these test envs don't support SMB1, use nt4_dc instead
556 environs
= ["nt4_member", "ad_member"]
557 if "NT1" in options
or "LANMAN2" in options
:
558 environs
= ["nt4_dc_smb1_done"]
560 plantestsuite("samba3.blackbox.smbclient_auth.plain.%s" % (options
), env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME', '$DC_PASSWORD', smbclient3
, configuration
, options
])
561 plantestsuite("samba3.blackbox.smbclient_auth.plain.%s.member_creds" % (options
), env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', '$SERVER/$USERNAME', '$PASSWORD', smbclient3
, configuration
, options
])
563 for env
in ["nt4_member", "ad_member"]:
564 plantestsuite("samba3.blackbox.smbclient_auth.empty_domain.domain_creds", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', '/$DC_USERNAME', '$DC_PASSWORD', smbclient3
, configuration
, options
])
565 plantestsuite("samba3.blackbox.smbclient_auth.empty_domain.member_creds", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', '/$USERNAME', '$PASSWORD', smbclient3
, configuration
, options
])
566 plantestsuite("samba3.blackbox.smbclient_auth.dot_domain.domain_creds", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', './$DC_USERNAME', '$DC_PASSWORD', smbclient3
, configuration
, options
])
567 plantestsuite("samba3.blackbox.smbclient_auth.dot_domain.member_creds", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', './$USERNAME', '$PASSWORD', smbclient3
, configuration
, options
])
568 plantestsuite("samba3.blackbox.smbclient_auth.upn.domain_creds", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME@$REALM', '$DC_PASSWORD', smbclient3
, configuration
, options
])
569 plantestsuite("samba3.blackbox.smbclient_auth.upn.member_creds", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', '$USERNAME@$SERVER', '$PASSWORD', smbclient3
, configuration
, options
])
572 plantestsuite("samba3.blackbox.smbspool", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbspool.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME', '$DC_PASSWORD', env
])
574 plantestsuite("samba3.blackbox.printing_var_exp", "nt4_dc", [os
.path
.join(samba3srcdir
, "script/tests/test_printing_var_exp.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$DC_USERNAME', '$DC_PASSWORD'])
576 for env
in ["ad_member:local", "nt4_dc:local"]:
577 plantestsuite("samba3.blackbox.smbpasswd", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbpasswd.sh"), '$SERVER', '$SERVER_IP', '$DC_USERNAME', '$DC_PASSWORD'])
580 plantestsuite("samba3.blackbox.smbclient_auth.plain.ipv6", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IPV6', '$SERVER/$USERNAME', '$PASSWORD', smbclient3
, configuration
])
582 for env
in ["nt4_member", "ad_member"]:
583 plantestsuite("samba3.blackbox.net_cred_change", "%s:local" % env
, [os
.path
.join(samba3srcdir
, "script/tests/test_net_cred_change.sh"), configuration
])
585 plantestsuite("samba3.blackbox.net_cred_change_at", "ad_member_s3_join:local", [os
.path
.join(samba3srcdir
, "script/tests/test_net_cred_change_at.sh"), configuration
, '$DC_SERVER'])
588 t
= "--krb5auth=$DOMAIN/$DC_USERNAME%$DC_PASSWORD"
589 plantestsuite("samba3.wbinfo_simple.%s" % t
, "%s:local" % env
, [os
.path
.join(srcdir(), "nsswitch/tests/test_wbinfo_simple.sh"), t
])
590 plantestsuite("samba3.wbinfo_name_lookup", env
,
591 [os
.path
.join(srcdir(),
592 "nsswitch/tests/test_wbinfo_name_lookup.sh"),
593 '$DOMAIN', '$REALM', '$DC_USERNAME'])
596 plantestsuite("samba3.wbinfo_user_info_cached", env
,
597 [os
.path
.join(srcdir(),
598 "nsswitch/tests/test_wbinfo_user_info_cached.sh"),
599 '$DOMAIN', '$REALM', 'joe', 'Secret007', '"Samba Users"', env
])
600 plantestsuite("samba3.wbinfo_user_info_cached.trustdom", env
,
601 [os
.path
.join(srcdir(),
602 "nsswitch/tests/test_wbinfo_user_info_cached.sh"),
603 '$TRUST_F_BOTH_DOMAIN', '$TRUST_F_BOTH_REALM', 'joe', 'Secret007', '"Samba Users"', env
])
605 env
= "ad_member:local"
606 plantestsuite("samba3.wbinfo_user_info", env
,
607 [os
.path
.join(srcdir(),
608 "nsswitch/tests/test_wbinfo_user_info.sh"),
609 '$DOMAIN', '$REALM', '$DOMAIN', 'alice', 'alice', 'jane', 'jane.doe', env
])
611 plantestsuite("samba3.winbind_call_depth_trace", env
,
612 [os
.path
.join(srcdir(),
613 "source3/script/tests/test_winbind_call_depth_trace.sh"),
614 smbcontrol
, configuration
, '$PREFIX', env
])
616 env
= "fl2008r2dc:local"
617 plantestsuite("samba3.wbinfo_user_info", env
,
618 [os
.path
.join(srcdir(),
619 "nsswitch/tests/test_wbinfo_user_info.sh"),
620 '$TRUST_DOMAIN', '$TRUST_REALM', '$DOMAIN', 'alice', 'alice', 'jane', 'jane.doe', env
])
622 env
= "nt4_member:local"
623 plantestsuite("samba3.wbinfo_sids_to_xids", env
,
624 [os
.path
.join(srcdir(),
625 "nsswitch/tests/test_wbinfo_sids_to_xids.sh")])
627 "samba.wbinfo_lookuprids_cache",
629 [os
.path
.join(samba3srcdir
,
630 "script/tests/test_wbinfo_lookuprids_cache.sh")])
633 t
= "WBCLIENT-MULTI-PING"
634 plantestsuite("samba3.smbtorture_s3.%s" % t
, env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"), t
, '//foo/bar', '""', '""', smbtorture3
, ""])
635 plantestsuite("samba3.substitutions", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_substitutions.sh"), "$SERVER", "alice", "Secret007", "$PREFIX"])
637 for env
in ["maptoguest", "simpleserver"]:
638 plantestsuite("samba3.blackbox.smbclient_auth.plain.local_creds", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_auth.sh"), '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', smbclient3
, configuration
+ " --option=clientntlmv2auth=no --option=clientlanmanauth=yes"])
641 plantestsuite("samba3.blackbox.smbclient_auth.plain.bad_username", 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"])
642 plantestsuite("samba3.blackbox.smbclient_ntlm.plain.NT1", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_ntlm.sh"), '$SERVER', '$USERNAME', '$PASSWORD', "baduser", smbclient3
, "NT1", configuration
])
643 plantestsuite("samba3.blackbox.smbclient_ntlm.plain.SMB3", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_ntlm.sh"), '$SERVER', '$USERNAME', '$PASSWORD', "baduser", smbclient3
, "SMB3", configuration
])
646 env
= "nt4_dc_smb1_done"
647 plantestsuite("samba3.blackbox.smbclient_s3.NT1.plain", 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
, "NT1"])
649 plantestsuite("samba3.blackbox.smbclient_s3.SMB3.plain", 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
, "SMB3"])
651 for env
in ["nt4_member", "ad_member"]:
652 plantestsuite("samba3.blackbox.smbclient_s3.NT1.plain.member_creds", 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
, "NT1"])
653 plantestsuite("samba3.blackbox.smbclient_s3.SMB3.plain.member_creds", 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
, "SMB3"])
655 env
= "nt4_dc_smb1_done"
656 plantestsuite("samba3.blackbox.smbclient_s3.NT1.sign", 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
, "NT1", "--client-protection=sign"])
658 plantestsuite("samba3.blackbox.smbclient_s3.SMB3.sign", 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
, "SMB3", "--client-protection=sign"])
660 for env
in ["nt4_member", "ad_member"]:
661 plantestsuite("samba3.blackbox.smbclient_s3.NT1.sign.member_creds", 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
, "NT1", "--client-protection=sign"])
662 plantestsuite("samba3.blackbox.smbclient_s3.SMB3.sign.member_creds", 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
, "SMB3", "--client-protection=sign"])
664 env
= "nt4_dc_smb1_done"
666 plantestsuite("samba3.blackbox.smbclient_s3.NT1.crypt", 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
, "NT1", "--client-protection=encrypt"])
668 plantestsuite("samba3.blackbox.smbclient_s3.SMB3.crypt", 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
, "SMB3", "--client-protection=encrypt"])
670 for env
in ["fileserver"]:
671 plantestsuite("samba3.blackbox.preserve_case.NT1", env
+ "_smb1_done", [os
.path
.join(samba3srcdir
, "script/tests/test_preserve_case.sh"), '$SERVER', '$DOMAIN', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, "NT1"])
672 plantestsuite("samba3.blackbox.preserve_case.SMB2+", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_preserve_case.sh"), '$SERVER', '$DOMAIN', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, '"SMB2 SMB3"'])
673 plantestsuite("samba3.blackbox.dfree_command.NT1", env
+ "_smb1_done", [os
.path
.join(samba3srcdir
, "script/tests/test_dfree_command.sh"), '$SERVER', '$DOMAIN', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, "NT1"])
674 plantestsuite("samba3.blackbox.dfree_command.SMB3", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_dfree_command.sh"), '$SERVER', '$DOMAIN', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, "SMB3"])
675 plantestsuite("samba3.blackbox.dfree_quota.NT1", env
+ "_smb1_done", [os
.path
.join(samba3srcdir
, "script/tests/test_dfree_quota.sh"), '$SERVER', '$DOMAIN', '$USERNAME', '$PASSWORD', '$LOCAL_PATH', smbclient3
, smbcquotas
, smbcacls
, "NT1"])
676 plantestsuite("samba3.blackbox.dfree_quota.SMB3", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_dfree_quota.sh"), '$SERVER', '$DOMAIN', '$USERNAME', '$PASSWORD', '$LOCAL_PATH', smbclient3
, smbcquotas
, smbcacls
, "SMB3"])
677 plantestsuite("samba3.blackbox.smbcquotas", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbcquota.sh"), '$SERVER', '$DOMAIN', '$USERNAME', '$PASSWORD', '$LOCAL_PATH', smbcquotas
])
678 plantestsuite("samba3.blackbox.valid_users", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_valid_users.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
])
679 plantestsuite("samba3.blackbox.force_create_mode", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_force_create_mode.sh"), '$SERVER', '$DOMAIN', '$USERNAME', '$PASSWORD', '$PREFIX', env
, smbclient3
])
680 plantestsuite("samba3.blackbox.dropbox", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_dropbox.sh"), '$SERVER', '$DOMAIN', 'gooduser', '$PASSWORD', '$PREFIX', env
, smbclient3
])
681 plantestsuite("samba3.blackbox.offline", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_offline.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$USERNAME', '$PASSWORD', '$LOCAL_PATH/offline', smbclient3
])
682 plantestsuite("samba3.blackbox.shadow_copy2.NT1", env
+ "_smb1_done", [os
.path
.join(samba3srcdir
, "script/tests/test_shadow_copy.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$USERNAME', '$PASSWORD', '$LOCAL_PATH/shadow', smbclient3
, '-m', 'NT1'])
683 plantestsuite("samba3.blackbox.shadow_copy2.SMB3", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_shadow_copy.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$USERNAME', '$PASSWORD', '$LOCAL_PATH/shadow', smbclient3
, '-m', 'SMB3'])
684 plantestsuite("samba3.blackbox.shadow_copy_torture", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_shadow_copy_torture.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$USERNAME', '$PASSWORD', '$LOCAL_PATH/shadow', smbtorture4
, smbclient3
])
685 plantestsuite("samba3.blackbox.smbclient.forceuser_validusers", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_forceuser_validusers.sh"), '$SERVER', '$DOMAIN', '$USERNAME', '$PASSWORD', '$LOCAL_PATH', smbclient3
])
686 plantestsuite("samba3.blackbox.smbget", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbget.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', 'smbget_user', '$PASSWORD', '$LOCAL_PATH/smbget', smbget
])
687 plantestsuite("samba3.blackbox.netshareenum", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_shareenum.sh"), '$SERVER', '$USERNAME', '$PASSWORD', rpcclient
])
688 plantestsuite("samba3.blackbox.acl_xattr.NT1", env
+ "_smb1_done", [os
.path
.join(samba3srcdir
, "script/tests/test_acl_xattr.sh"), '$SERVER', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, smbcacls
, '-mNT1'])
689 plantestsuite("samba3.blackbox.acl_xattr.SMB3", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_acl_xattr.sh"), '$SERVER', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, smbcacls
, '-mSMB3'])
690 plantestsuite("samba3.blackbox.smb2.not_casesensitive", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smb2_not_casesensitive.sh"), '//$SERVER/tmp', '$SERVER_IP', '$USERNAME', '$PASSWORD', '$LOCAL_PATH', smbclient3
])
691 plantestsuite("samba3.blackbox.inherit_owner.default.NT1", env
+ "_smb1_done", [os
.path
.join(samba3srcdir
, "script/tests/test_inherit_owner.sh"), '$SERVER', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, smbcacls
, net
, 'tmp', '0', '0', '-m', 'NT1'])
692 plantestsuite("samba3.blackbox.inherit_owner.default.SMB3", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_inherit_owner.sh"), '$SERVER', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, smbcacls
, net
, 'tmp', '0', '0', '-m', 'SMB3'])
693 plantestsuite("samba3.blackbox.inherit_owner.full.NT1", env
+ "_smb1_done", [os
.path
.join(samba3srcdir
, "script/tests/test_inherit_owner.sh"), '$SERVER', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, smbcacls
, net
, 'inherit_owner', '1', '1', '-m', 'NT1'])
694 plantestsuite("samba3.blackbox.inherit_owner.full.SMB3", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_inherit_owner.sh"), '$SERVER', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, smbcacls
, net
, 'inherit_owner', '1', '1', '-m', 'SMB3'])
695 plantestsuite("samba3.blackbox.inherit_owner.unix.NT1", env
+ "_smb1_done", [os
.path
.join(samba3srcdir
, "script/tests/test_inherit_owner.sh"), '$SERVER', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, smbcacls
, net
, 'inherit_owner_u', '0', '1', '-m', 'NT1'])
696 plantestsuite("samba3.blackbox.inherit_owner.unix.SMB3", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_inherit_owner.sh"), '$SERVER', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, smbcacls
, net
, 'inherit_owner_u', '0', '1', '-m', 'SMB3'])
697 plantestsuite("samba3.blackbox.large_acl.NT1", env
+ "_smb1_done", [os
.path
.join(samba3srcdir
, "script/tests/test_large_acl.sh"), '$SERVER', '$USERNAME', '$PASSWORD', smbclient3
, smbcacls
, '-m', 'NT1'])
698 plantestsuite("samba3.blackbox.large_acl.SMB3", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_large_acl.sh"), '$SERVER', '$USERNAME', '$PASSWORD', smbclient3
, smbcacls
, '-m', 'SMB3'])
699 plantestsuite("samba3.blackbox.give_owner", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_give_owner.sh"), '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, smbcacls
, net
, 'tmp'])
700 plantestsuite("samba3.blackbox.delete_stream", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_delete_stream.sh"), '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
, smbcacls
, net
, 'acl_streams_xattr'])
701 plantestsuite("samba3.blackbox.homes", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_homes.sh"), '$SERVER', '$USERNAME', '$PASSWORD', '$LOCAL_PATH', '$PREFIX', smbclient3
, configuration
])
702 plantestsuite("samba3.blackbox.force_group_change", env
,
703 [os
.path
.join(samba3srcdir
, "script/tests/test_force_group_change.sh"),
704 '$SERVER', '$USERNAME', '$PASSWORD', '$LOCAL_PATH', smbclient3
, smbcontrol
])
705 plantestsuite("samba3.blackbox.zero-data", env
,
706 [os
.path
.join(samba3srcdir
, "script/tests/test_zero_data.sh"),
707 '$SERVER_IP', '$USERNAME', '$PASSWORD', '$LOCAL_PATH'])
708 plantestsuite("samba3.blackbox.timestamps", env
,
709 [os
.path
.join(samba3srcdir
, "script/tests/test_timestamps.sh"),
710 '$SERVER_IP', '$USERNAME', '$PASSWORD', '$LOCAL_PATH', smbclient3
])
711 plantestsuite("samba3.blackbox.volumeserialnumber", env
,
712 [os
.path
.join(samba3srcdir
, "script/tests/test_volume_serial_number.sh"),
713 '$SERVER_IP', '$USERNAME', '$PASSWORD', 'volumeserialnumber', smbclient3
])
714 plantestsuite("samba3.blackbox.smb1_system_security", env
+ "_smb1_done",
715 [os
.path
.join(samba3srcdir
, "script/tests/test_smb1_system_security.sh"),
716 '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', smbtorture3
, net
, 'tmp'])
717 plantestsuite("samba3.blackbox.sacl_get_set", env
,
718 [os
.path
.join(samba3srcdir
, "script/tests/test_sacl_set_get.sh"),
719 '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', smbtorture3
, net
, 'tmp'])
720 plantestsuite("samba3.blackbox.NT1.shadow_copy_torture", env
+ "_smb1_done",
721 [os
.path
.join(samba3srcdir
, "script/tests/test_smb1_shadow_copy_torture.sh"),
722 '$SERVER', '$SERVER_IP', '$DOMAIN', '$USERNAME', '$PASSWORD', '$LOCAL_PATH/shadow', smbtorture4
])
723 plantestsuite("samba3.blackbox.smbclient_iconv.SMB2", env
,
724 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_iconv.sh"),
725 '$SERVER', '$SERVER_IP', 'bad_iconv', '$USERNAME', '$PASSWORD', smbclient3
])
726 plantestsuite("samba3.blackbox.smbclient_iconv.NT1", env
+ "_smb1_done",
727 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_iconv.sh"),
728 '$SERVER', '$SERVER_IP', 'bad_iconv', '$USERNAME', '$PASSWORD', smbclient3
, '-mNT1'])
729 plantestsuite("samba3.blackbox.smbclient_iconv.CORE", env
+ "_smb1_done",
730 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_iconv.sh"),
731 '$SERVER', '$SERVER_IP', 'bad_iconv', '$USERNAME', '$PASSWORD', smbclient3
, '-mCORE'])
732 plantestsuite("samba3.blackbox.test_veto_rmdir", env
,
733 [os
.path
.join(samba3srcdir
, "script/tests/test_veto_rmdir.sh"),
734 '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', '$LOCAL_PATH/veto', smbclient3
])
735 plantestsuite("samba3.blackbox.test_dangle_rmdir", env
,
736 [os
.path
.join(samba3srcdir
, "script/tests/test_delete_veto_files_only_rmdir.sh"),
737 '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', '$LOCAL_PATH/veto', smbclient3
])
738 plantestsuite("samba3.blackbox.test_list_servers.NT1",
740 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_list_servers.sh"),
747 plantestsuite("samba3.blackbox.test_list_servers.SMB2",
749 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_list_servers.sh"),
757 plantestsuite("samba3.blackbox.test_symlink_traversal.SMB2", env
,
758 [os
.path
.join(samba3srcdir
, "script/tests/test_symlink_traversal_smb2.sh"),
759 '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', '$LOCAL_PATH/local_symlinks',
760 '$PREFIX', smbclient3
])
762 plantestsuite("samba3.blackbox.test_symlink_traversal.SMB1", env
+ "_smb1_done",
763 [os
.path
.join(samba3srcdir
, "script/tests/test_symlink_traversal_smb1.sh"),
764 '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', '$LOCAL_PATH/local_symlinks',
765 '$PREFIX', smbclient3
])
767 plantestsuite("samba3.blackbox.test_symlink_traversal.SMB1.posix", env
+ "_smb1_done",
768 [os
.path
.join(samba3srcdir
, "script/tests/test_symlink_traversal_smb1_posix.sh"),
769 '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', '$LOCAL_PATH/local_symlinks',
770 '$PREFIX', smbclient3
])
772 plantestsuite("samba3.blackbox.test_symlink_rename.SMB1.posix", env
+ "_smb1_done",
773 [os
.path
.join(samba3srcdir
, "script/tests/test_symlink_rename_smb1_posix.sh"),
774 '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', '$LOCAL_PATH/local_symlinks',
775 '$PREFIX', smbclient3
])
777 plantestsuite("samba3.blackbox.test_veto_files", env
,
778 [os
.path
.join(samba3srcdir
, "script/tests/test_veto_files.sh"),
779 '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', '$LOCAL_PATH/veto', smbclient3
])
781 plantestsuite("samba3.blackbox.stream_dir_rename", env
,
782 [os
.path
.join(samba3srcdir
, "script/tests/test_stream_dir_rename.sh"),
783 '$SERVER', '$USERNAME', '$PASSWORD', '$PREFIX', smbclient3
])
789 # Test smbclient/tarmode
790 plantestsuite("samba3.blackbox.smbclient_tarmode.NT1", env
+ "_smb1_done",
791 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_tarmode.sh"),
792 '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD',
793 '$LOCAL_PATH/tarmode/smbclient_tar', '$PREFIX', smbclient3
, configuration
, "-mNT1"])
794 plantestsuite("samba3.blackbox.smbclient_tarmode.SMB3", env
,
795 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_tarmode.sh"),
796 '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD',
797 '$LOCAL_PATH/tarmode/smbclient_tar', '$PREFIX', smbclient3
, configuration
, "-mSMB3"])
799 # Test suite for new smbclient/tar with libarchive (GSoC 13)
800 plantestsuite("samba3.blackbox.smbclient_tar.NT1", env
+ "_smb1_done",
801 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_tarmode.pl"),
802 '-n', '$SERVER', '-i', '$SERVER_IP', '-s', 'tarmode2',
803 '-u', '$USERNAME', '-p', '$PASSWORD', '-l', '$LOCAL_PATH/tarmode2',
804 '-d', 'smbclient_tar.NT1', '-b', smbclient3
,
805 '--subunit', '--', configuration
, '-mNT1'])
806 plantestsuite("samba3.blackbox.smbclient_tar.SMB3", env
,
807 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_tarmode.pl"),
808 '-n', '$SERVER', '-i', '$SERVER_IP', '-s', 'tarmode2',
809 '-u', '$USERNAME', '-p', '$PASSWORD', '-l', '$LOCAL_PATH/tarmode2',
810 '-d', 'smbclient_tar.SMB3', '-b', smbclient3
,
811 '--subunit', '--', configuration
, '-mSMB3'])
812 plantestsuite("samba3.blackbox.fifo", env
,
813 [os
.path
.join(samba3srcdir
, "script/tests/test_fifo.sh"),
814 '$SERVER', '$DOMAIN', 'gooduser', '$PASSWORD', '$PREFIX', env
, smbclient3
])
815 plantestsuite("samba3.blackbox.test_full_audit_success_badname", env
,
816 [os
.path
.join(samba3srcdir
, "script/tests/test_bad_auditnames.sh"),
817 '$SERVER', 'full_audit_success_bad_name', '$USERNAME', '$PASSWORD', smbclient3
])
818 plantestsuite("samba3.blackbox.test_full_audit_fail_badname", env
,
819 [os
.path
.join(samba3srcdir
, "script/tests/test_bad_auditnames.sh"),
820 '$SERVER', 'full_audit_fail_bad_name', '$USERNAME', '$PASSWORD', smbclient3
])
821 plantestsuite("samba3.blackbox.fruit.resource_stream", env
,
822 [os
.path
.join(samba3srcdir
, "script/tests/test_fruit_resource_stream.sh"),
823 '$SERVER', 'fruit_resource_stream', '$USERNAME', '$PASSWORD',
824 '$LOCAL_PATH/fruit_resource_stream', smbclient3
])
826 for env
in ["fileserver:local"]:
827 plantestsuite("samba3.blackbox.net_usershare", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_net_usershare.sh"), '$SERVER', '$SERVER_IP', '$USERNAME', '$PASSWORD', smbclient3
])
829 plantestsuite("samba3.blackbox.smbstatus", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_smbstatus.sh"), '$SERVER', '$SERVER_IP', '$DOMAIN', '$USERNAME', '$PASSWORD', '$USERID', '$LOCAL_PATH', '$PREFIX', smbclient3
, smbstatus
, configuration
, "SMB3"])
830 plantestsuite("samba3.blackbox.net_registry_import", env
, [os
.path
.join(samba3srcdir
, "script/tests/test_net_registry_import.sh"), '$SERVER', '$LOCAL_PATH', '$USERNAME', '$PASSWORD'])
832 plantestsuite("samba3.blackbox.server_addresses",
834 [os
.path
.join(samba3srcdir
,
835 "script/tests/test_server_addresses.sh")])
837 # TODO encrypted against member, with member creds, and with DC creds
838 plantestsuite("samba3.blackbox.net.misc NT1", "ad_dc_smb1_done:local",
839 [os
.path
.join(samba3srcdir
, "script/tests/test_net_misc.sh"),
840 scriptdir
, "$SMB_CONF_PATH", net
, configuration
, "NT1"])
841 plantestsuite("samba3.blackbox.net.misc SMB3", "ad_dc:local",
842 [os
.path
.join(samba3srcdir
, "script/tests/test_net_misc.sh"),
843 scriptdir
, "$SMB_CONF_PATH", net
, configuration
, "SMB3"])
844 plantestsuite("samba3.blackbox.net.local.registry", "nt4_dc:local",
845 [os
.path
.join(samba3srcdir
, "script/tests/test_net_registry.sh"),
846 scriptdir
, "$SMB_CONF_PATH", net
, configuration
])
847 plantestsuite("samba3.blackbox.net.registry.check", "nt4_dc:local",
848 [os
.path
.join(samba3srcdir
, "script/tests/test_net_registry_check.sh"),
849 scriptdir
, "$SMB_CONF_PATH", net
, configuration
, dbwrap_tool
])
850 plantestsuite("samba3.blackbox.net.rpc.registry", "nt4_dc",
851 [os
.path
.join(samba3srcdir
, "script/tests/test_net_registry.sh"),
852 scriptdir
, "$SMB_CONF_PATH", net
, configuration
, 'rpc'])
854 plantestsuite("samba3.blackbox.net.local.registry.roundtrip", "nt4_dc:local",
855 [os
.path
.join(samba3srcdir
, "script/tests/test_net_registry_roundtrip.sh"),
856 scriptdir
, "$SMB_CONF_PATH", net
, configuration
])
857 plantestsuite("samba3.blackbox.net.rpc.registry.roundtrip", "nt4_dc",
858 [os
.path
.join(samba3srcdir
, "script/tests/test_net_registry_roundtrip.sh"),
859 scriptdir
, "$SMB_CONF_PATH", net
, configuration
, 'rpc'])
861 plantestsuite("samba3.blackbox.net.local.conf", "nt4_dc:local",
862 [os
.path
.join(samba3srcdir
, "script/tests/test_net_conf.sh"),
863 scriptdir
, "$SMB_CONF_PATH", net
, configuration
])
864 plantestsuite("samba3.blackbox.net.rpc.conf", "nt4_dc",
865 [os
.path
.join(samba3srcdir
, "script/tests/test_net_conf.sh"),
866 scriptdir
, "$SMB_CONF_PATH", net
, configuration
, 'rpc'])
869 plantestsuite("samba3.blackbox.testparm", "nt4_dc:local",
870 [os
.path
.join(samba3srcdir
, "script/tests/test_testparm_s3.sh"),
874 "samba3.pthreadpool", "none",
875 [os
.path
.join(samba3srcdir
, "script/tests/test_pthreadpool.sh")])
877 if with_pthreadpool
and have_ldwrap
:
878 plantestsuite("samba3.pthreadpool_cmocka", "none",
879 [os
.path
.join(bindir(), "pthreadpooltest_cmocka")])
882 plantestsuite("samba3.libwbclient_threads",
884 [os
.path
.join(samba3srcdir
,
885 "script/tests/test_libwbclient_threads.sh"),
886 "$DOMAIN", "$DC_USERNAME"])
888 plantestsuite("samba3.test_nfs4_acl", "none",
889 [os
.path
.join(bindir(), "test_nfs4_acls"),
892 plantestsuite("samba3.test_vfs_full_audit", "none",
893 [os
.path
.join(bindir(), "test_vfs_full_audit"),
896 plantestsuite("samba3.test_vfs_posixacl", "none",
897 [os
.path
.join(bindir(), "test_vfs_posixacl"),
900 if is_module_enabled("vfs_gpfs"):
901 plantestsuite("samba3.test_vfs_gpfs", "none",
902 [os
.path
.join(bindir(), "test_vfs_gpfs")])
905 "samba3.resolvconf", "none",
906 [os
.path
.join(samba3srcdir
, "script/tests/test_resolvconf.sh")])
908 plantestsuite("samba3.tevent_glib_glue", "none",
909 [os
.path
.join(samba3srcdir
, "script/tests/test_tevent_glib_glue.sh")])
911 plantestsuite("samba3.async_req", "nt4_dc",
912 [os
.path
.join(samba3srcdir
, "script/tests/test_async_req.sh")])
916 base
= ["base.attr", "base.charset", "base.chkpath", "base.createx_access", "base.defer_open", "base.delaywrite", "base.delete",
917 "base.deny1", "base.deny2", "base.deny3", "base.denydos", "base.dir1", "base.dir2",
918 "base.disconnect", "base.fdpass", "base.lock",
919 "base.mangle", "base.negnowait", "base.ntdeny1",
920 "base.ntdeny2", "base.open", "base.openattr", "base.properties", "base.rename", "base.rw1",
921 "base.secleak", "base.tcon", "base.tcondev", "base.trans2", "base.unlink", "base.vuid",
922 "base.xcopy", "base.samba3error"]
924 raw
= ["raw.acls", "raw.chkpath", "raw.close", "raw.composite", "raw.context", "raw.eas",
925 "raw.ioctl", "raw.lock", "raw.mkdir", "raw.mux", "raw.notify", "raw.open", "raw.oplock",
926 "raw.qfileinfo", "raw.qfsinfo", "raw.read", "raw.rename", "raw.search", "raw.seek",
927 "raw.sfileinfo.base", "raw.sfileinfo.bug", "raw.streams", "raw.unlink", "raw.write",
928 "raw.samba3hide", "raw.samba3badpath", "raw.sfileinfo.rename", "raw.session",
929 "raw.samba3caseinsensitive", "raw.samba3posixtimedlock",
930 "raw.samba3rootdirfid", "raw.samba3rootdirfid2", "raw.sfileinfo.end-of-file",
931 "raw.bench-oplock", "raw.bench-lock", "raw.bench-open", "raw.bench-tcon",
932 "raw.samba3checkfsp", "raw.samba3closeerr", "raw.samba3oplocklogoff", "raw.samba3badnameblob"]
934 smb2
= smbtorture4_testsuites("smb2.")
936 rpc
= ["rpc.authcontext",
939 "rpc.samba3.sharesec",
940 "rpc.samba3.spoolss",
943 "rpc.samba3.getaliasmembership-0",
944 "rpc.samba3.netlogon",
945 "rpc.samba3.sessionkey",
946 "rpc.samba3.getusername",
947 "rpc.samba3.smb1-pipe-name",
948 "rpc.samba3.smb2-pipe-name",
949 "rpc.samba3.smb-reauth1",
950 "rpc.samba3.smb-reauth2",
951 "rpc.samba3.lsa_over_netlogon",
952 "rpc.samba3.pipes_supported_interfaces",
957 "rpc.spoolss.printserver",
959 "rpc.spoolss.notify",
960 "rpc.spoolss.printer",
961 "rpc.spoolss.driver",
964 "rpc.lsa.lookupsids",
965 "rpc.lsa.lookupnames",
966 "rpc.lsa.privileges",
971 "rpc.samr.users.privileges",
972 "rpc.samr.passwords.default",
973 "rpc.samr.passwords.pwdlastset",
974 "rpc.samr.passwords.lockout",
975 "rpc.samr.passwords.badpwdcount",
977 "rpc.samr.machine.auth",
979 "rpc.samr.passwords.validate",
980 "rpc.samr.handletype",
981 "rpc.netlogon.admin",
982 "rpc.netlogon.zerologon",
985 "rpc.bench-schannel1",
986 "rpc.schannel_anon_setpw",
993 local
= ["local.nss"]
995 idmap
= ["idmap.rfc2307", "idmap.alloc", "idmap.rid", "idmap.ad"]
997 rap
= ["rap.basic", "rap.rpc", "rap.printing", "rap.sam"]
999 unix
= ["unix.info2", "unix.whoami"]
1006 "vfs.fruit_netatalk",
1007 "vfs.fruit_file_id",
1008 "vfs.fruit_timemachine",
1009 "vfs.fruit_conversion",
1013 tests
= base
+ raw
+ smb2
+ rpc
+ unix
+ local
+ rap
+ nbt
+ idmap
+ vfs
1016 if t
== "base.delaywrite" or t
== "base.deny1" or t
== "base.deny2":
1017 plansmbtorture4testsuite(t
, "fileserver_smb1", '//$SERVER/tmp -U$USERNAME%$PASSWORD --maximum-runtime=900')
1018 elif t
== "base.createx_access":
1019 plansmbtorture4testsuite(t
, "ad_dc_smb1", '//$SERVER/tmp -U$USERNAME%$PASSWORD -k yes --maximum-runtime=900')
1020 elif t
== "rap.sam":
1021 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD --option=doscharset=ISO-8859-1')
1022 plansmbtorture4testsuite(t
, "ad_dc_smb1", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD --option=doscharset=ISO-8859-1')
1023 elif t
== "winbind.pac":
1024 plansmbtorture4testsuite(t
, "ad_member:local", '//$SERVER/tmp --realm=$REALM --machine-pass --option=torture:addc=$DC_SERVER', description
="machine account")
1025 elif t
== "unix.whoami":
1026 plansmbtorture4testsuite(t
, "nt4_member:local", '//$SERVER/tmp --machine-pass', description
="machine account")
1027 plansmbtorture4testsuite(t
, "ad_dc_smb1:local", '//$SERVER/tmp --machine-pass', description
="machine account")
1028 plansmbtorture4testsuite(t
, "ad_member:local", '//$SERVER/tmp --machine-pass --option=torture:addc=$DC_SERVER', description
="machine account")
1029 plansmbtorture4testsuite(t
, "ad_dc_smb1:local", '//$SERVER/tmp --machine-pass --option=torture:addc=$DC_SERVER', description
="machine account")
1030 for env
in ["nt4_dc_smb1", "nt4_member"]:
1031 plansmbtorture4testsuite(t
, env
, '//$SERVER/tmp -U$DC_USERNAME%$DC_PASSWORD')
1032 plansmbtorture4testsuite(t
, env
, '//$SERVER/tmpguest -U%', description
='anonymous connection')
1033 for env
in ["ad_dc_smb1", "ad_member"]:
1034 plansmbtorture4testsuite(t
, env
, '//$SERVER/tmp -U$DC_USERNAME@$REALM%$DC_PASSWORD --option=torture:addc=$DC_SERVER')
1035 plansmbtorture4testsuite(t
, env
, '//$SERVER/tmp -k yes -U$DC_USERNAME@$REALM%$DC_PASSWORD --option=torture:addc=$DC_SERVER', description
='kerberos connection')
1036 plansmbtorture4testsuite(t
, env
, '//$SERVER/tmpguest -U% --option=torture:addc=$DC_SERVER', description
='anonymous connection')
1037 plansmbtorture4testsuite(t
, env
, '//$SERVER/tmp -k no -U$DC_USERNAME@$REALM%$DC_PASSWORD', description
='ntlm user@realm')
1038 elif t
== "raw.samba3posixtimedlock":
1039 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmpguest -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/nt4_dc_smb1/share')
1040 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/brl_delay_inject1 -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/nt4_dc_smb1/share',
1041 description
="brl_delay_inject1")
1042 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/brl_delay_inject2 -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/nt4_dc_smb1/share',
1043 description
="brl_delay_inject2")
1044 plansmbtorture4testsuite(t
, "ad_dc_smb1", '//$SERVER_IP/tmpguest -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/ad_dc_smb1/share')
1045 elif t
== "smb2.samba3misc":
1046 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmpguest -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/nt4_dc/share')
1047 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/brl_delay_inject1 -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/nt4_dc/share',
1048 description
="brl_delay_inject1")
1049 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/brl_delay_inject2 -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/nt4_dc/share',
1050 description
="brl_delay_inject2")
1051 plansmbtorture4testsuite(t
, "ad_dc", '//$SERVER_IP/tmpguest -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/ad_dc/share')
1052 elif t
== "raw.chkpath":
1053 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmpcase -U$USERNAME%$PASSWORD')
1054 plansmbtorture4testsuite(t
, "ad_dc_smb1", '//$SERVER_IP/tmpcase -U$USERNAME%$PASSWORD')
1055 elif t
== "raw.samba3hide" or t
== "raw.samba3checkfsp" or t
== "raw.samba3closeerr":
1056 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1057 plansmbtorture4testsuite(t
, "fileserver_smb1", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1058 plansmbtorture4testsuite(t
, "ad_dc_smb1", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
1059 elif t
== "raw.session":
1060 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD', 'plain')
1061 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmpenc -U$USERNAME%$PASSWORD', 'enc')
1062 plansmbtorture4testsuite(t
, "ad_dc_smb1", '//$SERVER/tmp -k no -U$USERNAME%$PASSWORD', 'ntlm')
1063 plansmbtorture4testsuite(t
, "ad_dc_smb1", '//$SERVER/tmp -k yes -U$USERNAME%$PASSWORD', 'krb5')
1064 elif t
== "smb2.session":
1065 alice_creds
= "--option='torture:user2name=alice' --option='torture:user2password=Secret007'"
1066 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD', 'plain')
1067 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmpenc -U$USERNAME%$PASSWORD', 'enc')
1068 plansmbtorture4testsuite(t
, "ad_dc", '//$SERVER/tmp -k no -U$USERNAME%$PASSWORD ' + alice_creds
, 'ntlm')
1069 plansmbtorture4testsuite(t
, "ad_dc", '//$SERVER/tmp -k yes -U$USERNAME%$PASSWORD ' + alice_creds
, 'krb5')
1070 # Certain tests fail when run against ad_member with MIT kerberos because the private krb5.conf overrides the provisioned lib/krb5.conf,
1071 # ad_member_idmap_rid sets "create krb5.conf = no"
1072 plansmbtorture4testsuite(t
, "ad_member_idmap_rid", '//$SERVER/tmp -k yes -U$DC_USERNAME@$REALM%$DC_PASSWORD', 'krb5')
1073 elif t
== "rpc.lsa":
1074 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD', 'over ncacn_np ')
1075 plansmbtorture4testsuite(t
, "nt4_dc", 'ncacn_ip_tcp:$SERVER_IP -U$USERNAME%$PASSWORD', 'over ncacn_ip_tcp ')
1076 elif t
.startswith("rpc.lsa."):
1077 # This avoids the rpc.lsa.* tests runing under ncacn_ip_tcp:
1078 # (there is rpc.lsa.secrets fails due to OpenPolicy2 for example)
1079 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1080 elif t
== "rpc.mdssvc":
1081 plansmbtorture4testsuite(t
, "fileserver", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1082 elif t
== "smb2.durable-open" or t
== "smb2.durable-v2-open" or t
== "smb2.replay" or t
== "smb2.durable-v2-delay":
1083 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/durable -U$USERNAME%$PASSWORD')
1084 plansmbtorture4testsuite(t
, "ad_dc", '//$SERVER_IP/durable -U$USERNAME%$PASSWORD')
1085 elif t
== "base.rw1":
1086 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1087 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/valid-users-tmp -U$USERNAME%$PASSWORD')
1088 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/write-list-tmp -U$USERNAME%$PASSWORD')
1089 plansmbtorture4testsuite(t
, "ad_dc_smb1", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
1090 elif t
== "idmap.rfc2307":
1091 plantestsuite(t
, "ad_member_rfc2307",
1092 [os
.path
.join(samba3srcdir
,
1093 "../nsswitch/tests/test_idmap_rfc2307.sh"),
1095 'Administrator', '2000000',
1097 '"Domain Users"', '2000002',
1098 'DnsAdmins', '2000003',
1100 'ou=idmap,dc=samba,dc=example,dc=com',
1101 '$DC_SERVER', '$DC_USERNAME', '$DC_PASSWORD'])
1102 elif t
== "idmap.alloc":
1103 plantestsuite(t
, "ad_member_rfc2307", [os
.path
.join(samba3srcdir
, "../nsswitch/tests/test_idmap_nss.sh"), '$DOMAIN'])
1104 elif t
== "idmap.rid":
1105 plantestsuite(t
, "ad_member_idmap_rid", [os
.path
.join(samba3srcdir
, "../nsswitch/tests/test_idmap_rid.sh"), '$DOMAIN', '2000000'])
1107 "admem_idmap_autorid",
1108 [os
.path
.join(samba3srcdir
,
1109 "../nsswitch/tests/test_idmap_rid.sh"),
1112 elif t
== "idmap.ad":
1113 plantestsuite(t
, "ad_member_idmap_ad", [os
.path
.join(samba3srcdir
, "../nsswitch/tests/test_idmap_ad.sh"), '$DOMAIN', '$DC_SERVER', '$DC_PASSWORD', '$TRUST_DOMAIN', '$TRUST_SERVER', '$TRUST_PASSWORD'])
1114 elif t
== "raw.acls":
1115 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1116 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/nfs4acl_simple_40 -U$USERNAME%$PASSWORD', description
='nfs4acl_xattr-simple-40')
1117 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/nfs4acl_special_40 -U$USERNAME%$PASSWORD', description
='nfs4acl_xattr-special-40')
1118 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/nfs4acl_simple_41 -U$USERNAME%$PASSWORD', description
='nfs4acl_xattr-simple-41')
1119 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/nfs4acl_xdr_40 -U$USERNAME%$PASSWORD', description
='nfs4acl_xattr-xdr-40')
1120 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/nfs4acl_xdr_41 -U$USERNAME%$PASSWORD', description
='nfs4acl_xattr-xdr-41')
1121 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/nfs4acl_nfs_40 -U$USERNAME%$PASSWORD', description
='nfs4acl_xattr-nfs-40')
1122 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/nfs4acl_nfs_41 -U$USERNAME%$PASSWORD', description
='nfs4acl_xattr-nfs-41')
1123 plansmbtorture4testsuite(t
, "ad_dc_smb1", '//$SERVER_IP/tmpcase -U$USERNAME%$PASSWORD')
1124 elif t
== "smb2.ioctl":
1125 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/fs_specific -U$USERNAME%$PASSWORD', 'fs_specific')
1126 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1127 plansmbtorture4testsuite(t
, "ad_dc", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
1128 elif t
== "smb2.ioctl-on-stream":
1129 plansmbtorture4testsuite(t
, "fileserver", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1130 elif t
== "smb2.lock":
1131 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/aio -U$USERNAME%$PASSWORD', 'aio')
1132 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1133 elif t
== "raw.lock" or t
== "base.lock":
1134 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1135 elif t
== "raw.read":
1136 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1137 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/aio -U$USERNAME%$PASSWORD', 'aio')
1138 plansmbtorture4testsuite(t
, "ad_dc_smb1", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
1139 elif t
== "raw.search":
1140 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1141 # test the dirsort module.
1142 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmpsort -U$USERNAME%$PASSWORD')
1143 plansmbtorture4testsuite(t
, "ad_dc_smb1", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
1144 elif t
== "vfs.fruit":
1145 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/vfs_fruit -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/nt4_dc/share --option=torture:share2=vfs_wo_fruit', 'metadata_netatalk')
1146 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/vfs_fruit_metadata_stream -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/nt4_dc/share --option=torture:share2=vfs_wo_fruit', 'metadata_stream')
1147 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/vfs_fruit_stream_depot -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/nt4_dc/share --option=torture:share2=vfs_wo_fruit_stream_depot', 'streams_depot')
1148 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/vfs_fruit_delete_empty_adfiles -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/nt4_dc/share --option=torture:share2=vfs_wo_fruit', 'fruit_delete_empty_adfiles')
1149 elif t
== "vfs.fruit_netatalk":
1150 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/vfs_fruit_xattr -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/nt4_dc/share')
1151 elif t
== "vfs.fruit_timemachine":
1152 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/vfs_fruit_timemachine -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/nt4_dc/share')
1153 elif t
== "vfs.fruit_file_id":
1154 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/vfs_fruit_zero_fileid -U$USERNAME%$PASSWORD')
1155 elif t
== "vfs.fruit_conversion":
1156 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD --option=torture:share2=vfs_fruit_wipe_intentionally_left_blank_rfork --option=torture:delete_empty_adfiles=false', 'wipe_intentionally_left_blank_rfork')
1157 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD --option=torture:share2=vfs_fruit_delete_empty_adfiles --option=torture:delete_empty_adfiles=true', 'delete_empty_adfiles')
1158 elif t
== "vfs.unfruit":
1159 creds
= '-U$USERNAME%$PASSWORD'
1160 share2
= '--option=torture:share2=tmp'
1161 netopt
= '--option=torture:net=%s' % net
1162 shareopt
= '--option=torture:sharename'
1164 plansmbtorture4testsuite(t
, "nt4_dc:local", '//$SERVER_IP/vfs_fruit %s %s %s %s=%s' % (creds
, share2
, netopt
, shareopt
, 'vfs_fruit'), 'metadata_netatalk')
1165 plansmbtorture4testsuite(t
, "nt4_dc:local", '//$SERVER_IP/vfs_fruit_metadata_stream %s %s %s %s=%s' % (creds
, share2
, netopt
, shareopt
, 'vfs_fruit_metadata_stream'), 'metadata_stream')
1166 plansmbtorture4testsuite(t
, "nt4_dc:local", '//$SERVER_IP/vfs_fruit_stream_depot %s %s %s %s=%s' % (creds
, share2
, netopt
, shareopt
, 'vfs_fruit_stream_depot'), 'streams_depot')
1167 elif t
== "rpc.schannel_anon_setpw":
1168 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$%', description
="anonymous password set")
1169 plansmbtorture4testsuite(t
, "nt4_dc_schannel", '//$SERVER_IP/tmp -U$%', description
="anonymous password set (schannel enforced server-side)")
1170 plansmbtorture4testsuite(t
, "ad_dc", '//$SERVER/tmp -U$%', description
="anonymous password set")
1171 elif t
== "local.nss":
1172 for env
in ["nt4_dc:local", "ad_member:local", "nt4_member:local", "ad_dc:local"]:
1173 plansmbtorture4testsuite(t
, env
, '//$SERVER/tmp -U$USERNAME%$PASSWORD')
1174 elif t
== "smb2.change_notify_disabled":
1175 plansmbtorture4testsuite(t
, "simpleserver", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
1176 elif t
== "smb2.notify" or t
== "raw.notify" or t
== "smb2.oplock" or t
== "raw.oplock":
1178 if t
== "raw.notify" or t
== "raw.oplock":
1179 tmp_env
= "nt4_dc_smb1"
1180 # These tests are a little slower so don't duplicate them with ad_dc
1181 plansmbtorture4testsuite(t
, tmp_env
, '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD --client-protection=sign')
1182 elif t
== "smb2.dosmode":
1183 plansmbtorture4testsuite(t
, "simpleserver", '//$SERVER/dosmode -U$USERNAME%$PASSWORD')
1184 elif t
== "smb2.kernel-oplocks":
1185 if have_linux_kernel_oplocks
:
1186 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER/kernel_oplocks -U$USERNAME%$PASSWORD --option=torture:localdir=$SELFTEST_PREFIX/nt4_dc/share')
1187 elif t
== "smb2.notify-inotify":
1189 plansmbtorture4testsuite(t
, "fileserver", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1190 elif t
== "vfs.acl_xattr":
1191 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1192 elif t
== "smb2.compound_find":
1193 plansmbtorture4testsuite(t
, "fileserver", '//$SERVER/compound_find -U$USERNAME%$PASSWORD')
1194 plansmbtorture4testsuite(t
, "fileserver", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1195 elif t
== "smb2.compound":
1196 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1197 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/aio -U$USERNAME%$PASSWORD', 'aio')
1198 plansmbtorture4testsuite(t
, "ad_dc", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
1199 elif t
== "smb2.compound_async":
1200 plansmbtorture4testsuite(t
, "fileserver", '//$SERVER_IP/aio_delay_inject -U$USERNAME%$PASSWORD')
1201 elif t
== "smb2.ea":
1202 plansmbtorture4testsuite(t
, "fileserver", '//$SERVER/ea_acl_xattr --option=torture:acl_xattr_name=hackme -U$USERNAME%$PASSWORD')
1203 elif t
== "rpc.samba3.netlogon" or t
== "rpc.samba3.sessionkey":
1204 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD --option=torture:wksname=samba3rpctest')
1205 plansmbtorture4testsuite(t
, "ad_dc_smb1", '//$SERVER/tmp -U$USERNAME%$PASSWORD --option=torture:wksname=samba3rpctest')
1206 elif t
== "smb2.streams":
1207 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1208 plansmbtorture4testsuite(t
, "ad_dc", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
1209 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/streams_xattr -U$USERNAME%$PASSWORD', 'streams_xattr')
1210 elif t
== "smb2.aio_delay":
1211 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/aio_delay_inject -U$USERNAME%$PASSWORD')
1212 elif t
== "smb2.delete-on-close-perms":
1213 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1214 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/delete_readonly -U$USERNAME%$PASSWORD --option=torture:delete_readonly=true')
1215 plansmbtorture4testsuite(t
, "ad_dc", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
1216 elif t
== "smb2.fileid":
1217 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/vfs_fruit_xattr -U$USERNAME%$PASSWORD')
1218 elif t
== "smb2.acls_non_canonical":
1219 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/acls_non_canonical -U$USERNAME%$PASSWORD')
1220 elif t
== "smb2.async_dosmode":
1221 plansmbtorture4testsuite("smb2.async_dosmode",
1223 "//$SERVER_IP/async_dosmode_shadow_copy2 -U$USERNAME%$PASSWORD")
1224 elif t
== "smb2.rename":
1225 plansmbtorture4testsuite(t
, "fileserver", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1226 elif t
== "smb2.twrp":
1227 # This is being driven by samba3.blackbox.shadow_copy_torture
1229 elif t
== "smb2.create_no_streams":
1230 plansmbtorture4testsuite(t
, "fileserver", '//$SERVER_IP/nfs4acl_simple_40 -U$USERNAME%$PASSWORD')
1231 elif t
== "rpc.wkssvc":
1232 plansmbtorture4testsuite(t
, "ad_member", '//$SERVER/tmp -U$DC_USERNAME%$DC_PASSWORD')
1233 elif t
== "rpc.srvsvc":
1234 plansmbtorture4testsuite(t
, "ad_member", '//$SERVER/tmp -U$DC_USERNAME%$DC_PASSWORD')
1235 plansmbtorture4testsuite(t
, "ad_dc", '//$SERVER/tmp -U$DC_USERNAME%$DC_PASSWORD')
1236 elif t
== "rpc.samba3.lsa_over_netlogon":
1237 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1238 elif t
== "rpc.samba3.pipes_supported_interfaces":
1239 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1240 plansmbtorture4testsuite(t
, "ad_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1241 elif t
== "rpc.spoolss.notify":
1242 plansmbtorture4testsuite(t
, "ad_member", '//$SERVER_IP/tmp -U$DC_USERNAME%$DC_PASSWORD')
1243 elif (t
in base
and t
!= "base.charset") \
1244 or (t
in rap
and t
!= "rap.printing") \
1246 or (t
in ["rpc.authcontext",
1249 "rpc.samba3.getusername",
1250 "rpc.samba3.sharesec",
1251 "rpc.samba3.smb1-pipe-name",
1252 "rpc.samba3.smb-reauth1",
1253 "rpc.samba3.smb-reauth2",
1254 "rpc.samba3.spoolss",
1255 "rpc.samba3.wkssvc",]) \
1256 or (t
in ["raw.close",
1262 "raw.samba3badnameblob",
1263 "raw.samba3badpath",
1264 "raw.samba3caseinsensitive",
1265 "raw.samba3oplocklogoff",
1266 "raw.samba3posixtimedlock",
1267 "raw.samba3rootdirfid",
1268 "raw.samba3rootdirfid2",
1270 "raw.sfileinfo.bug",
1271 "raw.sfileinfo.end-of-file",
1272 "raw.sfileinfo.rename",
1276 plansmbtorture4testsuite(t
, "nt4_dc_smb1", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1277 plansmbtorture4testsuite(t
, "ad_dc_smb1", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
1278 elif t
in ["base.mangle", "base.tcon", "raw.mkdir"]:
1279 plansmbtorture4testsuite(t
, "nt4_dc_smb1_done", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1280 plansmbtorture4testsuite(t
, "ad_dc_smb1_done", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
1281 elif t
== "rpc.samr.passwords.validate":
1282 plansmbtorture4testsuite(t
, "nt4_dc", 'ncacn_ip_tcp:$SERVER_IP[seal] -U$USERNAME%$PASSWORD', 'over ncacn_ip_tcp ')
1283 elif t
== "rpc.samr.users.privileges":
1284 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD --option=torture:nt4_dc=true')
1285 elif t
== "rpc.samr" or t
.startswith("rpc.samr."):
1286 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1288 plansmbtorture4testsuite(t
, "nt4_dc", '//$SERVER_IP/tmp -U$USERNAME%$PASSWORD')
1289 plansmbtorture4testsuite(t
, "ad_dc", '//$SERVER/tmp -U$USERNAME%$PASSWORD')
1292 "idmap_ad.ticket_expiry",
1293 "ad_member_idmap_ad:local",
1294 [os
.path
.join(samba3srcdir
, "../nsswitch/tests/test_ticket_expiry.sh"),
1297 plansmbtorture4testsuite(
1302 plansmbtorture4testsuite(
1305 '//$SERVER/external_streams_depot -U$USERNAME%$PASSWORD')
1307 test
= 'rpc.lsa.lookupsids'
1308 auth_options
= ["", "ntlm", "spnego", "spnego,ntlm", "spnego,smb1", "spnego,smb2"]
1309 signseal_options
= ["", ",connect", ",packet", ",sign", ",seal"]
1310 endianness_options
= ["", ",bigendian"]
1311 for s
in signseal_options
:
1312 for e
in endianness_options
:
1313 for a
in auth_options
:
1314 binding_string
= "ncacn_np:$SERVER[%s%s%s]" % (a
, s
, e
)
1315 options
= binding_string
+ " -U$USERNAME%$PASSWORD"
1317 plansmbtorture4testsuite(test
, "nt4_dc_smb1_done", options
, 'over ncacn_np with [%s%s%s] ' % (a
, s
, e
))
1319 plansmbtorture4testsuite(test
, "nt4_dc", options
, 'over ncacn_np with [%s%s%s] ' % (a
, s
, e
))
1321 f
'samba3.blackbox.rpcclient over ncacn_np with [{a}{s}{e}] ',
1323 [os
.path
.join(samba3srcdir
, "script/tests/test_rpcclient.sh"),
1325 options
+ " -c getusername",
1328 f
'samba3.blackbox.rpcclient over ncalrpc with [{a}{s}{e}] ',
1330 [os
.path
.join(samba3srcdir
, "script/tests/test_rpcclient.sh"),
1332 f
'ncalrpc:[{a}{s}{e}] -c epmmap',
1336 f
'samba3.blackbox.rpcclient over ncacn_ip_tcp with [{a}{s}{e}] ',
1338 [os
.path
.join(samba3srcdir
, "script/tests/test_rpcclient.sh"),
1340 f
'ncacn_ip_tcp:"$SERVER_IP"[{a}{s}{e}] -c epmmap -U"$USERNAME"%"$PASSWORD"',
1343 # We should try more combinations in future, but this is all
1344 # the pre-calculated credentials cache supports at the moment
1346 # As the ktest env requires SMB3_00 we need to use "smb2" until
1347 # dcerpc client code in smbtorture support autonegotiation
1348 # of any smb dialect.
1351 binding_string
= "ncacn_np:$SERVER[%s%s%s]" % (a
, s
, e
)
1352 options
= binding_string
+ " --use-krb5-ccache=$PREFIX/ktest/krb5_ccache-2"
1353 plansmbtorture4testsuite(test
, "ktest", options
, 'krb5 with old ccache ncacn_np with [%s%s%s] ' % (a
, s
, e
))
1355 options
= binding_string
+ " --use-krb5-ccache=$PREFIX/ktest/krb5_ccache-3"
1356 plansmbtorture4testsuite(test
, "ktest", options
, 'krb5 ncacn_np with [%s%s%s] ' % (a
, s
, e
))
1358 auth_options2
= ["krb5", "spnego,krb5"]
1359 for a
in auth_options2
:
1360 binding_string
= "ncacn_np:$SERVER[%s%s%s]" % (a
, s
, e
)
1363 f
'samba3.blackbox.rpcclient krb5 ncacn_np with [{a}{s}{e}] ',
1365 [os
.path
.join(samba3srcdir
, "script/tests/test_rpcclient.sh"),
1366 "$PREFIX/ktest/krb5_ccache-3",
1368 "--use-krb5-ccache=$PREFIX/ktest/krb5_ccache-3 -c getusername",
1371 plantestsuite("samba3.blackbox.rpcclient_samlogon", "ad_member:local", [os
.path
.join(samba3srcdir
, "script/tests/test_rpcclient_samlogon.sh"),
1372 "$DC_USERNAME", "$DC_PASSWORD", "ncacn_np:$DC_SERVER", configuration
])
1373 plantestsuite("samba3.blackbox.sharesec", "simpleserver:local",
1374 [os
.path
.join(samba3srcdir
, "script/tests/test_sharesec.sh"),
1375 configuration
, os
.path
.join(bindir(), "sharesec"),
1376 os
.path
.join(bindir(), "net"), "tmp"])
1378 plantestsuite("samba3.blackbox.close-denied-share", "simpleserver:local",
1379 [os
.path
.join(samba3srcdir
,
1380 "script/tests/test_close_denied_share.sh"),
1382 os
.path
.join(bindir(), "sharesec"),
1383 os
.path
.join(bindir(), "smbclient"),
1384 os
.path
.join(bindir(), "smbcontrol"),
1388 plantestsuite("samba3.blackbox.force-close-share", "simpleserver:local",
1389 [os
.path
.join(samba3srcdir
,
1390 "script/tests/test_force_close_share.sh"),
1392 os
.path
.join(bindir(), "smbclient"),
1393 os
.path
.join(bindir(), "smbcontrol"),
1396 '$PREFIX/force-close-share'])
1398 plantestsuite("samba3.blackbox.open-eintr", "simpleserver:local",
1399 [os
.path
.join(samba3srcdir
,
1400 "script/tests/test_open_eintr.sh"),
1402 os
.path
.join(bindir(), "smbclient"),
1403 os
.path
.join(bindir(), "smbcontrol"),
1407 plantestsuite("samba3.blackbox.chdir-cache", "simpleserver:local",
1408 [os
.path
.join(samba3srcdir
,
1409 "script/tests/test_chdir_cache.sh"),
1411 os
.path
.join(bindir(), "smbclient"),
1412 os
.path
.join(bindir(), "smbcontrol"),
1418 plantestsuite("samba3.blackbox.zero_readsize",
1419 "simpleserver:local",
1420 [os
.path
.join(samba3srcdir
,
1421 "script/tests/test_zero_readsize.sh"),
1423 os
.path
.join(bindir(), "smbclient"),
1424 os
.path
.join(bindir(), "smbcontrol"),
1430 plantestsuite("samba3.blackbox.netfileenum", "simpleserver:local",
1431 [os
.path
.join(samba3srcdir
,
1432 "script/tests/test_netfileenum.sh"),
1433 os
.path
.join(bindir(), "smbclient"),
1434 os
.path
.join(bindir(), "rpcclient"),
1435 os
.path
.join(bindir(), "net"),
1439 plantestsuite("samba3.blackbox.netshareenum_username", "fileserver",
1440 [os
.path
.join(samba3srcdir
,
1441 "script/tests/test_user_in_sharelist.sh"),
1442 os
.path
.join(bindir(), "rpcclient"),
1445 plantestsuite("samba3.blackbox.net_tdb", "simpleserver:local",
1446 [os
.path
.join(samba3srcdir
, "script/tests/test_net_tdb.sh"),
1447 smbclient3
, '$SERVER', 'tmp', '$USERNAME', '$PASSWORD',
1448 configuration
, '$LOCAL_PATH', '$LOCK_DIR'])
1450 plantestsuite("samba3.blackbox.aio-outstanding", "simpleserver:local",
1451 [os
.path
.join(samba3srcdir
,
1452 "script/tests/test_aio_outstanding.sh"),
1454 os
.path
.join(bindir(), "smbclient"),
1456 "aio_delay_inject"])
1458 plantestsuite("samba3.blackbox.deadtime", "simpleserver:local",
1459 [os
.path
.join(samba3srcdir
, "script/tests/test_deadtime.sh"),
1462 plantestsuite("samba3.blackbox.smbd_error", "simpleserver:local",
1463 [os
.path
.join(samba3srcdir
, "script/tests/test_smbd_error.sh")])
1465 plantestsuite("samba3.blackbox.smbd_no_krb5", "ad_member:local",
1466 [os
.path
.join(samba3srcdir
, "script/tests/test_smbd_no_krb5.sh"),
1467 smbclient3
, '$SERVER', "$DC_USERNAME", "$DC_PASSWORD", "$PREFIX"])
1469 plantestsuite("samba3.blackbox.winbind_ignore_domain", "ad_member_idmap_ad:local",
1470 [os
.path
.join(samba3srcdir
, "script/tests/test_winbind_ignore_domains.sh")])
1472 plantestsuite("samba3.blackbox.durable_v2_delay", "simpleserver:local",
1473 [os
.path
.join(samba3srcdir
, "script/tests/test_durable_handle_reconnect.sh")])
1475 plantestsuite("samba3.blackbox.net_cache_samlogon", "ad_member:local",
1476 [os
.path
.join(samba3srcdir
, "script/tests/test_net_cache_samlogon.sh"),
1477 '$SERVER', 'tmp', '$DC_USERNAME', '$DC_PASSWORD'])
1479 plantestsuite("samba3.blackbox.net_rpc_share_allowedusers", "nt4_dc",
1480 [os
.path
.join(samba3srcdir
, "script/tests/test_net_rpc_share_allowedusers.sh"),
1481 "$SERVER", "$USERNAME", "$PASSWORD", "$PREFIX/net_rpc_share_allowedusers",
1484 plantestsuite("samba3.blackbox.net_dom_join_fail_dc", "nt4_dc",
1485 [os
.path
.join(samba3srcdir
, "script/tests/test_net_dom_join_fail_dc.sh"),
1486 "$USERNAME", "$PASSWORD", "$SERVER", "$PREFIX/net_dom_join_fail_dc",
1488 plantestsuite("samba3.blackbox.net_rpc_join", "nt4_dc",
1489 [os
.path
.join(samba3srcdir
, "script/tests/test_net_rpc_join.sh"),
1490 "$USERNAME", "$PASSWORD", "$SERVER", "$PREFIX/net_rpc_join",
1492 plantestsuite("samba3.blackbox.net_rpc_oldjoin", "nt4_dc:local",
1493 [os
.path
.join(samba3srcdir
, "script/tests/test_net_rpc_oldjoin.sh"),
1494 "$SERVER", "$PREFIX/net_rpc_oldjoin",
1496 plantestsuite("samba3.blackbox.net_rpc_join_creds", "nt4_dc",
1497 [os
.path
.join(samba3srcdir
, "script/tests/test_net_rpc_join_creds.sh"),
1498 "$DOMAIN", "$USERNAME", "$PASSWORD", "$SERVER", "$PREFIX/net_rpc_join_creds",
1501 plantestsuite("samba3.blackbox.rpcclient_srvsvc", "simpleserver",
1502 [os
.path
.join(samba3srcdir
, "script/tests/test_rpcclientsrvsvc.sh"),
1503 "$USERNAME", "$PASSWORD", "$SERVER",
1504 os
.path
.join(bindir(), "rpcclient"), "tmp"])
1506 plantestsuite("samba3.blackbox.rpcclient_lookup", "simpleserver",
1507 [os
.path
.join(samba3srcdir
, "script/tests/test_rpcclient_lookup.sh"),
1508 "$USERNAME", "$PASSWORD", "$SERVER",
1509 os
.path
.join(bindir(), "rpcclient")])
1511 plantestsuite("samba3.blackbox.rpcclient_dfs", "fileserver:local",
1512 [os
.path
.join(samba3srcdir
, "script/tests/test_rpcclient_dfs.sh"),
1513 "$USERNAME", "$PASSWORD", "$SERVER",
1514 os
.path
.join(bindir(), "rpcclient")])
1516 plantestsuite("samba3.blackbox.rpcclient.pw-nt-hash", "simpleserver",
1517 [os
.path
.join(samba3srcdir
, "script/tests/test_rpcclient_pw_nt_hash.sh"),
1518 "$USERNAME", "$PASSWORD", "$SERVER",
1519 os
.path
.join(bindir(), "rpcclient")])
1521 plantestsuite("samba3.blackbox.smbclient.encryption_off", "simpleserver",
1522 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_encryption_off.sh"),
1523 "$USERNAME", "$PASSWORD", "$SERVER",
1526 plantestsuite("samba3.blackbox.smbXsrv_client_dead_rec", "fileserver:local",
1527 [os
.path
.join(samba3srcdir
,
1528 "script/tests/test_smbXsrv_client_dead_rec.sh"),
1533 plantestsuite("samba3.blackbox.smbXsrv_client_cross_node", "clusteredmember:local",
1534 [os
.path
.join(samba3srcdir
,
1535 "script/tests/test_smbXsrv_client_cross_node.sh"),
1539 plantestsuite("samba3.blackbox.registry_share", "clusteredmember",
1540 [os
.path
.join(samba3srcdir
,
1541 "script/tests/test_registry_share.sh"),
1542 "$SERVER", '$DC_USERNAME', "$DC_PASSWORD"])
1545 plantestsuite("samba3.blackbox.virus_scanner", "%s:local" % (env
),
1546 [os
.path
.join(samba3srcdir
,
1547 "script/tests/test_virus_scanner.sh"),
1553 for env
in ['fileserver', 'simpleserver']:
1554 plantestsuite("samba3.blackbox.smbclient.encryption", env
,
1555 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_encryption.sh"),
1556 "$USERNAME", "$PASSWORD", "$SERVER",
1559 plantestsuite("samba3.blackbox.smbclient.kerberos", 'ad_dc',
1560 [os
.path
.join(samba3srcdir
,
1561 "script/tests/test_smbclient_kerberos.sh"),
1568 for env
in ['ad_dc_fips', 'ad_member_fips']:
1569 plantestsuite("samba3.blackbox.smbclient.kerberos", env
,
1570 [os
.path
.join(samba3srcdir
,
1571 "script/tests/test_smbclient_kerberos.sh"),
1578 environ
={'GNUTLS_FORCE_FIPS_MODE': '1',
1579 'OPENSSL_FORCE_FIPS_MODE': '1'})
1581 plantestsuite("samba3.blackbox.rpcclient_netsessenum", "ad_member",
1582 [os
.path
.join(samba3srcdir
,
1583 "script/tests/test_rpcclient_netsessenum.sh"),
1584 "$DOMAIN", "$DC_USERNAME", "$DC_PASSWORD", "$SERVER",
1585 os
.path
.join(bindir(), "rpcclient"), smbtorture3
, "tmp"])
1587 # The ktest environment uses:
1588 # server min protocol = SMB3_00
1589 # client max protocol = SMB3
1590 options_list
= ["", "--client-protection=encrypt"]
1591 for options
in options_list
:
1592 plantestsuite("samba3.blackbox.smbclient_krb5 old ccache %s" % options
, "ktest:local",
1593 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_krb5.sh"),
1594 "$PREFIX/ktest/krb5_ccache-2",
1595 smbclient3
, "$SERVER", options
, configuration
])
1597 plantestsuite("samba3.blackbox.smbclient_krb5 new ccache %s" % options
, "ktest:local",
1598 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_krb5.sh"),
1599 "$PREFIX/ktest/krb5_ccache-3",
1600 smbclient3
, "$SERVER", options
, configuration
])
1602 plantestsuite("samba3.blackbox.smbclient_large_file %s krb5" % options
, "ktest:local",
1603 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_large_file.sh"),
1604 "$PREFIX/ktest/krb5_ccache-3",
1605 smbclient3
, "$SERVER", "$PREFIX", options
, "--use-krb5-ccache=$PREFIX/ktest/krb5_ccache-3 " + configuration
])
1607 options_list
= ["-mNT1", "-mNT1 --client-protection=encrypt", "-mSMB3", "-mSMB3 --client-protection=encrypt"]
1608 for options
in options_list
:
1610 if "NT1" in options
:
1611 env
= "nt4_dc_smb1_done"
1612 plantestsuite("samba3.blackbox.smbclient_large_file %s NTLM" % options
, "%s:local" % env
,
1613 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_large_file.sh"),
1615 smbclient3
, "$SERVER", "$PREFIX", options
, "-U$USERNAME%$PASSWORD " + configuration
])
1617 for alias
in ["foo", "bar"]:
1618 plantestsuite("samba3.blackbox.smbclient_netbios_aliases [%s]" % alias
, "ad_member:local",
1619 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_netbios_aliases.sh"),
1620 smbclient3
, alias
, "$DC_USERNAME", "$DC_PASSWORD", "$PREFIX",
1623 for e
in endianness_options
:
1624 for a
in auth_options
:
1625 for s
in signseal_options
:
1626 binding_string
= "ncacn_ip_tcp:$SERVER_IP[%s%s%s]" % (a
, s
, e
)
1627 options
= binding_string
+ " -U$USERNAME%$PASSWORD"
1628 plansmbtorture4testsuite(test
, "nt4_dc", options
, 'over ncacn_ip_tcp with [%s%s%s] ' % (a
, s
, e
))
1630 plansmbtorture4testsuite('rpc.epmapper', 'nt4_dc:local', 'ncalrpc: -U$USERNAME%$PASSWORD', 'over ncalrpc')
1631 plansmbtorture4testsuite('rpc.fsrvp', 'nt4_dc:local', 'ncacn_np:$SERVER_IP -U$USERNAME%$PASSWORD', 'over ncacn_np')
1633 for env
in ["ad_member_idmap_rid:local", "maptoguest:local"]:
1634 plantestsuite("samba3.blackbox.guest", env
,
1635 [os
.path
.join(samba3srcdir
, "script/tests/test_guest_auth.sh"),
1636 '$SERVER', smbclient3
, smbcontrol
, net
, configuration
])
1638 plantestsuite("samba3.blackbox.smbclient-mget",
1640 [os
.path
.join(samba3srcdir
, "script/tests/test_smbclient_mget.sh"),
1648 t
= "readdir-timestamp"
1650 "samba3.smbtorture_s3.plain.%s" % t
,
1652 [os
.path
.join(samba3srcdir
,
1653 "script/tests/test_smbtorture_s3.sh"),
1656 '$DOMAIN\\\\$DC_USERNAME',
1660 "-b $PREFIX/clusteredmember/unclists/tmp.txt -N 5 -o 10"])
1663 "samba3.net_machine_account",
1665 [os
.path
.join(samba3srcdir
,
1666 "script/tests/test_net_machine_account.sh"),
1672 "samba3.net_lookup_ldap",
1674 [os
.path
.join(samba3srcdir
,
1675 "script/tests/test_net_lookup.sh"),
1683 plantestsuite("samba3.blackbox.force-user-unlink",
1685 [os
.path
.join(samba3srcdir
,
1686 "script/tests/test_force_user_unlink.sh")])
1688 def planclusteredmembertestsuite(tname
, prefix
):
1689 '''Define a clustered test for the clusteredmember environment'''
1693 autharg
= '-U${DOMAIN}/${DC_USERNAME}%${DC_PASSWORD}'
1694 namearg
= 'clustered.%s' % tname
1695 modnamearg
= 'samba3.%s' % namearg
1698 prefix
= os
.path
.join(prefix
, 'clusteredmember')
1699 unclist
= os
.path
.join(prefix
, 'unclists/%s.txt' % tshare
)
1701 unclistarg
= '--unclist=%s' % unclist
1702 sharearg
= '//$SERVER_IP/%s' % tshare
1704 return selftesthelpers
.plansmbtorture4testsuite(
1707 [extraargs
, unclistarg
, sharearg
, autharg
, tname
],
1712 CLUSTERED_TESTS
= [ 'smb2.deny.deny2' ]
1714 for test
in CLUSTERED_TESTS
:
1715 planclusteredmembertestsuite(test
, "$PREFIX")
1717 CLUSTERED_LOCAL_TESTS
= [
1719 "local-dbwrap-ctdb1"
1722 for t
in CLUSTERED_LOCAL_TESTS
:
1725 "clusteredmember:local",
1726 [os
.path
.join(samba3srcdir
, "script/tests/test_smbtorture_s3.sh"),
1734 if have_smb3_unix_extensions
:
1735 planpythontestsuite("fileserver", "samba.tests.smb3unix")
1736 planpythontestsuite("fileserver", "samba.tests.reparsepoints")
1737 planpythontestsuite("fileserver_smb1", "samba.tests.smb2symlink")
1738 planpythontestsuite("fileserver_smb1", "samba.tests.smb1posix")