1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-04 05:18:06 +03:00
Commit Graph

406 Commits

Author SHA1 Message Date
Tim Potter
0bcc0c343f SAMR lookupdomain rpc client patches from amber palekar <amber@nu3.net>
(This used to be commit 67bc6bccc2)
2003-04-04 00:52:42 +00:00
Andrew Bartlett
1f5e93e2e7 NTLM Authentication:
- Add a 'privileged' mode to Winbindd.  This is achieved by means of a directory
  under lockdir, that the admin can change the group access for.

- This mode is now required to access with 'CRAP' authentication feature.
- This *will* break the current SQUID helper, so I've fixed up our ntlm_auth
  replacement:
 - Update our NTLMSSP code to cope with 'datagram' mode, where we don't get a
   challenge.
 - Use this to make our ntlm_auth utility suitable for use in current Squid 2.5
   servers.
 - Tested - works for Win2k clients, but not Win9X at present.  NTLMSSP updates
   are needed.
 - Now uses fgets(), not x_fgets() to cope with Squid environment (I think
   somthing to do with non-blocking stdin).

- Add much more robust connection code to wb_common.c - it will not connect to
  a server of a different protocol version, and it will automatically try and
  reconnect to the 'privileged' pipe if possible.
  - This could help with 'privileged' idmap operations etc in future.

- Add a generic HEX encode routine to util_str.c,
- fix a small line of dodgy C in StrnCpy_fn()

- Correctly pull our 'session key' out of the info3 from th the DC.  This is
  used in both the auth code, and in for export over the winbind pipe to
  ntlm_auth.

- Given the user's challenge/response and access to the privileged pipe,
  allow external access to the 'session key'.  To be used for MSCHAPv2
  integration.

Andrew Bartlett
(This used to be commit dcdc75ebd8)
2003-03-23 13:03:25 +00:00
Martin Pool
8cfec8554e Ignore .po and .po32 files.
(This used to be commit 8d64419625)
2003-03-18 05:51:41 +00:00
Tim Potter
991f6cc3c1 More const fixes and flow on fixes from yesterday's const-fest.
(This used to be commit 018733eedd)
2003-02-25 23:34:57 +00:00
Tim Potter
e25aa22a8f Merge:
> Exit path cleanup for cli_samr_enum_dom_users()
(This used to be commit 655c1e0351)
2003-02-24 02:12:39 +00:00
Tim Potter
ae8d3538c7 Exit path cleanup for cli_samr_enum_dom_users()
(This used to be commit 0bc1dfc68b)
2003-02-21 04:26:58 +00:00
Tim Potter
e486396267 Return a WERROR instead of a NTSTATUS like the rest of the srvsvc
rpc calls.
(This used to be commit 619af61644)
2003-02-17 04:35:32 +00:00
Jeremy Allison
4cd6e31bd3 Ensure that only parse_prs.c access internal members of the prs_struct.
Needed to move to disk based i/o later.
Jeremy.
(This used to be commit 4c3ee228fc)
2003-02-14 23:04:03 +00:00
Andrew Tridgell
faf30e69ae initial server side privileges implementation, using a tdb. This needs to be hooked into pdb, and we need some access control on changing privileges. That's next
(This used to be commit f4f1f84a6b)
2003-02-12 09:14:35 +00:00
Andrew Tridgell
6c66e42d2c added the 'lsaenumacctwithright' command to rpcclient. This allows you
to lookup what SIDs have a particular privilege (that is how
privileges are stored).
(This used to be commit 3ddb5fb0dd)
2003-02-10 11:31:23 +00:00
Andrew Bartlett
df3acbadf8 One more signed/unsigned fix
(This used to be commit 013fa87473)
2003-02-01 06:25:08 +00:00
Tim Potter
c21af45555 Pass down max_size parameter to cli_samr_query_dispinfo() instead of
using a hardcoded value later on.

Added a helper function that returns the observed values for
max_entries and max_size for each cli_samr_query_dispinfo() call.
These values were obtained from watching the NT4 user manager
application with ethereal and are the only ones that can enumerate a
60k user domain reliably under Windows 2000.
(This used to be commit 2eea2813d9)
2003-01-29 06:20:08 +00:00
Andrew Tridgell
79b26867c0 added LsaRemoveAccountRights
this now gives us complete remove privileges control in the client
libs, so we are in good shape for starting on the server side.
(This used to be commit bf99440398)
2003-01-28 21:31:45 +00:00
Andrew Tridgell
5f9112ac1b cleaned up the lsa_enum_acct_rights function and added a
lsa_add_acct_rights function.

