summaryrefslogtreecommitdiffstats
path: root/selftest
Commit message (Collapse)AuthorAgeFilesLines
* s4-auth: Support password history correctly, including allowing NTLM logins ↵Andrew Bartlett2014-04-021-1/+0
| | | | | | | | | | | | | | | using the old password This is only done during a 1 hour allowed period, by default. We only update bad password count when not one of the last 3 passwords Andrew Bartlett Change-Id: I76fd8010ce273a21efb55f9601d17b9978a0acf0 Pair-Programmed-With: Stefan Metzmacher <metze@samba.org> Signed-off-by: Andrew Bartlett <abartlet@samba.org> Signed-off-by: Stefan Metzmacher <metze@samba.org>
* s4-auth: Add authsam_zero_bad_pwd_count to zero out badPwdCount and ↵Andrew Bartlett2014-04-021-1/+0
| | | | | | | | lockoutTime on successful login Change-Id: I2530f08a91f9b6484203dbdaba988f2df1a04ea1 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* selftest: Run rpc.samr.passwords.lockout against the s3dc environmentAndrew Bartlett2014-04-021-0/+1
| | | | | | Change-Id: I7ee562cbf1e067ed90b22e212002e88752450e34 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* selftest: Remove print_smbtorture4_version and smbtorture4_possible checkAndrew Bartlett2014-03-261-15/+0
| | | | | | | | | | | | | smbtorture is now always the same version as the rest of Samba, and is strictly required. Andrew Bartlett Change-Id: I89d9c52275477177fa8a89050920ff8a2fec9288 Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-By: Jelmer Vernooij <jelmer@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Wed Mar 26 04:20:16 CET 2014 on sn-devel-104
* selftest/subunithelper.py: correctly pass testsuite-uxsuccess to end_testsuite()Stefan Metzmacher2014-03-131-1/+4
| | | | | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Thu Mar 13 23:49:36 CET 2014 on sn-devel-104
* selftest/subunithelper.py: correctly handle fail_immediately in ↵Stefan Metzmacher2014-03-131-0/+6
| | | | | | | | | end_testsuite of FilterOps This way --fail-immediately also works if a command segfaults. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* selftest/subunithelper.py: correctly handle unexpected success in FilterOpsStefan Metzmacher2014-03-131-1/+13
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* selftest: Use the absolute path to the ldb modules.Andreas Schneider2014-02-211-1/+1
| | | | | | | This fixes 'make test' on Fedora with external ldb. Reviewed-by: Guenther Deschner <gd@samba.org> Reviewed-by: Alexander Bokovoy <ab@samba.org>
* s3: vfs_dirsort module.Jeremy Allison2014-02-121-0/+4
| | | | | | | | | | | | Add raw.search torture test on a share definition with: vfs objects = dirsort https://bugzilla.samba.org/show_bug.cgi?id=10406 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* selftest: let "make testenv SCREEN=1" use tmux if it is runningGregor Beck2014-02-111-1/+5
| | | | | | Signed-off-by: Gregor Beck <gbeck@sernet.de> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
* selftest/Samba3: make --log-stdout optionalStefan Metzmacher2014-02-011-14/+26
| | | | | | | | | | | | | | | It's still used by default, but the following environment variables are able to avoid it NMBD_DONT_LOG_STDOUT=1, WINBINDD_DONT_LOG_STDOUT=1 and SMBD_DONT_LOG_STDOUT=1. It's strange that nmbd and smbd take --log-stdout, while winbindd takes --stdout. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org> Autobuild-User(master): Stefan Metzmacher <metze@samba.org> Autobuild-Date(master): Sat Feb 1 01:27:18 CET 2014 on sn-devel-104
* selftets: durable-open.reopen4 succeeds now.Michael Adam2014-01-301-1/+0
| | | | | | | | Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Thu Jan 30 23:32:13 CET 2014 on sn-devel-104
* selftest: Use the absolute path to libnss_winbind.so.Andreas Schneider2014-01-171-0/+2
| | | | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Günther Deschner <gd@samba.org> Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org> Autobuild-Date(master): Fri Jan 17 16:45:27 CET 2014 on sn-devel-104
* s3:rpcclient: add support for DCERPC_AUTH_LEVEL_CONNECTStefan Metzmacher2014-01-161-9/+0
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
* s3:dir - We now pass the previously spinning directory tests on ext4.Jeremy Allison2014-01-151-2/+0
| | | | | | | | | | https://bugzilla.samba.org/show_bug.cgi?id=2662 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org> Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org> Autobuild-Date(master): Wed Jan 15 11:39:12 CET 2014 on sn-devel-104
* selftest/Samba4: use "allow nt4 crypto = yes" for testingStefan Metzmacher2014-01-071-0/+1
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* selftest: pass -l logdir to daemon processes.Gregor Beck2013-12-111-3/+7
| | | | | | | | | The daemons try to set up the corefile path within logdir before the config file was read. Signed-off-by: Gregor Beck <gbeck@sernet.de> Reviewed-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* selftest: use MALLOC_CHECK_=3 to give a diagnostic on failureGregor Beck2013-12-112-2/+2
| | | | | | | | | | With MALLOC_CHECK_ set to 2 in case of a failure abort() is called silently which hopefully creates a core dump. MALLOC_CHECK_=3 additionally gives an error message on stderr in case. Signed-off-by: Gregor Beck <gbeck@sernet.de> Reviewed-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* selftest: set valgrind optionsGregor Beck2013-12-111-1/+5
| | | | | | | | | In particular '--db-attach' interferes badly with the io redirection of the test environment and is superseded by the vgdb feature of valgrind. Signed-off-by: Gregor Beck <gbeck@sernet.de> Reviewed-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* selftest: setup {NMBD,WINBINDD,SMBD}_VALGRINDStefan Metzmacher2013-12-111-0/+3
| | | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* selftest/Samba3: export ENVNAMEStefan Metzmacher2013-12-111-1/+9
| | | | | | | | This is used by selftest/in_screen. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org> Reviewed-by: Michael Adam <obnox@samba.org>
* selftest: Remove samba3.smb2.lock.*.rw-exclusive from flapping fileChristof Schmitt2013-12-061-1/+0
| | | | | | | | | | This test demonstrates a problem with byte range locks and AIO. Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Fri Dec 6 05:19:37 CET 2013 on sn-devel-104
* selftest: Introduce share for testing AIOChristof Schmitt2013-12-051-0/+4
| | | | | Signed-off-by: Christof Schmitt <cs@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* smbtorture: New torture test for bug #9870.Jeremy Allison2013-12-051-0/+1
| | | | | | | | | | | | | | | Not fetching the latest modification time on a folder if we have read locks on it. Prove we should just rely on the mtime value from the underlying filesystem, even with an open handle. BUG: https://bugzilla.samba.org/show_bug.cgi?id=9870 Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> Autobuild-User(master): Volker Lendecke <vl@samba.org> Autobuild-Date(master): Thu Dec 5 10:05:06 CET 2013 on sn-devel-104
* selftest/s3: expose share with FS applicable configDavid Disseldorp2013-11-221-1/+25
| | | | | | | | | | Attempt to determine the underlying test share filesystem using statfs. If the filesystem is detected and an applicable configuration is available, then apply it to a new filesystem specific share. Btrfs is currently the only VFS module to utilize this logic. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* CVE-2013-4476: selftest/Samba4: use umask 0077 within mk_keyblobs()Stefan Metzmacher2013-11-111-1/+5
| | | | | | | | | | | | We should generate private keys with 0600. Bug: https://bugzilla.samba.org/show_bug.cgi?id=10234 Pair-Programmed-With: Björn Baumbach <bb@sernet.de> Signed-off-by: Stefan Metzmacher <metze@samba.org> Signed-off-by: Björn Baumbach <bb@sernet.de> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* Add regression test for bug #10229 - No access check verification on stream ↵Jeremy Allison2013-11-041-0/+1
| | | | | | | | | | | | | | files. Checks against a file with attribute READONLY, and a security descriptor denying WRITE_DATA access. Signed-off-by: Jeremy Allison <jra@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: David Disseldorp <ddiss@suse.de> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Mon Nov 4 23:10:10 CET 2013 on sn-devel-104
* torture: Add smb2.rename.rename_dir_benchVolker Lendecke2013-11-041-0/+1
| | | | | | | | | This is a little benchmark test excercising parallel directory renames. With lots of open files directory renames get pretty slow against some SMB server implementations. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* torture: Add smb2.oplock.levelII501 testVolker Lendecke2013-10-241-0/+2
| | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: David Disseldorp <ddiss@samba.org> Autobuild-User(master): David Disseldorp <ddiss@samba.org> Autobuild-Date(master): Thu Oct 24 16:15:50 CEST 2013 on sn-devel-104
* smbd: Fix breaking level2 on OVERWRITE create_dispositionVolker Lendecke2013-10-231-1/+0
| | | | | | | This is shown by the new raw.oplock.level_ii_1 test Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* torture: Add a test showing we have to break L2 at open timeVolker Lendecke2013-10-231-0/+2
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* smbd: Fix raw.batch.exclusive[59]Volker Lendecke2013-10-231-3/+0
| | | | | | | | | | | | | | | The level we have to break to depend on the breakers create_disposition: If we overwrite, we have to break to none. This patch overloads the "op_type" field in the break message we send across to the smbd holding the oplock with the oplock level we want to break to. Because it depends on the create_disposition in the breaking open, only the breaker can make that decision. We might want to use a different mechanism for this in the future, but for now using the op_type field seems acceptable to me. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* torture: Add oplock break to l2/none testsVolker Lendecke2013-10-231-0/+4
| | | | | | | | | The level we have to break to depends on the create disposition of the second opener. If it's overwriting, break to none. If it's not, break to level2. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* torture: Check break level in raw.oplock.exclusive5Volker Lendecke2013-10-231-0/+2
| | | | | | | | | | This is what Windows does in this case, we don't survive that. We break to LEVEL2 here. Fixes and more precise test to follow. We don't survive this anymore. Re-enable later. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org>
* s3-winbindd: Remove undocumented winbindd:socket dir parameterAndrew Bartlett2013-10-151-1/+1
| | | | | | | | | | | | | | | | This uses the documeted "winbindd socket directory" parameter instead. This came about due to the merge of the two smb.conf tables in s3 and s4 for the Samba 4.0 release. The s4 code used a real parameter, which caused this to be documented, whereas no automatic procedure existed to notice the parametric option and the need to document that. The fact that this was not used consistently in both codebases is one of the many areas of technical debt we still need to pay off here. Andrew Bartlett Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* param: disable print notify backchannel by defaultDavid Disseldorp2013-10-142-0/+2
| | | | | | | | | | | | | | | | | | In handling RemoteFindFirstPrinterChangeNotifyEx requests, the spoolss server can establish a "backchannel" connection to the print client, as a mechanism for sending print notifications. This behaviour is governed by the "print notify backchannel" smb.conf parameter. This change sets "print notify backchannel" to "no" by default, which sees Samba respond to RemoteFindFirstPrinterChangeNotifyEx requests with WERR_SERVER_UNAVAILABLE. In recieving such a response, print clients can fall back to polling for print queue changes. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Günther Deschner <gd@samba.org> Autobuild-User(master): Günther Deschner <gd@samba.org> Autobuild-Date(master): Mon Oct 14 18:49:41 CEST 2013 on sn-devel-104
* torture: Extend the smb2.oplock.doc1 testVolker Lendecke2013-10-111-0/+1
| | | | | | | If delete_on_close is set, there is no oplock break. Check that. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* torture: Extend the raw.oplock.doc1 testVolker Lendecke2013-10-111-0/+1
| | | | | | | If delete_on_close is set, there is no oplock break. Check that. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s4-openldap: Added an -H option to delegation scriptNadezhda Ivanova2013-09-231-2/+3
| | | | | | | | Also calling delegation locally without credentials, as this is not really necessary and causes selftest errors against the openldap backend. Signed-off-by: Nadezhda Ivanova <nivanova@symas.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* Cleanup start/stop codeHoward Chu2013-09-231-32/+39
| | | | | | | | | teardown was bailing out before stopping slapd. Use fork/exec to start slapd, just like samba. Signed-off-by: Howard Chu <hyc@symas.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Nadezhda Ivanova <nivanova@symas.com>
* selftst: add tests based on 4.1.0rc3 to check for zero invocationID in ↵Andrew Bartlett2013-09-231-0/+1
| | | | | | | | | | | replPropertyMetaData Signed-off-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Michael Adam <obnox@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Mon Sep 23 01:29:10 CEST 2013 on sn-devel-104
* selftest: change to src dir for panic backtraceDavid Disseldorp2013-09-121-1/+1
| | | | | | | | | | | | | | | | | | When running selftest against a Samba3 target, the working directory is set to st/s3dc/share. The existing "panic action" script attempts obtain a backtrace for a paniced smbd process using GDB, which does not locate debug info relative to the working directory. This commit changes the S3 selftest panic action to first enter the base source directory before attempting to obtain the backtrace, ensuring that GDB can locate the debug info. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Autobuild-User(master): Andrew Bartlett <abartlet@samba.org> Autobuild-Date(master): Thu Sep 12 00:19:39 CEST 2013 on sn-devel-104
* smbd: Fix breaking level2 on allocateVolker Lendecke2013-09-051-1/+0
| | | | | | | | This needs doing even if we don't have strct allocate set. The client should not know that we lied. Fixes smb2.oplock.batch12. Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* selftest: Start internal DNS server on domain provisioned for BIND9_DLZAndrew Bartlett2013-09-041-1/+1
| | | | | | | | | This shows that the internal server can use the dns-SERVER account. Andrew Bartlett Reviewed-by: Stefan Metzmacher <metze@samba.org> Signed-off-by: Andrew Bartlett <abartlet@samba.org>
* selftest: Test creation of the dns-SERVER account during selftestAndrew Bartlett2013-09-041-1/+1
| | | | | | | | | | We do this by having the samba-tool domain dcpromo for promoted_vampire_dc also create a dns-SERVER account. Andrew Bartlett Reviewed-by: Stefan Metzmacher <metze@samba.org> Signed-off-by: Andrew Bartlett <abartlet@samba.org>
* torture: Add buffercheck testsVolker Lendecke2013-08-291-0/+3
| | | | | | | | | | | | | Make sure we get the smb2 infolevel fixed portions right I could not find correct #defines for the infolevels Bug: https://bugzilla.samba.org/show_bug.cgi?id=10106 Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Thu Aug 29 01:27:11 CEST 2013 on sn-devel-104
* torture: Split the fsinfo check into a separate testVolker Lendecke2013-08-231-0/+1
| | | | | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Fri Aug 23 20:53:12 CEST 2013 on sn-devel-104
* torture: Change smb2.getinfo into a suiteVolker Lendecke2013-08-231-2/+2
| | | | | Signed-off-by: Volker Lendecke <vl@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* Remove the knownfail flag on cracknames as it didn't fail anymoreMatthieu Patou2013-08-061-2/+0
| | | | | Signed-off-by: Matthieu Patou <mat@matws.net> Reviewed-by: Andrew Bartlett <abarlett@samba.org>
* dsdb: Improve DRS deleted link source/target handing in repl_meta_dataAndrew Bartlett2013-07-301-1/+0
| | | | | | | | | | | | | | We now correctly ignore the link updates if the source or target is deleted locally. This fixes the long-standing failure in the vampire_dc dbcheck test. Pair-Programmed-With: Stefan Metzmacher <metze@samba.org> Andrew Bartlett Signed-off-by: Andrew Bartlett <abartlet@samba.org> Signed-off-by: Stefan Metzmacher <metze@samba.org>