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

419 Commits

Author SHA1 Message Date
Gerald Carter
2a7847ea37 r13821: replacing some strings with macros
(This used to be commit a34ab5c827)
2007-10-10 11:10:56 -05:00
Gerald Carter
354c24d525 r13820: * Start fleshing out the XcvDataPort() server implementation
* Add support for the "Local Port" monitor as well through this API
(This used to be commit ba9cdd88a0)
2007-10-10 11:10:55 -05:00
Gerald Carter
e33b728c7b r13815: "Into the blind world let us now descend,"
Began the poet, his face as pale as death.
"I will go first, and you will follow me."
---

Adding XcvDataPort() to the spoolss code for remotely
add ports.  The design is to allow an intuitive means
of creating a new CUPS print queue from the Windows 2000/XP
APW without hacks like specifying the deviceURI in the
location field of the printer properties dialog.

Also set 'default devmode = yes' as the new default
since it causes no harm and only is executed when you
have a NULL devmode anyways.
(This used to be commit 123e478ce5)
2007-10-10 11:10:55 -05:00
Gerald Carter
b2ae6e08da r13547: add earlier checks to deny deleting a printer driver. The previous
code relied upon file permissions alone.  Now we check that
the user is a printer administrator and that the share has not been
marked read only for that user.
(This used to be commit 117d9fd9e1)
2007-10-10 11:10:12 -05:00
Gerald Carter
0af1500fc0 r13316: Let the carnage begin....
Sync with trunk as off r13315
(This used to be commit 17e63ac4ed)
2007-10-10 11:06:23 -05:00
Jeremy Allison
d14af63e6a r13293: Rather a big patch I'm afraid, but this should fix bug #3347
by saving the UNIX token used to set a delete on close flag,
and using it when doing the delete. libsmbsharemodes.so still
needs updating to cope with this change.
Samba4 torture tests to follow.
Jeremy.
(This used to be commit 23f16cbc2e)
2007-10-10 11:06:21 -05:00
Jeremy Allison
d1f91f7c72 r12043: It's amazing the warnings you find when compiling on a 64-bit
box with gcc4 and -O6...
Fix a bunch of C99 dereferencing type-punned pointer will break
strict-aliasing rules errors. Also added prs_int32 (not uint32...)
as it's needed in one place. Find places where prs_uint32 was being
used to marshall/unmarshall a time_t (a big no no on 64-bits).
More warning fixes to come.
Thanks to Volker for nudging me to compile like this.
Jeremy.
(This used to be commit c65b752604)
2007-10-10 11:05:42 -05:00
Gerald Carter
f2ecd4fed0 r11860: BUG 3156: don't use find_service() when explicitly looking for a printer as the username map might get in the way
(This used to be commit 46bf28c81c)
2007-10-10 11:05:31 -05:00
Gerald Carter
cd310c19ce r11240: * fix invalid read reported by valgrind in the
spoolss backchannel connection by rewriting
  spoolss_connect_to_client().  Ensure that we
  save the cli_state* in the rpc_pipe_client struct.

* fix typo in debug message in cli_start_connection"
(This used to be commit 18400f9662)
2007-10-10 11:05:09 -05:00
Gerald Carter
6fc9098dcc r11235: fix segfault in addprinter due to mixing talloc() and malloc()'d memory
(This used to be commit f6f78877b4)
2007-10-10 11:05:08 -05:00
Gerald Carter
6f72169c7c r11135: should fix seg fault in addprinter code reported by Marcin. Allocate memory in convert_printer_info() if necessary
(This used to be commit 7ada5da8e9)
2007-10-10 11:05:02 -05:00
Gerald Carter
54abd2aa66 r10656: BIG merge from trunk. Features not copied over
* \PIPE\unixinfo
* winbindd's {group,alias}membership new functions
* winbindd's lookupsids() functionality
* swat (trunk changes to be reverted as per discussion with Deryck)
(This used to be commit 939c3cb5d7)
2007-10-10 11:04:48 -05:00
Günther Deschner
513e81458f r9945: fix typos.
Guenther
(This used to be commit 12029e9022)
2007-10-10 11:03:28 -05:00
Gerald Carter
c53e760ea5 r9752: figured out why talloc_steal() is a bad idea for SEC_DESC*
Add a comment so someone else doesn't get bitten by this as well.
(This used to be commit 050364ef34)
2007-10-10 11:03:25 -05:00
Gerald Carter
44707ad2e0 r9739: conver the reg_objects (REGSUBKEY_CTR & REGVAL_CTR) to use
the new talloc() features:

 Note that the REGSUB_CTR and REGVAL_CTR objects *must* be talloc()'d
 since the methods use the object pointer as the talloc context for
 internal private data.

 There is no longer a regXXX_ctr_intit() and regXXX_ctr_destroy()
 pair of functions.  Simply TALLOC_ZERO_P() and TALLOC_FREE() the
 object.

