1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-19 10:03:58 +03:00

1549 Commits

Author SHA1 Message Date
Jim McDonough
e042a93cce Format objectGUIDs on ads dumps.
(This used to be commit 7eaf7e7115c75e682b1b9368c6f28c60429885e5)
2002-10-18 20:11:29 +00:00
Jeremy Allison
e13dd2f302 Start to merge the new ACL mapping code from Andreas Gruenbacher <agruen@suse.de>.
Jeremy.
(This used to be commit f6103f866a5e698ab55fdab1444a14e3d8da16bb)
2002-10-18 19:46:28 +00:00
Andrew Bartlett
4ac9ccfde4 Nice *big* patch from metze.
The actual design change is relitivly small however:

It all goes back to jerry's 'BOOL store', added to many of the elements in a
SAM_ACCOUNT.  This ensured that smb.conf defaults did not get 'fixed' into
ldap.  This was a great win for admins, and this patch follows in the same way.

This patch extends the concept - we don't store values back into LDAP unless
they have been changed.  So if we read a value, but don't update it, or we
read a value, find it's not there and use a default, we will not update
ldap with that value.  This reduced clutter in our LDAP DB, and makes it
easier to change defaults later on.

Metze's particular problem was that when we 'write back' an unchanged value,
we would clear any muliple values in that feild.  Now he can still have his
mulitivalued 'uid' feild, without Samba changing it for *every* other
operation.

This also applies to many other attributes, and helps to eliminate a nasty
race condition.  (Time between get and set)

This patch is big, and needs more testing, but metze has tested usrmgr, and
I've fixed some pdbedit bugs, and tested domain joins, so it isn't compleatly
flawed ;-).

The same system will be introduced into the SAM code shortly, but this fixes
bugs that people were coming across in production uses of Samba 3.0/HEAD, hence
it's inclusion here.

Andrew Bartlett
(This used to be commit 7f237bde212eb188df84a5d8adb598a93fba8155)
2002-10-12 03:38:07 +00:00
Simo Sorce
650e0274a1 try to put every security descriptors related definitions in the same file.
also try to uniform names to a clean scheme.

first part.
(This used to be commit a123e05877caf90c28980be2d84b1d0b46e4fd21)
2002-10-06 23:53:34 +00:00
Jelmer Vernooij
7ee8de012b Add more common options to popt_common - and start using
the ones for debuglevel and configuration file in pdbedit
(This used to be commit cb0d03a393d9009c3e16b9d05d88c171de9a9414)
2002-10-05 05:43:44 +00:00
Jeremy Allison
9c94d1a2f7 Add a timeout to tdb_lock_bystring(). Ensure we never have more than
MAX_PRINT_JOBS in a queue.
Jeremy.
(This used to be commit bb58a08af459b4abae9d53ab98c15f40638ce52b)
2002-10-04 22:53:30 +00:00
Jelmer Vernooij
f7832e935f Remove useless spaces - this broke make proto
(This used to be commit 0341fb45829c5d13a7e02daaa9b960fdff492323)
2002-10-04 20:14:41 +00:00
Andrew Bartlett
08387abd7d Another patch from Steve Langasek <vorlon@netexpress.net>, again from the
Debian patchset.

The idea is to still allow DNS domains to be specified in 'hosts allow' and
'hosts deny' without making the admin set 'hostname lookups' in their smb.conf.
His concern is about upgrades.

This has been designed not to change the value of %M.

