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

857 Commits

Author SHA1 Message Date
Jeremy Allison
5d5762d178 Lots of fixes for error paths where tdb_fetch() data need freeing.
Found via a post from Arcady Chernyak <Arcady.Chernyak@efi.com>.
Jeremy.
0001-01-01 00:00:00 +00:00
Jeremy Allison
f755711df8 Removed global_myworkgroup, global_myname, global_myscope. Added liberal
dashes of const. This is a rather large check-in, some things may break.
It does compile though :-).
Jeremy.
0001-01-01 00:00:00 +00:00
Jeremy Allison
82b8f749a3 Removed global_myworkgroup, global_myname, global_myscope. Added liberal
dashes of const. This is a rather large check-in, some things may break.
It does compile though :-).
Jeremy.
0001-01-01 00:00:00 +00:00
Jim McDonough
f6e21ba4c7 Sync with HEAD to get enumprinterkey api. 0001-01-01 00:00:00 +00:00
Jeremy Allison
a4c8c8f3b7 Being tpot's janitor again.... checking in things only checked into HEAD.
We are meant to be keeping 3.0 up to date...
Jeremy.
0001-01-01 00:00:00 +00:00
Jeremy Allison
10024ed06e Merge of scalable printing code fix... Needs testing.
Also tidied up some of Richard's code (I don't think he uses the compiler
flags -g -Wall -Wshadow -Wstrict-prototypes -Wpointer-arith -Wcast-qual like
I do :-) :-).
Jeremy.
0001-01-01 00:00:00 +00:00
Jeremy Allison
d030df7643 Merge of scalable printing code fix... Needs testing.
Jeremy.
0001-01-01 00:00:00 +00:00
Tim Potter
28871bb696 For a BUFFER5, don't parse the buffer if the buffer length is zero. 0001-01-01 00:00:00 +00:00
Tim Potter
f56ce473b6 Client side functions for enumprinterkey. 0001-01-01 00:00:00 +00:00
Andrew Bartlett
2044d60bbe Merge passdb from HEAD -> 3.0
The work here includes:
 - metze' set/changed patch, which avoids making changes to ldap on unmodified
attributes.

 - volker's group mapping in passdb patch

 - volker's samsync stuff
 - volkers SAMR changes.

 - mezte's connection caching patch

 - my recent changes (fix magic root check, ldap ssl)

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Volker Lendecke
32d6bcf3ac This fixes some bugs for NT4 usrmgr.exe
Volker
0001-01-01 00:00:00 +00:00
Tim Potter
0f2ddfcd95 Merge NULL relstr fix from HEAD. 0001-01-01 00:00:00 +00:00
Tim Potter
e62c6bf066 When unmarshalling a relstr, don't unmarshall the string data if the
offset is zero.  Previously we were jumping to the start of the
parse buffer (i.e offset zero) and reading string data until we hit
a terminating NULL.

Test case: in a PRINTER_INFO_0 structure, the servername field may be
NULL when doing an enumprinters with flags = PRINTER_ENUM_LOCAL.
0001-01-01 00:00:00 +00:00
Andrew Bartlett
7f237bde21 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
0001-01-01 00:00:00 +00:00
Gerald Carter
f149a5a547 missing prs_align()'s 0001-01-01 00:00:00 +00:00
Gerald Carter
33f4a2fe1c missing prs_align()'s 0001-01-01 00:00:00 +00:00
Gerald Carter
028477e352 merge of working dsrolegetprimdominfo() client code from APP_HEAD 0001-01-01 00:00:00 +00:00
cvs2svn Import User
7950dfc795 This commit was manufactured by cvs2svn to create branch 'SAMBA_3_0'. 0001-01-01 00:00:00 +00:00
Gerald Carter
f70caa25e4 merge of working dsrolegetprimdominfo() client code from APP_HEAD 0001-01-01 00:00:00 +00:00
Gerald Carter
1cfd2ee433 merge of new client side support the Win2k LSARPC UUID in rpcbind
from APP_HEAD
0001-01-01 00:00:00 +00:00
Gerald Carter
38c9e42998 merge of new client side support the Win2k LSARPC UUID in rpcbind
from APP_HEAD
0001-01-01 00:00:00 +00:00
Jeremy Allison
cb89bcc935 HEAD and APP-HEAD spoolss parsing was out of sync. This MUST NOT HAPPEN !
Jeremy.
0001-01-01 00:00:00 +00:00
Jeremy Allison
e42b76337b HEAD and APP-HEAD spoolss parsing was out of sync. This MUST NOT HAPPEN !
Jeremy.
0001-01-01 00:00:00 +00:00
Gerald Carter
e026b84815 syncing up with HEAD again.... 0001-01-01 00:00:00 +00:00
Andrew Bartlett
ab878b6cc4 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
0001-01-01 00:00:00 +00:00
Gerald Carter
65e7b5273b sync'ing up for 3.0alpha20 release 0001-01-01 00:00:00 +00:00
Volker Lendecke
8c41b5cd1b Change parsing of policy and privs delta to what Ethereal says.
Volker
0001-01-01 00:00:00 +00:00
Simo Sorce
eda0e7589f wrong alignment size calculation
spot by Florian Weimer <Weimer@CERT.Uni-Stuttgart.DE>
0001-01-01 00:00:00 +00:00
Tim Potter
2d227bdce2 Display debug data we are marshalling/unmarshalling a UNISTR in a
similar format to UNISTR2.
0001-01-01 00:00:00 +00:00
Tim Potter
88653130bc A netshareenum reply always contains an enum_hnd. win2k returns zero
total entries on an error whereas nt4 must send uninitialised data so
we didn't catch this one before.
0001-01-01 00:00:00 +00:00
Tim Potter
47b8ec632e Fix typo in comment. 0001-01-01 00:00:00 +00:00
Tim Potter
6d792c683d Implemented client function for deleteprinterdataex. 0001-01-01 00:00:00 +00:00
Tim Potter
6a1953f243 Implemented some more client side spoolss functions:
- getprinterdataex(), setprinterdataex(), enumprinterdataex()