This allows us to add privileges remotely to accounts using rpcclient.
(This used to be commit 2e5e659e09)
2003-01-28 12:52:51 +00:00
Andrew Tridgell
96c795cea7 reverted this patch till I sort out the craziness with UNIHDR
(This used to be commit e3d00fa47d)
2003-01-17 06:15:18 +00:00
Andrew Tridgell
ec879eacc2 This removes the 3rd argument from init_unistr2(). There were 240
calls to init_unistr2() in the code and every one of them got the 3rd
argument incorrect, so I thought it best just to remove the argument.

The incorrect usage was caused by callers using strlen() to determine
the length of the string. The 3rd argument to init_unistr2() was
supposed to be the character length, not the byte length of the
string, so for non-english this could come out wrong.

I also removed the bogus 'always allocate at least 256 bytes'
hack. There may be some code that relies on this, but if there is then
the code is broken and needs fixing.
(This used to be commit b9eff31b14)
2003-01-17 04:58:45 +00:00
Tim Potter
5183aada24 Let's clean up client side ntlmssp!
Removed a dead function.
(This used to be commit a1c790b5ea)
2003-01-17 04:05:28 +00:00
Andrew Tridgell
eb6312af9f added cli_lsa_enum_account_rights() call. Note that this is in
principal similar to the existing cli_lsa_enum_privsaccount() call,
except that cli_lsa_enum_account_rights() doesn't require a call to
open_account first. There is also the minor matter that
cli_lsa_enum_account_rights() works whereas
cli_lsa_enum_privsaccount() doesn't!

this call can be used to find what privileges an account or group
has. This is a first step towards proper privileges support in Samba.
(This used to be commit 65bac11d71)
2003-01-15 07:40:40 +00:00
Tim Potter
3c23522863 Added comment about a SMB_ASSERT()
(This used to be commit 056bdfbce7)
2003-01-14 05:25:08 +00:00
Richard Sharpe
5bbac9dd80 Make sure that those cleanups actually went in.
(This used to be commit 9a38e37811)
2003-01-13 20:30:28 +00:00
Gerald Carter
47873e781d [merge] make sure to updatre print queue cache during timeout_processing() to send notify events; CR 1491
(This used to be commit 142c5029c7)
2003-01-11 02:29:23 +00:00
Andrew Bartlett
6d66fb308a BIG patch...
This patch makes Samba compile cleanly with -Wwrite-strings.
 - That is, all string literals are marked as 'const'.  These strings are
always read only, this just marks them as such for passing to other functions.

What is most supprising is that I didn't need to change more than a few lines of code (all
in 'net', which got a small cleanup of net.h and extern variables).  The rest
is just adding a lot of 'const'.

As far as I can tell, I have not added any new warnings - apart from making all
of tdbutil.c's function const (so they warn for adding that const string to
struct).

Andrew Bartlett
(This used to be commit 92a777d0ea)
2003-01-02 09:07:17 +00:00
Simo Sorce
60667264b7 the shutdown call does not have a 16 bit flags, but 2 byte representing booleans
this commit change the structure and code to reflect this

some test revelead I'm right.

some other revelead currently the abort shutdown does not work against my test machine even if it returns successfully ... need investigation
(This used to be commit c5892b656d)
2002-12-30 04:41:27 +00:00
Simo Sorce
a543e6ea62 make querygroup in rpcclient working, same fix as per 2.2 tree
(This used to be commit 8877ff2482)
2002-12-08 11:56:45 +00:00
Gerald Carter
e6f956f9b4 fix cli_ds_getprimarydominfo(); merge from SAMBA_3_0
(This used to be commit 481a8a8aa9)
2002-11-27 02:23:25 +00:00
Tim Potter
b2201f2f39 Merge from appliance:
>Fix memory leak in cli_ds_getprimarydominfo()
(This used to be commit e643003dd4)
2002-11-19 01:14:00 +00:00
Tim Potter
e0d81b7728 A cool idea from mbp: create a big shared library of all Samba objects
which we can use to link against Samba unit test programs.  Now we can
compile and link unit tests without having to create 4MB executables
for each program

