summaryrefslogtreecommitdiff
path: root/source4/lib
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2004-05-22 07:55:48 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:53:52 -0500
commit93076cb9bc56a515bbefb6d88470d6776169779a (patch)
tree388d016f9552a244ddae086cee518bb0d48f8dbd /source4/lib
parent8222c13ce98b0beef0ca34621c93c2b4878eb902 (diff)
downloadsamba-93076cb9bc56a515bbefb6d88470d6776169779a.tar.gz
samba-93076cb9bc56a515bbefb6d88470d6776169779a.tar.bz2
samba-93076cb9bc56a515bbefb6d88470d6776169779a.zip
r816: - Make use of tridge's new samdb_result_sid_prefix() helper function.
- Remove legacy sid_to_string (which contained a memleak) - Remove some unused parts of lib/util_sid.c Andrew Bartlett (This used to be commit 7c69a85984e47c004ddfd9bb5eadcb3191b56f9d)
Diffstat (limited to 'source4/lib')
-rw-r--r--source4/lib/util_sid.c70
1 files changed, 0 insertions, 70 deletions
diff --git a/source4/lib/util_sid.c b/source4/lib/util_sid.c
index 6f63e25c5d..5ce72a6f51 100644
--- a/source4/lib/util_sid.c
+++ b/source4/lib/util_sid.c
@@ -143,76 +143,6 @@ void generate_wellknown_sids(void)
initialised = True;
}
-/**************************************************************************
- Splits a name of format \DOMAIN\name or name into its two components.
- Sets the DOMAIN name to lp_netbios_name() if it has not been specified.
-***************************************************************************/
-
-void split_domain_name(const char *fullname, char *domain, char *name)
-{
- pstring full_name;
- const char *sep;
- char *p;
-
- sep = lp_winbind_separator();
-
- *domain = *name = '\0';
-
- if (fullname[0] == sep[0] || fullname[0] == '\\')
- fullname++;
-
- pstrcpy(full_name, fullname);
- p = strchr_m(full_name+1, '\\');
- if (!p) p = strchr_m(full_name+1, sep[0]);
-
- if (p != NULL) {
- *p = 0;
- fstrcpy(domain, full_name);
- fstrcpy(name, p+1);
- } else {
- fstrcpy(domain, lp_netbios_name());
- fstrcpy(name, full_name);
- }
-
- DEBUG(10,("split_domain_name:name '%s' split into domain :'%s' and user :'%s'\n",
- fullname, domain, name));
-}
-
-/*****************************************************************
- Convert a SID to an ascii string.
-*****************************************************************/
-
-char *sid_to_string(fstring sidstr_out, const struct dom_sid *sid)
-{
- char *tmp_string;
- TALLOC_CTX *mem_ctx;
- if (!(mem_ctx = talloc_init("sid_to_string temp context"))) {
- return NULL;
- }
-
- tmp_string = dom_sid_string(mem_ctx, sid);
- if (!tmp_string)
- return NULL;
-
- fstrcpy(sidstr_out, tmp_string);
- return sidstr_out;
-}
-
-/*****************************************************************
- Removes the last rid from the end of a sid
-*****************************************************************/
-
-BOOL sid_split_rid(struct dom_sid *sid, uint32 *rid)
-{
- if (sid->num_auths > 0) {
- sid->num_auths--;
- if (rid)
- *rid = sid->sub_auths[sid->num_auths];
- return True;
- }
- return False;
-}
-
/*****************************************************************
Return the last rid from the end of a sid
*****************************************************************/