[PATCH] net: groupmap cleanup should not delete BUILTIN mappings
Ralph Böhme
slow at samba.org
Sat Sep 30 06:50:05 UTC 2017
Hi!
Not 100% I'm correct here, but afaict mappings for the BUILTIN domain are
perfectly fine and should not be deleted by `net groupmap cleanup`.
Please review&push if ok.
Cheerio!
-slow
-------------- next part --------------
From a90676e46835c46ff40e4d22da441ca7d1ccd4a4 Mon Sep 17 00:00:00 2001
From: Ralph Boehme <slow at samba.org>
Date: Sat, 30 Sep 2017 08:45:41 +0200
Subject: [PATCH] net: groupmap cleanup should not delete BUILTIN mappings
Bug: https://bugzilla.samba.org/show_bug.cgi?id=13065
Signed-off-by: Ralph Boehme <slow at samba.org>
---
source3/utils/net_groupmap.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/source3/utils/net_groupmap.c b/source3/utils/net_groupmap.c
index b8c81de5bf1..2b75dd21a90 100644
--- a/source3/utils/net_groupmap.c
+++ b/source3/utils/net_groupmap.c
@@ -764,7 +764,9 @@ static int net_groupmap_cleanup(struct net_context *c, int argc, const char **ar
printf(_("Group %s is not mapped\n"),
maps[i]->nt_name);
- if (!sid_check_is_in_our_sam(&maps[i]->sid)) {
+ if (!sid_check_is_in_our_sam(&maps[i]->sid) &&
+ !sid_check_is_in_builtin(&maps[i]->sid))
+ {
printf(_("Deleting mapping for NT Group %s, sid %s\n"),
maps[i]->nt_name,
sid_string_tos(&maps[i]->sid));
--
2.13.5
More information about the samba-technical
mailing list