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

1119 Commits

Author SHA1 Message Date
Simo Sorce
a557af96e9 THE Idmap patch :-)
includes a --with-idmap=no switch to disable idmap usage if you find
problems.

cosmetic fixes and param aliases to separate winbind from idamp roles.

A temporarily remote idmap winbind compatibility backend.
As I have time I will further change code to not call directly winbind
(partly done but not tested) and a specilized module will be built in place
for the current glue hack.

The patch has been tested locally in my limited time, the patch is simple and
clear and should not reserve problems, if any just disable it.

As usual, comments and fisex are welcome :-)

Simo.
(This used to be commit 0278132047)
2003-04-02 10:36:02 +00:00
Jeremy Allison
f6f96c2966 Subtle changes to message handling after ENUMJOBS.
Jeremy.
(This used to be commit 48f3bf0ea5)
2003-04-02 02:26:01 +00:00
Gerald Carter
c5ff693082 fix potential handle leak in _spoolss_open_printer_ex(); final fix for CR2102; reviewed by jra
(This used to be commit 3d37e1ece9)
2003-04-01 14:58:42 +00:00
Gerald Carter
b5733dd6ef fix potential smbd crash when we fail to alloacte a policy handle for a printer open; CR 2102 (reviewed by jreilly)
(This used to be commit a179c2cefb)
2003-03-31 17:39:21 +00:00
Gerald Carter
47f230b761 add a few error checks in EnumPrinterData()
(This used to be commit 453813ec6e)
2003-03-31 01:00:34 +00:00
Jelmer Vernooij
cdfe4b9b85 Fix two typos
(This used to be commit 898a246c16)
2003-03-24 19:53:02 +00:00
Jelmer Vernooij
f2c1d6895f Give error message when module doesn't seem to contain
pipe functions
(This used to be commit 4dd1679043)
2003-03-24 18:38:59 +00:00
Andrew Bartlett
677838b999 Give volker a hand, and let domain joins with existing user accounts work
a bit better.

This just sets the minimum possible attributes - if we are 'upgrading' an
LDAP based user account, the attributes will be there anyway.  This matches
NT pretty well to.

This also fixes some use of unitialised values in the desired_access checking.
(found by valgrind).

Andrew Bartlett
(This used to be commit 929213ff2a)
2003-03-21 13:28:06 +00:00
Jeremy Allison
c8eed69be0 lib/messages.c: Check return from chainlock before modifying message queue.
Apply the job returned limit across all requests for job queues.
Jeremy.
(This used to be commit dee1326a1d)
2003-03-20 00:51:41 +00:00
Jelmer Vernooij
47ea3a2bf2 Put in the new modules system. It's now used by passdb and rpc. I will
put a doc about it in dev-doc later today.
(This used to be commit af7bfee0c6)
2003-03-19 18:45:19 +00:00
Jeremy Allison
736c753841 Ensure dev in make_connection is const.
Jeremy.
(This used to be commit e8155fade6)
2003-03-18 23:51:18 +00:00
Andrew Bartlett
7b18c5d164 Make sure we mark the assumption of a fstring parameter for 'devicetype'
in the function prototype, and change callers to respect this.

Andrew Bartlett
(This used to be commit 9f3d3c3801)
2003-03-16 13:24:36 +00:00
Andrew Bartlett
04858cd702 Limit the number of SIDs that may be looked up, in line with existing code
for name->sid.
(This used to be commit 0ebccc0dbe)
2003-03-07 09:29:56 +00:00
Gerald Carter
03a4c1907f * always report ourselves as a Windows 2000 print server (even
without ADS support)
* add "MinorVersion" print server data key and comment on "OSVersion"
(This used to be commit 342734e3de)
2003-03-03 17:33:57 +00:00
Gerald Carter
21be9e7776 * CR1868: only send a change notify message if we have something
that changed that the client is monitoring.

* couple of comments abnout how we need to validate driver names
  on SetPrinter() and AddPrinter()

* up the debug level on some overly verbose dev mode parsing messages
(This used to be commit 7377d671e8)
2003-03-03 16:34:19 +00:00
Jeremy Allison
e2366787ae Added limit to number of jobs enumerated. Set to 0 (means no limit).
Yes I will add the docs....
Jeremy.
(This used to be commit 4a739d914b)
2003-03-01 02:39:14 +00:00
Gerald Carter
97e7d2ffae additional fix for CR 601
* distinguish WinXP from Win2k
  * add a 1/3 of a second delay in OpenPrinter
    in order to trigger a LAN/WAN optimization in
    2k clients.
(This used to be commit 96570699d1)
2003-02-27 21:21:02 +00:00
Gerald Carter
7c7d796b6d Progress on CR 601
cache the printer_info_2 with the open printer handle.
cache is invalidated on a mod_a_printer() call **on that smbd**.

Yes, this means that the window for admins to step on each other
from different clients just got larger, but since handles a generally
short lived this is probably ok.
(This used to be commit 33c7b75225)
2003-02-25 20:51:23 +00:00
Gerald Carter
3d730f89cf i patched the wrong branch! s/unistr2_to_dos/unistr2_to_ascii/
(This used to be commit 513fb2ddd8)
2003-02-21 20:00:46 +00:00
Gerald Carter
ab985b983f couple of merges from APP_HEAD
* performance optimization in enumprinterdataex() when keyname is empty
  * fix a few typos in comments
  * reload services after addprinter_command()

