1
0
mirror of https://github.com/samba-team/samba.git synced 2025-02-09 09:57:48 +03:00

9882 Commits

Author SHA1 Message Date
Gerald Carter
dc1cd583cb don't pass NULL pointers to strcmp()
(This used to be commit 6631984b12a3f74b93f7031c433dd81d6586a5df)
2003-02-27 21:37:54 +00:00
Gerald Carter
97e7d2ffae additional fix for CR 601
* distinguish WinXP from Win2k
  * add a 1/3 of a second delay in OpenPrinter
    in order to trigger a LAN/WAN optimization in
    2k clients.
(This used to be commit 96570699d1b715f47c35aa211da6ec18f6fc4109)
2003-02-27 21:21:02 +00:00
Martin Pool
5c82d3f00a Doxygen janitor
(This used to be commit 67bf36c69d19463c28066b276d74ac4784b26bed)
2003-02-27 05:53:25 +00:00
Jelmer Vernooij
742dcedfa2 We now use <anchor/> instead of just <anchor> (strict XML syntax)
(This used to be commit 7c00fff475e15a9e9d5c3d2c8394a2cdc1b90cac)
2003-02-27 02:17:54 +00:00
Jelmer Vernooij
d21b15ff57 - Rename 'modules = ' to 'preload modules = '
- Add smb_probe_module()
- Add init_modules()
- Call these functions
(This used to be commit f8f21653225792c0001d183c6efe8b7d89a0785d)
2003-02-27 01:54:41 +00:00
Andrew Bartlett
d62f60f53a Fix possible memory leak on failure.
(This used to be commit 052ebc44cde8d31571ed1edb602794349825be11)
2003-02-27 01:05:12 +00:00
Jeremy Allison
f6f76ad5ed Fix to allow blocking lock notification to be done rapidly (no wait
for smb -> smb lock release). Adds new PENDING_LOCK type to lockdb
(does not interfere with existing locks).
Jeremy.
(This used to be commit 22fc0d48ff2052b4274c65f85050c58b235bf4e4)
2003-02-27 00:43:23 +00:00
Andrew Bartlett
20d0bb2310 Add -Wwrite-strings to our --enable-developer settings.
We have compiled relitivly 'clean' with this setting since I did a massive
cleanup last month.  This should help us stay that way.

Andrew Bartlett
(This used to be commit 284479bf388f5e39d9be78eeb1ac6cdd001fb8df)
2003-02-26 12:31:17 +00:00
Andrew Bartlett
ca80787248 Netlogon-unigroup changes needed for the winbind RID-to-SID conversion.
This changes the cache format, which will simply invalidate existing entries,
leaving them dead in the cache.