Pass data type down to setprinterdata() fn instead of hardcoding REG_SZ.

Did some trickyness to get enumprinterdataex replies unmarshalled
properly.  The code seems to have been written to require the number
of entries returned before unpacking said entries.  Skip to the end of
the response and read the number of entries then jump back and process
the printer data.
0001-01-01 00:00:00 +00:00
Andrew Bartlett
52db44b5c0 Avoid writing unitialised bytes to the wire (and consequent valgrind warnings)
by zeroing them out if they don't have meaning.

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Gerald Carter
ec37633548 fix up print portion of registry. Merge from APP_HEAD. 0001-01-01 00:00:00 +00:00
Gerald Carter
cb13d334a5 merge of phant0m key fix from APP_HEAD 0001-01-01 00:00:00 +00:00
Andrew Tridgell
5185f495d0 removed a debug line 0001-01-01 00:00:00 +00:00
Volker Lendecke
23a4f6991e There's more work to be done on samsync. Intermediate commit, now
I get all the groups at least.

Volker
0001-01-01 00:00:00 +00:00
Gerald Carter
901769acc3 fix 2 byte alignment/offset bug that prevented Win2k/XP clients
from receiving all the printer data in EnumPrinterDataEx().
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
23501ea971 some cleanup while working on the NETLOGON pipe.
smb_io_chal() did a prs_align() but a challenge is an array of bytes.
and all code calling smb_io_chal() played with the alignment to not align !

I'm confident in my change, but I would *really* like if jeremy could look
at that.

	J.F.
0001-01-01 00:00:00 +00:00
Tim Potter
1f29276c2f Added some new delta types discovered by Ronnie from ethereal"
- SAM_DELTA_RENAME{USER,GROUP,ALIAS}
 - SAM_DELTA_DELETE{USER,GROUP}

Renamed some of the unknown delta types and their unmarshalling functions:

 - SAM_DELTA_TRUST_DOMS
 - SAM_DELTA_SECRET_INFO
0001-01-01 00:00:00 +00:00
Andrew Tridgell
e4cb106d2e added a 'net rpc samdump' command for dumping the whole sam via
samsync operations (as a BDC)
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
2f68d6f5ec NETLOGON NetServerAuthenticate3 include and parser file
J.F.
0001-01-01 00:00:00 +00:00
Jelmer Vernooij
3928578b52 sync 3.0 branch with head 0001-01-01 00:00:00 +00:00
Gerald Carter
d59b0eb123 * the printing code should now be back to the working state it was
before the swap from NT_PRINTER_PARAM to REGISTRY_VALUE.

* XxxPrinterDataEx() functions have not been expanded to support
  keys other than SPOOL_PRINTERDATA_KEY yet

* fixed apparent long standing bug regarding the dependentfiles
  list in the DRIVER_INFO struct
0001-01-01 00:00:00 +00:00
Gerald Carter
7ba7c04c0e Fairly large change to printing code.
* removed support for PHANTOM_DEVMODE printer data

* s/NT_PRINTER_PARAM/REGISTRY_VALUE/g - This was a good bit
  of work.  Everything seems stable, but is not complete.

* support for printer data keys other than PrinterDriverData
  in the store and fetch routines.  Still needs to be plugged
  into the XxxPrinterDataEx() calls.

Tested against NT4.0 & 2k.  Like I said, it's not done, but doesn't
crash so it shouldn't upset anyone (unless you're trying to build
a Samba printer server off of HEAD).  More work to come.  Should
settle by Monday.


jerry
0001-01-01 00:00:00 +00:00
Tim Potter
482d873c26 Rename unknown_0 field in create_user2 reply in the actual struct. 0001-01-01 00:00:00 +00:00
Tim Potter
8bca308583 The unknown_0 field in a CREATE_USER2 reply is the access granted. 0001-01-01 00:00:00 +00:00
Gerald Carter
fb822e97cb added comment about a new specversion seen from client.
Device mode size is still the same though.




jerry
0001-01-01 00:00:00 +00:00
Jim McDonough
c3b05b21a0 Add lsa 0x2e (queryinfo2) client side 0001-01-01 00:00:00 +00:00
Jim McDonough
ed2370b91f Add client side support for samr connect4 (0x3e). Seems to have one
additional parm compared to samr connect, but I've only seen 0x00000002
in that field...
0001-01-01 00:00:00 +00:00
Gerald Carter
11ddfd9cfa printing change notification merge from APPLIANCE_HEAD 0001-01-01 00:00:00 +00:00
Tim Potter
fe43c2ac2d Merge of incomplete rffpcnex testing code from APPLIANCE_HEAD. 0001-01-01 00:00:00 +00:00
Jim McDonough
2663446349 Add SAMR 0x3e, which is samr_connect4. Seems to be the same as our
existing connect (which I've been told is really connect2), with one
extra dword.  We've only seen 0x00000002 there...
0001-01-01 00:00:00 +00:00
Tim Potter
28ba237a9e Spelling fix. 0001-01-01 00:00:00 +00:00
Andrew Bartlett
167f122b67 Winbind updates!
This updates the 'winbind' authentication module and winbind's 'PAM' (actually
netlogon) code to allow smbd to cache connections to the DC.

This is particulary relevent when we need mutex locks already - there is no
parallelism to be gained anyway.

The winbind code authenticates the user, and if successful, passes back the
'info3' struct describing the user.  smbd then interprets that in exactly the
same way as an 'ntdomain' logon.

Also, add parinoia to winbind about null termination.

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Jim McDonough
31d7168530 Add LSA RPC 0x2E, lsa_query_info2. Only level implemented is 0x0c, which
is netbios and dns domain info.  Also add code to set/fetch the domain GUID
from secrets.tdb (although set is not yet called by anyone).
0001-01-01 00:00:00 +00:00
Gerald Carter
66104a3614 add another registry rpc (opnum 0x14). Have no idea what it's real name
is.  I'm calling it REG_SAVE_KEY, because 2k preps a regedt32.exe
Registry->Save Key with this call.