dump registry data in ascii when the key is REG_SZ or REG_MULTI_SZ
(This used to be commit fde6ef7cc6)
2003-02-21 17:08:43 +00:00
Tim Potter
9383d61f6c Fixed compiler warning.
(This used to be commit b3f9cf8c1c)
2003-02-21 04:47:24 +00:00
Jelmer Vernooij
8d8a8c9633 Make init_module() and thus smb_load_module() return an int.
modules/developer.c: init_module() should return an int
(This used to be commit 7f59703550)
2003-02-20 22:26:28 +00:00
Jelmer Vernooij
c536b88b2b Use the new modules stuff to load dynrpc modules. Basically this means:
- calling the initialization function in the module init_module() instead of rpc_pipe_init()
- calling smb_load_module() to do the dlopen(), dlsym() and init_module() calls

I'll merge this to 3.0, together with the smb_load_module() function.

Discussed with Anthony.
(This used to be commit 3757ed8df0)
2003-02-18 18:34:48 +00:00
Gerald Carter
336ae66c5a set the various DsSpooler keys that are linked to PRINTER_INFO_2 fields; CR 985
(This used to be commit 9a4b7a86fd)
2003-02-18 03:43:08 +00:00
Andrew Bartlett
cc0202884b This patch fixes one of my longest-standing pet hates with Samba :-).
When we look see if a user is in a list, and we try to 'expand' an @group, we
should lookup the user's own list of groups, rather than looking for all the
members of a group.

I'm sure this will fix some nasty performance issues, particularly on large
domains etc.  In particular, this avoids contacting winbind at all, if the
group is not a winbind group.

(This caused a deadlock on my winbind-on-PDC setup).

The groups list always includes the user's primary group, as per the
getgrouplist manpage, and my recent changes to our implementation.

Andrew Bartlett
(This used to be commit 9be21976f7)
2003-02-17 12:27:34 +00:00
Gerald Carter
a703d55cd7 * set PRINTER_ATTRIBUTE_RAW_ONLY; CR 1736
* never save a pointer to an automatic variable (they go away)
  implement a deep copy for SPOOLSS_NOTIFY_MSG to correct
  messages being sent that have junk for strings;
  fix in response to changes for CR 1504
(This used to be commit 043b9dff22)
2003-02-15 23:36:18 +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
Jeremy Allison
db937d3965 Removed unused variable.
Jeremy.
(This used to be commit c9654c8ec7)
2003-02-13 19:42:50 +00:00
Jeremy Allison
f4092b90bf Merge JohnR's patch.
Removed extra copy of server name in the printername field (it was
mangling the the name to be \\server\\\server\printer ... yes, there
were 3 backslashes) reported by get & enum jobs level 2.
Jeremy.
(This used to be commit d079edf732)
2003-02-13 06:52:45 +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
8ddccd47c7 added server stubs for lsa_enum_acct_with_right
(This used to be commit aa2abacaf4)
2003-02-11 21:55:48 +00:00
Andrew Tridgell
b4776d89ea added the LSA privileges server backend stubs. Right now they just log
what was requested.
(This used to be commit 64ac6c2bcb)
2003-02-06 05:42:19 +00:00
Jeremy Allison
56060dcf9e Fixed type.
Jeremy.
(This used to be commit ae635bb6ec)
2003-02-05 22:09:32 +00:00
Andrew Bartlett
28e3e48431 Send the user's session key in the SAMLOGON reply, so that a member server can
use smb signing.

Andrew Bartlett
(This used to be commit 574e8a8ab7)
2003-02-02 05:10:26 +00:00
Gerald Carter
2bdcf68ab6 don't free() auto variables; fixes segfault when looking up RefusePasswordChange registry value
(This used to be commit d89b0bff44)
2003-01-21 03:42:38 +00:00
Gerald Carter
52b65f70ca strip any trailing \'s from reg key names in an open
(This used to be commit 03807cd564)
2003-01-19 05:04:20 +00:00
Jim McDonough
e2f2558753 Fix some debug levels (were set to 0 with RPC module patch), and
change one fprintf(stderr,...) to DEBUG.
(This used to be commit 77f8913977)
2003-01-18 20:41:19 +00:00
Gerald Carter
8c6790b6f0 removing extra debug statement
(This used to be commit 657f8c25a5)
2003-01-18 01:41:00 +00:00
Jim McDonough
9eb368e068 Enable dynamic loading of RPC modules. See docs/textdocs/RPC_PLUGGIN.txt for instructions.
(This used to be commit d51e12df78)
2003-01-17 20:57:26 +00:00
Jeremy Allison
074c99a852 Fix reference count bug where smbd's would not terminate with no
open resources.
Jeremy.
(This used to be commit 0173d6fe16)
2003-01-17 06:35:33 +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
Gerald Carter
5fb5950258 small merges from SAMBA_3_0; mostly typos, renames, etc...
(This used to be commit 9ac196dad4)
2003-01-15 18:31:46 +00:00
Andrew Bartlett
1fdaca3342 The last of the fstring/pstring mixups, and an extra 'static'.
(This used to be commit b328b67fd8)
2003-01-14 06:46:14 +00:00
Andrew Bartlett
183ccefce7 A couple more pstcpy/fstrcpy mixups - doing an fstrcpy into a pstring is
harmless, but breaks my automated check.
(This used to be commit e5d2b1f6c3)
2003-01-14 06:36:40 +00:00
Gerald Carter
27b05b4df9 typo from merge
(This used to be commit 1f33b4acb3)
2003-01-11 02:36:13 +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
Gerald Carter
6df2dc56ff a 0 length printer data value is not a memory allocation error; fix CR601
(This used to be commit 3442c270f1)
2003-01-09 19:51:28 +00:00
Andrew Bartlett
ff18825765 We already have one function to move unistr2 -> multibyte-static, so we
don't need a second just for pdb.

Also, remove magic 'is lp_guest_account' test - the magic RID should be
up to the passdb backend to set.

Andrew Bartlett
(This used to be commit f71c8338d3)
2003-01-02 13:10:25 +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