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

510 Commits

Author SHA1 Message Date
Tim Potter
c24bf6d8ab Added arg to querygroupinfo.
(This used to be commit ab58fdf77a12d101f5ac6b6702cd8ed9dc2c7d55)
2001-05-14 03:51:39 +00:00
Tim Potter
862fe3b7ed Memory leak fixes plus general cleanup.
(This used to be commit 48688c4592d03d6404631a7d57701f0af38cfb2d)
2001-05-11 07:04:47 +00:00
Tim Potter
481a727687 Fixed querydispinfo command.
(This used to be commit 727d2929bc4025ab418e933356d8ba4f31420423)
2001-05-08 03:53:16 +00:00
Tim Potter
8e84cde71d iAdded querydispinfo and querydominfo functions.
Allow rid to be specified in lookupuser.
(This used to be commit 1ea5aa4a80f9da56b071b403fb8f1cfa0ff79b8d)
2001-05-07 02:00:28 +00:00
Tim Potter
b8adb72139 Added queryaliasmem function.
Moved fetch_domain_sid() calls out of harms way so they didn't spam out
queries on SAMR pipe.
(This used to be commit 982195c89d2ea0e66c24f6426f50c7d2f35800e0)
2001-05-04 07:35:25 +00:00
Tim Potter
a8be5dced6 Tidyup of server vs servername, username vs user to remove compiler
warnings.
(This used to be commit d4f6ce9422ae53fb5b0cc72407131d5a9e1bd36d)
2001-05-04 07:34:16 +00:00
Tim Potter
206a2a61da Added cmd_samr_enum_dom_groups() function.
(This used to be commit 23427a57da8b18506bbd970e5d7491c0917f6d06)
2001-05-04 04:17:39 +00:00
Tim Potter
0eaa469aa8 More usability fixes.
(This used to be commit 3434e0bf7fe5cdc8478518c6b1311dda7a7d3e81)
2001-05-04 04:15:48 +00:00
Tim Potter
1bbc3d193b Allow ctrl-d to exit rpcclient.
Don't try to run anything if user just presses return at rpcclient prompt.
(This used to be commit 37cdf37fee8414183c4ecb49e68a468ad235787d)
2001-05-04 01:04:23 +00:00
Gerald Carter
e40449fa72 rpcclient merge from 2.2 (including Jeremy's non-void return fix)
(This used to be commit 0a6ceed279cc8111008b21f75c6791efbd993f4b)
2001-04-28 00:32:56 +00:00
Jeremy Allison
f9a15ce1a6 Got "medieval on our ass" about adding the -1 to slprintf.
Jeremy.
(This used to be commit 94747b4639ed9b19f7d0fb896e43aa392a84989a)
2001-04-08 20:22:39 +00:00
Tim Potter
7a1f5c517b Changed usage message for query_groupmem and query_usergroups as they don't
convert names to rids yet.
(This used to be commit cea13dff759dfb7efb5d2a248dd77905e16b1605)
2001-03-28 05:01:54 +00:00
Jeremy Allison
194a87bf76 Added Gerald's fixes.
Jeremy.
(This used to be commit be825b07464f54d717333318a08154cff632f706)
2001-03-23 21:54:30 +00:00
Jeremy Allison
cd4fea0098 More unused variables.
Jeremy.
(This used to be commit 38b19fad2851a65268b31c7e0240ed36a8407be4)
2001-03-23 20:41:22 +00:00
Gerald Carter
6e64ea1473 merge from 2.2 (reorder commands in array)
(This used to be commit 1d14d812ea44d96d0fd170091b489b0580226da6)
2001-03-19 17:23:26 +00:00
Andrew Tridgell
62711a9ceb fixed rpcclient readline code
(This used to be commit 4ec971e905cefada5f3980a25781730acdbf4469)
2001-03-19 00:32:16 +00:00
Gerald Carter
207e715059 addprinter and adddriver are working now :-)
(This used to be commit 0cb7639cef4a1ba0d56d7e58bd7e03343cbf229d)
2001-03-15 22:06:53 +00:00
Gerald Carter
729b7cf214 added getdriverdir and cleaned up the PRINTER_DRIVER_CTR struct
(This used to be commit 5d321673850e1e28e1bee4093705d7e319421687)
2001-03-15 16:43:19 +00:00
Gerald Carter
f4ae39d53a added getdriver and enumdrivers commands. Also fixed
enumprinters so that it works as well.  Couple of other
misc fixes while we're working on rpcclient.
(This used to be commit 83d6bc4454f0cda581d26de32a4fcaad42431b34)
2001-03-15 07:13:27 +00:00
Gerald Carter
79dc43767e more updates. several spoolss commands added as placeholders
to be filled in one at a time.
(This used to be commit 6aaac3766324302b995b5a55876bf2ab74af1ff8)
2001-03-15 02:15:05 +00:00
Gerald Carter
fb3d8452e5 set of changes in the beginning of bringing rpcclient changes
back to working order.  The main change is that the cli_*() RPC
functions from libsmb/*.c now should accept a struct cli_state*.

The reason for this is that rpcclient should establish the
connection to the server at startup so that it is not necessary
to keep the clear test or password hash in memory for each command.

enumports and enumprinters now works as well.  lsa* functions
have been tested.  SAMR calls may or may not work (one of the core
dumps I know), but it compiles :-)



jerry
(This used to be commit d98ac8852ae6b39b6fcff92c346ba56d9e63c518)
2001-03-14 20:22:57 +00:00
Gerald Carter
381e8299dc move charset_initialize() up in the food chain so that lp_load_services
and stuff will work....
(This used to be commit e652a14264cf6bed6c6563ad090f645f386d903f)
2001-03-13 18:48:26 +00:00
Jeremy Allison
da3053048c Merge of new 2.2 code into HEAD (Gerald I hate you :-) :-). Allows new SAMR
RPC code to merge with new passdb code.
Currently rpcclient doesn't compile. I'm working on it...
Jeremy.
(This used to be commit 0be41d5158ea4e645e93e8cd30617c038416e549)
2001-03-11 00:32:10 +00:00
Tim Potter
19a8acda64 rpcclient functions for remaining samr and lsa functions. All functions
now pass through insure except for some of the dodgy spoolss prs
weirdness.
(This used to be commit 76f08426a08881793b0ef32ccc4e13c54f26417f)
2001-01-15 23:35:59 +00:00
Tim Potter
7237fd3c85 Pass correctly formatted args to cli_spoolss_open_printer_ex()
(This used to be commit 635db9b6015a422505a5d8507c44e12f146597bc)
2001-01-12 19:47:08 +00:00
Tim Potter
44a9dc1ba8 Memory leak fixes and uninitialised variables spotted by insure.
(This used to be commit 079f46aca453978a5c313e90f3b24620760ebafc)
2001-01-12 18:19:57 +00:00
Tim Potter
eb1e855f4e Memory leak fixes spotted by insure.
(This used to be commit 8072ee62b082df5d06459667615bb3b78461ec0a)
2001-01-12 17:53:47 +00:00
Tim Potter
78b2616049 Use MAXIMUM_ALLOWED_ACCESS when doing a cli_spoolss_open_printer_ex()
(This used to be commit 42674cc616dccbef090254a2c4a3ab0b4360e547)
2001-01-12 02:58:29 +00:00
Tim Potter
fc659e07d0 Start of a rewrite of rpcclient based on the libsmb rpc client routines.
Currently there are a small selection of lsa, samr and spoolss functions
implemented.  More to follow...
(This used to be commit 9a953514f2a2cfd3c43105dd6203bc3e36aff1b1)
2001-01-11 22:49:30 +00:00
Tim Potter
3478427f2e Port of lsa_lookup_sids() and lsa_lookup_names() rpc client functions from
TNG branch.

Re-instated lsa_lookup_sids and lsa_lookup_names functions in rpcclient.

This requires most samba binaries to link in another handful of object
files due to uncessary coupling between modules.  )-:
(This used to be commit 817819d0cc3ecf642be5a1656be3b71bed260ee4)
2000-12-08 03:34:00 +00:00
Tim Potter
cf9443677d Modified argc passed to rpc_client cmd_* functions to include argv[0].
Gerald, could you check to see I haven't introduced any bugs into
rpcclient/cmd_spoolss.c?
(This used to be commit 77b0bda4df3217cd186d5b8f902a50f35346d98d)
2000-12-08 03:24:38 +00:00
Gerald Carter
072d39165d spoolgetprinterdriver now returns "Windows NT x86" and "Windows 4.0"
driver information.

Will merge into TNG.



jerry
(This used to be commit ae7dd77c2495d5e17f6e8da94afbe8cab3e773bb)
2000-09-12 16:03:16 +00:00
Gerald Carter
a86ae846ad added -P (for no prompt) and -A <authfile> options
jerry
(This used to be commit 2d95c38f7e65a0379cbaadd57b8eb41d830b5a6b)
2000-08-29 14:43:42 +00:00
Gerald Carter
0136927ed8 fixed an off by one error where I was tromping on memory
when initializing a driver_info_3 struct.  See spoolss_addprinterdriver()



jerry
(This used to be commit 4fad1fc28a0396443e4723d2065860feb283a785)
2000-08-18 06:03:13 +00:00
Gerald Carter
74f2fc40db FIxed some unmarshalling problems with relstr and unistr arrays
jerry
(This used to be commit ce2d20395ae3d41d55030427f4b7b44ce87c605e)
2000-08-12 14:26:01 +00:00
Jeremy Allison
1e823bc781 Tidied up security rights definitions.
Jeremy.
(This used to be commit e466c863f5540e13776f4477b6d58e3fbfe7276d)
2000-08-10 19:51:45 +00:00
Gerald Carter
536a055a9a Working on spoolss_getprinterdriver() as it does not display all the
dependentfiles.



jery
(This used to be commit 206565368b887ba83791efe018f24175e6f31137)
2000-08-10 14:05:19 +00:00
Gerald Carter
8e0e319674 Needed to add the SHARED attribute bit when creating a printer
on a Samba host.  Also needed to add an option to pass the share
name (printer name) on the command line.

And fixed the checking of the return code for spoolss_r_addprinterex()




jerry
(This used to be commit 880e81161640cd38540b06d982c592cbada51d40)
2000-08-10 04:10:29 +00:00
Gerald Carter
a08d444896 More work on AddPrinterDriver() and AddPrinterEx() client RPC's
Also fixed init_unistr() to deal with a NULL source character string.



-jerry
(This used to be commit 8ecd5dd52a6bd867f5d117352048ee43ce7254d9)
2000-08-09 20:14:29 +00:00
Gerald Carter
0756908d55 Fixed AddPrinterDriver()
jerry
(This used to be commit 39d025693eadf4ca1c4fe17dd9110bb8a647f361)
2000-08-09 02:04:25 +00:00
Gerald Carter
f296a8d087 All changes related to rpcclient...
- cleaned up some code
- Fixed a few memory leaks of my own making
- Add AddPrinterDriver(); I'm missing some of the semantics
  here as the call is done correctly, but I'm not getting all
  the information right in the DRIVER_INFO_3 struct I think.
  Will work on it tomorrow some more...



--jerry
(This used to be commit 3bf9a29f34ee4ade5180c5a0b0b9ff4aca7f0f08)
2000-08-08 06:57:48 +00:00
Gerald Carter
4fabc1ad0d spoolss_addprinterex() was adding the printer and returning the
correct handle, but was deleting the connection to the server.
Doh!!



--jerry
(This used to be commit 8e5e929561a1ae954bd60f7bd745d697438f835c)
2000-08-04 20:32:34 +00:00
Gerald Carter
4003a1c55b clunky support for calling AddPrinterEx(). The code currently reports
that the call failed, but the printer shows up on the remote NT client.
(note this is the client side call).  I've botched the return value
somewhere and will fix that today.




jerry
(This used to be commit e15d9befd24cf5f3410c4be819b2a1fcf68048fb)
2000-08-04 12:46:36 +00:00
Jeremy Allison
7f36df301e Tidyup removing many of the 0xC0000000 | NT_STATUS_XXX stuff (only need NT_STATUS_XXX).
Removed IS_BITS_xxx macros as they were just reproducing "C" syntax in a more
obscure way.
Jeremy.
(This used to be commit c55bcec817f47d6162466b193d533c877194124a)
2000-08-01 18:32:34 +00:00
Gerald Carter
a6ef985df4 More work on rpcclient...
* Fixed to work with Jeremy's recent changes re: dunamic
    memory allocation when unmarshalling unistr[2]
  * included EnumPorts level 1
  * more work on AddPrinterEx




--jerry
(This used to be commit 45fbf31b698d6e754630590034cff712c0a716b1)
2000-07-31 14:50:53 +00:00
Jean-François Micouleau
1e3a5503cd Found out that we are crashing spoolss in enumprinterdata.
So fixed enumprinterdatas in rpcclient to debug the server code,
and found that the parsing code was missing 2 prs_align().

We are not crashing NT anymore. :-)

        J.F.
(This used to be commit 883f7402d495182aeff85152216cc8b3cfc18bef)
2000-07-26 09:40:49 +00:00
Gerald Carter
48a3e00224 some initial code for AddPrinterEx() project. Most is ifdef'd out
'cause it's not all written.


-jerry
(This used to be commit 2c0f6bcc8f926ee9c17de12671075e8a9239bb94)
2000-07-25 21:07:46 +00:00
Jean-François Micouleau
5a5ef18379 A rather big change set ! (listed in no particular order)
- changed the default forms flag to 2
- all short architecture name are uppercased
- get_short_archi() is now case unsensitive
- the drivers TDB is indexed by archi/version/name
- implemented code to move drivers from the upload area to the download
area. Someone else need to look at that code.
- don't return anymore a default driver if it doesn't exist in the TDB.
Instead return an error.
- cleaned prs_unistr.
- #ifdef out jeremy's new SD parsing in printer_info_2
- removed the unused MANGLE_CODE

- #ifdef out the security checking in update_printer() as it doesn't work
for me.

Zap your ntdrivers.tdb, it won't work anymore.

	J.F.
(This used to be commit ac0a145acc0953a6f362497abbf4dfe70aa522a6)
2000-07-25 13:15:16 +00:00
Gerald Carter
92708e3945 Added EnumPorts() and fixed up some problems
with the other spoolss client calls.

Also cleaned up output for 'help' command.



jerry
(This used to be commit 56ce247977c05ef37888c2572e679c44346e5568)
2000-07-21 19:59:51 +00:00
Gerald Carter
58221bfcf7 Fixed unitilized secdesc pointer which was causing spoolgetprinter
rpcclient command to fail on shared printers.




jerry
(This used to be commit c8abc31187dbfe6076277896b029fa11443e43bd)
2000-07-20 13:38:48 +00:00