1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-17 02:05:21 +03:00

64 Commits

Author SHA1 Message Date
Jeremy Allison
f9e9f98a4a lib/util_unistr.c: Removed ascii_to_unistr() as it does no codepage.
Removed unistr_to_ascii() as it was never used.
printing/nt_printing.c: Removed "DUMMY.XX" files.
rpc_server/srv_spoolss_nt.c: Use dos_PutUniCode() instead of ascii_to_unistr().
							Attempted to fix the "return value" size code based on J.F's
							comments. This needs looking at.
Jeremy.
(This used to be commit de99011bf3b2a23bd1854a047382a107aaeb9c68)
2000-06-22 01:39:17 +00:00
Jeremy Allison
69c75c8a16 Fixes for Win2k "add printer driver" INFO_LEVEL_6 was wrong, also some
memory fixes.
Jeremy.
(This used to be commit 2a9e645cbddef1cddc5c978310b7efed492758d2)
2000-06-20 23:58:56 +00:00
Tim Potter
e83ddf6e69 Simplified server pipe implementation by changing arguments passed down
through to the individual pipe api calls.  Instead of passing two
prs_struct pointers, we now pass the pipes_struct pointer which contains
the former information as well as other useful stuff like the vuid.

Pass the vuid from the pipes_struct down to the lower level spoolss
functions to perform security checks.

ZERO_STRUCTP the info_2 structure before filling it.  Free the device mode
field before freeing the info_2 to avoid a memory leak.  Fixed
uninitialised pointer bug in fill_job_info_2().
(This used to be commit a9547b7e3a068941cda5619f05a64e798584535a)
2000-06-16 08:18:09 +00:00
Jeremy Allison
0164047afb Fixing get/set of security descriptors.
Removed ugly hack for NT printing.
Fixed up tdb parse stuff memory leaks.
Jeremy.
(This used to be commit 8ef41f31c53e14ad057d883810a1cd2301fede2a)
2000-06-07 01:49:23 +00:00
Jeremy Allison
d253db1b9a Memory leak fixes.
Jeremy.
(This used to be commit 34b63896ab1543936d6b9b382ef6727a161b6bf2)
2000-06-06 20:44:58 +00:00
Jeremy Allison
84aa9ad049 Create elements in default, not in read.
Jeremy.
(This used to be commit 0d681ea252e0cf7fdf57d316d2bfe7caa9b4fbf5)
2000-06-06 01:34:20 +00:00
Jeremy Allison
6d8c131f50 Some tidyup fixes (memory leaks etc.). Still no progress with the
"no driver" issue. I'm banging my head against comparitive packet
dumps right now...
Jeremy.
(This used to be commit 03cd4aa1443acd958593f37c61ff9c90a43c660b)
2000-06-05 20:55:57 +00:00
Andrew Tridgell
dbf004bdab added a MANGLE_DRIVER_PATH define to chooose whether we stuff with the
driver path do a rename etc.

