]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
s4:torture/rpc: test how CSDVersion="" wipes operatingSystemServicePack
authorStefan Metzmacher <metze@samba.org>
Tue, 21 Dec 2021 12:58:07 +0000 (13:58 +0100)
committerJeremy Allison <jra@samba.org>
Tue, 11 Jan 2022 21:13:37 +0000 (21:13 +0000)
BUG: https://bugzilla.samba.org/show_bug.cgi?id=14936

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
selftest/knownfail.d/samba4.rpc.netlogon [new file with mode: 0644]
source4/torture/rpc/netlogon.c

diff --git a/selftest/knownfail.d/samba4.rpc.netlogon b/selftest/knownfail.d/samba4.rpc.netlogon
new file mode 100644 (file)
index 0000000..12d871e
--- /dev/null
@@ -0,0 +1,9 @@
+^samba4.rpc.netlogon.on.ncacn_np.with.seal,padcheck.netlogon.GetDomainInfo\(ad_dc_ntvfs\)
+^samba4.rpc.netlogon.on.ncacn_ip_tcp.with.seal,padcheck.netlogon.GetDomainInfo\(ad_dc_ntvfs\)
+^samba4.rpc.netlogon.on.ncacn_np.with.validate.netlogon.GetDomainInfo\(ad_dc_ntvfs\)
+^samba4.rpc.netlogon.on.ncacn_ip_tcp.with.validate.netlogon.GetDomainInfo\(ad_dc_ntvfs\)
+^samba4.rpc.netlogon.on.ncacn_np.with.bigendian.netlogon.GetDomainInfo\(ad_dc_ntvfs\)
+^samba4.rpc.netlogon.on.ncacn_ip_tcp.with.bigendian.netlogon.GetDomainInfo\(ad_dc_ntvfs\)
+^samba4.rpc.netlogon.with.seal,padcheck.netlogon.GetDomainInfo\(ad_dc\)
+^samba4.rpc.netlogon.with.validate.netlogon.GetDomainInfo\(ad_dc\)
+^samba4.rpc.netlogon.with.bigendian.netlogon.GetDomainInfo\(ad_dc\)
index 0d8926b6d815cfd61c631cabe83c14f1905cae20..11f950d3aab4aa34828c9bd7df2024cb1542d7bc 100644 (file)
@@ -5143,8 +5143,8 @@ static bool test_GetDomainInfo(struct torture_context *tctx,
        torture_comment(tctx, "Testing netr_LogonGetDomainInfo 2nd call (variation of DNS hostname doesn't work)\n");
        netlogon_creds_client_authenticator(creds, &a);
 
-       /* Wipe out the osVersion, and prove which values still 'stick' */
-       q1.os_version.os = NULL;
+       /* Wipe out the CSDVersion, and prove which values still 'stick' */
+       os.os.CSDVersion = "";
 
        /* Change also the DNS hostname to test differences in behaviour */
        talloc_free(discard_const_p(char, q1.dns_hostname));
@@ -5175,9 +5175,9 @@ static bool test_GetDomainInfo(struct torture_context *tctx,
                torture_assert(tctx,
                               ldb_msg_find_attr_as_string(res[0], "operatingSystemServicePack", NULL) == NULL,
                               "'operatingSystemServicePack' shouldn't stick!");
-               torture_assert(tctx,
-                              ldb_msg_find_attr_as_string(res[0], "operatingSystemVersion", NULL) == NULL,
-                              "'operatingSystemVersion' shouldn't stick!");
+               torture_assert_str_equal(tctx,
+                                        ldb_msg_find_attr_as_string(res[0], "operatingSystemVersion", NULL),
+                                        version_str, "'operatingSystemVersion' wrong!");
 
                /* The DNS host name shouldn't have been updated by the server */