From 2803a72751cf511aa0b5e6745e1b169faa66f68a Mon Sep 17 00:00:00 2001 From: Luke Leighton Date: Wed, 24 Nov 1999 22:45:09 +0000 Subject: ok. *whew*. this is the first completed part of the restructure. verified that lsaquery, lsalookupsids work, and found some bugs in the parameters of these commands :-) soo... we now have an lsa_* api that has the same arguments as the nt Lsa* api! cool! the only significant coding difference is the introduction of a user_credentials structure, containing user, domain, pass and ntlmssp flags. (This used to be commit 57bff6fe82d777e599d535f076efb2328ba1188b) --- source3/lib/util.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'source3/lib/util.c') diff --git a/source3/lib/util.c b/source3/lib/util.c index 26f0482162..cd6368ee77 100644 --- a/source3/lib/util.c +++ b/source3/lib/util.c @@ -3228,3 +3228,24 @@ BOOL become_user_permanently(uid_t uid, gid_t gid) return(True); } +BOOL resolve_srv_name(const char* srv_name, fstring dest_host, + struct in_addr *ip) +{ + DEBUG(10,("resolve_srv_name: %s\n", srv_name)); + + if (srv_name == NULL || strequal("\\\\.", srv_name)) + { + fstrcpy(dest_host, global_myname); + ip = interpret_addr2("127.0.0.1"); + return True; + } + + if (!strnequal("\\\\", srv_name, 2)) + { + return False; + } + + fstrcpy(dest_host, &srv_name[2]); + return resolve_name(dest_host, ip, 0x20); +} + -- cgit