1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-28 07:21:54 +03:00
Commit Graph

483 Commits

Author SHA1 Message Date
Volker Lendecke
13248e8917 Revert "s:Fix uid_to_sid mapping when the idmap cache is empty."
This reverts commit 9a9b64dbdf.
2009-01-02 15:00:05 +01:00
Volker Lendecke
c033ea5626 Revert "s3:idmap: Remove passd check from idmap_backends_unixid_to_sid()."
This reverts commit 45db33e732.
2009-01-02 15:00:05 +01:00
Jeremy Allison
bb23f5725f Fix more asprintf and "ignoring return code" warnings from gcc 4.3.
Jeremy.
2008-12-31 16:30:11 -08:00
Stefan Metzmacher
429276556a s3:winbindd: we don't need to call messaging_reinit() twice
reinit_after_fork() already calls messaging_reinit()

metze
2008-12-31 11:01:46 +01:00
Michael Adam
45db33e732 s3:idmap: Remove passd check from idmap_backends_unixid_to_sid().
As noted by Metzy, it makes no sense here to check id->sid.
What is worse, this might even be passed in uninitialized.

This still fixes the bug for me (of course), but we might need
to check, if another special handling of passdb is needed
(possibly changing from constant return code NT_STATUS_OK...)

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
2008-12-25 12:14:03 +01:00
Michael Adam
9a9b64dbdf s:Fix uid_to_sid mapping when the idmap cache is empty.
This failed for backends other than passed, since
idmap_backends_unixid_to_sid() always asked passdb first,
which returned Success no matter whether a mapping was
found or not.

One effect wast that getpwuid failed after "net cache flush".
Only after filling the cache with a getpwnam call it succeeded.

This fix makes the behaviour of idmap_backends_unixid_to_sid()
exactly the same as that of idmap_backends_sid_to_unixid()

Michael

Signed-off-by: Michael Adam <obnox@samba.org>
2008-12-25 12:14:02 +01:00
Gerald (Jerry) Carter
5aadfe29f0 Fix "allow trusted domain" so it disables trusted domains. 2008-12-22 11:07:29 -08:00
Volker Lendecke
2504d78c82 Fix a "ignoring function call result" warning 2008-12-19 13:57:32 +01:00
Volker Lendecke
bb8ca0fdbf Make cli_negprot return NTSTATUS instead of bool 2008-12-19 10:28:30 +01:00
SATOH Fumiyasu
d46c1907fc winbindd: vars for signals must be volatile sig_atomic_t 2008-12-12 18:04:03 +01:00
Volker Lendecke
15c942657d Add wb_trans_send/revc 2008-12-08 22:09:34 +01:00
Volker Lendecke
2bd8a6e21e Add infrastructure to transfer winbindd_request/response asynchronously 2008-12-08 22:09:33 +01:00
Volker Lendecke
1db7076b8e Fix nonempty blank lines 2008-12-07 21:30:35 +01:00
Michael Adam
0f38bd9072 s3:winbindd: fix horrible mis-indentation of toplvl braces in getgrsid_sid2gid_recv
to make code more readble

Michael
2008-12-04 14:00:44 +01:00
Michael Adam
95b4baf5ad s3:winbindd: don't open a new dc connection in winbindd_getpwnam (main winbindd)
This is just to find the corresponding domain struct.
Actual connection is handled by the domain child.

Michael
2008-12-04 13:39:05 +01:00
Michael Adam
db59cbfba8 s3:winbindd: don't open a new dc connection in winbindd_getgrnam (main winbindd)
This is just to find the corresponding domain struct.
Actual connection is handled by the domain child.

