summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
authorLuke Leighton <lkcl@samba.org>2000-05-27 04:51:02 +0000
committerLuke Leighton <lkcl@samba.org>2000-05-27 04:51:02 +0000
commit6ec1ae35b4dda41a59c03666aedaf3744bd5312c (patch)
tree64ab28c3b452689bb6c86a07e80d3ea2f90a7e77 /source3
parentb6ecd4fbe29fe44e229c6e9ec38c51b67f53825b (diff)
downloadsamba-6ec1ae35b4dda41a59c03666aedaf3744bd5312c.tar.gz
samba-6ec1ae35b4dda41a59c03666aedaf3744bd5312c.tar.bz2
samba-6ec1ae35b4dda41a59c03666aedaf3744bd5312c.zip
hack to get setprinter working, level2, null sec desc.
(This used to be commit 3f976e713924a2fa47194ae3edfa3f1592e4cf1c)
Diffstat (limited to 'source3')
-rw-r--r--source3/aparser/cifs.struct12
-rw-r--r--source3/rpc_parse/parse_spoolss.c22
2 files changed, 28 insertions, 6 deletions
diff --git a/source3/aparser/cifs.struct b/source3/aparser/cifs.struct
index 8d5cef4d8f..e9ec462b1e 100644
--- a/source3/aparser/cifs.struct
+++ b/source3/aparser/cifs.struct
@@ -529,8 +529,10 @@ typedef struct _R_SMB {
uint8 reh;
uint16 err;
uint8 flg;
- uint8 flg2;
- uint8 reb[13];
+ uint16 flg2;
+ uint16 reserved;
+ uint8 SecuritySignature[8];
+ uint16 pad;
uint16 tid;
uint16 pid;
uint16 uid;
@@ -557,8 +559,10 @@ typedef struct _Q_SMB {
uint8 reh;
uint16 err;
uint8 flg;
- uint8 flg2;
- uint8 reb[13];
+ uint16 flg2;
+ uint16 reserved;
+ uint8 SecuritySignature[8];
+ uint16 pad;
uint16 tid;
uint16 pid;
uint16 uid;
diff --git a/source3/rpc_parse/parse_spoolss.c b/source3/rpc_parse/parse_spoolss.c
index c33cf58762..4148caa7b2 100644
--- a/source3/rpc_parse/parse_spoolss.c
+++ b/source3/rpc_parse/parse_spoolss.c
@@ -2907,6 +2907,8 @@ BOOL spoolss_io_r_setprinter(char *desc, SPOOL_R_SETPRINTER *r_u, prs_struct *ps
********************************************************************/
BOOL spoolss_io_q_setprinter(char *desc, SPOOL_Q_SETPRINTER *q_u, prs_struct *ps, int depth)
{
+ uint32 ptr_sec_desc = 0;
+
prs_debug(ps, depth, desc, "spoolss_io_q_setprinter");
depth++;
@@ -2924,8 +2926,24 @@ BOOL spoolss_io_q_setprinter(char *desc, SPOOL_Q_SETPRINTER *q_u, prs_struct *ps
if (!spoolss_io_devmode_cont(desc, &q_u->devmode_ctr, ps, depth))
return False;
- if (!sec_io_desc_buf(desc, &q_u->secdesc_ctr, ps, depth))
- return False;
+ switch (q_u->level)
+ {
+ case 2:
+ {
+ ptr_sec_desc = q_u->info.info_2->secdesc_ptr;
+ break;
+ }
+ case 3:
+ {
+ ptr_sec_desc = q_u->info.info_3->secdesc_ptr;
+ break;
+ }
+ }
+ if (ptr_sec_desc)
+ {
+ if (!sec_io_desc_buf(desc, &q_u->secdesc_ctr, ps, depth))
+ return False;
+ }
if(!prs_uint32("command", ps, depth, &q_u->command))
return False;