summaryrefslogtreecommitdiff
path: root/source4/librpc/ndr/ndr_sec_helper.c
diff options
context:
space:
mode:
Diffstat (limited to 'source4/librpc/ndr/ndr_sec_helper.c')
-rw-r--r--source4/librpc/ndr/ndr_sec_helper.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/source4/librpc/ndr/ndr_sec_helper.c b/source4/librpc/ndr/ndr_sec_helper.c
index dd4435daf1..8059c0f4ea 100644
--- a/source4/librpc/ndr/ndr_sec_helper.c
+++ b/source4/librpc/ndr/ndr_sec_helper.c
@@ -34,6 +34,21 @@ size_t ndr_size_dom_sid(const struct dom_sid *sid, int flags)
return 8 + 4*sid->num_auths;
}
+size_t ndr_size_dom_sid28(const struct dom_sid *sid, int flags)
+{
+ struct dom_sid zero_sid;
+
+ if (!sid) return 0;
+
+ ZERO_STRUCT(zero_sid);
+
+ if (memcmp(&zero_sid, sid, sizeof(zero_sid)) == 0) {
+ return 0;
+ }
+
+ return 8 + 4*sid->num_auths;
+}
+
/*
return the wire size of a security_ace
*/