Done in the process of tracking down a PrinterDriverData issue.
0001-01-01 00:00:00 +00:00
Gerald Carter
0793612cca passing -1 for the src length in rpcstr_pull results in only
converting the first character of the unicode string.,  See convert_string()
for why.  uniarray_2_dosarray() passes 0 for the src length now which works.
0001-01-01 00:00:00 +00:00
Andrew Bartlett
f9bac7c5c2 A very long time ago (actually 6 months ago) I promised to commit this code
to the Samba tree.

Originally written by Nigel Williams" <nigel@veritas.com>, I've been
trying to keep it in some form of shape for the last 6 months.  In particular
I think some of the code got committed a few months ago, and others have made
changes to the CVS version over time.

anyway, its finally in - and doesn't appear to have broken anything.

Now to try the client-side patches :-)

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Gerald Carter
5640e6cdb2 3 things:
* normalize all registry key strings before storing or looking
  up paths in the registry tdb
* return the current buffer size for REG_INFO even when not returning
  actual data
* fix a segfault report by metze on #samba-technical so that the
  user/group object picker works again (was the "ProductType" key
  lookup that was failing).
0001-01-01 00:00:00 +00:00
Gerald Carter
419d7208e8 several changes in this checkin
* added REG_OPEN_HKCR for supporting regedit.exe

* All data n a REGISTRY_VALUE is stored to a pointer now

* fixed REG_INFO to correctly display data when double clicking on
  and entry in the registry editor

* Will now enumerate installed driver_info_3 data

* fixed numerous bugs related to pointer offsets, memory issues, etc..
  in the registry routines

* added a simple caching mechanism to fetch_reg_[keys|values]_specific()

All that is left now is to enumerate PrinterData and I will have finished
what I started out to do....
0001-01-01 00:00:00 +00:00
Gerald Carter
998eb9c731 * changed structure of REG_R_ENUM_VALUE structure since the BUFFER2
is not and [in/out] buffer

* registry value enumeration is working now for the Print\Forms
  key.  The format of the binary data is not quite right yet
  but all installed forms are listed
0001-01-01 00:00:00 +00:00
Tim Potter
290a304d2c Name get and set dir drive functions consistently. 0001-01-01 00:00:00 +00:00
Andrew Bartlett
8196ee908e Try to fix up warnings - particularly on the IRIX 64 bit compiler (which had a
distinction between uchar and char).

Lots of const etc.

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Andrew Tridgell
8b769bf5bb more bug updates from head 0001-01-01 00:00:00 +00:00
Andrew Tridgell
04de6bbc80 fixed a number of real bugs found by warnings on the 64 bit irix compiler 0001-01-01 00:00:00 +00:00
Andrew Tridgell
03ac082dcb updated the 3.0 branch from the head branch - ready for alpha18 0001-01-01 00:00:00 +00:00
Jeremy Allison
175d43980e The changes in make_sec_desc to make us match W2K broke the marshalling/unmarshalling of
security descriptors. We need to calculate the maximum offset and set the offset
back after reading/writing every field in the SEC_DESC.
This was *nasty* to find....
Jeremy.
0001-01-01 00:00:00 +00:00
Gerald Carter
7207662504 all that is left to do is to actually perform the
file deletion now.  I have the file list.
One more commit should do it.
0001-01-01 00:00:00 +00:00
Gerald Carter
f57640720e 8-byte alignment needed for beginning driver_info_level_6.
Verified by looking at NT4 and 2k servers.  First time
for everything I guess.
0001-01-01 00:00:00 +00:00
Gerald Carter
b0f178f452 fixup ADDPRINTERDRIVEREX some more. unknown uint32 for now. 0001-01-01 00:00:00 +00:00
Gerald Carter
55fbfd02ba added parsing routines for SPOOLSS_ADDPRINTERDRIVEREX and
SPOOLSS_DELETEPRINTERDRIVEREX.  Ran them through some testing.
I know I'm off by 2 x uint32's in the former RPC.
0001-01-01 00:00:00 +00:00
Gerald Carter
d675974d0c * basic implementation of SPOOLSS_DELETEPRINTERDATAEX and
SPOOLSS_DELETEPRINTERKEY
* stub funnctions for SPOOLSS_ADDPRINTERDRIVEREX and
  SPOOLSS_DELETEPRINTERDRIVEREX
0001-01-01 00:00:00 +00:00
Gerald Carter
2a68e4529a fixed the geyed out registry keys. Stupid typo on my part.
Now on to plug in the printing tdbs to the registry view....

jerry
0001-01-01 00:00:00 +00:00
Andrew Bartlett
0c4afe075a More code from "Kai Krueger" <kai@kruegernetz.de>, this time starting to make
the 'user cannot change password' button work.  Needs help from a future SAM
backend, but at least this parses the data, and returns an error.

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Gerald Carter
542d3c93a9 first cut at implementing support for browsing printer and driver driver
via regedt32.exe.  The regsitry.tdb is only a framework.  It is not
intended to store values, only key/subkey structure.  The data
will be retrieved from nt*tdb (for printers) creating a virtual view
of the data.

You can currently connect to a Samba box using regedt32.exe (haven't
tried regedit.exe).  Some basic keys are created in registry.tdb
for use.

There are two problems....

  * something is getting freed in the winreg code that causes heap
    corruption later on.  As long as you don't play with the winreg
    server functionality, I don't think you'll be bitten by this.

  * no access controls are currently implemented

  * I can't browse HKLM because regedt32 greys out the SYSTEM subkey.

ok so that was three....
0001-01-01 00:00:00 +00:00
Andrew Bartlett
5a2a6f1ba3 Break up the passdb objects (to allow RPC clients to link without brining in
*.o) and implment new enum_dom_users code in the SAMR RPC subsystem.

