summaryrefslogtreecommitdiff
path: root/testprogs
Commit message (Collapse)AuthorAgeFilesLines
* s3/utils: when encoding ace string use "FA", "FR", "FW", "FX" string rightsNoel Power2023-04-281-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | prior to this patch rights matching "FA", "FR", "FW", "FX" were outputted as the hex string representing the bit value. While outputting the hex string is perfectly fine, it makes it harder to compare icacls output (which always uses the special string values) Additionally adjust various tests to deal with use of shortcut access masks as sddl format now uses FA, FR, FW & FX strings (like icalcs does) instead of hex representation of the bit mask. adjust samba4.blackbox.samba-tool_ntacl samba3.blackbox.large_acl samba.tests.samba_tool.ntacl samba.tests.ntacls samba.tests.posixacl so various string comparisons of the sddl format now pass Signed-off-by: Noel Power <noel.power@suse.com> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> [abartlet@samba.org Adapted to new stricter SDDL behaviour around leading zeros in hex numbers, eg 0x001]
* test:bb/samba-tool ntacl: let return acl flag lack hex paddingDouglas Bagnall2023-04-281-5/+10
| | | | | Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Set PREFIX_ABS before it is used in test_primary_group.shPavel Filipenský2023-04-141-3/+3
| | | | | | | | Signed-off-by: Pavel Filipenský <pfilipensky@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org> Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org> Autobuild-Date(master): Fri Apr 14 06:18:18 UTC 2023 on atb-devel-224
* testprogs: Return correct status codeJoseph Sutton2023-04-121-1/+1
| | | | Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz> Reviewed-by: Andreas Schneider <asn@samba.org>
* testprogs: Make test_rpcclient_expect_failure_grep() return 0 on successJoseph Sutton2023-04-122-7/+7
| | | | | | | | | This is more consistent with the behaviour of the other expect_failure functions. Adjust all callers expecting the opposite behaviour to match. Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz> Reviewed-by: Andreas Schneider <asn@samba.org>
* testprogs: Return correct status codeJoseph Sutton2023-04-121-1/+1
| | | | Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz> Reviewed-by: Andreas Schneider <asn@samba.org>
* testprogs: Make test_smbclient_expect_failure() return 0 on successJoseph Sutton2023-04-123-7/+8
| | | | | | | | | This is the behaviour that most existing callers expect, but the function actually returns a non-zero status code in that case. Adjust all callers expecting the opposite behaviour to match. Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz> Reviewed-by: Andreas Schneider <asn@samba.org>
* testprogs: Make testit_expect_failure() return 0 on successJoseph Sutton2023-04-1210-22/+23
| | | | | | | | | This is the behaviour that most existing callers expect, but the function actually returns a non-zero status code in that case. Adjust all callers expecting the opposite behaviour to match. Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz> Reviewed-by: Andreas Schneider <asn@samba.org>
* testprogs: Fix comparisonJoseph Sutton2023-04-121-1/+1
| | | | | | SC2039: In POSIX sh, == in place of = is undefined. Signed-off-by: Joseph Sutton <josephsutton@catalyst.net.nz> Reviewed-by: Andreas Schneider <asn@samba.org>
* testprogs: Remove unused test_export_keytab_(heimdal|mit).shAndreas Schneider2023-04-062-360/+0
| | | | | | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org> Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org> Autobuild-Date(master): Thu Apr 6 14:47:20 UTC 2023 on atb-devel-224
* testprogs: Merge export keytab tests into a single script for MIT and HeimdalAndreas Schneider2023-04-061-0/+263
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=15336 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Fix shell arithmetic in test_export_keytab_mit.shAndreas Schneider2023-04-061-14/+14
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Reformat test_export_keytab_mit.shAndreas Schneider2023-04-061-25/+78
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Fix shell arithmetic in test_export_keytab_heimdal.shAndreas Schneider2023-04-061-15/+15
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Reformat test_export_keytab_heimdal.shAndreas Schneider2023-04-061-30/+78
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Remove unused test_kinit_trusts_(heimdal|mit).shAndreas Schneider2023-04-062-353/+0
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Merge kinit trust tests into a single script for MIT and HeimdalAndreas Schneider2023-04-061-0/+247
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=15336 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Fix shell arithmetic in test_kinit_trusts_heimdal.shAndreas Schneider2023-04-061-22/+22
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Fix shell arithmetic in test_kinit_trusts_mit.shAndreas Schneider2023-04-061-20/+20
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Reformat test_kinit_trusts_mit.shAndreas Schneider2023-04-061-26/+76
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Reformat test_kinit_trusts_heimdal.shAndreas Schneider2023-04-061-25/+83
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Remove unused test_kinit_(heimdal|mit).shAndreas Schneider2023-04-062-843/+0
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Merge kinit tests into a single script for MIT and HeimdalAndreas Schneider2023-04-061-0/+555
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=15336 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Fix shell arithmetic in test_kinit_mit.shAndreas Schneider2023-04-061-45/+45
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Reformat test_kinit_mit.shAndreas Schneider2023-04-061-48/+172
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Use common binary detection functions in test_kinit_heimdal.shAndreas Schneider2023-04-061-37/+31
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Fix shell arithmetic in test_kinit_heimdal.shAndreas Schneider2023-04-061-47/+47
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Reformat test_kinit_heimdal.shAndreas Schneider2023-04-061-55/+195
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Pass configuration to test_kinit_trusts_mit.shAndreas Schneider2023-04-061-3/+4
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=15336 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Pass configuration to test_kinit_trusts_heimdal.shAndreas Schneider2023-04-061-2/+3
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=15336 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Remove UID_WRAPPER_ROOT exportAndreas Schneider2023-04-061-3/+0
| | | | | | | This is not needed, we only need it for smbpasswd and in order to get root we need to set the ruid and euid, which we already do. Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Pass configuration to test_password_settings.shAndreas Schneider2023-04-061-25/+27
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=15336 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Pass configuration to test_kpasswd_mit.shAndreas Schneider2023-04-061-13/+11
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=15336 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Pass configuration to test_kpasswd_heimdal.shAndreas Schneider2023-04-061-13/+11
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=15336 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Specify the KRB5CCNAME on the command lineAndreas Schneider2023-04-061-2/+2
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=15336 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Pass configuration to test_export_keytab_mit.shAndreas Schneider2023-04-061-11/+12
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=15336 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Pass configuration to test_export_keytab_heimdal.shAndreas Schneider2023-04-061-11/+12
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=15336 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Correctly set configuration in test_kinit_heimdal.shAndreas Schneider2023-04-061-3/+4
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=15336 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Correctly set configuration in test_kinit_mit.shAndreas Schneider2023-04-061-3/+4
| | | | | | BUG: https://bugzilla.samba.org/show_bug.cgi?id=15336 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: Fix running export.keytab heimdal testAndreas Schneider2023-04-061-4/+4
| | | | Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs/blackbox: add test_net_ads_search_server.shStefan Metzmacher2023-04-061-0/+37
| | | | | | | | | | This reproduces a regression with 'net ads search -P --server server.of.trusted.domain' BUG: https://bugzilla.samba.org/show_bug.cgi?id=15323 Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andreas Schneider <asn@samba.org>
* python:provision: run adprep as part of provisionStefan Metzmacher2023-03-222-4/+4
| | | | | | | With the default of base_schema=2019 we'll adprep to 2016. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* samba-tool: let 'domain functionalprep' to use functional level 2016 by defaultStefan Metzmacher2023-03-221-2/+21
| | | | | Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* python/samba: let get_domain_descriptor() include adprep 2016 ACEsStefan Metzmacher2023-03-221-6/+2
| | | | | | | | | We need to make sure a new provision as well as dbcheck --reset-well-known-acls include acls used by adprep 2016, otherwise we would undo the adprep result. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* blackbox/dbcheck: also run currently unused dbcheck_reset_well_known_aclsStefan Metzmacher2023-03-221-4/+5
| | | | | | | | | This makes sure that we detect if dbcheck --reset-well-known-acls tries to reset to unexpected values, which we expect to currect in recent provisions. Signed-off-by: Stefan Metzmacher <metze@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: add test for new net ads dns register --dns-ttl optionBjörn Baumbach2023-03-031-0/+36
| | | | | Signed-off-by: Björn Baumbach <bb@sernet.de> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs/blackbox/test_weak_disable_ntlmssp_ldap.sh: verify test results ↵Björn Baumbach2023-03-031-1/+1
| | | | | | | ($failed) Signed-off-by: Björn Baumbach <bb@sernet.de> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs/blackbox/test_special_group.sh: verify test results ($failed)Björn Baumbach2023-03-031-1/+1
| | | | | Signed-off-by: Björn Baumbach <bb@sernet.de> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs/blackbox/test_net_ads_dns.sh: verify test results ($failed)Björn Baumbach2023-03-031-1/+1
| | | | | Signed-off-by: Björn Baumbach <bb@sernet.de> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
* testprogs: net ads dns: do not increase the $failed counter in "net ads dns" ↵Björn Baumbach2023-03-031-2/+3
| | | | | | | when test is OK Signed-off-by: Björn Baumbach <bb@sernet.de> Reviewed-by: Andrew Bartlett <abartlet@samba.org>