I turned it off by default as it is causing me no end of problems. The
client will *cache* this path, and that screws things up badly as the
temp directory is no longer there when it is needed.
(This used to be commit 46f5f41c88b6ffa117d30f7702628b43dd456902)
2000-06-04 00:26:08 +00:00
Jeremy Allison
5a5540f87a rpc_client/cli_lsarpc.c: Removed unused variable.
rpc_server/srv_spoolss_nt.c: Fixed more memory leaks.
smbd/nttrans.c: Fixed shadow variable problem.
Jeremy.
(This used to be commit f0a7540831181d3a47e7f8ce8be55a36a2f2aba1)
2000-06-03 00:53:07 +00:00
Jeremy Allison
0cc1389935 More memory leak and PANIC action fixes.
This is *horrible* code :-(.
Jeremy.
(This used to be commit ac383bb765ea606fc1105aa91470fcdf453d9335)
2000-06-02 21:16:39 +00:00
Jeremy Allison
c7d0975183 More memory leak fixes.
Jeremy.
(This used to be commit 4e7b6b20eabe02f1ab74254607178ba35e61c9ce)
2000-06-02 20:08:28 +00:00
Jeremy Allison
2472ab1e60 More memory corruption (leaks etc.) fixes.
Jeremy.
(This used to be commit 71a0621f552083880e89923055e8bd14d0b1b82f)
2000-06-02 19:42:11 +00:00
Jeremy Allison
01c4ecd234 Fixed null pointer indirect in addprinterex. Still working on problem
with extra directory layer in NT drivers.
Jeremy.
(This used to be commit 48a80318269c832e702678237e86ba55c10444f1)
2000-06-02 18:38:49 +00:00
Jeremy Allison
8ff6458a3e More insure found memory leak and corruption fixes.
Jeremy.
(This used to be commit 3cdcfa6325b9cd2d7f7c90c4b2d1c6ec73fc2f6d)
2000-06-01 21:52:49 +00:00
Jeremy Allison
b9fedcb2de param/loadparm.c: Looks like someone ran indent on this !
passdb/smbpass.c: Insure uninitialized memory reference fix.
printing/nt_printing.c:
rpc_server/srv_spoolss_nt.c: Insure memory leak fixes.
smbd/unix_acls.c: Shadow ref fix.
Jeremy.
(This used to be commit d175d3ebefc053e9badd91ca5f2d8bd03eb6705d)
2000-06-01 21:00:37 +00:00
Jeremy Allison
cc22d7ea29 Changes I really don't want to lose whilst CVS is playing up.
Dynamic changes to spoolss code.
Jeremy.
(This used to be commit 0a5e7a8f31c26fe80db5398a441a1969a8882845)
2000-06-01 02:35:30 +00:00
Andrew Tridgell
5b5f41d8e0 fixed some more crashes
this introduces some memory leaks that I need to fix later
(This used to be commit 2170d72d508ab8fb63a1da3024395f8fd6011cfa)
2000-05-29 01:09:14 +00:00
Andrew Tridgell
38b32fb97f don't free a driver structure from the stack!
(This used to be commit d241f1dcaf612881a428dd578b97383d02a4d3c3)
2000-05-28 23:00:23 +00:00
Luke Leighton
4a0635cd6d #ifdef not #if
(This used to be commit f0229102fe337213cd53fcb0a3d7e2ba786470b9)
2000-05-28 21:21:07 +00:00
Luke Leighton
b38aa95bc9 moved notif_y_table struct to spoolss_nt.c only used there.
#ifdef'd driver-code out with define RELIES_ON_SMBD_SPECIFIC_CODE because
spoolssd doesn't link with smbd/*.c (find_service("print$") is not
possible).
(This used to be commit 726c359d1d9f1fc8227ca920c888d2f040170e0b)
2000-05-28 21:01:14 +00:00
Andrew Tridgell
5f7c40f6d0 getting and setting security descriptors on printers now works
this needed some fixes in tdb_unpack(). Tim, you'll need to update
(This used to be commit 9422719ab4c35e4ce3199b62dd632433bf391283)
2000-05-27 09:53:11 +00:00
Luke Leighton
afab6492e1 uninitialised variable "list"
(This used to be commit bf33b10a43a42c3ec5dbfdc713869c4aeb452aef)
2000-05-27 03:12:06 +00:00
Luke Leighton
682cccd8af unistr_to_dos not unistr_to_ascii
(This used to be commit f46c4fe876a0cabe7044ca30c17e6c217d618635)
2000-05-27 02:05:15 +00:00
Luke Leighton
a65dead017 security descs in spoolss. needs parse_sec.c nttrans.c broken.
(This used to be commit f9f2a04fdb7b2af1cfe5bf26ec6f0d955ea948b9)
2000-05-27 01:26:34 +00:00
Jeremy Allison
9646e6e1ba Compile time warning fixes and a time_t -> uint32 conversion fix.
Jeremy.
(This used to be commit 80a0079b2f993159ef35b02ba5c70ce9d8096879)
2000-05-26 20:54:46 +00:00
Andrew Tridgell
722c86a38f a fairly big change in spoolss.
got rid of the forms, drivers and printers files in the nt drivers
directory and instead use a single tdb