Incresingly, we are using the pdb_get_{user,group}_sid() functions, in the
eventual hope that we might one day support muliple domains off a single
passdb.  To extract the RID, we use sid_peek_check_rid(), and supply an
'expected' domain SID.

The id21 -> SAM_ACCOUNT and id23 -> SAM_ACCOUNT code has been moved to
srv_samr_util.c, to ease linking in passdb users.

Compatiblity code that uses 'get_global_sam_sid()' for the 'expected' sid is in
pdb_compat.c

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Andrew Tridgell
80c3c68de2 fixed our winreg parsing to handle a diifferent form given to us by
WinXP. This fixes setting security decsriptors from XP Professional.
0001-01-01 00:00:00 +00:00
Tim Potter
daf4c6a013 Merge of constant renames from APPLIANCE_HEAD. 0001-01-01 00:00:00 +00:00
Andrew Tridgell
91ad9041e9 used findstatic.pl to make some variables static and remove some dead
code
0001-01-01 00:00:00 +00:00
Jeremy Allison
3603cd4947 Proper merge of all the working printing stuff from APPLIANCE_HEAD.
Now let's keep this in sync !
Jeremy.
0001-01-01 00:00:00 +00:00
Gerald Carter
fc3770f281 a null grp_sid should have a 0 offset. Also removed a few more unnecessary
prs_align() for sec_desc.
0001-01-01 00:00:00 +00:00
Gerald Carter
d8cf54399d merge from APP_HEAD 0001-01-01 00:00:00 +00:00
Jeremy Allison
4ed134426d Typo...
Jeremy.
0001-01-01 00:00:00 +00:00
Jeremy Allison
374182a9ba Added prs_align_uint16 for SD aligns.
Jeremy.
0001-01-01 00:00:00 +00:00
Gerald Carter
f471c880db sync with the sec_desc parsing fix from APP_HEAD. I will probably need
to revisit this some.
0001-01-01 00:00:00 +00:00
Gerald Carter
f753676286 printing merge from SAMBA_2_2. Ther server code looks to be in sync now.
Mostly formatting and s/free/SAFE_FREE/g changes with the two exceptions
being

  * John driver init changes
  * Tim's printer enumeration bug fix
0001-01-01 00:00:00 +00:00
Simo Sorce
897e64d2e0 more debug classess activated 0001-01-01 00:00:00 +00:00
Andrew Bartlett
a2c791c0bb Add a touch of const to this - helps with some yet-to-be-commited changes 0001-01-01 00:00:00 +00:00
Jeremy Allison
64af68924b Merge of Jerry's fix from 2.2.
Jeremy.
0001-01-01 00:00:00 +00:00
Jim McDonough
2b4a5b5666 Add user name to netsessenum RPC to stop 1783 messages. Also fix where username was sent as machine name. 0001-01-01 00:00:00 +00:00
Tim Potter
2e25b5c309 Fixed bogus alignment in unmarshalling of SAMR_GET_DOM_PWINFO reply. 0001-01-01 00:00:00 +00:00
Jim McDonough
4b18a94590 Add rpc for file close, expand file enum to take username 0001-01-01 00:00:00 +00:00
Jim McDonough
4e31716385 Add fns for netshareadd and netsharedel rpcs 0001-01-01 00:00:00 +00:00
Jim McDonough
b3fea72ee9 Update netfileenum on both client and server sides to do an arbitrary number
of files.  This was done to better enable net rpc file.  Perhaps we can start
giving back real info this way, too.
0001-01-01 00:00:00 +00:00
Jim McDonough
8fc3dba8bd netfileenum was missing the username filter. 0001-01-01 00:00:00 +00:00
Tim Potter
0c65978ed0 Added netremotetod to try and figure out which srvsvc commands are denied
when using restrictanonymous.
0001-01-01 00:00:00 +00:00
Tim Potter
c7214baa05 When marshalling a netshareenum request the share ctr has to be initialised
to an empty value instead of a null pointer otherwise the server service
crashes on NT.
0001-01-01 00:00:00 +00:00
Gerald Carter
83f109c940 merge from SAMBA_2_2.
Tim, please check the prs_align() removed from sec_io_desc()
and make sure it doesn't break anything else.  I know it is
right for the printing needs and I have tested some other
general things like viewing acls on directories, but I would
feel more comfortable if you would have a look as well.


jerry
0001-01-01 00:00:00 +00:00
Tim Potter
bbad6c6678 OK that last commit was incorrect - this call is parsed properly. I only
imagined it wasn't!
0001-01-01 00:00:00 +00:00
Tim Potter
2429c4cc79 There's probably a pointer to a buffer at the end of a enumprinterdrivers()
rpc call which we currently don't parse - just added a comment about it for
the moment as not parsing it is harmless.
0001-01-01 00:00:00 +00:00
Tim Potter
1fb8e2b3a0 No need to pass a fstring in make_spoolss_q_enumprinters() 0001-01-01 00:00:00 +00:00
Andrew Bartlett
c28668068b A few things in this commit:
cleanup some of the code in net_rpc_join re const warnings and
fstrings.

Passdb:

Make the %u and %U substituions in passdb work.
This is done by declaring these paramters to be 'const' and doing
the substitution manually.  I'm told this is us going full circle,
but I can't really see a better way.

Finally these things actually seem to work properly...

Make the lanman code use the pdb's recorded values for homedir etc
rather than the values from lp_*()

Add code to set the plaintext password in the passdb, where it can
decide how to store/set it.  For use with a future 'ldap password
change' option, or somthing like that...

Add pdb_unix, so as to remove the 'not in passdb' special cases from the
local_lookup_*() code.  Quite small, as it uses the new 'struct passwd ->
SAM_ACCOUNT' code that is now in just one place.  (also used by pdb_smbpasswd)

Other:
Fix up the adding of [homes] at session setup time to actually pass
the right string, that is the unix homedir, not the UNC path.

Fix up [homes] so that for winbind users is picks the correct name.
(bad interactions with the default domain code previously)

