summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* s3-vfs: Fix stream_depot vfs module on btrfs.Andreas Schneider2013-11-081-8/+8
| | | | | | | | | | | | Checking if the directory is empty using 'nlink == 2' only checks if there are no subdirectories. It doesn't indicate if there are files in the directory. However checking link count for no subdirectories is wrong and applications shouldn't rely on it, see: https://lkml.org/lkml/2012/2/1/756 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* vfstest: fix uninitialised variable usage in openDavid Disseldorp2013-11-081-2/+3
| | | | | | | | The vfstest open command currently fails intermittently due to a read of a potentially uninitialised status variable. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* net: remove net idmap secretAtul Kulkarni2013-11-081-8/+0
| | | | | | | | | | | This is moved to net idmap set secret for consistency. Signed-off-by: Atul Kulkarni <atul.kulkarni@in.ibm.com> Reviewed-by: Michael Adam <obnox@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> Autobuild-User(master): Jeremy Allison <jra@samba.org> Autobuild-Date(master): Fri Nov 8 01:03:25 CET 2013 on sn-devel-104
* doc: update the net manpage for net idmap set, get and deleteAtul Kulkarni2013-11-071-2/+67
| | | | | | Signed-off-by: Atul Kulkarni <atul.kulkarni@in.ibm.com> Reviewed-by: Michael Adam <obnox@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* idmap_autorid: fix failure in reverse lookup if ID is from domain range index #0Abhidnya Joshi2013-11-071-1/+1
| | | | | | | | | Domain range index #0 is not included in the database record. So in this special case we only have the SID, not SID#IDX... Signed-off-by: Abhidnya Joshi <achirmul@in.ibm.com> Reviewed-by: Michael Adam <obnox@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* idmap_autorid: fix status code when trying to load range for an invalid inputMichael Adam2013-11-071-0/+6
| | | | | | | | | | | | | | The "sid" input needs to be verified (it can currently be a SID or "ALLOC"). When handing in string that is valid for other kinds of records, but not for the SID[#IDX]-->RANGE direction of mappings, like for instance a range number, then we get "NT_STATUS_INTERNAL_DB_CORRUPTION" because parse records finds the record, but it does not have the expected size... This patch fixes this problem by pre-validating the input before fetching the record from the database. Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* net: correct typos in net idmap delete ranges help messageAtul Kulkarni2013-11-071-2/+2
| | | | | | Signed-off-by: Atul Kulkarni <atul.kulkarni@in.ibm.com> Reviewed-by: Michael Adam <obnox@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* idmap_autorid: add space between two words in a debug messageAtul Kulkarni2013-11-071-2/+2
| | | | | | Signed-off-by: Atul Kulkarni <atul.kulkarni@in.ibm.com> Reviewed-by: Michael Adam <obnox@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
* s4-lsa: Make sure we also duplicate the domain_name.Andreas Schneider2013-11-071-4/+20
| | | | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org> Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org> Autobuild-Date(master): Thu Nov 7 18:58:44 CET 2013 on sn-devel-104
* s4-lsa: Add missing null checks in dcesrv_lsa_lookup_name().Andreas Schneider2013-11-071-0/+12
| | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org>
* s4-lsa: Fix a user after free in dcesrv_lsa_lookup_name().Andreas Schneider2013-11-071-3/+9
| | | | | | Pair-Programmed-With: Volker Lendecke <vl@samba.org> Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Volker Lendecke <vl@samba.org>
* test_smbclient_tarmode.pl: remove unneccesary arg defaultsDavid Disseldorp2013-11-051-6/+9
| | | | | | | | | | | The host, share and localpath arguments should not take default values. Check that these required arguments are specified. Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org> Autobuild-User(master): Jim McDonough <jmcd@samba.org> Autobuild-Date(master): Tue Nov 5 16:40:20 CET 2013 on sn-devel-104
* test_smbclient_tarmode.pl: depend only on perl v5.10Aurélien Aptel2013-11-051-10/+17
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: remove all ./ prefix when dealing with remote filesAurélien Aptel2013-11-051-3/+11
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: sanitize $DIR + whitespaceAurélien Aptel2013-11-051-1/+2
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: use -n flag for specifiying hostname (was ↵Aurélien Aptel2013-11-051-3/+6
| | | | | | | | ambiguous with help) Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: enable create with exclude testsAurélien Aptel2013-11-051-1/+1
| | | | | | [ddiss@samba.org: split from clitar implementation commit] Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add subunit output flagAurélien Aptel2013-11-051-6/+51
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add test for interactive sessionAurélien Aptel2013-11-051-20/+29
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add extraction regex tests, verbose flagAurélien Aptel2013-11-051-15/+90
| | | | | | | | | | * reset_remote() now removes the whole share content * verbose flag to control stdout of each test * extraction with regex test Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: test regex flag behaviourAurélien Aptel2013-11-051-67/+65
| | | | | | [ddiss@samba.org: split from clitar implementation commit] Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add large file and long path testsAurélien Aptel2013-11-051-15/+50
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add simple wildcard testAurélien Aptel2013-11-051-3/+46
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: test interactive commandAurélien Aptel2013-11-051-1/+7
| | | | | | [ddiss@samba.org: split from clitar implementation commit] Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: whitespaceAurélien Aptel2013-11-051-1/+0
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: let --test run multiple testsAurélien Aptel2013-11-051-7/+45
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: sanitize input, use File::Temp instead of ↵Aurélien Aptel2013-11-051-8/+19
| | | | | | | | hardcoding temp dir Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: cosmetic changesAurélien Aptel2013-11-051-70/+68
| | | | | | | | | - Add whitespace around paren in if/for/while/... blocks - Don't split if/elsif/else cascade Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add copyright headerAurélien Aptel2013-11-051-0/+17
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: samba 3.6.9 can print a empty attribute stringAurélien Aptel2013-11-051-1/+1
| | | | | | | | | While changing my setup, I discovered that for some unknown reasons samba (serv/client) doesn't print any attributes for normal files. Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: disable failing tests for nowAurélien Aptel2013-11-051-3/+3
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: make script work on older Perl (now only need 5.14)Aurélien Aptel2013-11-051-2/+7
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: fix a few minor typosDavid Disseldorp2013-11-051-7/+7
| | | | | Signed-off-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: refactor, cleanup and document in PODAurélien Aptel2013-11-051-178/+459
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add tests for wildcard pattern (cI, cX, cF, xF).Aurélien Aptel2013-11-051-33/+161
| | | | | | | | | | | * add some test for wildcard pattern and r switch, when possible (-r is very buggy) * change default DIR to "tar_test_dir" * add tests for attributes (nohidden, nosystem which are undocumented) Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add a first simple wildcard testAurélien Aptel2013-11-051-40/+145
| | | | | | | | | | | | | * File::list() now takes an absolute path * check_remote() now takes the dir to check * added an optional File destructor * added cleanpath() to remove unecessary slashes * File::new_remote() can take an absolute path * File->{dir} is now absolute from the localpath Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add a clean option to erase the local pathAurélien Aptel2013-11-051-0/+7
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add test for xFAurélien Aptel2013-11-051-2/+28
| | | | | | | | Add test for extracting from a file list. Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add test for creation w/ filelistAurélien Aptel2013-11-051-2/+39
| | | | | | | | | * add test_creation_list() * add parameter to File::new_local() to provide file content Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add extraction test for I and X.Aurélien Aptel2013-11-051-7/+60
| | | | | | | | | | * add test for xI and xX * fix bug in check_remote(): print filename instead of ref * replace hash by list in test_extraction_normal() Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add tests for X and I.Aurélien Aptel2013-11-051-2/+34
| | | | | | | | Found a bug while doing so. X doesn't exclude file path. Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add option to choose and run a single testAurélien Aptel2013-11-051-1/+22
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add first extraction testAurélien Aptel2013-11-051-8/+173
| | | | | | | | | | | | | | | | | | * add normal extraction test * add (or bring back) - File::list() -- return list of File in a path - File::tree() -- same but recursive - File::walk() -- high order function to iterate on a File hierarchy * compute md5 sum when not cached * add check_remote(), will be useful for all extraction tests * fix consecutive slashes bug in some File::xxxpath() At this point, the script can replace the old test_smbclient_tarmode.sh in terms of features. Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: remove unused functionsAurélien Aptel2013-11-051-27/+0
| | | | | | Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add nested dirs testAurélien Aptel2013-11-051-5/+8
| | | | | | | | add a test to check that the backup handles nested directories. Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: refactored file related function to a File packageAurélien Aptel2013-11-051-155/+194
| | | | | | | | | all the localpath(), remotepath() and all file related functions were getting out of hand. The tests are now simpler to write. Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add test for "newer than" (`N` flag)Aurélien Aptel2013-11-051-1/+45
| | | | | | | | | add test for the N FILE flag which makes smbclient only backup files newer or as new as FILE. Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add test for reset modeAurélien Aptel2013-11-051-6/+52
| | | | | | | | | add a new test for the reset mode which can be triggered via `-a` or `tarmode reset`. Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: improve incremental testAurélien Aptel2013-11-051-2/+5
| | | | | | | | | instead of using archived and non-archived files for the test, use archive and various flags (system, hidden, readonly). Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>
* test_smbclient_tarmode.pl: add proper argument parsing for configuration.Aurélien Aptel2013-11-051-50/+94
| | | | | | | | documentation is included in the script in POD format. Signed-off-by: Aurélien Aptel <aurelien.aptel@gmail.com> Reviewed-by: David Disseldorp <ddiss@samba.org> Reviewed-by: Jim McDonough <jmcd@samba.org>