note that this is _not_ all finished.
(This used to be commit 537cd6dff057df481fb208121ce4396fc76c2a06)
2000-05-24 06:34:47 +00:00
Jeremy Allison
69519df0f6 Modify NT driver heirarchy to fix HP bug with duplicate printer driver
filenames :-).
Jeremy.
(This used to be commit adb6ad812a4d897ee0c0712cc06d1ff8553fa093)
2000-05-22 20:04:50 +00:00
Andrew Tridgell
0806cf75ff added spool_io_printer_driver_info_level_6()
thsi function and the associated header structure were autogenerated
using a little awk based code geerator I wroe ths evening. I'll commit
that next ...
(This used to be commit 974813f0d4afb6c14ed27c48ab24b19932557f9f)
2000-05-12 14:28:46 +00:00
Jeremy Allison
612738a9e1 lib/util_unistr.c:
libsmb/clilist.c:
rpc_server/srv_spoolss_nt.c:
smbd/trans2.c: Changed unistr_to_ascii to unistr_to_dos - do codepage conversion.
msdfs/msdfs.c: Removed stub unistr_to_dos.
libsmb/pwd_cache.c: Removed obfuscation functions as they don't do anything and
					don't add any security.
Jeremy.
(This used to be commit 1ed146467e764e6a81d8f78cd58fb5765ebf5d21)
2000-05-10 22:47:09 +00:00
Andrew Tridgell
59fa2dbe2c added support for deleting printers into the spoolss system
(This used to be commit e72a5718537b84409fc20ff21951b1d1ab24d97f)
2000-05-02 15:31:55 +00:00
Andrew Tridgell
f6dec4d551 fixed a memory leak
(This used to be commit d4743ec0be419565c805fbc5ba2680c6ad5fe36d)
2000-05-02 07:10:26 +00:00
Jeremy Allison
693ffb8466 Added sys_fork() and sys_getpid() functions to stop the overhead
of doing a system call every time we want to just get our pid.
Jeremy.
(This used to be commit 148628b616b5c29ba6340d65fc3ddbcabba6e67a)
2000-05-02 02:23:41 +00:00
Andrew Tridgell
565cc66e6a fix handing of ascii_to_unistr
(This used to be commit 385b1844b60beeb9db5f412a452816444e25cb83)
2000-04-30 14:27:39 +00:00
Andrew Tridgell
00e3fe1324 moved trans2.h and nterr.h into includes.h with all our other includes
(This used to be commit d7cd7c88fdabb01d9e40ae8a657737907a21ac37)
2000-04-25 14:06:57 +00:00
Andrew Tridgell
d315f69e54 more pstring/fstring errors found by insure
(This used to be commit ba1931bb6596b538549e712cb8898b1ed19f5adc)
2000-04-23 14:25:36 +00:00
Andrew Tridgell
d0e9a0c4f2 another fstring/pstring fix
(This used to be commit 91ed7d8ffe8208d06191c64f5332954ec6bf75da)
2000-04-23 08:44:55 +00:00
Andrew Tridgell
6d667ad4d3 fixed another spoolss memory leak
I am falling in love with insure - it is finding _lots_ of memory
problems
(This used to be commit d9b4076293a4d37e1558ad63a3f522385ee3e521)
2000-04-23 08:40:54 +00:00
Andrew Tridgell
b1686a6109 we can't pass a fstring to a routine expecting a pstring
(This used to be commit 8af70f288723e4597bc8639fc0cbec44af2e50c7)
2000-04-23 08:13:48 +00:00
Andrew Tridgell
b062fe0d8f - put the job status in english not french!
- add helper fns to change from internal status codes to nt spoolss codes
(This used to be commit 917c4814fe076cc38b1becf7d219f2437cba6e60)
2000-04-16 07:28:06 +00:00
Andrew Tridgell
8a91379a00 JF and Jeremy - please have a look at what I did to the spoolss
code. It now uses the new printing backend.