Change the rpc_server/srv_lsa_nt.c code to match NT when for the
SATUS_NONE_MAPPED reply:  This was only being triggered on
no queries, now it is on the 'no mappings' (ie all mappings failed).
Checked against Win2k.

Policy Question:  Should SID -> unix_user.234/unix_group.364 be
considered a mapping or not?  Currently it isn't.

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Andrew Bartlett
e5b4331ffa Make non-static for some later work (pushing the info3 across the winbind
pipe for smbd to decode), and fix up the debug.  (At least I assume it is
wrong, can an expert care to comment?)
0001-01-01 00:00:00 +00:00
Andrew Bartlett
3e93b216dd Add a touch of const 0001-01-01 00:00:00 +00:00
Andrew Bartlett
d57a1b4629 A few more trusted domains updates from mimir.
I think we may still need to look at our server enumeration code, but
other than that, its much better in the tree than out.

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Tim Potter
217ae50acd Added deleteprinterdata client rpc. 0001-01-01 00:00:00 +00:00
Tim Potter
a1934a7a8e Added writeprinter rpc command. 0001-01-01 00:00:00 +00:00
Tim Potter
89633a1d87 Change make_spoolss_q_{get,set}printerdata() take a char* and length rather
than a unistr2.  Printer data isn't necessarily in unistr format.

Tallocate memory to hold returned data when unmarshalling getprinterdata
and enumprinterdata replies.
0001-01-01 00:00:00 +00:00
Gerald Carter
2676be4e41 compile fix merge from SAMBA_2_2 0001-01-01 00:00:00 +00:00
Tim Potter
8e09e94546 Support for client side startdocprinter.
Set useless_ptr = 1 for marshalling smb_io_doc_info() so it actually works.
0001-01-01 00:00:00 +00:00
Gerald Carter
0420098c47 misc merge from SAMBA_2_2 0001-01-01 00:00:00 +00:00
Gerald Carter
59e49a79b4 devmode parsing merge from SAMBA_2_2 0001-01-01 00:00:00 +00:00
Tim Potter
d091a9d300 Added client side spoolss rpc commands for startpageprinter,
endpageprinter, setjob and getjob.
0001-01-01 00:00:00 +00:00
Tim Potter
4d715cb682 Grr - the removal of the nnecessary prs_align() from relative unicode
strings didn't make it across into HEAD.
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
68e9211f5d don't set the owner and group sid offset is there are no owner or group
owner.

	J.F.
0001-01-01 00:00:00 +00:00
Gerald Carter
d3aed37dd8 printing merge from HEAD 0001-01-01 00:00:00 +00:00
Gerald Carter
5e381abbbf merge from SAMBA_2_2 0001-01-01 00:00:00 +00:00
Andrew Bartlett
0bdd94cb99 Partly based on the work by mimir (Rafal Szczesniak
<mimir@diament.ists.pwr.wroc.pl>) this patch allows samba to correctly
enumerate its trusted domains - by exaimining the keys in the secrets.tdb file.

This patch has been tested with both NT4 and rpcclient/wbinfo, and adds
some extra functionality to talloc and rpc_parse to allow it to deal with
already unicode strings.

Finally, this cleans up some const warnings that were in net_rpc.c by pushing
another dash of const into the rpc client code.

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Jeremy Allison
4369a58765 HP2500C driver writes devmode with private data that ends
on a 2 byte boundary. We then miss-parse the desired_access. Also added
other fixes to ensure we align after private data (discussed with Gerry).
Jeremy.
0001-01-01 00:00:00 +00:00
Gerald Carter
d87aa35d48 specversion merge from SAMBA_2_2 0001-01-01 00:00:00 +00:00
Tim Potter
e878cdc9f5 Fixed missing alignment in spoolss_io_q_enumjobs() function. 0001-01-01 00:00:00 +00:00
Jeremy Allison
16015c07ea Added Shirish's client side caching policy change.
Jeremy.
0001-01-01 00:00:00 +00:00
Tim Potter
6367bfc478 The useless_ptr must be non-zero for addform and setform client functions
to work.

Note about setprinter level 1 not existing.
0001-01-01 00:00:00 +00:00
Jeremy Allison
5de792e7e9 Fixed the handle leak in the connection management code (this code is crap
and should be rewritten, just not now... :-).
Jeremy.
0001-01-01 00:00:00 +00:00
Gerald Carter
619397cc90 OpenPrinter() merge from 2.2 0001-01-01 00:00:00 +00:00
Tim Potter
e66bdf1229 Stomped on some header file version numbers that have crept back in. 0001-01-01 00:00:00 +00:00
Gerald Carter
88d8897e21 resetprinter merge from SAMBA_2_2 0001-01-01 00:00:00 +00:00
Jeremy Allison
5b43519219 Fix for debug typo. 0001-01-01 00:00:00 +00:00
Tim Potter
ddb5753e36 Added dos_errstr() function. Not all errors in list yet. 0001-01-01 00:00:00 +00:00
Tim Potter
1f007d3ed4 Renamed get_nt_error_msg() to nt_errstr(). 0001-01-01 00:00:00 +00:00
Gerald Carter
5760315c1d 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
0001-01-01 00:00:00 +00:00
Tim Potter
ab1ebd3779 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.
0001-01-01 00:00:00 +00:00
Andrew Tridgell
6891393b5d yipee! Finally put in the patch from Alexey Kotovich
<a.kotovich@sam-solutions.net> that adds the security decsriptor code
for ADS workstation accounts