Michael
2008-12-04 13:39:05 +01:00
Tim Prouty
1eb743ab8e s3: Change sockaddr util function names for consistency
Also eliminates name conflicts with OneFS system libraries
2008-12-03 10:40:20 -08:00
Tim Prouty
1bcd91366d s3: Fix 'ctx' might be used unitialized warnings 2008-12-01 21:59:00 -08:00
Michael Adam
0744c32678 s3:winbindd/nss_info: remove unused variable from nss_init()
Michael
2008-12-01 04:37:24 +01:00
Michael Adam
c77435caaf s3:winbindd/nss_info: make nss_domain_list_add_domain() static
Michael
2008-12-01 04:37:24 +01:00
Michael Adam
37be1f6d08 s3:winbindd/nss_info: fix default backend handling for ad backends.
This fixes "winbind nss info = rfc2307" (or sfu or sfu20).
Originally, only explicitly configured domains (like "rfc2307:domain")
worked with the ad module, since the domain name was not passed
backe to the module. This is fixed by recording the first backend
listed without domain in the "winbind nss info" parameter as the
default backend, and creating new nss_domain entries (using this default
backend) on the fly as requests for domains which are not explicitly
configured are encountered.

Michael
2008-12-01 04:37:24 +01:00
Michael Adam
a7e60befdc s3:winbindd/nss_info: whitespace cleanup.
Remove trailing spaces and fix tab / space mixup.

