summaryrefslogtreecommitdiff
path: root/source3/rpc_server/srv_spoolss_nt.c
AgeCommit message (Collapse)AuthorFilesLines
2007-10-10r13316: Let the carnage begin....Gerald Carter1-7/+13
Sync with trunk as off r13315 (This used to be commit 17e63ac4ed8325c0d44fe62b2442449f3298559f)
2007-10-10r13293: Rather a big patch I'm afraid, but this should fix bug #3347Jeremy Allison1-6/+6
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 23f16cbc2e8cde97c486831e26bcafd4ab4a9654)
2007-10-10r12043: It's amazing the warnings you find when compiling on a 64-bitJeremy Allison1-1/+1
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 c65b752604f8f58abc4e7ae8514dc2c7f086271c)
2007-10-10r11860: BUG 3156: don't use find_service() when explicitly looking for a ↵Gerald Carter1-14/+16
printer as the username map might get in the way (This used to be commit 46bf28c81c27dfdc412318a83bf565211a58a47d)
2007-10-10r11240: * fix invalid read reported by valgrind in theGerald Carter1-68/+34
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 18400f96628ffdd332c2fb2aa52b5e9aee5cb3ce)
2007-10-10r11235: fix segfault in addprinter due to mixing talloc() and malloc()'d memoryGerald Carter1-3/+1
(This used to be commit f6f78877b485be5efd5cf1f3147b2e9fee647e52)
2007-10-10r11135: should fix seg fault in addprinter code reported by Marcin. ↵Gerald Carter1-6/+15
Allocate memory in convert_printer_info() if necessary (This used to be commit 7ada5da8e94a08a9a3e488172fa04ce688882299)
2007-10-10r10656: BIG merge from trunk. Features not copied overGerald Carter1-26/+29
* \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 939c3cb5d78e3a2236209b296aa8aba8bdce32d3)
2007-10-10r9945: fix typos.Günther Deschner1-1/+1
Guenther (This used to be commit 12029e902277053a4066eae1b3ae311fae5e6422)
2007-10-10r9752: figured out why talloc_steal() is a bad idea for SEC_DESC*Gerald Carter1-2/+10
Add a comment so someone else doesn't get bitten by this as well. (This used to be commit 050364ef34b1e69260bd9df9e2140c45263e92f5)
2007-10-10r9739: conver the reg_objects (REGSUBKEY_CTR & REGVAL_CTR) to useGerald Carter1-129/+38
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 ef721333ab9639cb5346067497e99fbd0d4425dd)
2007-10-10r9264: fix valgrind invalid write error in enumprinterdata()Gerald Carter1-2/+3
(This used to be commit bfebbc86fc0f90e580888da25006d8e5e50b6304)
2007-10-10r9021: Fix smbd-crash bug in openprinter (found by samba4 smbtortureGünther Deschner1-4/+10
RPC-SPOOLSS). Guenther (This used to be commit 06bfe789d54a12dfa3c46e9777f96ff7e162a9db)
2007-10-10r8916: should fix the valgrind invalid read of size 1 ontheGerald Carter1-8/+8
GetPrinterData("OSVersion") abartlet saw when browsing from Vista client. (This used to be commit b527b86ae80ebc0b6e7318ed31d44be985aa9af0)
2007-10-10r8617: Be very explicit if addprinterex is called that the "addprinter command"Jeremy Allison1-2/+7
must be defined in smb.conf. Jeremy. (This used to be commit 86f8368c997f0eece20724a0a7158832c66da9f7)
2007-10-10r8501: * disable printer handle object cache (was mostly usedGerald Carter1-0/+5
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 d07179de2f2a6eb1d13d0e25ac10de1a21475559)
2007-10-10r8326: factor out the delete printer code to a delete_printer_hook() for reuseGerald Carter1-56/+53
(This used to be commit 0689851a90fbd91ff30f6e2afc05d141f6ce082d)
2007-10-10r8324: * initial cut at creating printers via the registry APIGerald Carter1-3/+4
Need to add delete_key support (This used to be commit 9a27f7181adca10f60c47d342a51dec34321e12b)
2007-10-10r8322: * get RegSetValue() working for printer subkey valuesGerald Carter1-1/+1
(not immediate values below the <printer name> key yet. (This used to be commit a872ea5f0e29f7b585574a56b52a5eb44cb92278)
2007-10-10r8066: * had to modify the printer data storage slightly in ntprinters.tdbGerald Carter1-1/+1
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 00bce2b3bb78a44842a258b1737076281297d247)
2007-10-10r7995: * privileges are local except when they're *not*Gerald Carter1-3/+4
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 0d6352da4800aabc04dfd7c65a6afe6af7cd2d4b)
2007-10-10r7882: Looks like a large patch - but what it actually does is make SambaJeremy Allison1-8/+8
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 9506b8e145982b1160a2f0aee5c9b7a54980940a)
2007-10-10r7614: convert move_driver_to_download_area() to return WERROR in order to ↵Gerald Carter1-3/+1
provide better error messages to clients when a AddPrinterDriver[Ex]() call fails (This used to be commit c98e17446afffc4b12f1a31f6e5cce517fc0a95b)
2007-10-10r7139: trying to reduce the number of diffs between trunk and 3.0; changing ↵Gerald Carter1-38/+39
version to 3.0.20pre1 (This used to be commit 9727d05241574042dd3aa8844ae5c701d22e2da1)
2007-10-10r6942: * merging the registry changes back to the 3.0 treeGerald Carter1-63/+40
* removing the testprns tool (This used to be commit 81ffb0dbbbd244623507880c323a3c37e2b8dc4d)
2007-10-10r6890: Refactor printing interface to take offset into job. Fixes bugJeremy Allison1-2/+3
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 482f7e0e3706098b71aa0b31a134994acb1e9fcf)
2007-10-10r6679: BUG 2684: abartlett's patch for check the per service hosts ↵Gerald Carter1-0/+5
allow/deny on printers when connecting via MS-RPC (This used to be commit 80da9ca3869380541728cb38df93d012eb20c307)
2007-10-10r6225: get rid of warnings from my compiler about nested externsHerb Lewis1-1/+2
(This used to be commit efea76ac71412f8622cd233912309e91b9ea52da)
2007-10-10r6014: rather large change set....Gerald Carter1-11/+8
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 4e0ac63c36527cd8c52ef720cae17e84f67e7221)
2007-10-10r5806: * fix a couple more segvs in spoolssGerald Carter1-14/+9
* comment out unused variable after jra's change to revert the 56bit des smb signing changes (This used to be commit 13ed08cd2a1097021cc44f4109859ba89db7df81)
2007-10-10r5805: merging spoolss parsing changes from trunk and cleaning up resulting ↵Gerald Carter1-399/+509
segvs (This used to be commit 25121547caaaed0d60f4db7458570c14e7d21b2a)
2007-10-10r5605: only display the publish check box on printer ifGerald Carter1-12/+20
we are a member of an AD domain clean up some hardcoded constands with the REG_XXX constant. (This used to be commit a1d0be740d9ea8c9ea8c04950da826dd84bbc51b)
2007-10-10r4856: after testing a simple add printer script, i realized that you still ↵Gerald Carter1-9/+9
have to be root to send the message to all smbds that the config file has been updated (This used to be commit 6409de1a1ef34bb41c3efeebfabdf13be5e08613)
2007-10-10r4825: Printing changesGerald Carter1-17/+57
---------------- * 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 8ab8113d2e1bec6a1dbf464882ad724c7c591be4)
2007-10-10r4805: Last planned change to the privileges infrastructure:Gerald Carter1-1/+3
* 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 41dc7f7573c6d637e19a01e7ed0e716ac0f1fb15)
2007-10-10r4740: allow SE_PRINT_OPERATORS to have printer admin accessGerald Carter1-2/+4
(This used to be commit 85731706c9d794e8bd3f26ce9b1f881c1ee6a3ba)
2007-10-10r4184: Removed unused extern.Jeremy Allison1-1/+0
Jeremy. (This used to be commit 72e39041e9fbb7f252292182d56b1927a8133be0)
2007-10-10r4134: check the setprinter(3) based on the access permissions on the handle ↵Gerald Carter1-14/+11
and avoid the call to print_access_chaeck() (This used to be commit 426634df9c221fbe4f48b4ff9d1b4b8426a581f7)
2007-10-10r4088: Get medieval on our ass about malloc.... :-). Take control of all our ↵Jeremy Allison1-87/+87
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 620f2e608f70ba92f032720c031283d295c5c06a)
2007-10-10r4083: consolidate printer searches to use find_service rather than for loopsGerald Carter1-16/+6
(This used to be commit 12440744ba36445186042c8c254785766cce5385)
2007-10-10r3069: add 'force printername' service parameter for people that want to ↵Gerald Carter1-14/+30
enforce printername == sharename for spoolss printing (This used to be commit d47b8a0b4f348171df35b3b0028ce7d99fab8af3)
2007-10-10r3066: BUG 1519: fix segfault caused by double free of a printerGerald Carter1-1/+0
(This used to be commit 3760464193c540e82f0ba4e61d1d3b96a9803aca)
2007-10-10r3065: BUG 1519 (more): apparently the server_name notify request is used to ↵Gerald Carter1-13/+4
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 fc691572c9ba5ae85c63db5202b7777efdbf7260)
2007-10-10r3049: fixing some calls in the printing code to stanard_sub_basic(); fix ↵Gerald Carter1-3/+3
standard_sub_snum() to use the current user's gid; add some (snum == -1) checks to standard_sub_advanced() (This used to be commit 8c3fd1908d201e9891878ff4c3259ed9690dff97)
2007-10-10r2955: fixing a segfault uncovered by the changes for BUG 1519Gerald Carter1-1/+2
(This used to be commit 1664395257eb2425246e200ebde4384aa54484a4)
2007-10-10r2918: BUG 1907: fix getprinterdriverdir_1(). have to make sure we don't ↵Gerald Carter1-2/+11
add unnecessary double slashes to the servername (This used to be commit 859599dbcaa9e39a7902cc959955fcea2dad334b)
2007-10-10r2821: Adding "Windows x64" as architecture string and driverdir "x64" for theGünther Deschner1-0/+1
64bit AMD platform. (This used to be "Windows AMD64" and "AMD64" in one of the release candidates of SP2 for Windows XP. AMD64 is obviously still supported but not documented.) Guenther (This used to be commit cc5892f0411b8eb5daebe746164a2cf21d3d4c68)
2007-10-10r2768: BUG 1519: save the hostname used in the open_printer_ex() for later ↵Gerald Carter1-113/+164
reuse when filling in the spolss replies (also gets rid of get_called_name() (This used to be commit 57db8ca91f52329c7f8985c04463b6b69015b0c4)
2007-10-10r2569: Patch from Rob Foehl <rwf@loonybin.net>:Gerald Carter1-12/+12
- fix typo in libads/ldap_printer.c:39, ads_find_printer_on_server() (originally libads-typo.patch) - fix leak in printing/nt_printing.c, is_printer_published() (originally is_printer_published-leak.patch) - fix double print_backend_init() calls, now only called from main() - restructuring in printing/nt_printing.c - replaced (un)publish_it() with ads-specific functions - moved common code to nt_printer_publish() - improved error handling in several places - added check_published_printers() in printing/nt_printing.c, to verify that each published printer is actually in the directory at startup - changed calling semantics of mod_a_printer, dump_a_printer, and update_driver_init to be more consistent with the rest of the api and reduce some copying (This used to be commit 50a5a3dbd02acb0d09133b6e42cc37d091ea901d)
2007-10-10r2133: Several fixes:Gerald Carter1-2/+10
* BUG 1627: fix for NIS compiles on HPUX 11.00, AIX 4.3 and 5.1 patch from Olaf Flebbe <o.flebbe@science-computing.de>. Will need to watch this one in the build farm. * Fix bug found by rwf@loonybin.net where the PRINT_ATTRIBUTE_PUBLISHED was getting reset by attempts to sanitize the defined attributes (PRINTER_ATTRIBUTE_SAMBA) * Resolve name conflict on DEC OSF-5.1 (inspired by patch from Adharsh Praveen <rprav@india.hp.com>) * Work around parsing error in the print change notify code (not that the alignment bug is still there but reording the entries in the array works around it). * remove duplicate declaration of getprintprocdir from rpcclient. (This used to be commit 7474c6a446037f3ca2546cb6984d800bfc524029)