[PATCHES] some clustering/witness testing related patches
Günther Deschner
gd at samba.org
Mon Sep 28 19:19:01 UTC 2015
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi,
please review & push.
Thanks,
Guenther
- --
Günther Deschner GPG-ID: 8EE11688
Red Hat gdeschner at redhat.com
Samba Team gd at samba.org
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2
iEYEARECAAYFAlYJko0ACgkQSOk3aI7hFoh92gCeKATLwcA4iPQnyJxQVPKU99NU
/1gAoIB76eDGbMQhbqATrRzbgcDNgrRF
=WclQ
-----END PGP SIGNATURE-----
-------------- next part --------------
From baf4c6462d528277dc090e5d840a2b87872fec30 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?G=C3=BCnther=20Deschner?= <gd at samba.org>
Date: Mon, 28 Sep 2015 00:47:17 +0200
Subject: [PATCH 1/4] clusapi: remove security.idl dependency from IDL.
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Guenther
Signed-off-by: Günther Deschner <gd at samba.org>
---
librpc/idl/clusapi.idl | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/librpc/idl/clusapi.idl b/librpc/idl/clusapi.idl
index 42a9ecb..5a71273 100644
--- a/librpc/idl/clusapi.idl
+++ b/librpc/idl/clusapi.idl
@@ -1,4 +1,4 @@
-import "security.idl", "winreg.idl", "misc.idl";
+import "winreg.idl", "misc.idl";
#include "idl_types.h"
--
2.4.3
From de8c99376e992fc171c17210a553a451b18dbc2e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?G=C3=BCnther=20Deschner?= <gd at samba.org>
Date: Mon, 28 Sep 2015 19:08:58 +0200
Subject: [PATCH 2/4] librpc: properly quote uuids so that wireshark dissectors
can be built from them.
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Guenther
Signed-off-by: Günther Deschner <gd at samba.org>
---
librpc/idl/clusapi.idl | 2 +-
librpc/idl/dcom.idl | 2 +-
librpc/idl/wmi.idl | 8 ++++----
3 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/librpc/idl/clusapi.idl b/librpc/idl/clusapi.idl
index 5a71273..3440047 100644
--- a/librpc/idl/clusapi.idl
+++ b/librpc/idl/clusapi.idl
@@ -3,7 +3,7 @@ import "winreg.idl", "misc.idl";
#include "idl_types.h"
[
- uuid(b97db8b2-4c63-11cf-bff6-08002be23f2f),
+ uuid("b97db8b2-4c63-11cf-bff6-08002be23f2f"),
version(3.0),
pointer_default(unique),
endpoint("ncacn_ip_tcp:"),
diff --git a/librpc/idl/dcom.idl b/librpc/idl/dcom.idl
index ff44722..e53d7b8 100644
--- a/librpc/idl/dcom.idl
+++ b/librpc/idl/dcom.idl
@@ -265,7 +265,7 @@ interface IRemUnknown2 : IRemUnknown
}
[
- uuid(DA23F6DB-6F45-466C-9EED-0B65286F2D78),
+ uuid("DA23F6DB-6F45-466C-9EED-0B65286F2D78"),
helpstring("ICoffeeMachine Interface"),
pointer_default(unique),
object
diff --git a/librpc/idl/wmi.idl b/librpc/idl/wmi.idl
index 4d428a8..43b7408 100644
--- a/librpc/idl/wmi.idl
+++ b/librpc/idl/wmi.idl
@@ -35,7 +35,7 @@ interface IWbemClassObject : IUnknown
};
[
- uuid(9A653086-174F-11d2-B5F9-00104B703EFD)
+ uuid("9A653086-174F-11d2-B5F9-00104B703EFD")
]
coclass WbemClassObject
{
@@ -486,7 +486,7 @@ coclass WbemClassObject
[
object,
- uuid(027947e1-d731-11ce-a357-000000000001),
+ uuid("027947e1-d731-11ce-a357-000000000001"),
pointer_default(unique)
] interface IEnumWbemClassObject : IUnknown
{
@@ -669,7 +669,7 @@ coclass WbemClassObject
[
object,
/* restricted, */
- uuid(44aca675-e8fc-11d0-a07c-00c04fb68820)
+ uuid("44aca675-e8fc-11d0-a07c-00c04fb68820")
] interface IWbemCallResult : IUnknown
{
WERROR GetResultObject(
@@ -697,7 +697,7 @@ coclass WbemClassObject
[
object,
restricted,
- uuid(7c857801-7381-11cf-884d-00aa004b2e24)
+ uuid("7c857801-7381-11cf-884d-00aa004b2e24")
]
interface IWbemObjectSink : IUnknown
{
--
2.4.3
From fc3d8a515c148b35aba085a7b013e8c64450d834 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?G=C3=BCnther=20Deschner?= <gd at samba.org>
Date: Mon, 14 Sep 2015 17:12:58 +0200
Subject: [PATCH 3/4] s3-rpcclient: protect against empty witness async notify
messages.
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Guenther
Signed-off-by: Günther Deschner <gd at samba.org>
---
source3/rpcclient/cmd_witness.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/source3/rpcclient/cmd_witness.c b/source3/rpcclient/cmd_witness.c
index bd0372f..5d07dde 100644
--- a/source3/rpcclient/cmd_witness.c
+++ b/source3/rpcclient/cmd_witness.c
@@ -406,6 +406,11 @@ static WERROR cmd_witness_AsyncNotify(struct rpc_pipe_client *cli,
goto done;
}
+ if (response == NULL) {
+ d_printf("Got an empty response\n");
+ goto done;
+ }
+
switch(response->type) {
case WITNESS_NOTIFY_RESOURCE_CHANGE:
d_printf("Resource change");
--
2.4.3
From 6c7a44353b62aea03c4c1d4cf37b2ee918f71719 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?G=C3=BCnther=20Deschner?= <gd at samba.org>
Date: Mon, 21 Sep 2015 19:17:59 +0200
Subject: [PATCH 4/4] s4-torture: trying to make clusapi resource
online/offline testing a bit more robust
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Guenther
Signed-off-by: Günther Deschner <gd at samba.org>
---
source4/torture/rpc/clusapi.c | 18 ++++++++++++------
1 file changed, 12 insertions(+), 6 deletions(-)
diff --git a/source4/torture/rpc/clusapi.c b/source4/torture/rpc/clusapi.c
index e3fff82..8958dda 100644
--- a/source4/torture/rpc/clusapi.c
+++ b/source4/torture/rpc/clusapi.c
@@ -946,9 +946,12 @@ bool test_OnlineResource_int(struct torture_context *tctx,
torture_assert_ntstatus_ok(tctx,
dcerpc_clusapi_OnlineResource_r(b, tctx, &r),
"OnlineResource failed");
- torture_assert_werr_ok(tctx,
- r.out.result,
- "OnlineResource failed");
+ if (!W_ERROR_IS_OK(r.out.result) &&
+ !W_ERROR_EQUAL(r.out.result, WERR_IO_PENDING)) {
+ torture_result(tctx, TORTURE_FAIL, "OnlineResource failed with %s",
+ win_errstr(r.out.result));
+ return false;
+ }
return true;
}
@@ -986,9 +989,12 @@ bool test_OfflineResource_int(struct torture_context *tctx,
torture_assert_ntstatus_ok(tctx,
dcerpc_clusapi_OfflineResource_r(b, tctx, &r),
"OfflineResource failed");
- torture_assert_werr_ok(tctx,
- r.out.result,
- "OfflineResource failed");
+ if (!W_ERROR_IS_OK(r.out.result) &&
+ !W_ERROR_EQUAL(r.out.result, WERR_IO_PENDING)) {
+ torture_result(tctx, TORTURE_FAIL, "OfflineResource failed with %s",
+ win_errstr(r.out.result));
+ return false;
+ }
return true;
}
--
2.4.3
More information about the samba-technical
mailing list