Jeremy Allison [Thu, 21 Mar 2002 23:39:17 +0000 (23:39 +0000)]
Make winbindd_idmap tdb endian independent. This is very important for
sharing between machines with rsync.
Finally removed tdb_store_int/tdb_fetch_int.
Now only tdb_store_int32/tdb_fetch_int32 which are endian independent
are allowed.
Jeremy.
Jeremy Allison [Thu, 21 Mar 2002 23:19:17 +0000 (23:19 +0000)]
When upgrading from an old idmap tdb, remember to overwrite the reverse
mapping as well as the forward one. Found this in doing the backport to
2.2.x. This is *essential* to upgrade an old idmap file to a new one.
Jeremy.
Herb Lewis [Thu, 21 Mar 2002 22:36:04 +0000 (22:36 +0000)]
merge fix for core dump when called with no args from 2.2
Jeremy Allison [Thu, 21 Mar 2002 21:23:22 +0000 (21:23 +0000)]
Fix stupid typo !
Jeremy.
Herb Lewis [Thu, 21 Mar 2002 14:09:02 +0000 (14:09 +0000)]
add .proto.check
Herb Lewis [Thu, 21 Mar 2002 14:03:41 +0000 (14:03 +0000)]
update usage message with other options. Add a -d debuglevel option
Herb Lewis [Thu, 21 Mar 2002 14:01:57 +0000 (14:01 +0000)]
must use native endian index when creating default valid.dat table so it
is the same on big and little endian systems.
Herb Lewis [Thu, 21 Mar 2002 14:00:13 +0000 (14:00 +0000)]
return . and .. first in readdir - this fixes masktest on IRIX which
returns . then single letter files then .. then all other files.
Andrew Bartlett [Thu, 21 Mar 2002 11:54:43 +0000 (11:54 +0000)]
There is no reason we can't join a domain with secuirty=user. In fact we
need to when we are a BDC or a PDC doing a self-join.
Andrew Bartlett
Andrew Tridgell [Thu, 21 Mar 2002 04:48:24 +0000 (04:48 +0000)]
make net ads info work with -S
Tim Potter [Thu, 21 Mar 2002 04:25:31 +0000 (04:25 +0000)]
Compile fix for --with-profiling-data
Andrew Bartlett [Thu, 21 Mar 2002 04:00:25 +0000 (04:00 +0000)]
Don't leak memory on failure.
Andrew Bartlett [Thu, 21 Mar 2002 03:53:44 +0000 (03:53 +0000)]
Make sure to initaliase SAM_ACCOUNT pointers to NULL, otherwise pdb_init_sam()
fails.
Andrew Bartlett
Andrew Tridgell [Thu, 21 Mar 2002 02:28:23 +0000 (02:28 +0000)]
fixed the secondary group mappings for ADS users
Gerald Carter [Wed, 20 Mar 2002 23:09:34 +0000 (23:09 +0000)]
merge from APPLIANCE_HEAD
Jeremy Allison [Wed, 20 Mar 2002 22:39:30 +0000 (22:39 +0000)]
Ensure we don't do lp_servicename()'s in tdb traverse as this
allocates lots of memory.
Jeremy.
Jeremy Allison [Wed, 20 Mar 2002 21:55:57 +0000 (21:55 +0000)]
Print queue entries *must* have queue names, not numbers - numbers are
not identical between different smbds (mr potter, come here and take
your medicine.... :-).
Jeremy.
Jeremy Allison [Wed, 20 Mar 2002 21:08:19 +0000 (21:08 +0000)]
John's patch changed the size of a structure stored in the tdb - we
must thus update the versionid of the tdb.
Jeremy.
Jeremy Allison [Wed, 20 Mar 2002 19:29:06 +0000 (19:29 +0000)]
HEAD only fix for truncate from Alexander Bokovoy <a.bokovoy@sam-solutions.net>.
This code needs replacing with the trans2.c from 2.2.x.
Jeremy.
Andrew Bartlett [Wed, 20 Mar 2002 12:05:10 +0000 (12:05 +0000)]
Make ldapsam compile again.
Jeremy Allison [Wed, 20 Mar 2002 07:20:38 +0000 (07:20 +0000)]
BUFFER_SIZE Should be 128k if large read write tests are to work.
Jeremy.
Martin Pool [Wed, 20 Mar 2002 06:57:03 +0000 (06:57 +0000)]
Add assertions that kill() is never accidentally passed a non-positive
pid. This follows a bug in rsync where it would accidentally
kill(-1), removing all the user's processes. I can't see any way this
would directly happen in Samba, but having the assertions seems
beneficial.
http://cvs.samba.org/cgi-bin/cvsweb/rsync/util.c.diff?r1=1.108&r2=1.109&f=h
Tim Potter [Wed, 20 Mar 2002 06:29:23 +0000 (06:29 +0000)]
Actually use flags passed in PYTHON_CFLAGS variable.
Use py_common.c in winbind extension module for correct initialisation.
Some reformatting.
Tim Potter [Wed, 20 Mar 2002 06:27:41 +0000 (06:27 +0000)]
Added enum domain users and enum domain groups.
Tim Potter [Wed, 20 Mar 2002 04:58:38 +0000 (04:58 +0000)]
Pass $(CFLAGS) and $(CPPFLAGS) to python compile instead of $(FLAGS)
Tim Potter [Wed, 20 Mar 2002 04:53:44 +0000 (04:53 +0000)]
Added name_to_sid and sid_to_name functions.
Tim Potter [Wed, 20 Mar 2002 04:51:40 +0000 (04:51 +0000)]
Remove nsswitch from include directories.
Tim Potter [Wed, 20 Mar 2002 03:54:47 +0000 (03:54 +0000)]
Cache call to winbind separator.
Some random reformatting and cleanup.
Display output of wbinfo -s using actual winbind separator.
Gerald Carter [Wed, 20 Mar 2002 03:37:27 +0000 (03:37 +0000)]
resetprinter merge from SAMBA_2_2
Tim Potter [Wed, 20 Mar 2002 03:32:44 +0000 (03:32 +0000)]
Ignore autogenerated setup.py
Tim Potter [Wed, 20 Mar 2002 03:29:03 +0000 (03:29 +0000)]
Initial version.
Jeremy Allison [Wed, 20 Mar 2002 01:47:31 +0000 (01:47 +0000)]
Correctly increment offset in cli_smbwrite.
Jeremy.
Andrew Bartlett [Wed, 20 Mar 2002 01:46:40 +0000 (01:46 +0000)]
Allow a zero rid in pdb_smbpasswd. When given a zero rid the pdb backend
should chose the next available RID. For smbpasswd it just means using the algorithm, but other backends can do somthing more useful.
Andrew Bartlett
Jeremy Allison [Wed, 20 Mar 2002 01:43:06 +0000 (01:43 +0000)]
Test against W2K that we're doing large read/writes correctly (we are).
At least with 14 word writes.
Jeremy.
Jeremy Allison [Wed, 20 Mar 2002 00:58:23 +0000 (00:58 +0000)]
Ensure we get a real fd when opening for set file allocation.
Jeremy.
Tim Potter [Wed, 20 Mar 2002 00:56:36 +0000 (00:56 +0000)]
Merge of Richard's lookupsid fix.
Jeremy Allison [Wed, 20 Mar 2002 00:49:44 +0000 (00:49 +0000)]
Fix for debug typo.
Jeremy Allison [Wed, 20 Mar 2002 00:46:53 +0000 (00:46 +0000)]
Remove the "stat open" code - make it inline. This should fix the
bugs with opening and renaming mp3 files, also the word rename
problems that people have had for a while.
Needs a make clean :-) make.
Also added JohnR's printing fix.
Jeremy.
Tim Potter [Wed, 20 Mar 2002 00:24:35 +0000 (00:24 +0000)]
Merge from app-head:
> Don't put two copies of the server name in construct_printer_info_1()
Tim Potter [Tue, 19 Mar 2002 23:36:06 +0000 (23:36 +0000)]
Patch to configure.in and Makefile.in for Python extensions.
Jeremy Allison [Tue, 19 Mar 2002 23:33:32 +0000 (23:33 +0000)]
Merge JohnR's fix.
Jeremy.
Andrew Tridgell [Tue, 19 Mar 2002 23:19:00 +0000 (23:19 +0000)]
the beginning of a test to determine and display a servers properties
just shows capabilities at the moment
Tim Potter [Tue, 19 Mar 2002 22:55:21 +0000 (22:55 +0000)]
setup.py for samba python wrappers
Andrew Tridgell [Tue, 19 Mar 2002 22:16:19 +0000 (22:16 +0000)]
make "net ads user" and "net ads group" also use the new paged interface
Andrew Tridgell [Tue, 19 Mar 2002 22:15:32 +0000 (22:15 +0000)]
updated winbindd to used paged ldap searches for all ldap queries
Andrew Tridgell [Tue, 19 Mar 2002 22:14:53 +0000 (22:14 +0000)]
added a ads_do_search_all() call, which is a more convenient interface
to paged searches. This makes updating winbindd to used paged searches
trivial.
Simo Sorce [Tue, 19 Mar 2002 13:57:53 +0000 (13:57 +0000)]
second step to gain free uid<->rid mapping
we still need to free gid<->rid mapping and few other stuff
Andrew Tridgell [Tue, 19 Mar 2002 12:58:38 +0000 (12:58 +0000)]
fixed paged controls on my box. The problem seems to be incorrect
referrals parsing in the openldap libs. By disabling referrals we get
valid controls back and the cookies work.
Martin Pool [Tue, 19 Mar 2002 12:13:02 +0000 (12:13 +0000)]
Take out autobuild dependency on proto.h; breaks some proprietary Makes.
Martin Pool [Tue, 19 Mar 2002 11:46:31 +0000 (11:46 +0000)]
Refactor for systems like Solaris that cannot handle wildcards on the
right side of a dependency line.
Martin Pool [Tue, 19 Mar 2002 07:26:18 +0000 (07:26 +0000)]
Change the Makefile to rebuild proto.h as necessary -- note that this
does not imply that all source will be rebuilt when prototypes change,
merely that the prototypes will be updated.
make proto, clean, delheaders, headers, etc all behave equivalently to
before.
Intended new behaviour for proto.h, whenever source is being
compiled:
If proto.h does not exist, it is built.
If any source files have changed since proto.h was last checked
(.proto.check), then proto.h is checked. If there are no actual
changes since last time, its mtime is not changed, but we do
remember the time at which it was checked.
Whenever we try to build a .o, we need to check the headers are up
to date. However, rebuilding the prototypes does not imply
rebuilding all object files.
Also to allow people to build on machines without Awk, we never try
to use it unless a source file has changed. I guess if we wanted,
we could have lack of Awk only cause a warning, not failure.
The point of all of this is to be easier on people who don't
understand or forget to type "make proto", and to reduce the chance of
build breakage by having prototypes out of sync.
I also rolled back JF's changes to put proto.h into builddir rather
than srcdir. There are good arguments in both directions, but since
we keep proto.h in CVS, it seems important that the up-to-date copy by
in srcdir where it can be checked back in. If people are fussed about
having srcdir be readonly you could change this -- but since proto.h
is only rebuilt when there are changes, it's not a big deal.
I also fixed an apparent race condition in "make headers" that would
make it unsafe if you did 'make -j2', and made 'make clean' not kill
proto.h, since people may not be able to rebuild it.
I reckon there's nothing gnumake-specific here but we shall see.
I also have this great idea about rewriting libtool in C++...
Andrew Bartlett [Tue, 19 Mar 2002 06:36:37 +0000 (06:36 +0000)]
Fix a double-free bug in wbinfo -t's call in winbindd.
I forgot to clean this up when netlogon move across to the connection cache
arrangement.
Also add some smb_panics to the connection_ok() code to try to catch this kind
of thing better in future.
Andrew Bartlett
Tim Potter [Tue, 19 Mar 2002 05:35:06 +0000 (05:35 +0000)]
Don't try to sort a list of zero length in internal_resolve_name()
Jeremy Allison [Tue, 19 Mar 2002 02:51:48 +0000 (02:51 +0000)]
Sync up the VFS changes from 2.2.x.
Jeremy.
Jeremy Allison [Tue, 19 Mar 2002 02:35:12 +0000 (02:35 +0000)]
Merge in JohnR's page count fixes.
Jeremy.
Jeremy Allison [Tue, 19 Mar 2002 02:32:39 +0000 (02:32 +0000)]
Sync up vfs changes from 2.2.x.
Jeremy.
Simo Sorce [Tue, 19 Mar 2002 00:06:24 +0000 (00:06 +0000)]
ops forgot this :-)
Simo Sorce [Mon, 18 Mar 2002 23:57:14 +0000 (23:57 +0000)]
more verbose checking in talloc and util_pw
fixed tdbsam memory corruption (and segfault)
reducing calls to pdb_uid_to_user_rid and countrary to 0 to move to a non alghoritmic rid allocation with some passdb modules.
Simo Sorce [Mon, 18 Mar 2002 11:35:53 +0000 (11:35 +0000)]
Start to switch away from the alghorithmic uid->rid mapping model
Andrew Bartlett [Mon, 18 Mar 2002 10:53:02 +0000 (10:53 +0000)]
Allow us to see the difference between these two errors. (We need to chase
down some bugs with it...).
Andrew Bartlett
Samba Release Account [Mon, 18 Mar 2002 03:33:19 +0000 (03:33 +0000)]
preparing for release of 3.0-alpha17
John Terpstra [Sun, 17 Mar 2002 22:40:51 +0000 (22:40 +0000)]
Fix ability to compile with CUPS support.
Tim Potter [Sun, 17 Mar 2002 06:04:15 +0000 (06:04 +0000)]
Added dos_errstr() function. Not all errors in list yet.
Tim Potter [Sun, 17 Mar 2002 04:36:35 +0000 (04:36 +0000)]
Renamed get_nt_error_msg() to nt_errstr().
Jim McDonough [Sat, 16 Mar 2002 01:30:09 +0000 (01:30 +0000)]
Fix build for non-ads case
Jim McDonough [Sat, 16 Mar 2002 01:14:58 +0000 (01:14 +0000)]
Don't use // even temporarily, lest ye forget it and check it in...
Jim McDonough [Fri, 15 Mar 2002 22:10:19 +0000 (22:10 +0000)]
Change new style join function name for clarity in net_rpc.c
Jim McDonough [Fri, 15 Mar 2002 22:09:18 +0000 (22:09 +0000)]
Change net rpc join several ways: \n\t1) expose \n\t2) eliminate oldstyle subcommand \n\t3) try oldstyle first, then more secure method\n to allow for autodetect between ads and rpc on net join
Jim McDonough [Fri, 15 Mar 2002 22:05:39 +0000 (22:05 +0000)]
Expose net_ads_join to allow for auto-transport-detection for net join
Jim McDonough [Fri, 15 Mar 2002 22:04:53 +0000 (22:04 +0000)]
Add autodetect for net join, as well as some more help updates
Jim McDonough [Fri, 15 Mar 2002 20:03:07 +0000 (20:03 +0000)]
Some help cleanups. Formatting and consistency issues. Line up text nicely, and make 'net help rap user' the same as 'net rap user help'...stuff like that
Andrew Tridgell [Fri, 15 Mar 2002 09:51:37 +0000 (09:51 +0000)]
if our lock spin code fails then return the first error code, not the
last one. This is what caused the lock1 and lock2 tests to fail.
Andrew Tridgell [Fri, 15 Mar 2002 09:24:56 +0000 (09:24 +0000)]
the SEC_DOMAIN tests also apply to SEC_ADS
Andrew Tridgell [Fri, 15 Mar 2002 09:23:24 +0000 (09:23 +0000)]
nicer output from "net rpc user add"
Andrew Tridgell [Fri, 15 Mar 2002 09:21:28 +0000 (09:21 +0000)]
enable locking on the winbindd cache tdb so it can be backed up and
manipulated externally
Andrew Tridgell [Fri, 15 Mar 2002 09:20:36 +0000 (09:20 +0000)]
added a -h usage option to winbindd
Andrew Tridgell [Fri, 15 Mar 2002 09:19:51 +0000 (09:19 +0000)]
this tdb was being opened without locking, which is unsafe for shared
databases
Andrew Tridgell [Fri, 15 Mar 2002 09:19:07 +0000 (09:19 +0000)]
lower the debug level of failing to map a file
Gerald Carter [Fri, 15 Mar 2002 08:14:10 +0000 (08:14 +0000)]
syncing up printing code with SAMBA_2_2 (already done some merges
in the reverse).
* add in new printer change notify code from SAMBA_2_2
* add in se_map_standard() from 2.2 in _spoolss_open_printer_ex()
* sync up the _print_queue_struct in smb.h (why did someone change the
user/file names in fs_user/fs_file (or vice-versa) ? )
* sync up some cli_spoolss_XXX functions
Andrew Bartlett [Thu, 14 Mar 2002 22:52:19 +0000 (22:52 +0000)]
Actually include some *information* in the mangle debug messages.
In particular this shows the filename, prefix and counters involved.
The unicode -> unix converion only occours for the error case.
Andrew Bartlett
Jim McDonough [Thu, 14 Mar 2002 17:56:33 +0000 (17:56 +0000)]
Add paged search requests to net ads user and net ads group commands, allowing more than 1000 (or whatever the query limit is on the server) objects to be returned. Printers will come next.
Jim McDonough [Thu, 14 Mar 2002 17:48:26 +0000 (17:48 +0000)]
This adds the Paged Result Control to ads searching. The new function, ads_do_paged_search, is the same as ads_do_search, but it also contains a count of records returned in this page, and a cookie for resuming, to be passed back. The cookie must start off NULL, and when it returns as NULL, the search is done.
Tim Potter [Thu, 14 Mar 2002 02:48:03 +0000 (02:48 +0000)]
Remove studly gaps from prs_werror() calls so the same debug text is
logged. This makes it much easier to use grep on log files when searching
for errors.
Jeremy Allison [Thu, 14 Mar 2002 02:15:08 +0000 (02:15 +0000)]
Now we have reliable signals take SIGTERM inband.
Jeremy.
Tim Potter [Thu, 14 Mar 2002 01:53:04 +0000 (01:53 +0000)]
getpid() -> sys_getpid()
Tim Potter [Thu, 14 Mar 2002 01:48:59 +0000 (01:48 +0000)]
Backed out enumprinters stuff - leave it for another day.
Jeremy Allison [Thu, 14 Mar 2002 01:05:34 +0000 (01:05 +0000)]
Use sys_usleep not usleep.
Jeremy.
Jeremy Allison [Thu, 14 Mar 2002 00:58:53 +0000 (00:58 +0000)]
Get the current directory after becoming root.
Jeremy.
Tim Potter [Wed, 13 Mar 2002 22:55:47 +0000 (22:55 +0000)]
Fixed bodgy printf arguments in debug statment.
Who would have guessed it - we now use floating point maths in Samba.
Jeremy Allison [Wed, 13 Mar 2002 20:49:57 +0000 (20:49 +0000)]
Ensure we attempt to lock at least once. Only sleep if time param set.
Jeremy.
Jeremy Allison [Wed, 13 Mar 2002 20:28:19 +0000 (20:28 +0000)]
include/smb_macros.h: Don't round up an allocation if the size is zero.
"One of these locks is not like the others... One of these locks is not
quite the same" :-). When is a zero timeout lock not zero ? When it's
being processed by Windows 2000 of course.. This code change, ugly though
it is - completely fixes the foxpro/access multi-user file system database
problems that people have been having. I used a *wonderful* test program
donated by "Gerald Drouillard" <gerald@drouillard.ca> which allowed me
to completely reproduce this problem, and to finally determine the correct
fix. This also explains why Windows 2000 is *so slow* when responding to
the smbtorture lock tests. I *love* it when all these things come together
and finally make sense :-).
Jeremy.
Andrew Tridgell [Wed, 13 Mar 2002 06:43:52 +0000 (06:43 +0000)]
detect SIZELIMIT_EXCEEDED in ldap queries and truncate
the problem is, how the heck do we properly handle these? Jerry?
It seems that the Win2000 ADS server only returns a max of 1000 records!
Andrew Bartlett [Wed, 13 Mar 2002 01:51:01 +0000 (01:51 +0000)]
Ensure we never use "" as a domain name (Win9X apparently does this for 'net use' duirng login).
Picked up from a post to a TNG list by Volker.
Andrew Bartlett
Jeremy Allison [Wed, 13 Mar 2002 01:29:30 +0000 (01:29 +0000)]
Add "Creator Group" - was in 2.2.x and I'm syncing up the two.
Jeremy.
Andrew Bartlett [Wed, 13 Mar 2002 01:26:59 +0000 (01:26 +0000)]
Fix typo in copyright
Andrew Bartlett [Wed, 13 Mar 2002 01:25:36 +0000 (01:25 +0000)]
I don't need my name on this twice :-)
Andrew Bartlett [Wed, 13 Mar 2002 01:21:02 +0000 (01:21 +0000)]
Move the directory creation process outside the 'installbin.sh' script, and
into its own. The 'installdirs' makefile entry didn't do anything on my laptop,
so it has been replaced with the section from installbin.sh.
This also fixes the bug that we ignored the setting of $(PRIVATEDIR) when
making the directories.
Finally, link pam_winbind with .po objects only, not a mix of .o and .po
(as per Don Mccall's request).
Andrew Bartlett
Jeremy Allison [Wed, 13 Mar 2002 00:47:26 +0000 (00:47 +0000)]
Remove a stub function I forgot to fill in.
Jeremy.
Andrew Tridgell [Wed, 13 Mar 2002 00:30:26 +0000 (00:30 +0000)]
if we know that the SID is local then don't try via winbindd
Andrew Tridgell [Wed, 13 Mar 2002 00:19:40 +0000 (00:19 +0000)]
fixed mapping of SIDs for local users