cvs2svn Import User [Wed, 30 Jan 2002 12:12:17 +0000 (12:12 +0000)]
This commit was manufactured by cvs2svn to create tag
'release-3-0-alpha14'.
Samba Release Account [Wed, 30 Jan 2002 12:12:16 +0000 (12:12 +0000)]
preparing for release of 3.0-alpha14
Andrew Bartlett [Wed, 30 Jan 2002 12:06:22 +0000 (12:06 +0000)]
Back out herb's changes (to allow smbpasswd -x to work on accounts outside
/etc/passwd) and replace them with a version that works. Unfortunetly HEAD and
2.2 have different passdb interfaces and different local_password_change
functions...
Andrew Bartlett
Andrew Bartlett [Wed, 30 Jan 2002 10:50:07 +0000 (10:50 +0000)]
An attempt at producing the correct Makefile magic for wrepld_proto.h to be
automatically generated on first 'make'. This wasn't being picked up by the
build farm becouse of the explicit 'make proto'.
The 'make proto' bit isn't somthing our alpha testers know about (its certainly
not clearly documented) and its meant to be automatic.
I hope this works...
Andrew Bartlett
Tim Potter [Wed, 30 Jan 2002 06:10:09 +0000 (06:10 +0000)]
Addd wrepld (what a cool name!)
Tim Potter [Wed, 30 Jan 2002 06:09:48 +0000 (06:09 +0000)]
Added wrepld_proto.h
Tim Potter [Wed, 30 Jan 2002 06:08:46 +0000 (06:08 +0000)]
Removed version number from file header.
Changed "SMB/Netbios" to "SMB/CIFS" in file header.
Tim Potter [Wed, 30 Jan 2002 05:49:20 +0000 (05:49 +0000)]
Unused file.
Gerald Carter [Wed, 30 Jan 2002 05:45:09 +0000 (05:45 +0000)]
merge from 2.2
Herb Lewis [Wed, 30 Jan 2002 04:07:42 +0000 (04:07 +0000)]
merge change from @_2 to allow smbpasswd -x to delete user even if no
entry in /etc/passwd.
There are still differences in the local_password_change function. I'm
not sure which was the latest so I didn't change any thing else. Someone
needs to take a look and sync these up.
Tim Potter [Wed, 30 Jan 2002 03:23:40 +0000 (03:23 +0000)]
Fix for password change from Samuel Ziegler <sam@xpedion.com>
Tim Potter [Wed, 30 Jan 2002 03:14:20 +0000 (03:14 +0000)]
Removed silly fprintf(stderr, ...) debug.
Part of Samuel Ziegler's patch to get winbind password changing working
again in HEAD.
Martin Pool [Tue, 29 Jan 2002 05:34:16 +0000 (05:34 +0000)]
Doc.
Jeremy Allison [Tue, 29 Jan 2002 01:17:44 +0000 (01:17 +0000)]
Fix "strict allocate" to write the data out on ftruncate with extend.
Jeremy.
Tim Potter [Tue, 29 Jan 2002 01:01:14 +0000 (01:01 +0000)]
Since we have dynamic initialisation in the group mapping code, make
init_group_mapping() a static function and don't call it from any client
programs.
Not sure whether I've made a bigger mess here or not...
Gerald Carter [Mon, 28 Jan 2002 17:36:33 +0000 (17:36 +0000)]
make all-docs to make sure everything is up-to-date
Andrew Bartlett [Mon, 28 Jan 2002 00:54:37 +0000 (00:54 +0000)]
Name another talloc.
Simo Sorce [Sun, 27 Jan 2002 16:37:12 +0000 (16:37 +0000)]
minor fix and checks
Andrew Bartlett [Sun, 27 Jan 2002 12:12:22 +0000 (12:12 +0000)]
Some more 'winbind default domain' support patches from Alexander Bokovoy
<a.bokovoy@sam-solutions.net>.
This patch is designed to remove the 'special cases' required for this support.
In particular this now kills off winbind_initgroups, as it appears no longer to
be required.
Andrew Bartlett
Andrew Bartlett [Sun, 27 Jan 2002 12:06:27 +0000 (12:06 +0000)]
Yes, dev is an 'input/output' paramater...
Andrew Bartlett
Andrew Bartlett [Sun, 27 Jan 2002 10:53:43 +0000 (10:53 +0000)]
Patch from Kevin Stefanik <kstef@mtppi.org> to do some more error checking for
group mapping init failures.
Gerald Carter [Sun, 27 Jan 2002 05:37:23 +0000 (05:37 +0000)]
merge from 2.2 and regenerate
Andrew Bartlett [Sun, 27 Jan 2002 03:00:56 +0000 (03:00 +0000)]
Give pdbedit a -D paramater for setting the DEBUGLEVEL (makes debugging passdb
much saner :-).
Change to pdb_init_sam()/pdb_free_sam() loop rather than reset based due to
the talloc basis.
Andrew Bartlett
Gerald Carter [Sat, 26 Jan 2002 22:27:12 +0000 (22:27 +0000)]
merge from APPLIANCE_HEAD
Andrew Bartlett [Sat, 26 Jan 2002 12:24:18 +0000 (12:24 +0000)]
- Provide sid->name lookup support for non-unix accounts.
- Rework the name -> sid lookup function to always try local lookup first (for
local domain names) before trying winbind. This seems to eliminate my winbind
feedback loop problems. (I don't use winbind for nsswitch, where there are
almost certainly further issues).
Andrew Bartlett
Andrew Bartlett [Sat, 26 Jan 2002 11:48:42 +0000 (11:48 +0000)]
Back out some of the less well thought out ideas from last weeks work on
winbind default domains, particulary now I understand whats going on a lot
better. This ensures that the RPC client code does as little 'magic' as
possible - this is up to the application/user. (Where - for to name->sid code
- it was all along). This leaves the change that allows the sid->name code to
return domains and usernames in seperate paramaters.
Andrew Bartlett
Andrew Bartlett [Sat, 26 Jan 2002 10:10:25 +0000 (10:10 +0000)]
Bring this code into line with new winbind_lookup_name() interface. I think
this might need a bit more work - or at least documentation.
This is certainly a worthwile little hack, as it avoids the need to invert the
group database. I don't think we should allow unqualified domains here - as
that allows us to distinguish between (at least some) usernames and these
'special' groups.
Andrew Bartlett [Sat, 26 Jan 2002 10:06:23 +0000 (10:06 +0000)]
Make a talloc'ed copy of this strings so we can pass the right kind of pointer
to the function. This fixes a nice little segfault the brute-force-casting
created. :-)
Andrew Bartlett
Andrew Bartlett [Sat, 26 Jan 2002 10:05:10 +0000 (10:05 +0000)]
Rework lookup_name() to take seperate username/domain args, and to remove
varioius crazy 'if winbind didn't find it' cases. This makes winbind default
domain support easier to intergrate with smbd.
Andrew Bartlett [Sat, 26 Jan 2002 10:03:25 +0000 (10:03 +0000)]
Add the become_root()/unbecome_root() wrapper around the lookup_name() call,
and its new args.
Andrew Bartlett [Sat, 26 Jan 2002 10:02:23 +0000 (10:02 +0000)]
Move the lsa code across to the changed args for lookup_name, and surround it
in become_root()/unbecome_root().
Also only allocate the memory the client reqests - and don't allow the client
to trigger an SMB_ASSERT if they ask for 'more'.
Up the maximum number of sids allowed, and note that this is an arbiary guess,
and can be raised without consequence.
Andrew Bartlett
Andrew Bartlett [Sat, 26 Jan 2002 09:58:11 +0000 (09:58 +0000)]
We may as well not use these temporary variables - they are only used once and
just make it harder to debug (gcc stips optomises them away).
Andrew Bartlett [Sat, 26 Jan 2002 09:56:47 +0000 (09:56 +0000)]
local_lookup_name() doens't acutally use its 'domain' argument, so drop it and
make its use clearer.
Andrew Bartlett [Sat, 26 Jan 2002 09:55:38 +0000 (09:55 +0000)]
Change the winbind interface to use seperate 'domain' and 'username' feilds for
the sid->uid and uid->sid conversions.
Remove some duplicate arguments from these funcitons, and update the
request/response structures for this and the 'winbind domain name' feature.
As such 'winbindd_lookup_name' now takes both a domain and username.
Andrew Bartlett [Sat, 26 Jan 2002 09:52:55 +0000 (09:52 +0000)]
Allow a winbind client to obtain the server's domain name.
Andrew Bartlett [Sat, 26 Jan 2002 09:50:28 +0000 (09:50 +0000)]
Remove the 'direct to winbind' hacks, as they should (if I understand
correctly) be no longer needed. This is in aid of the 'winbind default domain'
code - which works much better when smbd always goes via the standard unix
interfaces.
Andrew Bartlett
Andrew Bartlett [Sat, 26 Jan 2002 06:28:50 +0000 (06:28 +0000)]
This always points at a string literal, so it probably should be 'const'.
Andrew Bartlett [Sat, 26 Jan 2002 06:24:53 +0000 (06:24 +0000)]
Fix up a security issue with the way we handle domain groups retuned on the
info3. These are RIDs, and it only makes sense to combine them with the domain
SID returned with them. This is important for trusted domains, where that sid
might be other than the one we currently reterive from the secrets.tdb.
Also remove the become_root()/unbecome_root() wrapper from around both
remaining TDB users: Both are now initialised at smbd startup.
Andrew Bartlett
Andrew Bartlett [Sat, 26 Jan 2002 06:18:59 +0000 (06:18 +0000)]
fix typo
Andrew Bartlett [Sat, 26 Jan 2002 06:16:36 +0000 (06:16 +0000)]
The new plugable password backend system needs to be initialised after
lp_load().
Andrew Bartlett
Andrew Bartlett [Sat, 26 Jan 2002 06:02:28 +0000 (06:02 +0000)]
These changes commited on a 'no less broken' basis.
The previous code attempted to call winbind to find out the domain sid. This
couldn't work for a number of reasons - not the least of which was that both
the client and server ends would reject any name (in this case domain name)
without a \ in it (or lp_winbind_seperator()).
I think this is what was intended to occour. If there is still some need to
contact winbind for this information, I suggest a new call be created for this
- as it the server-side code doesn't allow for this information to be extracted
easily in any case.
Finally, it gets in the way of the default domain code a bit - hence why I was
actually looking at it...
Andrew Bartlett
Andrew Bartlett [Sat, 26 Jan 2002 05:53:07 +0000 (05:53 +0000)]
Try to get the compiler not to complain about assignments and truth values...
Andrew Bartlett
Andrew Bartlett [Sat, 26 Jan 2002 05:52:20 +0000 (05:52 +0000)]
Try to move towards slightly sane linking for Samba by removing some pdb_...()
calls from rpc_parse/parse_net.c - instead these values are passed as a
paramater.
Unfortunetly some there is still some samr work to be done before this is
actually useful.
Andrew Bartlett
Andrew Bartlett [Sat, 26 Jan 2002 01:52:52 +0000 (01:52 +0000)]
Add some information tidbits to an error DEBUG().
Jeremy Allison [Sat, 26 Jan 2002 01:20:38 +0000 (01:20 +0000)]
Fixed ADDPRINTEREX to take a devmode and a security descriptor...
Jeremy.
Jean-François Micouleau [Fri, 25 Jan 2002 22:53:49 +0000 (22:53 +0000)]
that's the wins replication daemon !
there are still some work to do on it but it's already functionnal.
J.F.
Jean-François Micouleau [Fri, 25 Jan 2002 22:50:15 +0000 (22:50 +0000)]
rewrote nmbd's wins backend to use a tdb instead of a flat text file.
Changed the way the wins record are handled in memory. Now they are living
much longer with the different states: active, released and tombstone.
Also added a version ID, some wins flags and the wins owner ip address to
the namrec->data struct, and a function to process messages sent by the
wins replication daemon.
the initiate_wins_processing() function is not correct, I'll fix it later.
J.F.
Andrew Bartlett [Fri, 25 Jan 2002 22:44:21 +0000 (22:44 +0000)]
Change this code so that we don't do a lookup_name() on root.
This matches the lookup failure case in 2.2, and seems to make more sense than
giving the printer to 'world'. (Avoiding this lookup makes some of my other
changes - including winbind default domains - a little easier).
In any case, tpot has promised to look at this and test it when he gets back to
work. :-)
Andrew Bartlett
Jim McDonough [Fri, 25 Jan 2002 22:07:46 +0000 (22:07 +0000)]
Enable net ads commands to use existing tickets if the user doesn't specify a username on the commandline. Also don't continue past the kinit if a password is entered and fails because existing tickets would be used, which may not be desired if the username was specified.
Jeremy Allison [Fri, 25 Jan 2002 20:16:14 +0000 (20:16 +0000)]
Fixed display of "remote downlevel document" in old print job submission
case.
Jeremy.
Jeremy Allison [Fri, 25 Jan 2002 18:27:40 +0000 (18:27 +0000)]
Make systemtime work for spooling on bigendian systems. Fix from
Benjamin (Bj) Kuit bj@it.uts.edu.au.
Jeremy.
Jean-François Micouleau [Fri, 25 Jan 2002 17:04:47 +0000 (17:04 +0000)]
new message type for nmbd
J.F.
Jean-François Micouleau [Fri, 25 Jan 2002 17:03:36 +0000 (17:03 +0000)]
remove unused variable
J.F.
Jean-François Micouleau [Fri, 25 Jan 2002 17:02:54 +0000 (17:02 +0000)]
picky about realloc
J.F.
Gerald Carter [Fri, 25 Jan 2002 15:47:12 +0000 (15:47 +0000)]
merge from 2.2
Andrew Bartlett [Fri, 25 Jan 2002 11:44:15 +0000 (11:44 +0000)]
Passdb changes:
Modules now name themselves, which should allow for sane behaviour when we get
an 'extern' passdb module (which in turn loads a .so).
Fix up tdbsam for non-unix-accounts. Not sure if this fixes idra's bug, but
its a start...
Andrew Bartlett
Andrew Bartlett [Fri, 25 Jan 2002 10:38:00 +0000 (10:38 +0000)]
Fix a 'const' warning.
Andrew Bartlett [Fri, 25 Jan 2002 10:16:20 +0000 (10:16 +0000)]
Bring auth_winbind into line with the protocol changes
Andrew Bartlett
Simo Sorce [Fri, 25 Jan 2002 09:55:29 +0000 (09:55 +0000)]
micro fix :-)
Tim Potter [Fri, 25 Jan 2002 05:28:38 +0000 (05:28 +0000)]
Removed dodgy init of local variable.
Jeremy Allison [Fri, 25 Jan 2002 05:28:37 +0000 (05:28 +0000)]
Return correct RPC fault PDU on bad handle incoming.
Jeremy.
Tim Potter [Fri, 25 Jan 2002 05:24:07 +0000 (05:24 +0000)]
Much more useful handling of backup domain controllers in winbindd. Honour
the "password server" smb.conf parameter when choosing a DC to connect to.
Due to the origin of the code in cm_get_dc_name() it wouldn't try
additional DCs if the first DC didn't work. This would wedge winbindd if you
had "password server = foo1, foo2" and foo1 was down.
Tim Potter [Fri, 25 Jan 2002 05:17:49 +0000 (05:17 +0000)]
Remove check for passwordserver = "*" as we now initialise it.
Added TODO about perhaps doing a SAMLOGON udp/138 request before a
cli_full_connection in connect_to_domain_password_server()
Tim Potter [Fri, 25 Jan 2002 05:16:40 +0000 (05:16 +0000)]
Initialise password server to "*" in init_globals()
Tim Potter [Fri, 25 Jan 2002 04:26:16 +0000 (04:26 +0000)]
Removed unused static variable.
Simo Sorce [Fri, 25 Jan 2002 00:35:14 +0000 (00:35 +0000)]
minor fixes
Gerald Carter [Thu, 24 Jan 2002 17:04:30 +0000 (17:04 +0000)]
merge from 2.2
Andrew Tridgell [Thu, 24 Jan 2002 13:31:34 +0000 (13:31 +0000)]
handle filenames like .bashrc better in the new mangling code
Jim McDonough [Wed, 23 Jan 2002 18:09:56 +0000 (18:09 +0000)]
Check request flag for unicode capability and respond accordingly, rather than only doing unicode. smbfs didn't work.
Andrew Bartlett [Wed, 23 Jan 2002 13:44:32 +0000 (13:44 +0000)]
Oops...
Andrew Bartlett [Wed, 23 Jan 2002 12:59:24 +0000 (12:59 +0000)]
getpwnam -> getpwnam_alloc.
idra has promised not to revert these this time :-)
Andrew Bartlett [Wed, 23 Jan 2002 11:57:11 +0000 (11:57 +0000)]
Change the order of this a bit - as unix password change can fail.
This due for abstraction into chgpasswd.c shortly.
Andrew Bartlett
Tim Potter [Wed, 23 Jan 2002 11:47:19 +0000 (11:47 +0000)]
Sync up startpageprinter with appliance.
Gerald Carter [Wed, 23 Jan 2002 05:10:27 +0000 (05:10 +0000)]
merge from 2.2
Jeremy Allison [Tue, 22 Jan 2002 19:45:17 +0000 (19:45 +0000)]
Merge of fixes from 2.2.
Jeremy.
Gerald Carter [Tue, 22 Jan 2002 18:19:00 +0000 (18:19 +0000)]
merge from appliance_head
Gerald Carter [Tue, 22 Jan 2002 18:14:31 +0000 (18:14 +0000)]
merge from 2.2. of
* PRINTER_ATTRIBUTE's
* "default devmode" parameter
Jeremy Allison [Tue, 22 Jan 2002 07:24:12 +0000 (07:24 +0000)]
Ensure fsp->size is correct so readraw's return correct data.
Jeremy.
Martin Pool [Tue, 22 Jan 2002 05:11:28 +0000 (05:11 +0000)]
Add more string explanations of RAP errors that are already documented
in clirap2.
Martin Pool [Tue, 22 Jan 2002 03:51:28 +0000 (03:51 +0000)]
We have to do some initialization before the string conversion
routines can work. The code was copied into both convert_string and
convert_string_allocate -- I split it into a little static function,
and removed an apparently duplicate call to init_valid_table().
Tim Potter [Tue, 22 Jan 2002 00:38:36 +0000 (00:38 +0000)]
Raise log level of warning produced when the open() of the tdb fails.
Sometimes an open error is OK.
Tim Potter [Tue, 22 Jan 2002 00:36:53 +0000 (00:36 +0000)]
Display tdb name of "unknown" in logging debug when tdb has not been named.
Tim Potter [Tue, 22 Jan 2002 00:35:51 +0000 (00:35 +0000)]
Added comment about running lp_load() before calling pidfile_create().
Tim Potter [Tue, 22 Jan 2002 00:35:05 +0000 (00:35 +0000)]
Call pidfile_create() as part of init sequence.
Tim Potter [Tue, 22 Jan 2002 00:31:41 +0000 (00:31 +0000)]
Having a const parameter for set_socket_options() causes too much confusion.
Jeremy Allison [Mon, 21 Jan 2002 23:36:47 +0000 (23:36 +0000)]
Removed freebsd hack. Not correct.
Jeremy.
Jeremy Allison [Mon, 21 Jan 2002 23:34:13 +0000 (23:34 +0000)]
Found and fixed the logic bug in write cache code. Amazingly helpful
work from Juergen.Hasch@de.bosch.com in tracking this down.
Jermy.
Simo Sorce [Mon, 21 Jan 2002 08:08:54 +0000 (08:08 +0000)]
getpwnam_alloc -> getpwnam
same reason as per pdb_tdb.c
there isn't (and will never be probably) another call to any getpw* fn,
let's use getpwnam_alloc only when needed.
Simo Sorce [Mon, 21 Jan 2002 07:55:35 +0000 (07:55 +0000)]
hmm, get it right this time.
Simo Sorce [Mon, 21 Jan 2002 07:54:09 +0000 (07:54 +0000)]
fix also the comment.
Simo Sorce [Mon, 21 Jan 2002 07:51:26 +0000 (07:51 +0000)]
replace getpwnam_alloc with plain getpwnam.
We are not going to reuse any getpw* call, so the extra alloc,copy and free
only uses extra memory and extra cpu time for nothing.
Martin Pool [Mon, 21 Jan 2002 06:42:45 +0000 (06:42 +0000)]
Make the -L option to smbclient slightly less gross:
smbclient -L //nautilus1/
should definitely not say "unknown host "nautilus1/". Sheesh.
Tim Potter [Mon, 21 Jan 2002 06:12:22 +0000 (06:12 +0000)]
Spelling fix.
Andrew Bartlett [Mon, 21 Jan 2002 02:51:23 +0000 (02:51 +0000)]
getpwnam -> getpwnam_alloc
Andrew Bartlett [Mon, 21 Jan 2002 00:47:02 +0000 (00:47 +0000)]
getpwnam -> getpwnam_alloc
Andrew Bartlett [Mon, 21 Jan 2002 00:32:26 +0000 (00:32 +0000)]
One less Get_Pwnam_Modify call!
(the passdb backend is case-insensitive, so there isn't any point to this).
Andrew Bartlett
Andrew Bartlett [Mon, 21 Jan 2002 00:25:24 +0000 (00:25 +0000)]
Add the -s command to keep smbpasswd quiet during the tests.
Andrew Bartlett
Andrew Bartlett [Sun, 20 Jan 2002 23:17:36 +0000 (23:17 +0000)]
Inititialise the gid to what standard_sub_advanced wants for 'no value'.
Andrew Bartlett
Andrew Bartlett [Sun, 20 Jan 2002 23:05:23 +0000 (23:05 +0000)]
Fix the negation of the extra parinoia check on machine password changes.
I *love* automated testing - this one got picked up by the build farm.
Andew Bartlett
Andrew Bartlett [Sun, 20 Jan 2002 22:51:16 +0000 (22:51 +0000)]
Also echo the smbpasswd command line