summaryrefslogtreecommitdiff
path: root/source3/lib
diff options
context:
space:
mode:
Diffstat (limited to 'source3/lib')
-rw-r--r--source3/lib/util_uuid.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/source3/lib/util_uuid.c b/source3/lib/util_uuid.c
index a20387e8e5..4a9c0848d2 100644
--- a/source3/lib/util_uuid.c
+++ b/source3/lib/util_uuid.c
@@ -133,3 +133,19 @@ BOOL smb_string_to_uuid(const char *in, struct GUID* uu)
out:
return ret;
}
+
+/*****************************************************************
+ Return the binary string representation of a GUID.
+ Caller must free.
+*****************************************************************/
+
+char *guid_binstring(const struct GUID *guid)
+{
+ UUID_FLAT guid_flat;
+
+ smb_uuid_pack(*guid, &guid_flat);
+
+ return binary_string_rfc2254((char *)guid_flat.info, UUID_FLAT_SIZE);
+}
+
+