Andrew Bartlett
(This used to be commit f428ee98d83a55922c991b0eeddd47891b80d918)
2002-10-03 03:31:41 +00:00
Jeremy Allison
b69d0e39bc Added const. Anal formatting fixup.
Jeremy.
(This used to be commit ae4bf35f942de6025d3f364d599cca9720734a19)
2002-10-02 19:11:59 +00:00
Jeremy Allison
a9ccc38c08 Fix Solaris sendfile detection. Add small fixes to sendfile code.
Jeremy.
(This used to be commit ef7bcaf1b7e1ca073b27a8836c6aa86e112b5bee)
2002-10-01 05:55:25 +00:00
Jeremy Allison
7dc8aa0854 Added Solaris sendfile patch + configure tests from Pierre Belanger <belanger@yahoo.com>.
Jeremy.
(This used to be commit 8db4d46dc983ce37814fb375d61951b6220a4c61)
2002-09-30 21:14:46 +00:00
Jeremy Allison
09507f5315 Don't zero out numwritten before using.... Found by Pierre Belanger belanger@pobox.com
Jeremy.
(This used to be commit a7009ad5c8aaae350b2521b8c0cd2538e561618a)
2002-09-30 05:19:43 +00:00
Andrew Bartlett
6b1367a7bc Fix the compile issue in bin/samtest, and make the 'system' token just have the
System sid.  This avoids comparing with ACEs that we don't yet support in the
ADS Domain security descriptor.
(This used to be commit ace7738e123b28f69c290f9f1de50011d230e14b)
2002-09-30 02:28:28 +00:00
Andrew Bartlett
df316e3cd9 Remove sam/api.c.
In order to reduce complexity, this patch removes the upper layer of the SAM
API.  Also, we remove the function pointers on the sam context - there really
is no point making these replaceable - that's for the modules.

Move a number of functions in include/interface.c around to allow for use of
'static' and to keep the external API in one chunk, at the bottem.  All these
functions were renamed to remove the context_sam -> sam

Consequential changes in the samtest module, and back out metze's change for
ACB filtering, becouse I think it belongs in the SAM backeds.  (But I will take
debate on this one).

Changes to the lib/util_sid.c code to create a 'system' token, and make it a
SAM_ASSERT() enforced requirement to have a token on those calls that specify
it.  samtest now uses this.

We should have a samtest call to set your own token.

We also need to extend our se_access code to cover the things that Win2k is
returning in it's access tokens.  Currently our system token doesn't pass, due
to unexpected flags.  (When running sam_ads against Win2k)

Andrew Bartlett
(This used to be commit b9036900d0bb227ec16c6a5792c18ef943dcf015)
2002-09-29 06:07:58 +00:00
Andrew Bartlett
0a23b0b4d5 Add const.
(This used to be commit f7dd66e88dba947a167d9a14c96810854dfc5c9d)
2002-09-28 12:11:19 +00:00
Andrew Bartlett
3cfd42e83b Add const.
(This used to be commit 0f5d18626bebaa0621ee703ea2cc8bf47e14ea3e)
2002-09-28 00:12:49 +00:00
Andrew Bartlett
5f662896aa Vance picked up a pile of typos etc at the CIFS confernce, and finally got them
off his laptop :-)

Andrew Bartlett
(This used to be commit df8f0338fae01e5edc176708c2b798c67c2e8c36)
2002-09-27 05:29:43 +00:00
Andrew Bartlett
55b6cebbd4 Some small cleanups to the libads code (mainly error checking), and give a
sane prototype for the push_utf8_allocate code.

Andrew Bartlett
(This used to be commit ce00a3238ed8a82639c4d0ee3e960f7000b1a7b0)
2002-09-27 03:05:20 +00:00
Andrew Bartlett
ad514000db Patch from "Stefan (metze) Metzmacher" <metze@metzemix.de> to do a *much*
better job of working with usrmgr.   Previously we were blanking out entires,
and all sort of mischif.

