]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
libcli/lsarpc: add trust_forest_info_match_tln_namespace()
authorStefan Metzmacher <metze@samba.org>
Thu, 17 May 2018 08:37:34 +0000 (10:37 +0200)
committerRalph Boehme <slow@samba.org>
Sat, 22 Feb 2025 16:00:36 +0000 (16:00 +0000)
This will be used by the namespace filtering part of
sid filtering...

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Ralph Boehme <slow@samba.org>
libcli/lsarpc/util_lsarpc.c
libcli/lsarpc/util_lsarpc.h

index 351ac4b8481ad01fa7c0124512ca4d31f9e106ae..2a5752b4610af528aef23dce3843d043fb136cf6 100644 (file)
@@ -1285,3 +1285,22 @@ bool trust_forest_info_tln_ex_match(
 
        return false;
 }
+
+bool trust_forest_info_match_tln_namespace(
+               const struct lsa_ForestTrustInformation2 *info,
+               const char *tln)
+{
+       bool match;
+
+       match = trust_forest_info_tln_ex_match(info, tln);
+       if (match) {
+               return false;
+       }
+
+       match = trust_forest_info_tln_match(info, tln);
+       if (!match) {
+               return false;
+       }
+
+       return true;
+}
index 8b075f04f246294b7bc3ddb70376f77e511bde94..5fa6fed1e3e0c6a31848382faa37dfcd9024ebef 100644 (file)
@@ -68,4 +68,8 @@ bool trust_forest_info_tln_match(
 bool trust_forest_info_tln_ex_match(
                const struct lsa_ForestTrustInformation2 *info,
                const char *tln);
+bool trust_forest_info_match_tln_namespace(
+               const struct lsa_ForestTrustInformation2 *info,
+               const char *tln);
+
 #endif /* _LIBCLI_AUTH_UTIL_LSARPC_H_ */