summaryrefslogtreecommitdiff
path: root/source3/lib
diff options
context:
space:
mode:
authorLuke Leighton <lkcl@samba.org>1999-11-20 20:54:29 +0000
committerLuke Leighton <lkcl@samba.org>1999-11-20 20:54:29 +0000
commit24a069eac302069559c6347b24276e7f1a04cc91 (patch)
treed49a94cde47a03b2b8d2c988f418f3cf1de01876 /source3/lib
parenta56bea383b4813f77478f9859dc33c90a564f540 (diff)
downloadsamba-24a069eac302069559c6347b24276e7f1a04cc91.tar.gz
samba-24a069eac302069559c6347b24276e7f1a04cc91.tar.bz2
samba-24a069eac302069559c6347b24276e7f1a04cc91.zip
modified domain_client_validate to take trust account name / type. this
is to pass DOMAIN_NAME$ and SEC_CHAN_DOMAIN instead of WKSTA_NAME$ and SEC_CHAN_WKSTA. modified check_domain_security to determine if domain name is own domain, and to use wksta trust account if so, otherwise check "trusting domains" parameter and use inter-domain trust account if so, otherwise return False. (This used to be commit 97ec74e1fa99d773812d2df402251fafb76b181c)
Diffstat (limited to 'source3/lib')
-rw-r--r--source3/lib/sids.c3
-rw-r--r--source3/lib/util_pwdb.c3
-rw-r--r--source3/lib/util_str.c34
3 files changed, 37 insertions, 3 deletions
diff --git a/source3/lib/sids.c b/source3/lib/sids.c
index 052c05cb01..c18734c705 100644
--- a/source3/lib/sids.c
+++ b/source3/lib/sids.c
@@ -139,7 +139,8 @@ BOOL get_member_domain_sid(void)
}
}
- return get_domain_sids(NULL, &global_member_sid, lp_passwordserver());
+ return get_domain_sids(global_myname, NULL,
+ &global_member_sid, lp_passwordserver());
}
diff --git a/source3/lib/util_pwdb.c b/source3/lib/util_pwdb.c
index f27cce8fba..d80ec5f689 100644
--- a/source3/lib/util_pwdb.c
+++ b/source3/lib/util_pwdb.c
@@ -634,7 +634,8 @@ BOOL pwdb_initialise(BOOL is_server)
{
srvs = lp_passwordserver();
}
- if (!get_domain_sids(&global_member_sid, &global_sam_sid, srvs))
+ if (!get_domain_sids(global_myname, &global_member_sid,
+ &global_sam_sid, srvs))
{
return False;
}
diff --git a/source3/lib/util_str.c b/source3/lib/util_str.c
index 43e3224df4..a25043df78 100644
--- a/source3/lib/util_str.c
+++ b/source3/lib/util_str.c
@@ -1066,6 +1066,38 @@ void all_string_sub(char *s,const char *pattern,const char *insert)
/****************************************************************************
splits out the front and back at a separator.
****************************************************************************/
+void split_at_first_component(char *path, char *front, char sep, char *back)
+{
+ char *p = strchr(path, sep);
+
+ if (p != NULL)
+ {
+ *p = 0;
+ }
+ if (front != NULL)
+ {
+ pstrcpy(front, path);
+ }
+ if (p != NULL)
+ {
+ if (back != NULL)
+ {
+ pstrcpy(back, p+1);
+ }
+ *p = sep;
+ }
+ else
+ {
+ if (back != NULL)
+ {
+ back[0] = 0;
+ }
+ }
+}
+
+/****************************************************************************
+ splits out the front and back at a separator.
+****************************************************************************/
void split_at_last_component(char *path, char *front, char sep, char *back)
{
char *p = strrchr(path, sep);
@@ -1084,7 +1116,7 @@ void split_at_last_component(char *path, char *front, char sep, char *back)
{
pstrcpy(back, p+1);
}
- *p = '\\';
+ *p = sep;
}
else
{