thanks for your patience Cat, and thanks to Andrew Bartlett for
extensive reviews and suggestions about this code.
0001-01-01 00:00:00 +00:00
Jeremy Allison
2b85d3570c Fix the NTSTATUS -> WERROR for srvsvc pipe.
Jeremy.
0001-01-01 00:00:00 +00:00
Andrew Bartlett
f0b16b7b51 more const 0001-01-01 00:00:00 +00:00
Andrew Bartlett
044391b597 And a little more const. 0001-01-01 00:00:00 +00:00
Jeremy Allison
3f9063167f Patch for Domain users not showing up from "Ivan Zhakov" <vunny@mail.ru>.
Jeremy.
0001-01-01 00:00:00 +00:00
Tim Potter
e69222f081 Implemented client side functions for SPOOLSS addform, getform, setform and
enumforms.
0001-01-01 00:00:00 +00:00
Tim Potter
1803778451 Added make functions for SPOOL_Q_{ADD,SET,DELETE}FORM.
I'm pretty sure that the useless_ptr in spoolss_io_q_setform() needs to be
initialised to 1 otherwise the form isn't marshalled at all.  JF, can you
verify this?  If so then this probably applies to the io functions for
setform and deleteform.
0001-01-01 00:00:00 +00:00
Tim Potter
6a58c9bd06 Removed version number from file header.
Changed "SMB/Netbios" to "SMB/CIFS" in file header.
0001-01-01 00:00:00 +00:00
Andrew Bartlett
5dfba2cf53 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
0001-01-01 00:00:00 +00:00
Andrew Bartlett
100d2705dd 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).
0001-01-01 00:00:00 +00:00
Andrew Bartlett
4fc9e16ad7 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
0001-01-01 00:00:00 +00:00
Jeremy Allison
27f65b3aad Fixed ADDPRINTEREX to take a devmode and a security descriptor...
Jeremy.
0001-01-01 00:00:00 +00:00
Andrew Bartlett
e870f0e727 This patch makes the 'winbind use default domain' code interact better with
smbd, and also makes it much cleaner inside winbindd.

It is mostly my code, with a few changes and testing performed by Alexander
Bokovoy <a.bokovoy@sam-solutions.net>.  ab has tested it in security=domain and
security=ads, but more testing is always appricatiated.

The idea is that we no longer cart around a 'domain\user' string, we keep them
seperate until the last moment - when we push that string into a pwent on onto
the socket.

This removes the need to be constantly parsing that string - the domain prefix
is almost always already provided, (only a couple of functions actually changed
arguments in all this).

Some consequential changes to the RPC client code, to stop it concatonating the
two strings (it now passes them both back as params).

I havn't changed the cache code, however the usernames will no longer have a
double domain prefix in the key string.  The actual structures are unchanged
 - but the meaning of 'username' in the 'rid' will have changed.  (The cache is
invalidated at startup, so on-disk formats are not an issue here).

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Jeremy Allison
9a969069f1 Added prs_mem_clear(). Clear memory on buffer reallocation. That way
we're not returning what the client gave us.
Jeremy.
0001-01-01 00:00:00 +00:00
Jeremy Allison
6deb4caca5 Always clear malloced memory for parse structs.
Jeremy.
0001-01-01 00:00:00 +00:00
Jeremy Allison
b63b762978 Added PRINTER_INFO_4/PRINTER_INFO_5, we're seeing level 5 requested on the wire... so.
Jeremy.
0001-01-01 00:00:00 +00:00
Tim Potter
690cc12bad Sed error. The status value in the PRINTER_INFO_2 structure isn't a WERROR
but a plain old uint32.
0001-01-01 00:00:00 +00:00
Martin Pool
92a3ab274e Add prs_dump_before to dump everything from the start of the prs
buffer up to the current position, and use this to dump pipe buffers
just before parsing.
0001-01-01 00:00:00 +00:00
Andrew Tridgell
65e857b36e more irix -64 portability fixes 0001-01-01 00:00:00 +00:00
Andrew Bartlett
f0c301a12e Give the main loop talloc context a name (using mbp's new talloc naming
system).

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
87928c4d91 added a copyright notice.
J.F.
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
c0178e1a03 doesn't keep track of the struct's size we enumerate. W2K doesn't
calculate them and always reply a size of 32 bytes whereas NT4 did the
maths. Anyway, it looks like the clients don't complain.

in query_dom_info() at level 2, return the real number of users and
groups. That's the fix to the W95/98 userlist bug !

as W95/98 does a query_dom_info(2) followed by a query_disp_info(4) on
the SAME context handle (err we call it an lsa policy handle ! plain
wrong name), I was tempted to keep the snapshoot in memory, to prevent
2 full user db enumerations in a row and just have one shared. But if some
client does the 2 calls on two different handles, we would have 2 copies
in memory not free'ed before the samr_close().

We still have too many fixed constant and too many magic values in that
code. And btw, I really hates how the sequence number is generated !

        J.F.
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
3ab4521536 re-done all of samr_query_disp_info()
instead of enumerating the whole user db or group db every time, we store
a in memory copy linked to the handle.

that's much faster for large enumeration where the db can't fit in a
single rpc packet. And as it's a copy, it's constant between enumeration.

still some stuff to clean. But now I can fix the W95 userlist bug, as I've
finally found it.

	J.F.
0001-01-01 00:00:00 +00:00
Gerald Carter
72d3b16022 merge from 2.2 0001-01-01 00:00:00 +00:00
Jean-François Micouleau
589aa4fe22 added info level 1 to samr_query_alias() 0001-01-01 00:00:00 +00:00
Jean-François Micouleau
49764852c5 fixing bug I introduced.
J.F.
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
a217c4e4ff there is no unknown field in LSA_SEC_QOS
some cleanup of the lsa_open_policy and lsa_open_policy2 parser. the
length fields are not correct but that's what NT send. We don't anymore
underflow or overflow the decoding.

added the domain admins group to the default SD.

we are now checking the desired access flag in the lsa_open_policy_X()
calls and in most functions also.

        J.F.
0001-01-01 00:00:00 +00:00
Tim Potter
b596c0b171 Replaced some hardcoded hex numbers with constants.
Made a note about NOTIFY_OPTION_TYPE and NOTIFY_OPTION_TYPE_DATA - they are
actually one structure.  The latter is just the deferred referrant of the
former.
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
c99bc30559 update the ldap support code. it compiles.
Ignacio you can update your howto ;-)