Andrew Bartlett
(This used to be commit 3fc179362ea849db23490b971a9f64f943e7f7f8)
2003-02-26 12:23:03 +00:00
Andrew Bartlett
cee64b5353 Kill RID-only and domain+RID madness from winbind.
Now we deal with SIDs in almost all of winbind (a couple of limited exceptions
remain, but I'm looking into them - they use non-winbind structs ATM).

This has particular benifits in returning out-of-domain SIDs for group
membership (Need to look into this a bit more) as well as general code quality.

This also removes much of the complexity from the idmap interface, which now
only deals with mapping IDs, not with SID->domain translations.

Breifly tested, but needs more.  Fixes some valgrind-found bugs from my
previous commit.

Winbind cache chagned to using SID strings in some places, as I could not
follow exactly how to save and restore multiple packed sids properly.

Andrew Bartlett
(This used to be commit 9247cf08c40f016a924d600ac906cfc6a7016777)
2003-02-26 12:21:01 +00:00
Martin Pool
f7bb698298 init_valid_table: Fix a memory leak that would lose the
dynamically-created valid table every time the configuration was
reloaded.
(This used to be commit e42b237d980461caf2dd2a8f82c17bf674facb7d)
2003-02-26 06:19:16 +00:00
Tim Potter
b906a9df75 Merge from appliance:
>Another hopeful fix for CR#1168.  Change the RPC used in querying
>domain users from QueryDispInfo to EnumDomainUsers.  Hopefully this
>will fix the random dropouts that keep occuring when listing large
>domains.
>
>My thought is that since QueryDispInfo is only used in the NT user
>manager it may have a bug with large domains.  A more commonly used
>RPC may not have such problems.
(This used to be commit 0501b7d0b12fa8063ffe6a9d4ecc3391d0c2f45d)
2003-02-26 00:52:41 +00:00
Tim Potter
f9d577ac09 Fix compiler warning.
(This used to be commit 0308f24ad209a28799b36d041be2dc2be2b2dac8)
2003-02-25 23:35:25 +00:00
Tim Potter
991f6cc3c1 More const fixes and flow on fixes from yesterday's const-fest.
(This used to be commit 018733eedd7897e6811e8461c07e3acf418c0e09)
2003-02-25 23:34:57 +00:00
Tim Potter
7d581bebd4 Fix unused variable warning when ENCTYPE_ARCFOUR_HMAC is not defined.
(This used to be commit 92abafa62894a125c5a09fc92f5056e4d8b51089)
2003-02-25 23:30:46 +00:00
Tim Potter
64e53c9b22 Fix breakage done by myself yesterday.
(This used to be commit f4492de2d668082df6ae06933d12a3cfe120d403)
2003-02-25 23:28:28 +00:00
Gerald Carter
7c7d796b6d Progress on CR 601
cache the printer_info_2 with the open printer handle.
cache is invalidated on a mod_a_printer() call **on that smbd**.

Yes, this means that the window for admins to step on each other
from different clients just got larger, but since handles a generally
short lived this is probably ok.
(This used to be commit 33c7b7522504fb15989f32add8e9a087c8d9d0fa)
2003-02-25 20:51:23 +00:00
Tim Potter
3a2f56cb63 Fixed up some const related compiler warnings.
(This used to be commit 923425e497112c5d1e2e569da6c13dcd02b6a8af)
2003-02-25 06:24:13 +00:00
Andrew Bartlett
589371e1d5 After some comments from tridge, clean the new usergroups code into a helper
function.

Andrew Bartlett
(This used to be commit 212a52b3d2ca39fcea2990f9293754b08e9b68e4)
2003-02-25 05:49:24 +00:00
Andrew Bartlett
bf095b8372 For some reason some attributes in ADS do not appear (and are not available)
in general searches, but only if searching for the DN only.

In my case, it was the tokenGroups attribute that caused me trouble, hence
this patch.

Andrew Bartlett
(This used to be commit 8a0cc4c2beb5d6ad7e44bf47bf0f9ec4a3ffdb96)
2003-02-25 03:30:39 +00:00
Andrew Bartlett
d116f2c884 tokenGroups are SIDs, so dump them as such.
(This used to be commit 43f07e9de70ad9993265e28a54239caba0121ab6)
2003-02-25 02:23:19 +00:00
Andrew Bartlett
f803c32376 Fix a really nasty bug where some users in AD domains (particularly child
domains) would not have the tokenGroups or memberOf attributes filled in.

This would cause a user to have no supplementary group membership.

Detect this by the fact that the primaryGid must be present in the tokenGroups,
and if it isn't (ie, if there is no tokenGroups at all), do a server-side
search on all groups using the 'member' attribute and the user's DN.

Andrew Bartlett
(This used to be commit a074f74e627e1d947a76bcf3a39e3c5df4d4ffe5)
2003-02-25 02:20:46 +00:00
Andrew Bartlett
c5871a1893 Whenever we have a password, use the in-memory ccache. This fixes a bug where
we were overwriting the user's ccache with the machine password (the -P option).

Andrew Bartlett
(This used to be commit 231d2f84ef36b30be98baf3b56ebf4a5cd8dad11)
2003-02-24 22:25:19 +00:00
Andrew Bartlett
79aaa35ea5 Clean up non-krb5 breakages from my modifications to luke howard's patch.
Andrew Bartlett
(This used to be commit 32fd0c49009e38022523cc5c14567dd55de08206)
2003-02-24 21:07:03 +00:00
Andrew Bartlett
05262ea49a Finish removing setenv replacements from smbwrapper.
(This used to be commit 059ac2d839bf258408490f5ceb786a47cb5acb58)
2003-02-24 11:24:27 +00:00
Andrew Bartlett
426cd68f74 Move off-by-one buggy malloc()/safe_strcpy() combination to strdup() instead.
Andrew Bartlett
(This used to be commit c26881633d8a7f6d9b9ed9c6a97ce2b45bf2b317)
2003-02-24 11:23:15 +00:00
Andrew Bartlett
0e6dbeb273 typo
(This used to be commit a47dee787413daaf0b550a47bbd78125490c356e)
2003-02-24 11:16:27 +00:00
Andrew Bartlett
eb64538dba Patch from Luke Howard to add mutual kerberos authentication, and SMB session
keys for kerberos authentication.

Andrew Bartlett
(This used to be commit 8b798f03dbbdd670ff9af4eb46f7b0845c611e0f)
2003-02-24 11:09:21 +00:00
Andrew Bartlett
2f0c70efb2 setenv takes 3 arguments...
(This used to be commit 6d18f64ef518cbb3d522cf1f92dc5cbc2e2cb642)
2003-02-24 10:35:24 +00:00
Andrew Bartlett
9c6d78c54c If it's a pstring, use pstrcpy().
(This used to be commit 34fb5f0b1a6281b3aa7782edb3fcb82cc4ec4877)
2003-02-24 09:46:01 +00:00
Andrew Bartlett
2295c0cf29 Fix off-by-one bugs, and move to strdup() rather than malloc()/strcpy().
Andrew Bartlett
(This used to be commit aa486355e282b891b299d63cc07431f32213b1b8)
2003-02-24 09:10:41 +00:00
Tim Potter
6fa6b607c9 Quieten compiler warning.
(This used to be commit eb5d1a72dc9dc35997d39f8778ee98163b8cce32)
2003-02-24 04:59:15 +00:00
Martin Pool
5b5453e6c7 Merge documentation from 3_0.
(This used to be commit 5002555a9719987ccdc887ffff64ea8d02c9881d)
2003-02-24 04:42:24 +00:00
Andrew Bartlett
12f2ebf7f0 Always initialise
(This used to be commit ff2b5b2f85f2d9dade67077cea1b68719cf65352)
2003-02-24 03:45:02 +00:00
Tim Potter
e25aa22a8f Merge:
> Exit path cleanup for cli_samr_enum_dom_users()
(This used to be commit 655c1e03519d4fa174a85534c165bdd1ce163ae8)
2003-02-24 02:12:39 +00:00
Andrew Bartlett
ded88da1ea Add const
(This used to be commit ffaa608be01d72075942ca3aff2325c6364e0556)
2003-02-24 02:11:32 +00:00
Andrew Bartlett
e68684aa65 Fix 2 off-by-one bugs in the use of malloc()ed strings and safe_strcpy().
safe_strcpy() isn't particularly safe (this has been noted before) as it does
not take the size of the buffer, but instead the size of the buffer *minus 1*

The locking.c fix was causing segfaults on machines running with
--enable-developer, and was tracked down thanks to the fact that vance's build
farm machine runs with such an option, and smbtorture's DIR1 test hits this
bug very well.

(The --enable-developer code writes to the last byte of the string, to check
for incorrect use of safe_strcpy()).

Andrew Bartlett
(This used to be commit e908fd164d1b11b6f76a6fdffb22e139813cb3c0)
2003-02-24 01:13:31 +00:00
Simo Sorce
bd0bbde1bb forgot the altered include file
(This used to be commit f3be08472b8b34d8921ff23c52dd2ba030c96f25)
2003-02-23 18:08:07 +00:00
Simo Sorce
bfc5f0ba8e move genparser to use talloc contexts instead of [m|c|re]alloc() and free()s
(This used to be commit 70fce680c01fa1baa65fb3cbc83dfaf822fdadd7)
2003-02-23 17:40:43 +00:00
Andrew Bartlett
1d1ad2db2e Make sure we set the error code to indicate failure...
Andrew Bartlett
(This used to be commit 5a472e2a3cffe175ac4341e19c153a931505a2e8)
2003-02-22 20:11:29 +00:00
Andrew Bartlett
fa26737f40 See if I can make this look slightly like C. It compiled locally, honest...
Andrew Bartlett
(This used to be commit cfc4cc776899da92a5c9a17f0ea36c7cb65d7a80)
2003-02-22 20:01:00 +00:00
Andrew Bartlett
7e110f782a More signed/unsigned fixes (yes, I run with funny compiler options) and
make x_fwrite() match fwrite() in returning a size_t.

Andrew Bartlett
(This used to be commit 2943c695787b742e9a96b2eefe2d75f681bacf7c)
2003-02-22 12:22:06 +00:00
Andrew Bartlett
0dde23a7b2 Fixes from Paul Green and vorlon@debian.org for building shared libraries
(make it possible to build both shared and static) and -lcrypt handling.
(This used to be commit 30510f50077fd157664c127ac0182ce26843d43f)
2003-02-22 12:19:18 +00:00
Andrew Bartlett
db94beaa41 Fix comment - the other bits of code don't call this any more.
(This used to be commit 523d1429b1072c999d376d2b4e13a1c08349990a)
2003-02-22 12:17:02 +00:00
Andrew Bartlett
ae2f064dc6 Add static
(This used to be commit d0365f20c242bcfc4f5d8286c6c5654e310a9d45)
2003-02-22 12:16:17 +00:00
Andrew Bartlett
e22a1915fe With assuptions about unixsam gone, we can forget about looking up
the user a second time now.

Andrew Bartlett
(This used to be commit a1e27a02f52315df0dd05ab8a94ae5a2bf398655)
2003-02-22 12:14:08 +00:00
Andrew Bartlett
3e19eda335 Remove 'unixsam' from the default passdb backends.
The intention is to remove the muliple passdb backends, but we need the
'guest' account to always be there.  If the admin adds the guest account to
(say) LDAP, there will only be one backend required for operation.

This helps remove some nasty behaviours with adding accounts to the system
for both the RPC 'create user' and the SAMSYNC code.  Users 'added' with
an 'add user/machine' script won't magicly appear, and machine accounts
'pre-added' to unix, but not the smbpasswd file will not cause mayhem.

This commit also implements somthing tridge discussed with me, the concept
of 'default' passdb operation pointers - so that each backend does not
need it's own stub funcitons wrapping the default tdb privilages/group
mapping code.

This also removes an implicit 'sid->name' and 'name->sid' mapping from our
own local SID space, to winbind usernames.  When adding mapping for NIS/LDAP
non-sam users in future, we need to be careful.

Andrew Bartlett
(This used to be commit 6f32fa234961a525760a05418a08ec48d22d7617)
2003-02-22 12:01:05 +00:00
Andrew Bartlett
ab43a25b28 First check if the user is in the passdb, then check Get_Pwnam().
We check passdb becouse the user might have things like a logon script set,
but we have to check the passdb becouse the user might not be in smbpasswd at
all.

This is in preperation for the removal of unixsam as an assuption.

Andrew Bartlett
(This used to be commit 61e3e2695860c58f9b0e8d1856972318666682c8)
2003-02-22 11:34:04 +00:00
Jeremy Allison
4fdb86eb3b When checking is_locked() new WRITE locks conflict with existing READ locks even
if the context is the same. See LOCKTEST7 in smbtorture.
Jeremy.
(This used to be commit b362cc241b829f585a96b5d285ed12db50b21e2e)
2003-02-22 01:09:42 +00:00
Jeremy Allison
ca2e995576 New locktest7 code based on patch from "Srikanta Shivanna" <sshivanna@pillardata.com>
Jeremy.
(This used to be commit caf298c3808cbdd683e884b32b7a0538505a3066)
2003-02-22 01:08:19 +00:00