Michael
2008-12-01 04:37:23 +01:00
Michael Adam
af6f1b4085 s3:winbindd_cache: add debugging to get_nss_info_cached()
Michael
2008-12-01 04:37:23 +01:00
Michael Adam
09d05bcffe s3:winbindd/nss_info: add entry debug message to nss_get_info()
Michael
2008-12-01 04:37:23 +01:00
Michael Adam
1048c2ccbe s3:winbindd/nss_info: add debugging to nss_init()
Michael
2008-12-01 04:37:22 +01:00
Michael Adam
82ee6d2f7d s3:winbindd/idmap_ad: add entry debug message to nss_ad_get_info()
Michael
2008-12-01 04:37:22 +01:00
Michael Adam
484fa90aef s3:winbindd/idmap_ad: add support for trusted domains to idmap_ad (bug #3661)
This initial fix does at least work for explicitly configured domains.

The patch has a few disadvantages:

1. It does work only for explicitly configured domains, not with
   the default backend (idmap backend = ad), since it relies on the
   domain name being passed in via the idmap_domain. One workaround
   for this would be to create clones of the default idmap_domain
   for domains not explicitly configured.

2. It calls find_domain_from_name_noinit() from idmap_ad_cached_connection.
   The problem here is that only the NetBIOS domain name (workgroup
   name) is passed in via the idmap_domain struct, and the module
   has to establish a connection to the domain based on that information.
   find_domain_from_name_noinit() has the disadvantage that it uses the state
   of the domain list at fork time (unless used from the main winbindd).
   But this should be ok as long as the primary domain was reachable at
   start time.

For nss_info, the situation is similar - This will only work for domains
explicitly configured in smb.conf as follows:
"winbind nss info = rfc2307:dom1 sfu:dom2 rfc2307:dom3 template:dom4"
Setting the default nss info to one of the ad backends (rfc2307, sfu, sfu20)
will fail since the domain name is not passed in with the nss_domain_entry.

Michael
2008-12-01 04:37:22 +01:00
Michael Adam
be233ae32a s3:winbindd/idmap_ad: refactor core of nss_{sfu|sfu20|rfc2307}_init to common function.
Michael
2008-12-01 04:37:22 +01:00
Michael Adam
73fddcd656 s3:winbindd/idmap_ad: rename ctx to mem_ctx in nss_ad_get_info()
in preparation to using the idmap_ad_context there

Michael
2008-12-01 04:37:22 +01:00
Michael Adam
11d5b1a21a s3:winbindd/idmap: add diagnostic entry debug msg to idmap_backends_sid_to_unixid
Michael
2008-12-01 04:37:21 +01:00
Michael Adam
7b4e54359f s3:winbindd/idmap: add diagnostic entry debug msg to idmap_backends_unixid_to_sid
Michael
2008-12-01 04:37:21 +01:00
Michael Adam
5f5fa28c5d s3:winbindd/idmap: add diagnostic entry debug msg to idmap_find_domain().
Michael
2008-12-01 04:37:21 +01:00
Michael Adam
67cc93c4a2 s3:winbindd/idmap_util: unify entering debug messages and add ouput of domain
Michael
2008-12-01 04:37:20 +01:00
Michael Adam
757a1f5132 s3:winbindd/nss_info: change nss_map_{to|from}_alias to take nss_domain_entry
instead of just the domain name

Michael
2008-12-01 04:37:20 +01:00
Michael Adam
03304c5152 Revert "UNFINISHED - s3:idmap_ad: multi-domain"
This reverts commit 6a4957d35d.

Sorry - this got accidentially pushed.

Michael
2008-11-25 15:24:43 +01:00
Michael Adam
6a4957d35d UNFINISHED - s3:idmap_ad: multi-domain
Michael
2008-11-25 11:29:42 +01:00
Michael Adam
dd54e68014 s3-winbindd: make all winbind rpc-methods static.
Now that the methods are no longer needed in winbindd_ads,
we can make them static again.

Michael
2008-11-21 23:32:30 +01:00
Michael Adam
e179c41718 s3-winbindd_ads: use the reconnect methods instead of the rpc methods directly
Some of the ads methods just point to the rpc methods.
This makes winbindd_ads use the reconnect methods instead of
calling the rpc methods directly in order to prevent
negative cache entries for e.g. name_to_sid, when the dc
has closed the connection without sending a reset.

Michael
2008-11-21 23:32:29 +01:00
Michael Adam
fa60e4e97d s3-winbindd_ads: prevent negative GM/ cache entries due to broken connections
The ads lookup_groupmem() function calls lda_lookupsids to resolve sids
to names. This is tried only once. So in case the connection was broken,
e.g. closed by the server (without a reset packet), there will be an empty
GM/ cache entry for the requested group which will prevent proper working
of access checks among other checks for the expiry period.

This patch works around this problem by retrying once if the lsa_lookupsids
call fails, re-establishing the dc-connection, as we already do in many other
places (e.g. the winbindd retry methods for the rpc layer).

Michael
2008-11-21 23:32:29 +01:00
Günther Deschner
03e0d0fb37 s3-winbindd: for now only change machine pwd when not using a system krb5 keytab.
Guenther
2008-11-21 00:57:22 +01:00
Steven Danneman
ce44a20323 Clean-up various trailing space and >80 column lines. 2008-11-18 17:06:22 -08:00
Steven Danneman
00c6271d5c Added ability to remove id mappings in wbinfo and libwbclient.
The idmap_tdb backend already provides an interface to remove existing id
mappings.  This commit plumbs that ability up through, winbindd, libwbclient,
and wbinfo.

Added new winbindd command:
        WINBINDD_REMOVE_MAPPING
Added new libwbclient interfaces:
        wbcRemoveUidMapping() and wbcRemoveGidMapping()
Added new wbinfo options:
        --remove-uid-mapping
        --remove-gid-mapping

Increased libwbclient version to 0.2
Increased winbind interface version to 20
2008-11-18 16:04:04 -08:00
Steven Danneman
6d59be1e6d Fix extended DN parse error when AD object does not have a SID.
Some AD objects, like Exchange Public Folders, can be members of Security
Groups but do not have a SID attribute.  This patch adds more granular return
errors to ads_get_sid_from_extended_dn().  Callers can now determine if a parse
error occured because of bad input, or the DN was valid but contained no SID.

I updated all callers to ignore SIDless objects when appropriate.

Also did some cleanup to the out paths of lookup_usergroups_memberof()
2008-11-18 13:02:21 -08:00
Steven Danneman
9a7900fb38 Whitespace and >80 column cleanups. 2008-11-18 13:02:20 -08:00
Davide Sfriso
9ea794417e Fix bug #5906 when running winbindd on a Samba PDC. Winbindd crash on 'getent group'
Jeremy.
2008-11-17 15:38:56 -08:00
Günther Deschner
6a61580617 s3-winbindd: workaround for samr_ChangePasswordUser3 to User2 fallback for w2k dcs.
Guenther
2008-11-13 17:33:18 +01:00
Jeremy Allison
d67e7f3e15 Fix memory leak in error path, spotted by Martin Zielinski <mz@seh.de>.
Jeremy.
2008-11-12 14:06:47 -08:00
Günther Deschner
a4c24b4d30 s3-samr-idl: cleanup.
Guenther
2008-11-10 21:46:25 +01:00
Kai Blin
7d8787c915 ntlm_auth: Put huge NTLMv2 blobs into extra_data on CRAP auth.
This fixes bug #5865
2008-11-10 12:50:02 +01:00
Tim Prouty
2efacde8c4 s3: fix a few "shadows a global declaration" warnings 2008-11-03 14:44:38 -08:00
Michael Adam
17218df567 [s3]winbindd: speed up fill_grent_mem (i.e. winbindd_getgrent) a lot.
With large groups, getgrent ran into timeouts because after each
single user that was added to the expanded group list, the list
was sorted and made unique.

Now the list is sorted just once after all members have been added.

Michael
2008-11-02 22:29:17 +01:00
Jelmer Vernooij
ddcab787c4 Rename dos_errstr() to win_errstr() for consistency with Samba 4. 2008-11-01 17:19:26 +01:00
Jeremy Allison
f1a70d1e2a Coverity fix CID: 592 - null deref (can't happen but doesn't hurt to be sure).
Jeremy.
2008-10-29 16:02:45 -07:00
Michael Adam
b881d2ee78 [s3]winbind: fix smbd hanging on Solaris when winbindd closes socket.
On some versions of Solaris, we observed a strange effect of close(2)
on a socket: After the server (here winbindd) called close, the client fd
was not marked as readable for select. And a write call to the fd did
not produce an error EPIPE but just returned as if successful.

So while winbindd had called remove_client(), the corresponding smbd
still thought that it was connected, but failed to retrieve answers
for its queries.

This patch works around the problem by forcing the client fd to
the readable state: Just write one byte into the socket before
closing.

Michael
2008-10-27 14:59:33 +01:00
Tim Prouty
0058176ae3 s3: fix simple "incompatible pointer type" build warning 2008-10-23 16:38:19 -07:00
Jelmer Vernooij
d6a5476ee7 Use sockaddr_storage only where we rely on the size, use sockaddr
otherwise (to clarify we can also pass in structs smaller than
sockaddr_storage, such as sockaddr_in).
2008-10-23 19:53:15 +02:00
Volker Lendecke
bc9bbda8b3 Fix a valgrind error in idmap_ad_sids_to_unixids()
We need to initialize all mappings in case we don't find anything.

Simo, please check!

Volker
2008-10-20 21:08:20 +02:00
Jelmer Vernooij
2d89b52be8 Use separate make variables for libutil and libcrypto. 2008-10-18 14:28:40 +02:00
Günther Deschner
65dc1eeceb s3: fix various samr callers.
Guenther
2008-10-15 17:11:27 +02:00
Volker Lendecke
a781b78417 Remove smb_np_struct 2008-10-13 20:59:33 +02:00
Jelmer Vernooij
cb78d4593b Cope with changed signature of http_timestring(). 2008-10-11 23:57:44 +02:00
Günther Deschner
76a8da6f71 s3-winbindd: use new, richer structures in WINBINDD_DSGETDCNAME implementation.
Guenther
2008-10-09 12:37:18 +02:00
Jeremy Allison
14f835ba4b Fix bug #5814 - Winbindd dumping core in a strange manner while doing "rescan_trusted_domain".
From analysis by hargagan <shargagan@novell.com> :
"The winbindd_child_died() is also getting called from process_loop() in case of
SIGCHLD signal. In this case it doesn't make the timeout_handler to NULL for
the first request. It then initiate a new request using
schedule_async_request() which installs a new timeout handler for the same
request. In such a case, for a badly unresponsive system both the timeout
handler can be called. For the first call the "private_data" will be cleared
and for another call the timeout handler will be detecting the double free. So,
for such a case as well, the winbindd_child_died() should make the
timeout_handler to NULL."
Jeremy.
2008-10-08 11:39:32 -07:00
Gerald (Jerry) Carter
2a35985283 idmap_adex: Add more debugging to the basic search function.
Log the dn of all located entries in order to verify search results.
2008-10-06 14:10:03 -05:00
Gerald (Jerry) Carter
338f658a5a idmap_adex: Add log messages to dc_add_domain for easier debugging.
Part of continue work on BUG 5806.
2008-10-06 14:10:03 -05:00
Volker Lendecke
6aa8613b11 Log in the parent winbind log where a request is going 2008-10-06 10:57:47 +02:00
Jeremy Allison
e4f5bfb34b Fix use of DLIST_REMOVE as spotted by Constantine Vetoshev <gepardcv@gmail.com>.
This API is unusual in that if used to remove a non-list head it nulls out
the next and prev pointers. This is what you want for debugging (don't want
an entry removed from the list to be still virtually linked into it) but
means there is no consistent idiom for use as the next and prev pointers
get trashed on removal from the list, meaning you must save them yourself.
You can use it one way when deleting everything via the head pointer, as
this preserves the next pointer, but you *must* use it another way when not
deleting everything via the head pointer. Fix all known uses of this (the main
one is in conn_free_internal() and would not free all the private data entries
for vfs modules. The other changes in web/statuspage.c and winbindd_util.c
are not strictly neccessary, as the head pointer is being used, but I've done
them for consistency. Long term we must revisit this as this API is too hard
to use correctly.
Jeremy.
2008-10-01 13:15:54 -07:00
Andrew Tridgell
86612b1163 re-added "winbind:ignore domains" patch
This option really is essential, as we discover again and again at
customer sites. Due to bugs in winbind some domains are toxic. When
you are installing at a site and a particular domain in a complex
setup causes winbind to segfault or hang then you need a way to
disable that domain and continue.

In an ideal world winbind could handle arbitrarily complex ADS
domains, but we are nowhere near that yet. If we ever get to that
stage then we won't need this option.
2008-09-29 14:01:01 +02:00
Andrew Tridgell
a93dc2c858 removed unused variables 2008-09-29 14:01:00 +02:00
Andrew Tridgell
b8c9daac6e fixed segv on startup with trusted domains
With some setups, idmap_tdb2_allocate_id can be called before the
allocate backend is initialised, leading to a segv. This change
ensures that the db is opened in all paths that use it
2008-09-29 14:01:00 +02:00
Gerald W. Carter
6f46002ff6 idmap: Fix typo is gid2sid() that was caching using idmap_cache_set_sid2uid() 2008-09-25 10:46:31 -07:00
Günther Deschner
04979bcfb4 s3: fix idmap_adex.
Guenther
2008-09-24 03:34:24 +02:00
Jeremy Allison
3807b30f44 Fix winbindd crash in an unusual failure mode. Bug #5737. Based on original patch from shargagan@novell.com
Jeremy.
2008-09-23 16:39:57 -07:00
Günther Deschner
de54bac54c s3: fix NETLOGON_NT_VERSION version flags.
Guenther
2008-09-23 23:20:10 +02:00
Michael Adam
4432967532 [s3]winbindd_group: don't list the domain twice when expanding internal aliases
Before this, "getent group builtin\\administrators" expanded
domain group members in the form DOMAIN\domain\user.

Michael
2008-09-23 10:00:26 +02:00
Michael Adam
4205fab500 [s3]winbindd_group: sanely handle NULL domain in add_member().
Michael
2008-09-23 10:00:26 +02:00
Michael Adam
49145bfefa [s3]winbindd_ads: honour "winbind use default domain" in lookup_groupmem().
This fixes the output of "getent group" when "winbind use default domain = yes"
with security = ads.

Michael
2008-09-23 10:00:26 +02:00
Michael Adam
1f8a7739ac [s3]winbindd_rpc: add domain prefix to username in lookup_groupmem().
This makes the output of "getent group" of a domain group show the
domain prefix with "security = domain".

Michael
2008-09-23 10:00:26 +02:00
Michael Adam
1b9c2ccb1f [s3]winbindd_util: add fill_domain_username_talloc().
A talloc version of fill_domain_username().

Michael
2008-09-23 10:00:26 +02:00
Michael Adam
e401ce6de7 [s3]winbindd_util: add prototype for fill_domain_username_talloc().
A talloc version of fill_domain_username().

Michael
2008-09-23 10:00:25 +02:00
Michael Adam
f0dccdca6a [s3]winbindd: fix a comment typo
Michael
2008-09-23 10:00:25 +02:00
Michael Adam
6c8c5d7113 [s3]winbind_util: fix an implicit cast compile warning.
Michael
2008-09-23 10:00:25 +02:00
Günther Deschner
c48186f507 s3: use samba4 prototype for ndr_push/pull_struct_blob.
Guenther
2008-09-23 09:37:23 +02:00
Gerald (Jerry) Carter
7d5fb989ac idmap_adex: Add new idmap plugin for support RFC2307 enabled AD forests.
The adex idmap/nss_info plugin is an adapation of the Likewise
Enterprise plugin with support for OU based cells removed
(since the Windows pieces to manage the cells are not available).

This plugin supports

  * The RFC2307 schema for users and groups.
  * Connections to trusted domains
  * Global catalog searches
  * Cross forest trusts
  * User and group aliases

Prerequiste: Add the following attributes to the Partial Attribute
Set in global catalog:

  * uidNumber
  * uid
  * gidNumber

A basic config using the current trunk code would look like

 [global]
      idmap backend = adex
      idmap uid = 10000 - 19999
      idmap gid = 20000 - 29999
      idmap config US:backend = adex
      idmap config US:range = 20000 - 29999
      winbind nss info = adex

       winbind normalize names = yes
       winbind refresh tickets = yes
       template homedir = /home/%D/%U
       template shell = /bin/bash
2008-09-22 15:46:19 -07:00
Gerald (Jerry) Carter
28d2683903 * Allow an admin to define the "uid" attribute for a RFC2307
user object in AD to be the username alias.

For example:

  $ net ads search "(uid=coffeedude)"
  distinguishedName: CN=Gerald W. Carter,CN=Users,DC=pink,DC=plainjoe,DC=org
  sAMAccountName: gcarter
  memberOf: CN=UnixUsers,CN=Users,DC=pink,DC=plainjoe,DC=org
  memberOf: CN=Domain Admins,CN=Users,DC=pink,DC=plainjoe,DC=org
  memberOf: CN=Enterprise Admins,CN=Users,DC=pink,DC=plainjoe,DC=org
  memberOf: CN=Schema Admins,CN=Users,DC=pink,DC=plainjoe,DC=org
  uid: coffeedude
  uidNumber: 10000
  gidNumber: 10000
  unixHomeDirectory: /home/gcarter
  loginShell: /bin/bash

  $ ssh coffeedude@192.168.56.91
  Password:

  coffeedude@orville:~$ id
  uid=10000(coffeedude) gid=10000(PINK\unixusers) groups=10000(PINK\unixusers)

  $ getent passwd PINK\\gcarter
  coffeedude:*:10000:10000::/home/gcarter:/bin/bash

  $ getent passwd coffeedude
  coffeedude:*:10000:10000::/home/gcarter:/bin/bash

  $ getent group PINK\\Unixusers
  PINK\unixusers10000:coffeedude
2008-09-16 10:35:21 -07:00
Gerald (Jerry) Carter
63554b4078 idmap_hash: Add the idmap/nss-info provider from Likewise Open.
* Port the Likewise Open idmap/nss_info provider (renamed to
  idmap_hash).

* uids & gids are generated based on a hashing algorithm that collapse
  the Domain SID to a 31 bit number.  The reverse mapping from the
  high order 11 bits to the originat8ing sdomain SID is stored in
  a has table initialized at start up.

* Includes support for "idmap_hash:name_map = <filename>" for the
  name aliasing layer.  The name map file consist of entries in
  the form "alias = DOMAIN\name"
2008-09-16 10:28:11 -07:00
Gerald (Jerry) Carter
544cd1b4b9 winbindd: Update the calls to ws_name_XX() to reflect API changes.
* Ensures that all points an which a name is received or returned
  to/from a client passes through the name aliases layer (users
  and groups).
2008-09-16 10:27:59 -07:00
Gerald (Jerry) Carter
d6de32db2f winbindd: Add support for name aliasing.
* Add support user and group name aliasing by expanding
  the ws_name_replace() and ws_name_return() functions.
  The lookup path is
     aliases -> qualified name -> SID
     SID -> fully qualified name -> alias
  In other words, the name aliasing support is a thin layer
  built on top of SID/NAME translation.

* Rename the ws_name_XX() functions to normalize_name_map()
  and normalize_name_unmap().  Chaneg interface to return
  NTSTATUS rather than char *.

* Add associated cache validation functions.
2008-09-16 10:27:49 -07:00
Gerald W. Carter
62791bbd03 idmap_ad: Fix a segfault when calling nss_get_info() with a NULL ads structure. 2008-09-15 17:18:23 -05:00
Simo Sorce
f25863e04c Fix for bug 5571
Make sure that usernames are parsed using the correct separator.
Otherwise group memeberships in winbind may be result broken.
(This used to be commit 20b9c0aa7b)
2008-09-11 09:51:39 -04:00
Günther Deschner
ce9d896781 Revert "winbindd: the ad trusted_domains call should return talloced strings."
This reverts commit b57cbf62e8.
(This used to be commit b2a3f13e5b)
2008-09-05 23:29:54 +02:00
Qiao Yang
38c287740f Fix a memleak
request.extra_data is not freed if there is no extra_data in response or
when there is some error happens in processing. This patch will free the
buffer right after processing a request before sending back a response.
(This used to be commit be6f12273f)
2008-09-05 14:13:39 +02:00
James Ding
72df999759 Fix winbindd crash bug with trusted domains. Bug #5736
(This used to be commit d4f5caa3d3)
2008-09-04 15:13:12 -07:00
Herb Lewis
24992010cb get rid of unneeded argument in get_methods and get_alloc_methods
(This used to be commit 07b0323472)
2008-09-04 14:35:27 -07:00
Steven Danneman
304554115a Cleanup of DC enumeration in get_dcs()
This is a fix for a few small inefficiencies/bugs in the get_dcs() path.

* because the third add_one_dc_unique() loop was outside the ADS check all DCs
  returned from the non-sitename lookup were being tacked onto the dc_name_ip
  list twice.
* add_one_dc_unique() now checks if the given IP address already exists before
  adding it to the list, making the returned list actually unique
* added more thorough doxygen comment headers
(This used to be commit cb2d488e1d)
2008-09-04 11:50:25 -07:00
Simo Sorce
3fa16da8c7 Revert "Split lookup_name() and create a new functiong called"
This reverts commit 8594edf666.
(This used to be commit ad462e2e2d)
2008-09-03 14:36:43 -04:00
Simo Sorce
c5894e1477 Merge branch 'v3-devel' of ssh://git.samba.org/data/git/samba into v3-devel
(This used to be commit 8e4dca3b94)
2008-09-03 11:52:54 -04:00
Günther Deschner
aac60fead2 winbindd: the ad trusted_domains call should return talloced strings.
Guenther
(This used to be commit b57cbf62e8)
2008-09-02 21:53:04 +02:00
Volker Lendecke
ec4015d34f Fix Coverity ID 592
The scanner did not figure out that we always have a primary domain, so it
complained about us potentially passing a NULL pointer down to
set_domain_online_request() where it is dereferenced.

Make the code a bit clearer.
(This used to be commit e6e8d108f9)
2008-08-31 11:36:27 +02:00
Günther Deschner
52e23fe460 winbindd: fix invalid sid copy (hit when enumerating sibling domains).
Guenther
(This used to be commit 5eee742335)
2008-08-28 12:29:52 +02:00