samsync: a small patch to try chaning challenges.

	J.F.
0001-01-01 00:00:00 +00:00
Gerald Carter
5b4b3323a3 merge from 2.2 0001-01-01 00:00:00 +00:00
Jean-François Micouleau
8d359e6213 decoded SAM_DELTA 0x0e and 0x12.
One is an entry for the trusted domains
The other is an entry for the trusting domains

They are pretty basic, I'll improve them.

	J.F.
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
314b675ed9 a ugly decoder for SAM_DELTA_DOM_INFO (0x0d)
a correct decoder for SAM_PRIVS_INFO (0x10)

this code is totally useless right now, it's just fun to decode those and
will save tpot some time.

	J.F.
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
0a727afc66 added info level 3 to samrgetgroupinfo. I don't know what the value is.
It's just to keep usermanager happy ;-)

clean up a bit samr_query_aliasinfo to return the group description

added: samr_del_aliasmem, samr_del_groupmem and samr_del_domuser

with the correct scripts, you can now entirely manage the users from
usermanager ! Closer to full PDC every day ;-)

        J.F.
0001-01-01 00:00:00 +00:00
Tim Potter
bef4365647 Added client and server code for the GetPrintProcessorDirectory SPOOLSS
rpc.  This was supposed to fix a printer driver download bug but it didn't
but it seemed a shame to trash all this code so I'm commiting it #ifdef'ed
out in case someone needs it one day.
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
fef52c4b96 again an intrusive patch:
- removed the ugly as hell sam_logon_in_ssb variable, I changed a bit the
definition of standard_sub_basic() to cope with that.

- removed the smb.conf: 'domain admin group' and 'domain guest group'
parameters ! We're not playing anymore with the user's group RIDs !

- in get_domain_user_groups(), if the user's gid is a group, put it first
in the group RID list.

I just have to write an HOWTO now ;-)

        J.F.
0001-01-01 00:00:00 +00:00
Andrew Bartlett
575897e879 OK. Smbpasswd -j is DEAD.
This moves the rest of the functionality into the 'net rpc join' code.

Futhermore, this moves that entire area over to the libsmb codebase, rather
than the crufty old rpc_client stuff.

I have also fixed up the smbpasswd -a -m bug in the process.

We also have a new 'net rpc changetrustpw' that can be called from a
cron-job to regularly change the trust account password, for sites
that run winbind but not smbd.

With a little more work, we can kill rpc_client from smbd entirly!
(It is mostly the domain auth stuff - which I can rework - and the
spoolss stuff that sombody else will need to look over).

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Andrew Bartlett
64bf8f81c4 Const religion for some of the RPC code. 0001-01-01 00:00:00 +00:00
Jean-François Micouleau
bc28a8eebd added a tdb to store the account policy informations.
You can change them with either usermanager->policies->account
or from a command prompt on NT/W2K: net accounts /domain

we can add a rpc accounts to the net command. As the net_rpc.c is still
empty, I did not start. How should I add command to it ? Should I take the
rpcclient/cmd_xxx functions and call them from there ?

alse changed the SAM_UNK_INFO_3 parser, it's an NTTIME. This one is more
for jeremy ;-)

        J.F.
0001-01-01 00:00:00 +00:00
Andrew Tridgell
359ca8f246 const religion 0001-01-01 00:00:00 +00:00
Tim Potter
9712d3f15a Renamed sid field in SEC_ACE to trustee to be more in line with MS's
definitions.
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
3f0a9ef2b8 Changed again how the privilege list is handled in the group mapping code.
This time it's a PRIVILEGE_SET struct instead of a simple uint32 array. It
makes much more sense. Also added a uint32 systemaccount to the GROUP_MAP
struct as some privilege showing in USRMGR.EXE are not real privs but a
bitmask flag. I guess it's an heritage from NT 3.0 ! I could setup an NT
3.1 box to verify, but I'm too lazy (yes I still have my CDs).

Added 3 more LSA calls: SetSystemAccount, AddPrivileges and
RemovePrivileges, we can manage all this privilege from UserManager.

Time to change the NT_USER_TOKEN struct and add checks in all the rpc
functions. Fun, fun, fun.

        J.F.
0001-01-01 00:00:00 +00:00
Gerald Carter
c60aa6c06f merge from APPLIANCE_HEAD 0001-01-01 00:00:00 +00:00
Herb Lewis
5f625f2877 add .po32 files to ignore list 0001-01-01 00:00:00 +00:00
Jean-François Micouleau
99471d2569 added samr_set_domain_info and samr_unknown_2E.
We now get the full account policy window in usermanager, and the
framework to store all those values. I plan to add a TDB file to store
them.

oh, and found that the last value in a sam_unknown_info_12_inf struct is
an uint16 and not a uint32.

andrewb: you hardcoded the MAX_PASSWORD_AGE to 21 days. We can now turn it
to a value setable in usermanager.

        J.F.
0001-01-01 00:00:00 +00:00
Andrew Bartlett
3f1cfb62e8 Fix ./configure --enable-developer warnings (shadow of global) 0001-01-01 00:00:00 +00:00
Jean-François Micouleau
1748d5a2af added lsaenumprivsaccount and lsalookupprivvalue to rpcclient
and more to come ...

	J.F.
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
f29774e589 Changed how the privileges are stored in the group mapping code. It's now
an array of uint32. That's not perfect but that's better.

Added more privileges too.

Changed the local_lookup_rid/name functions in passdb.c to check if the
group is mapped. Makes the LSA rpc calls return correct groups

Corrected the return code in the LSA server code enum_sids.

Only enumerate well known aliases if they are mapped to real unix groups.
Won't confuse user seeing groups not available.

Added a short/long view to smbgroupedit.

now decoding rpc calls to add/remove privileges to sid.

        J.F.
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
646651018a added lsa_enum_sids to rpcclient
fixed lsa_enum_rpivs server code. This time it works as W2K.
fixed smbgroupedit to compile and work.

	J.F.
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
84035ae72f add another command to rpcclient: getdispname. Show the full description
of a privilege.

	J.F.