------------
The following series of commits are for the new tdb based printing
backend. This completely replaces our old printing backend.

Major changes include:

- all print ops are now done in printing/*.c rather than scattered all
  over the place
- system job ids are decoupled from SMB job ids
- the lpq parsers don't need to be nearly so smart, they only need to
  parse the filename, the status and system job id
- we can store lots more info about a job, including the full job name
- the queue cache control is much better

I also added a new utility routine file_lines_load() that loads a text
file and parses it into lines. This is used in out lpq parsing and I
also want to use it to replace all of our fgets() based code in other
places.
(This used to be commit 2df82862c061cca5644f5f69146c97302ccb42d5)
2000-04-16 06:20:43 +00:00
Jean-François Micouleau
416fa5377b added checks to open both \\server\printer and \\server\share.
it doesn't work, the getprinter level 0 reply is wrong...

	J.F.
(This used to be commit a7b09e3e11dc66779ee50524ebe1f6687ec744c6)
2000-04-10 21:47:46 +00:00
Jeremy Allison
aac823aca1 Modified interfaces and added checks around *all* *alloc calls
so that errors are returned on memory allocation failure.
Jeremy.
(This used to be commit 9a118cd4a2b03146b341eeffb62144a2d29b574c)
2000-04-06 22:48:53 +00:00
Jean-François Micouleau
154596cae5 filled the architecture table (useless for the moment).
fixed GetJob.

	J.F.
(This used to be commit 3fea49e1d896987c54187cb326607284810fcb0d)
2000-04-06 16:23:04 +00:00
Jean-François Micouleau
dc2d1544b3 changed all the status code to ERROR_xxx instead of NT_STATUS_xx which are
wrong in the spoolss case.

fxed a bug in the job notify code (that's the polite answer), the truth is
different: there is a bug in the NT spooler service, including SP6a and
NT2K.

changed the default lpcommand in the LPRNG case.

	J.F.
(This used to be commit 396f73c11b29a47650b3243fef0825252a3cef9b)
2000-04-05 10:05:32 +00:00
Jean-François Micouleau
c475ab51d9 split addprinterex in preparation for level 1 support and to stop it
coredump.

	J.F.
(This used to be commit aea47dee7d85310f35309ecfa91d0b87e632a33f)
2000-03-29 14:49:05 +00:00
Jean-François Micouleau
6ca0ed9baa rewrote getprinterdriver level 3, now correctly handle the dependent
files.
A number of memleak fixed
some error return values fixed.

	J.F.
(This used to be commit c212fbe009fe556d5329b5d7106159cf21402d82)
2000-03-29 12:36:44 +00:00
Jean-François Micouleau
4d43977130 fix a bug in enumprinterdrivers
J.F.
(This used to be commit a8d04c26da601cb97e66c27c7ad21dd672fcec2d)
2000-03-16 16:23:38 +00:00
Jean-François Micouleau
c5fbb293a8 oops ! forgot smb.h in last commit
added info level 1 parsing code for addprinter(ex)

	J.F.
(This used to be commit 4847f7b17b2d23e4efd4e7cae6bfcfc2319b9409)
2000-03-13 19:34:04 +00:00
Jean-François Micouleau
bf5f8bcf70 small fix for addprinterex at level 2
I have some network dumps at level 1, but quoting MSDN: "Level [in]
Specifies the version of the structure to which pPrinter points. This
value must be 2."

I like NT so much :-)

	J.F.
(This used to be commit fbf40c6a9140a27e773d59eaf056c9e25659d9b8)
2000-03-13 15:53:02 +00:00
Jean-François Micouleau
79bfb14318 parse correctly getprinterdriver2
found a stupid bug in enumprinters
fixed some memleaks
found a coredump in enumprinterdata
getprinterdriverdir responds correctly now.

	J.F.
(This used to be commit 07f2e194ba61e72320636fb7e5d0f041e255868b)
2000-03-13 11:09:20 +00:00