Also had to convert the printer_info_2->NT_PRINTER_DATA field
to be talloc()'d as well.  This is just a stop on the road to
cleaning up the printer memory management.
(This used to be commit ef721333ab)
2007-10-10 11:03:25 -05:00
Gerald Carter
d04c1efd0f r9264: fix valgrind invalid write error in enumprinterdata()
(This used to be commit bfebbc86fc)
2007-10-10 11:00:29 -05:00
Günther Deschner
fdc2ab72f7 r9021: Fix smbd-crash bug in openprinter (found by samba4 smbtorture
RPC-SPOOLSS).

Guenther
(This used to be commit 06bfe789d5)
2007-10-10 11:00:23 -05:00
Gerald Carter
57939971b4 r8916: should fix the valgrind invalid read of size 1 onthe
GetPrinterData("OSVersion") abartlet saw when browsing from
Vista client.
(This used to be commit b527b86ae8)
2007-10-10 11:00:20 -05:00
Jeremy Allison
ae64b2f2aa r8617: Be very explicit if addprinterex is called that the "addprinter command"
must be defined in smb.conf.
Jeremy.
(This used to be commit 86f8368c99)
2007-10-10 11:00:13 -05:00
Gerald Carter
6fe5451543 r8501: * disable printer handle object cache (was mostly used
for NT4 clients enumerating printer data on slow CPUs)
* fix pinter and secdesc record upgrade to normalize the key
  (rev'd printer tdb version)
* fixed problem that was normalizing the printername name field

in general, this should fix the issues upgrading print servers
from 3.0.14a to 3.0.20
(This used to be commit d07179de2f)
2007-10-10 11:00:06 -05:00
Gerald Carter
f2ff8bed26 r8326: factor out the delete printer code to a delete_printer_hook() for reuse
(This used to be commit 0689851a90)
2007-10-10 10:58:20 -05:00
Gerald Carter
e574081ad9 r8324: * initial cut at creating printers via the registry API
Need to add delete_key support
(This used to be commit 9a27f7181a)
2007-10-10 10:58:19 -05:00
Gerald Carter
18609ce1af r8322: * get RegSetValue() working for printer subkey values
(not immediate values below the <printer name> key yet.
(This used to be commit a872ea5f0e)
2007-10-10 10:58:19 -05:00
Gerald Carter
c296f858ef r8066: * had to modify the printer data storage slightly in ntprinters.tdb
when packing values.  It is a compatible change though and will
  not require a tdb version upgrade
* Can successfully create new printer subkeys via winreg that
  are immediately available via spoolss calls.  Still cannot delete
  keys yet though.  That comes next.
(This used to be commit 00bce2b3bb)
2007-10-10 10:58:10 -05:00
Gerald Carter
270b90e25f r7995: * privileges are local except when they're *not*
printmig.exe assumes that the LUID of the SeBackupPrivlege
  on the target server matches the LUID of the privilege
  on the local client.  Even though an LUID is never guaranteed
  to be the same across reboots.  How *awful*!  My cat could
  write better code! (more on my cat later....)

* Set the privelege LUID in the global PRIVS[] array

* Rename RegCreateKey() to RegCreateKeyEx() to better match MSDN

* Rename the unknown field in RegCreateKeyEx() to disposition
  (guess according to MSDN)

* Add the capability to define REG_TDB_ONLY for using the reg_db.c
  functions and stress the RegXXX() rpc functions.
(This used to be commit 0d6352da48)
2007-10-10 10:58:07 -05:00
Jeremy Allison
19ca97a70f r7882: Looks like a large patch - but what it actually does is make Samba
safe for using our headers and linking with C++ modules. Stops us
from using C++ reserved keywords in our code.
Jeremy
(This used to be commit 9506b8e145)
2007-10-10 10:58:00 -05:00
Gerald Carter
f2f115c2a2 r7614: convert move_driver_to_download_area() to return WERROR in order to provide better error messages to clients when a AddPrinterDriver[Ex]() call fails
(This used to be commit c98e17446a)
2007-10-10 10:57:16 -05:00
Gerald Carter
f24d88cf9d r7139: trying to reduce the number of diffs between trunk and 3.0; changing version to 3.0.20pre1
(This used to be commit 9727d05241)
2007-10-10 10:57:02 -05:00
Gerald Carter
f0c650a382 r6942: * merging the registry changes back to the 3.0 tree
* removing the testprns tool
(This used to be commit 81ffb0dbbb)
2007-10-10 10:56:57 -05:00
Jeremy Allison
fe0ce8dd8e r6890: Refactor printing interface to take offset into job. Fixes bug
where large print jobs can have out-of-order offsets. Bug found
by Arcady Chernyak <Arcady.Chernyak@efi.com>
Jeremy.
(This used to be commit 482f7e0e37)
2007-10-10 10:56:56 -05:00
Gerald Carter
4f3c2d4424 r6679: BUG 2684: abartlett's patch for check the per service hosts allow/deny on printers when connecting via MS-RPC
(This used to be commit 80da9ca386)
2007-10-10 10:56:51 -05:00
Herb Lewis
978ca84860 r6225: get rid of warnings from my compiler about nested externs
(This used to be commit efea76ac71)
2007-10-10 10:56:30 -05:00
Gerald Carter
5d1cb8e79e r6014: rather large change set....
pulling back all recent rpc changes from trunk into
3.0.  I've tested a compile and so don't think I've missed
any files.  But if so, just mail me and I'll clean backup
in a couple of hours.

Changes include \winreg, \eventlog, \svcctl, and
general parse_misc.c updates.

I am planning on bracketing the event code with an
#ifdef ENABLE_EVENTLOG until I finish merging Marcin's
changes (very soon).
(This used to be commit 4e0ac63c36)
2007-10-10 10:56:15 -05:00
Gerald Carter
d177f1bc8f r5806: * fix a couple more segvs in spoolss
* comment out unused variable after jra's change to revert the 56bit des
  smb signing changes
(This used to be commit 13ed08cd2a)
2007-10-10 10:56:02 -05:00
Gerald Carter
61dfab9f70 r5805: merging spoolss parsing changes from trunk and cleaning up resulting segvs
(This used to be commit 25121547ca)
2007-10-10 10:56:01 -05:00
Gerald Carter
5ba59da467 r5605: only display the publish check box on printer if
we are a member of an AD domain

clean up some hardcoded constands with the REG_XXX constant.
(This used to be commit a1d0be740d)
2007-10-10 10:55:50 -05:00
Gerald Carter
372440f207 r4856: after testing a simple add printer script, i realized that you still have to be root to send the message to all smbds that the config file has been updated
(This used to be commit 6409de1a1e)
2007-10-10 10:54:00 -05:00
Gerald Carter
10861a6160 r4825: Printing changes
----------------

* bracket the add/delete/set printer scripts with checks for se_print_op
* slight change to the add/set printer script semantics.  smbd no longer
  relies on output from the script (on stdout) to re-read smb.conf
* remove SIGHUP from set/add/delete printin script code and now just
  use MSG_SMB_CONF_UPDATED

* bracket the add/delete/set share scripts with checks for se_print_op
  (this includes setting share ACLs)
(This used to be commit 8ab8113d2e)
2007-10-10 10:53:56 -05:00
Gerald Carter
46e5effea9 r4805: Last planned change to the privileges infrastructure:
* rewrote the tdb layout of privilege records in account_pol.tdb
  (allow for 128 bits instead of 32 bit flags)
* migrated to using SE_PRIV structure instead of the PRIVILEGE_SET
  structure.  The latter is now used for parsing routines mainly.

Still need to incorporate some client support into 'net' so
for setting privileges.  And make use of the SeAddUserPrivilege
right.
(This used to be commit 41dc7f7573)
2007-10-10 10:53:55 -05:00
Gerald Carter
2c33c41b0c r4740: allow SE_PRINT_OPERATORS to have printer admin access
(This used to be commit 85731706c9)
2007-10-10 10:53:53 -05:00
Jeremy Allison
00eede9a6b r4184: Removed unused extern.
Jeremy.
(This used to be commit 72e39041e9)
2007-10-10 10:53:36 -05:00
Gerald Carter
3c45a093c4 r4134: check the setprinter(3) based on the access permissions on the handle and avoid the call to print_access_chaeck()
(This used to be commit 426634df9c)
2007-10-10 10:53:35 -05:00
Jeremy Allison
acf9d61421 r4088: Get medieval on our ass about malloc.... :-). Take control of all our allocation
functions so we can funnel through some well known functions. Should help greatly with
malloc checking.
HEAD patch to follow.
Jeremy.
(This used to be commit 620f2e608f)
2007-10-10 10:53:32 -05:00
Gerald Carter
3bd3be97dc r4083: consolidate printer searches to use find_service rather than for loops
(This used to be commit 12440744ba)
2007-10-10 10:53:31 -05:00
Gerald Carter
4e18fa46d5 r3069: add 'force printername' service parameter for people that want to enforce printername == sharename for spoolss printing
(This used to be commit d47b8a0b4f)
2007-10-10 10:53:00 -05:00
Gerald Carter
f2aca08c65 r3066: BUG 1519: fix segfault caused by double free of a printer
(This used to be commit 3760464193)
2007-10-10 10:53:00 -05:00
Gerald Carter
0af8284de1 r3065: BUG 1519 (more): apparently the server_name notify request is used to fill in the title bar of the port monitor window and unless we get it right, you cannot open the printer properties from the port monitor window
(This used to be commit fc691572c9)
2007-10-10 10:53:00 -05:00
Gerald Carter
c53e6401eb r3049: fixing some calls in the printing code to stanard_sub_basic(); fix standard_sub_snum() to use the current user's gid; add some (snum == -1) checks to standard_sub_advanced()
(This used to be commit 8c3fd1908d)
2007-10-10 10:52:59 -05:00
Gerald Carter
7df1ed060b r2955: fixing a segfault uncovered by the changes for BUG 1519
(This used to be commit 1664395257)
2007-10-10 10:52:57 -05:00
Gerald Carter
a169b950c7 r2918: BUG 1907: fix getprinterdriverdir_1(). have to make sure we don't add unnecessary double slashes to the servername
(This used to be commit 859599dbca)
2007-10-10 10:52:56 -05:00