It's called libbigballofmud.so both to discourage casual usage and
also to reflect what the dependencies within Samba have become.
(This used to be commit fdce4be719)
2002-11-15 00:20:55 +00:00
Jeremy Allison
250c980119 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.
(This used to be commit 82b8f749a3)
2002-11-12 23:15:52 +00:00
Jim McDonough
e4a5ae5259 What is wrong with you, Jim? Check in the final version, not an interim one...
(This used to be commit 1fd6d34526)
2002-11-07 15:43:04 +00:00
Jim McDonough
2b37e87bb9 Allow multiple fragment RPC's to be sent.
(This used to be commit d423e6424b)
2002-11-07 14:40:25 +00:00
Jeremy Allison
47955b2f6c 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.
(This used to be commit 10024ed06e)
2002-11-07 02:38:42 +00:00
Tim Potter
904649b6f0 Client side functions for enumprinterkey.
(This used to be commit f56ce473b6)
2002-11-06 23:38:39 +00:00
Tim Potter
84ef8d47a1 Display pipe name in rpc bind failure debug.
(This used to be commit 62ab0f8cbe)
2002-11-02 00:45:19 +00:00
Tim Potter
3a225c0785 Tidyup of some DCERPC pipe connection debugs. The new LSA_DS stuff
generates some errors we haven't seen before which are inappropriately
logged at level 0.
(This used to be commit bd64de3716)
2002-11-01 00:38:26 +00:00
Tim Potter
aed3a9f343 Fix a silly memset typo.
Change a int* to a uint32* in the cli_spoolss_enum_ports() function.
(This used to be commit 4663d79d3e)
2002-10-21 04:03:49 +00:00
Tim Potter
47cf2825f8 Zero tallocated memory in decode_printer_info, decode_driver_info,
decode_port_info and decode_printerdriver functions.
(This used to be commit bf2d9dd5ba)
2002-10-21 02:48:55 +00:00
Tim Potter
e7c011412b Do a SMB_ASSERT() in cli_nt_session_open() when the pipe index is out
of range instead of silently failing.
(This used to be commit b5111f47b5)
2002-10-17 05:08:34 +00:00
Gerald Carter
876afb5d0f merge from APP_HEAD
* s/driverlocation/comment
* detect native mode domain and enumerate local groups

Also

* Added sendfile stats from SAMBA_2_2
(This used to be commit 764b58e2c0)
2002-10-08 18:29:57 +00:00
Gerald Carter
d2eae2a299 merge native_mode flag in winbindd_domain struct from app-head
(This used to be commit dd948a302a)
2002-10-04 21:39:09 +00:00
Gerald Carter
d2ea6d5ae7 merge of working dsrolegetprimdominfo() client code from APP_HEAD
(This used to be commit f70caa25e4)
2002-10-04 19:11:36 +00:00
Gerald Carter
83e58265b5 merge of new client side support the Win2k LSARPC UUID in rpcbind
from APP_HEAD
(This used to be commit 38c9e42998)
2002-10-04 03:51:43 +00:00
Gerald Carter
5793e15a27 change notify merge from APP_HEAD
(This used to be commit b5227f0a64)
2002-09-10 02:38:15 +00:00
Tim Potter
18c3436f9d Return WERR_UNKNOWN_LEVEL for unknown info levels.
(This used to be commit d30da51956)
2002-09-09 03:22:39 +00:00
Tim Potter
1f919364f4 Return WERR_UNKNOWN_LEVEL for getprinterdriver level 6 as we don't
know how to decode a printer driver into a DRIVER_INFO_6 structure.
(This used to be commit 1338f623c2)
2002-09-09 01:13:27 +00:00
Tim Potter
c9e550f765 cli_spoolss_enumprinterdrivers:
Return WERR_UNKNOWN_LEVEL if we can't decode the returned buffer.
(This used to be commit 0379a32d82)
2002-09-06 01:12:52 +00:00
Tim Potter
7616f86a63 Conver cli_spoolss routines to use REGISTRY_VALUE and REGVAL_CTR code. Nice one jerry!
(Hey I thought I checked this in already?)
(This used to be commit f0c6303beb)
2002-09-03 05:35:47 +00:00
Tim Potter
70a132c2d9 Change JOB_INFO_CTR to return a pointer to an array rather than array of pointers.
Implemented client function for deleteprinterdataex.
(This used to be commit f7641c8fd1)
2002-09-03 03:18:19 +00:00
Tim Potter
882ff84daa Return data from enumprinterdataex by deep copying on passed in tdb context.
(This used to be commit 1f629aa54e)
2002-09-03 00:26:19 +00:00
Tim Potter
45fc6b503e Implemented some more client side spoolss functions:
- getprinterdataex(), setprinterdataex(), enumprinterdataex()

Pass data type down to setprinterdata() fn instead of hardcoding REG_SZ
(This used to be commit 62a6078253)
2002-09-02 07:37:35 +00:00
Jean-François Micouleau
cfb5e91178 added cli_net_auth_3 client code.
changed cli_nt_setup_creds() to call cli_net_auth_2 or cli_net_auth_3 based on a switch.
pass also the negociation flags all the way.
all the places calling cli_nt_setup_creds() are still using cli_net_aut2(), it's just for future use and for rpcclient.

in the future we will be able to call auth_2 or auth_3 as we want.

	J.F.
(This used to be commit 4d38caca40)
2002-08-30 10:46:59 +00:00