The new patch (which I've now had a chance to test/modify) also takes care not
to expand % values (ie we go \\%L\%U -> \\server\user, we don't want to store
\\server\user back) and to correctly notice 'not set' compared to 'null string'
etc.

Andrew Bartlett
(This used to be commit ab878b6cc4132594fc33f78aeebf0d8b7266c150)
2002-09-26 10:25:34 +00:00
Andrew Bartlett
8a3bb8b36b Kill of Get_Pwnam_Modify and smb_getpwnam(). The latter assumes some things
that just don't apply any more - now that we always keep username and domain
seperate.  Also, the policy it was trying to permit is now implemented by the
auth code.

Andrew Bartlett
(This used to be commit 760c0740cad948665db4a1d462fbbd99332713ef)
2002-09-25 09:55:41 +00:00
Jeremy Allison
b952ddfbe6 Merge of "profile acls" code.
Jeremy.
(This used to be commit cfd1bf250b417f3ba3ad21ff681ab282311bb7eb)
2002-09-25 05:11:25 +00:00
Jeremy Allison
515c1d42ee Merge back Richard's FreeBSD sendfile fixes.
Jeremy.
(This used to be commit f4845b0213aec58e0f489eba5653aa7b3855610f)
2002-09-21 08:53:05 +00:00
Jeremy Allison
994638f577 HPUX sendfile is now detected correctly.
Jeremy.
(This used to be commit 91e41ebe97c143f413e2a5614b20f3db4642490f)
2002-09-18 20:07:56 +00:00
Jeremy Allison
8b46126a07 Never, *ever* hold a mutex lock in the message database where there may
be traversals being attempted. Yes, this was from bitter experience (and
an out of control server :-). Also allow callers to break out of a tdb_chainlock
with sigalarm if desired.
Jeremy.
(This used to be commit a7781f91d8c1177210bffc199cd2f3b7ff993eaf)
2002-09-17 23:45:21 +00:00
Jeremy Allison
9bab1d0c1a Actually use sendfile if selected.
Jeremy.
(This used to be commit 5881f0a22633ed9fb73e6cd788d0751c4db6cd32)
2002-09-17 19:48:19 +00:00
Jeremy Allison
f74086ccf0 Attempt to make broken Linux sendfile work.... Still in progress.
Jeremy.
(This used to be commit f956a4d29d0d88cd92fac0f0c9f636fc152afe0a)
2002-09-17 01:00:03 +00:00
Jelmer Vernooij
479e82b8d8 Put unixsocket calls between #ifdef HAVE_UNIXSOCKET's - required for Stratus VOS
(Double checked)
(This used to be commit dc3c14fc2b661a62a1876149e96af6de07a2c4a6)
2002-09-15 17:49:53 +00:00
Jeremy Allison
3f02393bfd Use HAVE_SENDFILE64, not SENDFILE64.
Jeremy.
(This used to be commit 7e2f9769c9a7ee5d11267a8a8864371fc0aa8f50)
2002-09-14 01:38:55 +00:00
Jeremy Allison
febd3f929b Added fix for broken Linux (no sendfile64). When offset + count > 2GB
then return ENOSYS and let the upper layer handle it.
Jeremy
(This used to be commit 872dfd87cda585c33c3823b06580cb301567a9b9)
2002-09-14 00:34:46 +00:00
Jeremy Allison
6cf499ecff Fixed up FreeBSD sendfile code - only Solaris left then I can add the
configure tests...
Jeremy.
(This used to be commit 9dad88e1d4d09f61da87dab2633c6e989a9dd77f)
2002-09-12 18:18:35 +00:00
Jeremy Allison
8c5f577c6f HPUX takes offset, not pointer to offset.
Jeremy.
(This used to be commit d7024e8cb94a20cba789deb2c5b70221f6cca4fd)
2002-09-12 06:26:06 +00:00
Jeremy Allison
fdb8c4dfe1 Fixup sendfile to match HPUX semantics with signal interrups. This was
fiddly.... :-(.
Jeremy.
(This used to be commit 2b33a500a8ad13acdd7e4f593aba65229dc8dd96)
2002-09-12 06:24:41 +00:00
Jeremy Allison
4f613ac61e First cut at portable sendfile code. Only used in readX at the moment
and doesn't actually call sendfile. Needs to be vectored through the
VFS and tested on all supported platforms (Solaris/HPUX/FreeBSD/Linux).
Linux doesn't actually work (2.4.19 kernel) at the moment because it
doesn't have a 64-bit clean sendfile.
Jeremy.
(This used to be commit fd772ca7b16cd86e0d50c7ed8d537c202976a6d2)
2002-09-12 02:12:52 +00:00
Andrew Tridgell
cdca2ad1c4 added gencache implementation from mimir - thanks!
(This used to be commit 05a202c287f5daeb1ccbaf9479aa93e7928e93db)
2002-09-11 14:07:21 +00:00
Herb Lewis
dc1c14ca22 lowercase global_myname in %L substitution
(This used to be commit 43a39e85b67c026a5edd93bcd58b76ae67315975)
2002-09-09 21:01:53 +00:00
Simo Sorce
ec4f2af04a configure.in:
reflect the new example/VFS/ directory organization

lib/substitue.c:
added helper functions needed by recycle bin
(This used to be commit 29b4b9a2b5a0347d227b1a30e3f34bf40afa6de4)
2002-09-07 04:08:03 +00:00
Andrew Bartlett
df4e6c9bcc As per the 'OK' at CIFS2002, only use the readline headers (and this crasy
#ifdef mess...) in readline.c, we don't need or use them in the rest of Samba.

(This OK was of course conditional on 'if you break it, you better fix it...')

Andrew Bartlett
(This used to be commit 55ee289f587f107fa03c5f889491fdaab101df2d)
2002-09-06 23:10:28 +00:00
Andrew Bartlett
2d88135714 patch from metze: add a 'vfs' debug class
(This used to be commit 601b56e04fddd9ddfb9be5b0a625d6d279df7f4c)
2002-09-06 11:58:18 +00:00
Jeremy Allison
a1aafce4dc Add bcast_msg_flags to connection struct. Allows sender to filter when
sending broadcast messages. Also initial cut-down of printing notify
messages (not yet finished).
Jeremy.
(This used to be commit aca333719695b278843c59e1c6eb07d6655fd59c)
2002-09-04 19:13:06 +00:00
Jelmer Vernooij
d38ab3857f Fix typo - Thanks Kai
(This used to be commit 8fb4534212e49d2f64f45cbeb481b9f4a69f3158)
2002-09-02 10:58:03 +00:00
Simo Sorce
098b0b40fe wrong way to handle things, bug found by kai
(This used to be commit 58f912da47d18a6a548c50dc9d4298c6bec7ea0d)
2002-09-01 10:24:34 +00:00
Andrew Bartlett
7aca67c3e9 Add a bit of 'const' and move a lot of our 'repeditive' DEBUG() statements to
'DEBUGADD', so we don't repeat headers.  (Makes them much easier to read).

(Based on patch by kai)

Andrew Bartlett
(This used to be commit 9deada345c5f89f338530c4de62835cc1eeb3d0e)
2002-08-31 06:59:00 +00:00
Herb Lewis
dd0d4b5270 based on function prototype, the args were switched - this gave an error
on the IRIX compiler. could whoever put the FIXME message take a look and
see if it is still broken.
(This used to be commit 29a8f2121114cafca07797cadaeb26c9d0055b24)
2002-08-30 14:05:22 +00:00
Jelmer Vernooij
8e729a4d84 Move samr_make_sam_obj_sd to lib/util_seaccess.c. samtest now compiles and
links successfully!
(This used to be commit 0ea4bcb6b772a0d95d20f7c1a2a0c08a0ba9e466)
2002-08-29 16:38:43 +00:00
Jelmer Vernooij
b786c9a2ec Make debuglevel a string for use with debug classes
(This used to be commit fc29385029bf000dc70d23154e39970ee76e4d30)
2002-08-29 16:35:33 +00:00
Jelmer Vernooij
2b2b0f7119 Put in intermediate version of new SAM system. It's not stable yet, code
might be ugly, etc - please don't blame me for anything but instead try to fix
the code :-). Compiling of the new sam system can be enabled with the
configure option --with-sam

Removing passdb/passgrp.c as it's unused
fix typo in utils/testparm.c
(This used to be commit 4b7de5ee236c043e6169f137992baf09a95c6f2c)
2002-08-28 04:54:43 +00:00
Jelmer Vernooij
61e4ee500f Make const
(This used to be commit b1ab3bec8dc7c5d0873b7a4b4c6fab2d7591c9b3)
2002-08-28 04:21:11 +00:00
Tim Potter
f1597ae9d1 Some debugs for panic_action.
(This used to be commit 8f065f788b3af333c7c61236e33b6571b62b0c0d)
2002-08-28 02:11:24 +00:00
Simo Sorce
8f6c926a8f add a trivial seeking function to xfile (tseek) that does not do SEEK_CUR
and add commands reget and reput to smbclient that continues a transfer that has been onterrupted.

thanks to josef Zlomek that did the original patch.
(This used to be commit b275547c9ecc13bede5bd21a392fa1d695a3926d)
2002-08-27 09:07:08 +00:00
Andrew Bartlett
2560c73026 Updates!
- Don't print an uninitialised buffer in service.c
- Change some charcnv.c functions to take smb_ucs2_t ** instead of void **
- Update NTLMv2 code to use dynamic buffers
- Update experimental SMB signing code - still more work to do
- Move sys_getgrouplist() to SAFE_FREE() and do a DEBUG() on initgroups()
  failure.

Andrew Bartlett
(This used to be commit de1964f7fa855022258a84556b266100b917444b)
2002-08-26 03:08:37 +00:00