0001-01-01 00:00:00 +00:00
Jean-François Micouleau
fa63cb78e3 add a command to rpcclient: enumprivs
J.F.
0001-01-01 00:00:00 +00:00
Gerald Carter
90ed3d47e1 remove unused variables 0001-01-01 00:00:00 +00:00
Gerald Carter
96b3a65a73 merge from 2.2 0001-01-01 00:00:00 +00:00
Jean-François Micouleau
bfbe7f377e samr_querydom_info level 1: found the meaning of the unknow fields. And
discovered that our reply is short by 4 bytes since day 1 of this code.

Added a decode function to rpcclient too.

splitted the STRING2 fields filling while trying to understand the win9x
userlist bug. (didn't fix the bug, but the reply looks closer to NT).

        J.F.
0001-01-01 00:00:00 +00:00
Jeremy Allison
9148bb9eaa Tidyups when I was doing the big merge...
Jeremy.
0001-01-01 00:00:00 +00:00
Jeremy Allison
9c8439f25b Tidyups and things I discovered during the merge...
Jeremy.
0001-01-01 00:00:00 +00:00
Jeremy Allison
be7323163b No longer used.
Jeremy.
0001-01-01 00:00:00 +00:00
Martin Pool
5c892badbc Doxygen demo for Tim. 0001-01-01 00:00:00 +00:00
Martin Pool
be5d32eb9c spoolss_io_devmode private data is binary and should be shown in hex,
not ascii.
0001-01-01 00:00:00 +00:00
Tim Potter
87614c74b3 Wrote some stubs for new win2k only spoolss rpc commands:
GetPrinterDataEx() and SetPrinterDataEx().  Not sure what the command
number is for the latter is - I haven't seen it on the wire yet.
0001-01-01 00:00:00 +00:00
Andrew Tridgell
fd3a657b44 get the string lengths right in domain logons
Andrew, this fixes domain logons in head. Please look at the change,
as I think you may have misunderstood the max_str_len field (which is
badly named)
0001-01-01 00:00:00 +00:00
Andrew Bartlett
514c91b16b Various post AuthRewrite cleanups, fixups and tidyups.
Zero out some of the plaintext passwords for paranoia

Fix up some of the other passdb backends with the change to *uid_t rather than
uid_t.

Make some of the code in srv_netlog_nt.c clearer, is passing an array around,
so pass its lenght in is definition, not as a seperate paramater.

Use sizeof() rather than magic numbers, it makes things easier to read.

Cope with a PAM authenticated user who is not in /etc/passwd - currently by
saying NO_SUCH_USER, but this can change in future.

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Andrew Bartlett
f70fb819b2 This is a farily large patch (3300 lines) and reworks most of the AuthRewrite
code.

In particular this assists tpot in some of his work, becouse it provides the
connection between the authenticaion and the vuid generation.

Major Changes:
	- Fully malloc'ed structures.
	  - Massive rework of the code so that all structures are made and destroyed
	    using malloc and free, rather than hanging around on the stack.
	- SAM_ACCOUNT unix uids and gids are now pointers to the same, to allow them
	   to be declared 'invalid' without the chance that people might get ROOT by
	   default.

	- kill off some of the "DOMAIN\user" lookups.  These can be readded at a more
	  appropriate place (probably domain_client_validate.c) in the future. They
	  don't belong in session setups.

	- Massive introduction of DATA_BLOB structures, particularly for passwords.

	- Use NTLMSSP flags to tell the backend what its getting, rather than magic
	  lenghths.

	- Fix winbind back up again, but tpot is redoing this soon anyway.

	- Abstract much of the work in srv_netlog_nt back into auth helper functions.

This is a LARGE change, and any assistance is testing it is appriciated.

Domain logons are still broken (as far as I can tell) but other functionality
seems
intact.

Needs testing with a wide variety of MS clients.

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Tim Potter
0f6207f455 This one's a doozy. A cut&paste bug incorrectly sets the max string length
of the lm challenge/response header in the NET_ID_INFO_2 structure included
in a network logon request.  It seems Windows 2000 is the only OS that
cares about this.
0001-01-01 00:00:00 +00:00
Tim Potter
b496936634 Removed confusing comment. 0001-01-01 00:00:00 +00:00
Andrew Bartlett
c95f5aeb93 This commit is number 4 of 4.
In particular this commit focuses on:

Actually adding the 'const' to the passdb interface, and the flow-on changes.

Also kill off the 'disp_info' stuff, as its no longer used.

While these changes have been mildly tested, and are pretty small, any
assistance in this is appreciated.

----

These changes introduces a large dose of 'const' to the Samba tree.
There are a number of good reasons to do this:

	- I want to allow the SAM_ACCOUNT structure to move from wasteful
	pstrings and fstrings to  allocated strings.  We can't do that if
	people are modifying these outputs, as they may well make
	assumptions about getting pstrings and fstrings

	- I want --with-pam_smbpass to compile with a slightly sane
	volume of warnings, currently its  pretty bad, even in 2.2
	where is compiles at all.

	- Tridge assures me that he no longer opposes 'const religion'
	based on the ability to  #define const the problem away.

	- Changed Get_Pwnam(x,y) into two variants (so that the const
	parameter can work correctly): - Get_Pwnam(const x) and
	Get_Pwnam_Modify(x).

	- Reworked smbd/chgpasswd.c to work with these mods, passing
	around a 'struct passwd' rather  than the modified username

---

This finishes this line of commits off, your tree should now compile again :-)

Andrew Bartlett
0001-01-01 00:00:00 +00:00
Jeremy Allison
94403d8417 Fixed the bug with member servers in a Samba PDC hosted domain not allowing
other access. Problem was max time was being set to 0xffffffff, instead of
0x7fffffff.
Jeremy.
0001-01-01 00:00:00 +00:00