1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-29 21:47:30 +03:00

18 Commits

Author SHA1 Message Date
Tim Potter
83a160587e Fixed -d option for rpcclient.
(This used to be commit 44c5eb4def9a264f660b2398d28b72f54e6547e6)
2001-01-02 04:23:17 +00:00
Gerald Carter
c9d38e177b code review of rpcclient
o added some comments
  o abstracted a few code bits
  o cleaned up some code by removing unused code paths



-- jerry
(This used to be commit 679453af36c06ae9c82dd20742a56272ec73f427)
2000-12-11 18:13:19 +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
Jeremy Allison
fb71f4a0af Fix for plaintext passwords from Pat Sandfort @ HP.
Jeremy.
(This used to be commit b8753b92fbeb1d6768d0559e12ff2aa1d0148419)
2000-11-16 21:33:21 +00:00
Gerald Carter
08e73efdbc -U% should be an anonymous connection. Fixed bug where
the password was being set to "" instead of NULL.


..and yes Elrond, I'll merge this into TNG.


P
jerry
(This used to be commit cc611ecc674832f7e7390b5e7ad6648c9d622e9e)
2000-09-01 06:25:15 +00:00
Jeremy Allison
d407579b94 Implemented AbortPrinter() from Gerald's Win32 test code. Just purge all
possible printjobs from that printer (I think this is correct).
Added error code returns for print_queue_XXX() functions.
Jeremy.
(This used to be commit 6d081a9017f87f59b7189ba507e211db01c40af5)
2000-08-30 00:45:59 +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
Jeremy Allison
d8464d49c6 Reverted the change Luke made. Removed IS_BITS_SET_XX macros.
Do not re-add them. These macros are unsafe as they are not understood.
Change all TNG code using them to correct '&' and '|' please.
IS_BITS_SET_ALL was being used in cmd_interp.c when IS_BITS_SET_SOME
should have been used.
Jeremy.
(This used to be commit be4e5eeb4f808c1d8ac4030e8886a83a37914c57)
2000-08-14 23:48:07 +00:00
Luke Leighton
d2d074580d hey, jerry: turns out you _have_ converted to get_safe_nt_errmsg!!!
[got confused with which way dirdiff was going :)].

... but you forgot to update TNG's lib/cmd_interp.c...
(This used to be commit 8fe195df0b5826af7048ef6c87e4b55dfd336cf8)
2000-08-14 07:37:12 +00:00
Luke Leighton
becf055e78 jeremy,
please do not remove IS_BITS_SET_XXX macros just because you happen
"not to like them".  whilst still working on merging, you are not
responsible for this code, therefore do not hinder its development
whilst people are attempting to do merges.  after the merge from
TNG to cvs main is completed, you can do what the hell you like.

thank you.


jerry,

please could you consider adding underlying routines (in this case
get_safe_smb_errstr()) instead of reverting to a [less secure]
previous coding method.  thanks.
(This used to be commit b2e044f89de7cb12fd14540d5d7d5070951ce2fb)
2000-08-14 07:33:34 +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
Jeremy Allison
5ec1642809 Ok - this is a *BIG* change - but it fixes the problems with static strings
in the RPC code. This change was prompted by trying to save a long (>256)
character comment in the printer properties page.

The new system associates a TALLOC_CTX with the pipe struct, and frees
the pool on return of a complete PDU.

A global TALLOC_CTX is used for the odd buffer allocated in the BUFFERxx
code, and is freed in the main loop.

This code works with insure, and seems to be free of memory leaks and
crashes (so far) but there are probably the occasional problem with
code that uses UNISTRxx structs on the stack and expects them to contain
storage without doing a init_unistrXX().

This means that rpcclient will probably be horribly broken.
A TALLOC_CTX also needed associating with the struct cli_state also,
to make the prs_xx code there work.

The main interface change is the addition of a TALLOC_CTX to the
prs_init calls - used for dynamic allocation in the prs_XXX calls.

Now this is in place it should make dynamic allocation of all RPC
memory on unmarshall *much* easier to fix.

Jeremy.
(This used to be commit 0ff2ce543ee54f7364e6d839db6d06e7ef1edcf4)
2000-07-27 00:47:19 +00:00
Gerald Carter
fe245e2a92 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 a0e8a55c279af50c1f770c7b913262094b9b593a)
2000-07-21 20:01:20 +00:00
Gerald Carter
02fd5b08b5 Fixed a bug in cmd_interp.c where if user%pass was entered on
the command line, the password would still be cached in memory
in plain text for the lifetime of the rpcclient command line session.

removed loopback connection functions from msrpc-client.c since
we don't support that in the server code now anyways.  simplify,
simplify, ...


--jerry
(This used to be commit 8599e1bc394b1caee2483ec72d439a34d3f30629)
2000-07-14 16:54:07 +00:00
Gerald Carter
997e113a56 Fixed a bug in parsing the command line.
jerry
(This used to be commit ebcb7473c6b62266c30e276d02186d8e50a5629a)
2000-07-10 19:56:15 +00:00
Gerald Carter
d2b40a7de2 More rpcclient merge issues:
* fixes some readline bugs from the merge
        * first attempt at commands (spoolenum almost works)
        * no changes to existing functions in HEAD; only additions
          of new functions.  I'll weed out what I can as I go.




--jerry
(This used to be commit 61d2aad5dc2b212b11c981f1eca47efa627e9fc8)
2000-07-07 06:20:46 +00:00
Gerald Carter
33f6a1d9bb first pass at merging rpcclient from TNG to HEAD. You can get a
semi-connection and a rpcclient prompt, but no functionality there yet.
Will be a few more days on that.

--jerry
(This used to be commit 269051aa0c52728278a1d290148564f11cf7f189)
2000-07-03 04:28:29 +00:00