syncing up printing code with SAMBA_2_2 (already done some merges
[tprouty/samba.git] / source / include / rpc_spoolss.h
1 /* 
2    Unix SMB/CIFS implementation.
3    SMB parameters and setup
4    Copyright (C) Andrew Tridgell              1992-2000,
5    Copyright (C) Luke Kenneth Casson Leighton 1996-2000,
6    Copyright (C) Jean Francois Micouleau      1998-2000.
7    
8    This program is free software; you can redistribute it and/or modify
9    it under the terms of the GNU General Public License as published by
10    the Free Software Foundation; either version 2 of the License, or
11    (at your option) any later version.
12    
13    This program is distributed in the hope that it will be useful,
14    but WITHOUT ANY WARRANTY; without even the implied warranty of
15    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16    GNU General Public License for more details.
17    
18    You should have received a copy of the GNU General Public License
19    along with this program; if not, write to the Free Software
20    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
21 */
22
23 #ifndef _RPC_SPOOLSS_H          /* _RPC_SPOOLSS_H */
24 #define _RPC_SPOOLSS_H
25
26 #define INTEGER 1
27 #define STRING 2
28
29 /* spoolss pipe: this are the calls which are not implemented ...
30 #define SPOOLSS_OPENPRINTER                             0x01
31 #define SPOOLSS_GETPRINTERDRIVER                        0x0b
32 #define SPOOLSS_READPRINTER                             0x16
33 #define SPOOLSS_WAITFORPRINTERCHANGE                    0x1c
34 #define SPOOLSS_ADDPORT                                 0x25
35 #define SPOOLSS_CONFIGUREPORT                           0x26
36 #define SPOOLSS_DELETEPORT                              0x27
37 #define SPOOLSS_CREATEPRINTERIC                         0x28
38 #define SPOOLSS_PLAYGDISCRIPTONPRINTERIC                0x29
39 #define SPOOLSS_DELETEPRINTERIC                         0x2a
40 #define SPOOLSS_ADDPRINTERCONNECTION                    0x2b
41 #define SPOOLSS_DELETEPRINTERCONNECTION                 0x2c
42 #define SPOOLSS_PRINTERMESSAGEBOX                       0x2d
43 #define SPOOLSS_ADDMONITOR                              0x2e
44 #define SPOOLSS_DELETEMONITOR                           0x2f
45 #define SPOOLSS_DELETEPRINTPROCESSOR                    0x30
46 #define SPOOLSS_ADDPRINTPROVIDOR                        0x31
47 #define SPOOLSS_DELETEPRINTPROVIDOR                     0x32
48 #define SPOOLSS_FINDFIRSTPRINTERCHANGENOTIFICATION      0x36
49 #define SPOOLSS_FINDNEXTPRINTERCHANGENOTIFICATION       0x37
50 #define SPOOLSS_ROUTERFINDFIRSTPRINTERNOTIFICATIONOLD   0x39
51 #define SPOOLSS_ADDPORTEX                               0x3d
52 #define SPOOLSS_REMOTEFINDFIRSTPRINTERCHANGENOTIFICATION0x3e
53 #define SPOOLSS_SPOOLERINIT                             0x3f
54 #define SPOOLSS_RESETPRINTEREX                          0x40
55 #define SPOOLSS_DELETEPRINTERDATAEX                     0x51
56 #define SPOOLSS_DELETEPRINTERDRIVEREX                   0x54
57 #define SPOOLSS_ADDPRINTERDRIVEREX                      0x59
58 */
59
60 /* those are implemented */
61 #define SPOOLSS_ENUMPRINTERS                            0x00
62 #define SPOOLSS_SETJOB                                  0x02
63 #define SPOOLSS_GETJOB                                  0x03
64 #define SPOOLSS_ENUMJOBS                                0x04
65 #define SPOOLSS_ADDPRINTER                              0x05
66 #define SPOOLSS_DELETEPRINTER                           0x06
67 #define SPOOLSS_SETPRINTER                              0x07
68 #define SPOOLSS_GETPRINTER                              0x08
69 #define SPOOLSS_ADDPRINTERDRIVER                        0x09
70 #define SPOOLSS_ENUMPRINTERDRIVERS                      0x0a
71 #define SPOOLSS_GETPRINTERDRIVERDIRECTORY               0x0c
72 #define SPOOLSS_DELETEPRINTERDRIVER                     0x0d
73 #define SPOOLSS_ADDPRINTPROCESSOR                       0x0e
74 #define SPOOLSS_ENUMPRINTPROCESSORS                     0x0f
75 #define SPOOLSS_GETPRINTPROCESSORDIRECTORY              0x10
76 #define SPOOLSS_STARTDOCPRINTER                         0x11
77 #define SPOOLSS_STARTPAGEPRINTER                        0x12
78 #define SPOOLSS_WRITEPRINTER                            0x13
79 #define SPOOLSS_ENDPAGEPRINTER                          0x14
80 #define SPOOLSS_ABORTPRINTER                            0x15
81 #define SPOOLSS_ENDDOCPRINTER                           0x17
82 #define SPOOLSS_ADDJOB                                  0x18
83 #define SPOOLSS_SCHEDULEJOB                             0x19
84 #define SPOOLSS_GETPRINTERDATA                          0x1a
85 #define SPOOLSS_SETPRINTERDATA                          0x1b
86 #define SPOOLSS_CLOSEPRINTER                            0x1d
87 #define SPOOLSS_ADDFORM                                 0x1e
88 #define SPOOLSS_DELETEFORM                              0x1f
89 #define SPOOLSS_GETFORM                                 0x20
90 #define SPOOLSS_SETFORM                                 0x21
91 #define SPOOLSS_ENUMFORMS                               0x22
92 #define SPOOLSS_ENUMPORTS                               0x23
93 #define SPOOLSS_ENUMMONITORS                            0x24
94 #define SPOOLSS_ENUMPRINTPROCDATATYPES                  0x33
95 #define SPOOLSS_RESETPRINTER                            0x34
96 #define SPOOLSS_GETPRINTERDRIVER2                       0x35
97 #define SPOOLSS_FCPN                                    0x38    /* FindClosePrinterNotify */
98 #define SPOOLSS_REPLYOPENPRINTER                        0x3a
99 #define SPOOLSS_ROUTERREPLYPRINTER                      0x3b
100 #define SPOOLSS_REPLYCLOSEPRINTER                       0x3c
101 #define SPOOLSS_RFFPCNEX                                0x41    /* RemoteFindFirstPrinterChangeNotifyEx */
102 #define SPOOLSS_RRPCN                                   0x42    /* RouteRefreshPrinterChangeNotification */
103 #define SPOOLSS_RFNPCNEX                                0x43    /* RemoteFindNextPrinterChangeNotifyEx */
104 #define SPOOLSS_OPENPRINTEREX                           0x45
105 #define SPOOLSS_ADDPRINTEREX                            0x46
106 #define SPOOLSS_ENUMPRINTERDATA                         0x48
107 #define SPOOLSS_DELETEPRINTERDATA                       0x49
108 #define SPOOLSS_SETPRINTERDATAEX                        0x4d
109 #define SPOOLSS_GETPRINTERDATAEX                        0x4e
110 #define SPOOLSS_ENUMPRINTERDATAEX                       0x4f
111 #define SPOOLSS_ENUMPRINTERKEY                          0x50
112
113
114 #define PRINTER_CONTROL_UNPAUSE         0x00000000
115 #define PRINTER_CONTROL_PAUSE           0x00000001
116 #define PRINTER_CONTROL_RESUME          0x00000002
117 #define PRINTER_CONTROL_PURGE           0x00000003
118 #define PRINTER_CONTROL_SET_STATUS      0x00000004
119
120 #define PRINTER_STATUS_PAUSED           0x00000001
121 #define PRINTER_STATUS_ERROR            0x00000002
122 #define PRINTER_STATUS_PENDING_DELETION 0x00000004
123 #define PRINTER_STATUS_PAPER_JAM        0x00000008
124
125 #define PRINTER_STATUS_PAPER_OUT        0x00000010
126 #define PRINTER_STATUS_MANUAL_FEED      0x00000020
127 #define PRINTER_STATUS_PAPER_PROBLEM    0x00000040
128 #define PRINTER_STATUS_OFFLINE          0x00000080
129
130 #define PRINTER_STATUS_IO_ACTIVE        0x00000100
131 #define PRINTER_STATUS_BUSY             0x00000200
132 #define PRINTER_STATUS_PRINTING         0x00000400
133 #define PRINTER_STATUS_OUTPUT_BIN_FULL  0x00000800
134
135 #define PRINTER_STATUS_NOT_AVAILABLE    0x00001000
136 #define PRINTER_STATUS_WAITING          0x00002000
137 #define PRINTER_STATUS_PROCESSING       0x00004000
138 #define PRINTER_STATUS_INITIALIZING     0x00008000
139
140 #define PRINTER_STATUS_WARMING_UP       0x00010000
141 #define PRINTER_STATUS_TONER_LOW        0x00020000
142 #define PRINTER_STATUS_NO_TONER         0x00040000
143 #define PRINTER_STATUS_PAGE_PUNT        0x00080000
144
145 #define PRINTER_STATUS_USER_INTERVENTION        0x00100000
146 #define PRINTER_STATUS_OUT_OF_MEMORY    0x00200000
147 #define PRINTER_STATUS_DOOR_OPEN        0x00400000
148 #define PRINTER_STATUS_SERVER_UNKNOWN   0x00800000
149
150 #define PRINTER_STATUS_POWER_SAVE       0x01000000
151
152 #define SERVER_ACCESS_ADMINISTER        0x00000001
153 #define SERVER_ACCESS_ENUMERATE         0x00000002
154 #define PRINTER_ACCESS_ADMINISTER       0x00000004
155 #define PRINTER_ACCESS_USE              0x00000008
156 #define JOB_ACCESS_ADMINISTER           0x00000010
157
158 /* JOB status codes. */
159
160 #define JOB_STATUS_PAUSED               0x001
161 #define JOB_STATUS_ERROR                0x002
162 #define JOB_STATUS_DELETING             0x004
163 #define JOB_STATUS_SPOOLING             0x008
164 #define JOB_STATUS_PRINTING             0x010
165 #define JOB_STATUS_OFFLINE              0x020
166 #define JOB_STATUS_PAPEROUT             0x040
167 #define JOB_STATUS_PRINTED              0x080
168 #define JOB_STATUS_DELETED              0x100
169 #define JOB_STATUS_BLOCKED              0x200
170 #define JOB_STATUS_USER_INTERVENTION    0x400
171
172 /* ACE masks for the various print permissions */
173
174 #define PRINTER_ACE_FULL_CONTROL      GENERIC_ALL_ACCESS
175 #define PRINTER_ACE_MANAGE_DOCUMENTS  READ_CONTROL_ACCESS
176 #define PRINTER_ACE_PRINT             \
177     (GENERIC_READ_ACCESS | GENERIC_WRITE_ACCESS | GENERIC_EXECUTE_ACCESS)
178
179 /* Access rights for print servers */
180 #define SERVER_ALL_ACCESS       STANDARD_RIGHTS_REQUIRED_ACCESS|SERVER_ACCESS_ADMINISTER|SERVER_ACCESS_ENUMERATE
181 #define SERVER_READ             STANDARD_RIGHTS_READ_ACCESS|SERVER_ACCESS_ENUMERATE
182 #define SERVER_WRITE            STANDARD_RIGHTS_WRITE_ACCESS|SERVER_ACCESS_ADMINISTER|SERVER_ACCESS_ENUMERATE
183 #define SERVER_EXECUTE          STANDARD_RIGHTS_EXECUTE_ACCESS|SERVER_ACCESS_ENUMERATE
184
185 /* Access rights for printers */
186 #define PRINTER_ALL_ACCESS      STANDARD_RIGHTS_REQUIRED_ACCESS|PRINTER_ACCESS_ADMINISTER|PRINTER_ACCESS_USE
187 #define PRINTER_READ          STANDARD_RIGHTS_READ_ACCESS|PRINTER_ACCESS_USE
188 #define PRINTER_WRITE         STANDARD_RIGHTS_WRITE_ACCESS|PRINTER_ACCESS_USE
189 #define PRINTER_EXECUTE       STANDARD_RIGHTS_EXECUTE_ACCESS|PRINTER_ACCESS_USE
190
191 /* Access rights for jobs */
192 #define JOB_ALL_ACCESS  STANDARD_RIGHTS_REQUIRED_ACCESS|JOB_ACCESS_ADMINISTER
193 #define JOB_READ        STANDARD_RIGHTS_READ_ACCESS|JOB_ACCESS_ADMINISTER
194 #define JOB_WRITE       STANDARD_RIGHTS_WRITE_ACCESS|JOB_ACCESS_ADMINISTER
195 #define JOB_EXECUTE     STANDARD_RIGHTS_EXECUTE_ACCESS|JOB_ACCESS_ADMINISTER
196
197 #define ONE_VALUE 1
198 #define TWO_VALUE 2
199 #define POINTER   3
200
201 #define PRINTER_NOTIFY_TYPE 0x00
202 #define JOB_NOTIFY_TYPE     0x01
203
204 #define MAX_PRINTER_NOTIFY 26
205 #define MAX_JOB_NOTIFY 24
206
207 #define MAX_NOTIFY_TYPE_FOR_NOW 26
208
209 #define PRINTER_NOTIFY_SERVER_NAME              0x00
210 #define PRINTER_NOTIFY_PRINTER_NAME             0x01
211 #define PRINTER_NOTIFY_SHARE_NAME               0x02
212 #define PRINTER_NOTIFY_PORT_NAME                0x03
213 #define PRINTER_NOTIFY_DRIVER_NAME              0x04
214 #define PRINTER_NOTIFY_COMMENT                  0x05
215 #define PRINTER_NOTIFY_LOCATION                 0x06
216 #define PRINTER_NOTIFY_DEVMODE                  0x07
217 #define PRINTER_NOTIFY_SEPFILE                  0x08
218 #define PRINTER_NOTIFY_PRINT_PROCESSOR          0x09
219 #define PRINTER_NOTIFY_PARAMETERS               0x0A
220 #define PRINTER_NOTIFY_DATATYPE                 0x0B
221 #define PRINTER_NOTIFY_SECURITY_DESCRIPTOR      0x0C
222 #define PRINTER_NOTIFY_ATTRIBUTES               0x0D
223 #define PRINTER_NOTIFY_PRIORITY                 0x0E
224 #define PRINTER_NOTIFY_DEFAULT_PRIORITY         0x0F
225 #define PRINTER_NOTIFY_START_TIME               0x10
226 #define PRINTER_NOTIFY_UNTIL_TIME               0x11
227 #define PRINTER_NOTIFY_STATUS                   0x12
228 #define PRINTER_NOTIFY_STATUS_STRING            0x13
229 #define PRINTER_NOTIFY_CJOBS                    0x14
230 #define PRINTER_NOTIFY_AVERAGE_PPM              0x15
231 #define PRINTER_NOTIFY_TOTAL_PAGES              0x16
232 #define PRINTER_NOTIFY_PAGES_PRINTED            0x17
233 #define PRINTER_NOTIFY_TOTAL_BYTES              0x18
234 #define PRINTER_NOTIFY_BYTES_PRINTED            0x19
235
236 #define JOB_NOTIFY_PRINTER_NAME                 0x00
237 #define JOB_NOTIFY_MACHINE_NAME                 0x01
238 #define JOB_NOTIFY_PORT_NAME                    0x02
239 #define JOB_NOTIFY_USER_NAME                    0x03
240 #define JOB_NOTIFY_NOTIFY_NAME                  0x04
241 #define JOB_NOTIFY_DATATYPE                     0x05
242 #define JOB_NOTIFY_PRINT_PROCESSOR              0x06
243 #define JOB_NOTIFY_PARAMETERS                   0x07
244 #define JOB_NOTIFY_DRIVER_NAME                  0x08
245 #define JOB_NOTIFY_DEVMODE                      0x09
246 #define JOB_NOTIFY_STATUS                       0x0A
247 #define JOB_NOTIFY_STATUS_STRING                0x0B
248 #define JOB_NOTIFY_SECURITY_DESCRIPTOR          0x0C
249 #define JOB_NOTIFY_DOCUMENT                     0x0D
250 #define JOB_NOTIFY_PRIORITY                     0x0E
251 #define JOB_NOTIFY_POSITION                     0x0F
252 #define JOB_NOTIFY_SUBMITTED                    0x10
253 #define JOB_NOTIFY_START_TIME                   0x11
254 #define JOB_NOTIFY_UNTIL_TIME                   0x12
255 #define JOB_NOTIFY_TIME                         0x13
256 #define JOB_NOTIFY_TOTAL_PAGES                  0x14
257 #define JOB_NOTIFY_PAGES_PRINTED                0x15
258 #define JOB_NOTIFY_TOTAL_BYTES                  0x16
259 #define JOB_NOTIFY_BYTES_PRINTED                0x17
260
261 #define PRINTER_NOTIFY_OPTIONS_REFRESH          0x01
262
263 #define PRINTER_CHANGE_ADD_PRINTER                      0x00000001
264 #define PRINTER_CHANGE_SET_PRINTER                      0x00000002
265 #define PRINTER_CHANGE_DELETE_PRINTER                   0x00000004
266 #define PRINTER_CHANGE_FAILED_CONNECTION_PRINTER        0x00000008
267 #define PRINTER_CHANGE_PRINTER  (PRINTER_CHANGE_ADD_PRINTER | \
268                                  PRINTER_CHANGE_SET_PRINTER | \
269                                  PRINTER_CHANGE_DELETE_PRINTER | \
270                                  PRINTER_CHANGE_FAILED_CONNECTION_PRINTER )
271
272 #define PRINTER_CHANGE_ADD_JOB                          0x00000100
273 #define PRINTER_CHANGE_SET_JOB                          0x00000200
274 #define PRINTER_CHANGE_DELETE_JOB                       0x00000400
275 #define PRINTER_CHANGE_WRITE_JOB                        0x00000800
276 #define PRINTER_CHANGE_JOB      (PRINTER_CHANGE_ADD_JOB | \
277                                  PRINTER_CHANGE_SET_JOB | \
278                                  PRINTER_CHANGE_DELETE_JOB | \
279                                  PRINTER_CHANGE_WRITE_JOB )
280
281 #define PRINTER_CHANGE_ADD_FORM                         0x00010000
282 #define PRINTER_CHANGE_SET_FORM                         0x00020000
283 #define PRINTER_CHANGE_DELETE_FORM                      0x00040000
284 #define PRINTER_CHANGE_FORM     (PRINTER_CHANGE_ADD_FORM | \
285                                  PRINTER_CHANGE_SET_FORM | \
286                                  PRINTER_CHANGE_DELETE_FORM )
287
288 #define PRINTER_CHANGE_ADD_PORT                         0x00100000
289 #define PRINTER_CHANGE_CONFIGURE_PORT                   0x00200000
290 #define PRINTER_CHANGE_DELETE_PORT                      0x00400000
291 #define PRINTER_CHANGE_PORT     (PRINTER_CHANGE_ADD_PORT | \
292                                  PRINTER_CHANGE_CONFIGURE_PORT | \
293                                  PRINTER_CHANGE_DELETE_PORT )
294
295 #define PRINTER_CHANGE_ADD_PRINT_PROCESSOR              0x01000000
296 #define PRINTER_CHANGE_DELETE_PRINT_PROCESSOR           0x04000000
297 #define PRINTER_CHANGE_PRINT_PROCESSOR  (PRINTER_CHANGE_ADD_PRINT_PROCESSOR | \
298                                          PRINTER_CHANGE_DELETE_PRINT_PROCESSOR )
299
300 #define PRINTER_CHANGE_ADD_PRINTER_DRIVER               0x10000000
301 #define PRINTER_CHANGE_SET_PRINTER_DRIVER               0x20000000
302 #define PRINTER_CHANGE_DELETE_PRINTER_DRIVER            0x40000000
303 #define PRINTER_CHANGE_PRINTER_DRIVER   (PRINTER_CHANGE_ADD_PRINTER_DRIVER | \
304                                          PRINTER_CHANGE_SET_PRINTER_DRIVER | \
305                                          PRINTER_CHANGE_DELETE_PRINTER_DRIVER )
306
307 #define PRINTER_CHANGE_TIMEOUT                          0x80000000
308 #define PRINTER_CHANGE_ALL      (PRINTER_CHANGE_JOB | \
309                                  PRINTER_CHANGE_FORM | \
310                                  PRINTER_CHANGE_PORT | \
311                                  PRINTER_CHANGE_PRINT_PROCESSOR | \
312                                  PRINTER_CHANGE_PRINTER_DRIVER )
313
314 #define PRINTER_NOTIFY_INFO_DISCARDED   0x1
315
316 /*
317  * Set of macros for flagging what changed in the PRINTER_INFO_2 struct
318  * when sending messages to other smbd's
319  */
320 #define PRINTER_MESSAGE_NULL            0x00000000
321 #define PRINTER_MESSAGE_DRIVER          0x00000001
322 #define PRINTER_MESSAGE_COMMENT         0x00000002
323 #define PRINTER_MESSAGE_PRINTERNAME     0x00000004
324 #define PRINTER_MESSAGE_LOCATION        0x00000008
325 #define PRINTER_MESSAGE_DEVMODE         0x00000010      /* not curently supported */
326 #define PRINTER_MESSAGE_SEPFILE         0x00000020
327 #define PRINTER_MESSAGE_PRINTPROC       0x00000040
328 #define PRINTER_MESSAGE_PARAMS          0x00000080
329 #define PRINTER_MESSAGE_DATATYPE        0x00000100
330 #define PRINTER_MESSAGE_SECDESC         0x00000200
331 #define PRINTER_MESSAGE_CJOBS           0x00000400
332 #define PRINTER_MESSAGE_PORT            0x00000800
333 #define PRINTER_MESSAGE_SHARENAME       0x00001000
334 #define PRINTER_MESSAGE_ATTRIBUTES      0x00002000
335
336 typedef struct printer_message_info {
337         uint32 low;             /* PRINTER_CHANGE_XXX */
338         uint32 high;            /* PRINTER_CHANGE_XXX */
339         fstring printer_name;
340         uint32 flags;           /* PRINTER_MESSAGE_XXX */
341 }
342 PRINTER_MESSAGE_INFO;
343
344 /*
345  * The printer attributes.
346  * I #defined all of them (grabbed form MSDN)
347  * I'm only using:
348  * ( SHARED | NETWORK | RAW_ONLY )
349  * RAW_ONLY _MUST_ be present otherwise NT will send an EMF file
350  */
351
352 #define PRINTER_ATTRIBUTE_QUEUED                0x00000001
353 #define PRINTER_ATTRIBUTE_DIRECT                0x00000002
354 #define PRINTER_ATTRIBUTE_DEFAULT               0x00000004
355 #define PRINTER_ATTRIBUTE_SHARED                0x00000008
356
357 #define PRINTER_ATTRIBUTE_NETWORK               0x00000010
358 #define PRINTER_ATTRIBUTE_HIDDEN                0x00000020
359 #define PRINTER_ATTRIBUTE_LOCAL                 0x00000040
360 #define PRINTER_ATTRIBUTE_ENABLE_DEVQ           0x00000080
361
362 #define PRINTER_ATTRIBUTE_KEEPPRINTEDJOBS       0x00000100
363 #define PRINTER_ATTRIBUTE_DO_COMPLETE_FIRST     0x00000200
364 #define PRINTER_ATTRIBUTE_WORK_OFFLINE          0x00000400
365 #define PRINTER_ATTRIBUTE_ENABLE_BIDI           0x00000800
366
367 #define PRINTER_ATTRIBUTE_RAW_ONLY              0x00001000
368
369 #define NO_PRIORITY      0
370 #define MAX_PRIORITY    99
371 #define MIN_PRIORITY     1
372 #define DEF_PRIORITY     1
373
374 /* the flags of the query */
375 #define PRINTER_ENUM_DEFAULT            0x00000001
376 #define PRINTER_ENUM_LOCAL              0x00000002
377 #define PRINTER_ENUM_CONNECTIONS        0x00000004
378 #define PRINTER_ENUM_FAVORITE           0x00000004
379 #define PRINTER_ENUM_NAME               0x00000008
380 #define PRINTER_ENUM_REMOTE             0x00000010
381 #define PRINTER_ENUM_SHARED             0x00000020
382 #define PRINTER_ENUM_NETWORK            0x00000040
383
384 /* the flags of each printers */
385 #define PRINTER_ENUM_UNKNOWN_8          0x00000008
386 #define PRINTER_ENUM_EXPAND             0x00004000
387 #define PRINTER_ENUM_CONTAINER          0x00008000
388 #define PRINTER_ENUM_ICONMASK           0x00ff0000
389 #define PRINTER_ENUM_ICON1              0x00010000
390 #define PRINTER_ENUM_ICON2              0x00020000
391 #define PRINTER_ENUM_ICON3              0x00040000
392 #define PRINTER_ENUM_ICON4              0x00080000
393 #define PRINTER_ENUM_ICON5              0x00100000
394 #define PRINTER_ENUM_ICON6              0x00200000
395 #define PRINTER_ENUM_ICON7              0x00400000
396 #define PRINTER_ENUM_ICON8              0x00800000
397
398 /* this struct is undocumented */
399 /* thanks to the ddk ... */
400 typedef struct spool_user_1
401 {
402         uint32 size;            /* length of user_name & client_name + 2? */
403         uint32 client_name_ptr;
404         uint32 user_name_ptr;
405         uint32 build;
406         uint32 major;
407         uint32 minor;
408         uint32 processor;
409         UNISTR2 client_name;
410         UNISTR2 user_name;
411 }
412 SPOOL_USER_1;
413
414 typedef struct spool_user_ctr_info
415 {
416         uint32 level;
417         uint32 ptr;
418         SPOOL_USER_1 user1;
419 }
420 SPOOL_USER_CTR;
421
422 /*
423  * various bits in the DEVICEMODE.fields member
424  */
425
426 #define DEVMODE_ORIENTATION             0x00000001
427 #define DEVMODE_PAPERSIZE               0x00000002
428 #define DEVMODE_PAPERLENGTH             0x00000004
429 #define DEVMODE_PAPERWIDTH              0x00000008
430 #define DEVMODE_SCALE                   0x00000010
431 #define DEVMODE_POSITION                0x00000020
432 #define DEVMODE_NUP                     0x00000040
433 #define DEVMODE_COPIES                  0x00000100
434 #define DEVMODE_DEFAULTSOURCE           0x00000200
435 #define DEVMODE_PRINTQUALITY            0x00000400
436 #define DEVMODE_COLOR                   0x00000800
437 #define DEVMODE_DUPLEX                  0x00001000
438 #define DEVMODE_YRESOLUTION             0x00002000
439 #define DEVMODE_TTOPTION                0x00004000
440 #define DEVMODE_COLLATE                 0x00008000
441 #define DEVMODE_FORMNAME                0x00010000
442 #define DEVMODE_LOGPIXELS               0x00020000
443 #define DEVMODE_BITSPERPEL              0x00040000
444 #define DEVMODE_PELSWIDTH               0x00080000
445 #define DEVMODE_PELSHEIGHT              0x00100000
446 #define DEVMODE_DISPLAYFLAGS            0x00200000
447 #define DEVMODE_DISPLAYFREQUENCY        0x00400000
448 #define DEVMODE_ICMMETHOD               0x00800000
449 #define DEVMODE_ICMINTENT               0x01000000
450 #define DEVMODE_MEDIATYPE               0x02000000
451 #define DEVMODE_DITHERTYPE              0x04000000
452 #define DEVMODE_PANNINGWIDTH            0x08000000
453 #define DEVMODE_PANNINGHEIGHT           0x10000000
454
455
456 /* 
457  * Devicemode structure
458  */
459
460 typedef struct devicemode
461 {
462         UNISTR devicename;
463         uint16 specversion;
464         uint16 driverversion;
465         uint16 size;
466         uint16 driverextra;
467         uint32 fields;
468         uint16 orientation;
469         uint16 papersize;
470         uint16 paperlength;
471         uint16 paperwidth;
472         uint16 scale;
473         uint16 copies;
474         uint16 defaultsource;
475         uint16 printquality;
476         uint16 color;
477         uint16 duplex;
478         uint16 yresolution;
479         uint16 ttoption;
480         uint16 collate;
481         UNISTR formname;
482         uint16 logpixels;
483         uint32 bitsperpel;
484         uint32 pelswidth;
485         uint32 pelsheight;
486         uint32 displayflags;
487         uint32 displayfrequency;
488         uint32 icmmethod;
489         uint32 icmintent;
490         uint32 mediatype;
491         uint32 dithertype;
492         uint32 reserved1;
493         uint32 reserved2;
494         uint32 panningwidth;
495         uint32 panningheight;
496         uint8 *private;
497 }
498 DEVICEMODE;
499
500 typedef struct _devmode_cont
501 {
502         uint32 size;
503         uint32 devmode_ptr;
504         DEVICEMODE *devmode;
505 }
506 DEVMODE_CTR;
507
508 typedef struct _printer_default
509 {
510         uint32 datatype_ptr;
511         UNISTR2 datatype;
512         DEVMODE_CTR devmode_cont;
513         uint32 access_required;
514 }
515 PRINTER_DEFAULT;
516
517 /* SPOOL_Q_OPEN_PRINTER_EX request to open a printer */
518 typedef struct spool_q_open_printer_ex
519 {
520         uint32 printername_ptr;
521         UNISTR2 printername;
522         PRINTER_DEFAULT printer_default;
523         uint32 user_switch;
524         SPOOL_USER_CTR user_ctr;
525 }
526 SPOOL_Q_OPEN_PRINTER_EX;
527
528 /* SPOOL_R_OPEN_PRINTER_EX reply to an open printer */
529 typedef struct spool_r_open_printer_ex
530 {
531         POLICY_HND handle;      /* handle used along all transactions (20*uint8) */
532         WERROR status;
533 }
534 SPOOL_R_OPEN_PRINTER_EX;
535
536 typedef struct spool_notify_option_type
537 {
538         uint16 type;
539         uint16 reserved0;
540         uint32 reserved1;
541         uint32 reserved2;
542         uint32 count;
543         uint32 fields_ptr;
544         uint32 count2;
545         uint16 fields[MAX_NOTIFY_TYPE_FOR_NOW];
546 }
547 SPOOL_NOTIFY_OPTION_TYPE;
548
549 typedef struct spool_notify_option_type_ctr
550 {
551         uint32 count;
552         SPOOL_NOTIFY_OPTION_TYPE *type;
553 }
554 SPOOL_NOTIFY_OPTION_TYPE_CTR;
555
556
557
558 typedef struct s_header_type
559 {
560         uint32 type;
561         union
562         {
563                 uint32 value;
564                 UNISTR string;
565         }
566         data;
567 }
568 HEADER_TYPE;
569
570 typedef struct new_buffer
571 {
572         uint32 ptr;
573         uint32 size;
574         prs_struct prs;
575         uint32 struct_start;
576         uint32 string_at_end;
577 }
578 NEW_BUFFER;
579
580 typedef struct spool_q_getprinterdata
581 {
582         POLICY_HND handle;
583         UNISTR2 valuename;
584         uint32 size;
585 }
586 SPOOL_Q_GETPRINTERDATA;
587
588 typedef struct spool_r_getprinterdata
589 {
590         uint32 type;
591         uint32 size;
592         uint8 *data;
593         uint32 needed;
594         WERROR status;
595 }
596 SPOOL_R_GETPRINTERDATA;
597
598 typedef struct spool_q_deleteprinterdata
599 {
600         POLICY_HND handle;
601         UNISTR2 valuename;
602 }
603 SPOOL_Q_DELETEPRINTERDATA;
604
605 typedef struct spool_r_deleteprinterdata
606 {
607         WERROR status;
608 }
609 SPOOL_R_DELETEPRINTERDATA;
610
611 typedef struct spool_q_closeprinter
612 {
613         POLICY_HND handle;
614 }
615 SPOOL_Q_CLOSEPRINTER;
616
617 typedef struct spool_r_closeprinter
618 {
619         POLICY_HND handle;
620         WERROR status;
621 }
622 SPOOL_R_CLOSEPRINTER;
623
624 typedef struct spool_q_startpageprinter
625 {
626         POLICY_HND handle;
627 }
628 SPOOL_Q_STARTPAGEPRINTER;
629
630 typedef struct spool_r_startpageprinter
631 {
632         WERROR status;
633 }
634 SPOOL_R_STARTPAGEPRINTER;
635
636 typedef struct spool_q_endpageprinter
637 {
638         POLICY_HND handle;
639 }
640 SPOOL_Q_ENDPAGEPRINTER;
641
642 typedef struct spool_r_endpageprinter
643 {
644         WERROR status;
645 }
646 SPOOL_R_ENDPAGEPRINTER;
647
648
649 typedef struct spool_q_deleteprinterdriver
650 {
651         uint32 server_ptr;
652         UNISTR2 server;
653         UNISTR2 arch;
654         UNISTR2 driver;
655 }
656 SPOOL_Q_DELETEPRINTERDRIVER;
657
658 typedef struct spool_r_deleteprinterdriver
659 {
660         WERROR status;
661 }
662 SPOOL_R_DELETEPRINTERDRIVER;
663
664
665 typedef struct spool_doc_info_1
666 {
667         uint32 p_docname;
668         uint32 p_outputfile;
669         uint32 p_datatype;
670         UNISTR2 docname;
671         UNISTR2 outputfile;
672         UNISTR2 datatype;
673 }
674 DOC_INFO_1;
675
676 typedef struct spool_doc_info
677 {
678         uint32 switch_value;
679         DOC_INFO_1 doc_info_1;
680 }
681 DOC_INFO;
682
683 typedef struct spool_doc_info_container
684 {
685         uint32 level;
686         DOC_INFO docinfo;
687 }
688 DOC_INFO_CONTAINER;
689
690 typedef struct spool_q_startdocprinter
691 {
692         POLICY_HND handle;
693         DOC_INFO_CONTAINER doc_info_container;
694 }
695 SPOOL_Q_STARTDOCPRINTER;
696
697 typedef struct spool_r_startdocprinter
698 {
699         uint32 jobid;
700         WERROR status;
701 }
702 SPOOL_R_STARTDOCPRINTER;
703
704 typedef struct spool_q_enddocprinter
705 {
706         POLICY_HND handle;
707 }
708 SPOOL_Q_ENDDOCPRINTER;
709
710 typedef struct spool_r_enddocprinter
711 {
712         WERROR status;
713 }
714 SPOOL_R_ENDDOCPRINTER;
715
716 typedef struct spool_q_writeprinter
717 {
718         POLICY_HND handle;
719         uint32 buffer_size;
720         uint8 *buffer;
721         uint32 buffer_size2;
722 }
723 SPOOL_Q_WRITEPRINTER;
724
725 typedef struct spool_r_writeprinter
726 {
727         uint32 buffer_written;
728         WERROR status;
729 }
730 SPOOL_R_WRITEPRINTER;
731
732 typedef struct spool_notify_option
733 {
734         uint32 version;
735         uint32 flags;
736         uint32 count;
737         uint32 option_type_ptr;
738         SPOOL_NOTIFY_OPTION_TYPE_CTR ctr;
739 }
740 SPOOL_NOTIFY_OPTION;
741
742 typedef struct spool_notify_info_data
743 {
744         uint16 type;
745         uint16 field;
746         uint32 reserved;
747         uint32 id;
748         union
749         {
750                 uint32 value[2];
751                 struct
752                 {
753                         uint32 length;
754                         uint16 *string;
755                 }
756                 data;
757         }
758         notify_data;
759         uint32 size;
760         BOOL enc_type;
761 } SPOOL_NOTIFY_INFO_DATA;
762
763 typedef struct spool_notify_info
764 {
765         uint32 version;
766         uint32 flags;
767         uint32 count;
768         SPOOL_NOTIFY_INFO_DATA *data;
769 }
770 SPOOL_NOTIFY_INFO;
771
772 /* If the struct name looks obscure, yes it is ! */
773 /* RemoteFindFirstPrinterChangeNotificationEx query struct */
774 typedef struct spoolss_q_rffpcnex
775 {
776         POLICY_HND handle;
777         uint32 flags;
778         uint32 options;
779         uint32 localmachine_ptr;
780         UNISTR2 localmachine;
781         uint32 printerlocal;
782         uint32 option_ptr;
783         SPOOL_NOTIFY_OPTION *option;
784 }
785 SPOOL_Q_RFFPCNEX;
786
787 typedef struct spool_r_rffpcnex
788 {
789         WERROR status;
790 }
791 SPOOL_R_RFFPCNEX;
792
793 /* Remote Find Next Printer Change Notify Ex */
794 typedef struct spool_q_rfnpcnex
795 {
796         POLICY_HND handle;
797         uint32 change;
798         uint32 option_ptr;
799         SPOOL_NOTIFY_OPTION *option;
800 }
801 SPOOL_Q_RFNPCNEX;
802
803 typedef struct spool_r_rfnpcnex
804 {
805         uint32 info_ptr;
806         SPOOL_NOTIFY_INFO info;
807         WERROR status;
808 }
809 SPOOL_R_RFNPCNEX;
810
811 /* Find Close Printer Notify */
812 typedef struct spool_q_fcpn
813 {
814         POLICY_HND handle;
815 }
816 SPOOL_Q_FCPN;
817
818 typedef struct spool_r_fcpn
819 {
820         WERROR status;
821 }
822 SPOOL_R_FCPN;
823
824
825 typedef struct printer_info_0
826 {
827         UNISTR printername;
828         UNISTR servername;
829         uint32 cjobs;
830         uint32 total_jobs;
831         uint32 total_bytes;
832         
833         uint16 year;
834         uint16 month;
835         uint16 dayofweek;
836         uint16 day;
837         uint16 hour;
838         uint16 minute;
839         uint16 second;
840         uint16 milliseconds;
841
842         uint32 global_counter;
843         uint32 total_pages;
844
845         uint16 major_version;
846         uint16 build_version;
847
848         uint32 unknown7;
849         uint32 unknown8;
850         uint32 unknown9;
851         uint32 session_counter;
852         uint32 unknown11;
853         uint32 printer_errors;
854         uint32 unknown13;
855         uint32 unknown14;
856         uint32 unknown15;
857         uint32 unknown16;
858         uint32 change_id;
859         uint32 unknown18;
860         uint32 status;
861         uint32 unknown20;
862         uint32 c_setprinter;
863
864         uint16 unknown22;
865         uint16 unknown23;
866         uint16 unknown24;
867         uint16 unknown25;
868         uint16 unknown26;
869         uint16 unknown27;
870         uint16 unknown28;
871         uint16 unknown29;
872 } PRINTER_INFO_0;
873
874 typedef struct printer_info_1
875 {
876         uint32 flags;
877         UNISTR description;
878         UNISTR name;
879         UNISTR comment;
880 }
881 PRINTER_INFO_1;
882
883 typedef struct printer_info_2
884 {
885         UNISTR servername;
886         UNISTR printername;
887         UNISTR sharename;
888         UNISTR portname;
889         UNISTR drivername;
890         UNISTR comment;
891         UNISTR location;
892         DEVICEMODE *devmode;
893         UNISTR sepfile;
894         UNISTR printprocessor;
895         UNISTR datatype;
896         UNISTR parameters;
897         SEC_DESC *secdesc;
898         uint32 attributes;
899         uint32 priority;
900         uint32 defaultpriority;
901         uint32 starttime;
902         uint32 untiltime;
903         uint32 status;
904         uint32 cjobs;
905         uint32 averageppm;
906 }
907 PRINTER_INFO_2;
908
909 typedef struct printer_info_3
910 {
911         uint32 flags;
912         SEC_DESC *secdesc;
913 }
914 PRINTER_INFO_3;
915
916 typedef struct printer_info_4
917 {
918         UNISTR printername;
919         UNISTR servername;
920         uint32 attributes;
921 }
922 PRINTER_INFO_4;
923
924 typedef struct printer_info_5
925 {
926         UNISTR printername;
927         UNISTR portname;
928         uint32 attributes;
929         uint32 device_not_selected_timeout;
930         uint32 transmission_retry_timeout;
931 }
932 PRINTER_INFO_5;
933
934 typedef struct spool_q_enumprinters
935 {
936         uint32 flags;
937         uint32 servername_ptr;
938         UNISTR2 servername;
939         uint32 level;
940         NEW_BUFFER *buffer;
941         uint32 offered;
942 }
943 SPOOL_Q_ENUMPRINTERS;
944
945 typedef struct printer_info_ctr_info
946 {
947         PRINTER_INFO_0 *printers_0;
948         PRINTER_INFO_1 *printers_1;
949         PRINTER_INFO_2 *printers_2;
950         PRINTER_INFO_3 *printers_3;
951         PRINTER_INFO_4 *printers_4;
952         PRINTER_INFO_5 *printers_5;
953 }
954 PRINTER_INFO_CTR;
955
956 typedef struct spool_r_enumprinters
957 {
958         NEW_BUFFER *buffer;
959         uint32 needed;          /* bytes needed */
960         uint32 returned;        /* number of printers */
961         WERROR status;
962 }
963 SPOOL_R_ENUMPRINTERS;
964
965
966 typedef struct spool_q_getprinter
967 {
968         POLICY_HND handle;
969         uint32 level;
970         NEW_BUFFER *buffer;
971         uint32 offered;
972 }
973 SPOOL_Q_GETPRINTER;
974
975 typedef struct printer_info_info
976 {
977         union
978         {
979                 PRINTER_INFO_0 *info0;
980                 PRINTER_INFO_1 *info1;
981                 PRINTER_INFO_2 *info2;
982                 void *info;
983         } printer;
984 } PRINTER_INFO;
985
986 typedef struct spool_r_getprinter
987 {
988         NEW_BUFFER *buffer;
989         uint32 needed;
990         WERROR status;
991 } SPOOL_R_GETPRINTER;
992
993 typedef struct driver_info_1
994 {
995         UNISTR name;
996 } DRIVER_INFO_1;
997
998 typedef struct driver_info_2
999 {
1000         uint32 version;
1001         UNISTR name;
1002         UNISTR architecture;
1003         UNISTR driverpath;
1004         UNISTR datafile;
1005         UNISTR configfile;
1006 } DRIVER_INFO_2;
1007
1008 typedef struct driver_info_3
1009 {
1010         uint32 version;
1011         UNISTR name;
1012         UNISTR architecture;
1013         UNISTR driverpath;
1014         UNISTR datafile;
1015         UNISTR configfile;
1016         UNISTR helpfile;
1017         uint16 *dependentfiles;
1018         UNISTR monitorname;
1019         UNISTR defaultdatatype;
1020 }
1021 DRIVER_INFO_3;
1022
1023 typedef struct driver_info_6
1024 {
1025         uint32 version;
1026         UNISTR name;
1027         UNISTR architecture;
1028         UNISTR driverpath;
1029         UNISTR datafile;
1030         UNISTR configfile;
1031         UNISTR helpfile;
1032         uint16 *dependentfiles;
1033         UNISTR monitorname;
1034         UNISTR defaultdatatype;
1035         uint16* previousdrivernames;
1036         NTTIME driver_date;
1037         uint32 padding;
1038         uint32 driver_version_low;
1039         uint32 driver_version_high;
1040         UNISTR mfgname;
1041         UNISTR oem_url;
1042         UNISTR hardware_id;
1043         UNISTR provider;
1044 }
1045 DRIVER_INFO_6;
1046
1047 typedef struct driver_info_info
1048 {
1049         DRIVER_INFO_1 *info1;
1050         DRIVER_INFO_2 *info2;
1051         DRIVER_INFO_3 *info3;
1052         DRIVER_INFO_6 *info6;
1053 }
1054 PRINTER_DRIVER_CTR;
1055
1056 typedef struct spool_q_getprinterdriver2
1057 {
1058         POLICY_HND handle;
1059         uint32 architecture_ptr;
1060         UNISTR2 architecture;
1061         uint32 level;
1062         NEW_BUFFER *buffer;
1063         uint32 offered;
1064         uint32 clientmajorversion;
1065         uint32 clientminorversion;
1066 }
1067 SPOOL_Q_GETPRINTERDRIVER2;
1068
1069 typedef struct spool_r_getprinterdriver2
1070 {
1071         NEW_BUFFER *buffer;
1072         uint32 needed;
1073         uint32 servermajorversion;
1074         uint32 serverminorversion;
1075         WERROR status;
1076 }
1077 SPOOL_R_GETPRINTERDRIVER2;
1078
1079
1080 typedef struct add_jobinfo_1
1081 {
1082         UNISTR path;
1083         uint32 job_number;
1084 }
1085 ADD_JOBINFO_1;
1086
1087
1088 typedef struct spool_q_addjob
1089 {
1090         POLICY_HND handle;
1091         uint32 level;
1092         NEW_BUFFER *buffer;
1093         uint32 offered;
1094 }
1095 SPOOL_Q_ADDJOB;
1096
1097 typedef struct spool_r_addjob
1098 {
1099         NEW_BUFFER *buffer;
1100         uint32 needed;
1101         WERROR status;
1102 }
1103 SPOOL_R_ADDJOB;
1104
1105 /*
1106  * I'm really wondering how many different time formats
1107  * I will have to cope with
1108  *
1109  * JFM, 09/13/98 In a mad mood ;-(
1110 */
1111 typedef struct systemtime
1112 {
1113         uint16 year;
1114         uint16 month;
1115         uint16 dayofweek;
1116         uint16 day;
1117         uint16 hour;
1118         uint16 minute;
1119         uint16 second;
1120         uint16 milliseconds;
1121 }
1122 SYSTEMTIME;
1123
1124 typedef struct s_job_info_1
1125 {
1126         uint32 jobid;
1127         UNISTR printername;
1128         UNISTR machinename;
1129         UNISTR username;
1130         UNISTR document;
1131         UNISTR datatype;
1132         UNISTR text_status;
1133         uint32 status;
1134         uint32 priority;
1135         uint32 position;
1136         uint32 totalpages;
1137         uint32 pagesprinted;
1138         SYSTEMTIME submitted;
1139 }
1140 JOB_INFO_1;
1141
1142 typedef struct s_job_info_2
1143 {
1144         uint32 jobid;
1145         UNISTR printername;
1146         UNISTR machinename;
1147         UNISTR username;
1148         UNISTR document;
1149         UNISTR notifyname;
1150         UNISTR datatype;
1151         UNISTR printprocessor;
1152         UNISTR parameters;
1153         UNISTR drivername;
1154         DEVICEMODE *devmode;
1155         UNISTR text_status;
1156 /*      SEC_DESC sec_desc;*/
1157         uint32 status;
1158         uint32 priority;
1159         uint32 position;
1160         uint32 starttime;
1161         uint32 untiltime;
1162         uint32 totalpages;
1163         uint32 size;
1164         SYSTEMTIME submitted;
1165         uint32 timeelapsed;
1166         uint32 pagesprinted;
1167 }
1168 JOB_INFO_2;
1169
1170 typedef struct spool_q_enumjobs
1171 {
1172         POLICY_HND handle;
1173         uint32 firstjob;
1174         uint32 numofjobs;
1175         uint32 level;
1176         NEW_BUFFER *buffer;
1177         uint32 offered;
1178 }
1179 SPOOL_Q_ENUMJOBS;
1180
1181 typedef struct job_info_ctr_info
1182 {
1183         union
1184         {
1185                 JOB_INFO_1 **job_info_1;
1186                 JOB_INFO_2 **job_info_2;
1187                 void *info;
1188         } job;
1189
1190 } JOB_INFO_CTR;
1191
1192 typedef struct spool_r_enumjobs
1193 {
1194         NEW_BUFFER *buffer;
1195         uint32 needed;
1196         uint32 returned;
1197         WERROR status;
1198 }
1199 SPOOL_R_ENUMJOBS;
1200
1201 typedef struct spool_q_schedulejob
1202 {
1203         POLICY_HND handle;
1204         uint32 jobid;
1205 }
1206 SPOOL_Q_SCHEDULEJOB;
1207
1208 typedef struct spool_r_schedulejob
1209 {
1210         WERROR status;
1211 }
1212 SPOOL_R_SCHEDULEJOB;
1213
1214 typedef struct s_port_info_1
1215 {
1216         UNISTR port_name;
1217 }
1218 PORT_INFO_1;
1219
1220 typedef struct s_port_info_2
1221 {
1222         UNISTR port_name;
1223         UNISTR monitor_name;
1224         UNISTR description;
1225         uint32 port_type;
1226         uint32 reserved;
1227 }
1228 PORT_INFO_2;
1229
1230 typedef struct spool_q_enumports
1231 {
1232         uint32 name_ptr;
1233         UNISTR2 name;
1234         uint32 level;
1235         NEW_BUFFER *buffer;
1236         uint32 offered;
1237 }
1238 SPOOL_Q_ENUMPORTS;
1239
1240 typedef struct port_info_ctr_info
1241 {
1242         union
1243         {
1244                 PORT_INFO_1 *info_1;
1245                 PORT_INFO_2 *info_2;
1246         }
1247         port;
1248
1249 }
1250 PORT_INFO_CTR;
1251
1252 typedef struct spool_r_enumports
1253 {
1254         NEW_BUFFER *buffer;
1255         uint32 needed;          /* bytes needed */
1256         uint32 returned;        /* number of printers */
1257         WERROR status;
1258 }
1259 SPOOL_R_ENUMPORTS;
1260
1261 #define JOB_CONTROL_PAUSE              1
1262 #define JOB_CONTROL_RESUME             2
1263 #define JOB_CONTROL_CANCEL             3
1264 #define JOB_CONTROL_RESTART            4
1265 #define JOB_CONTROL_DELETE             5
1266
1267 typedef struct job_info_info
1268 {
1269         union
1270         {
1271                 JOB_INFO_1 job_info_1;
1272                 JOB_INFO_2 job_info_2;
1273         }
1274         job;
1275
1276 }
1277 JOB_INFO;
1278
1279 typedef struct spool_q_setjob
1280 {
1281         POLICY_HND handle;
1282         uint32 jobid;
1283         uint32 level;
1284         JOB_INFO ctr;
1285         uint32 command;
1286
1287 }
1288 SPOOL_Q_SETJOB;
1289
1290 typedef struct spool_r_setjob
1291 {
1292         WERROR status;
1293
1294 }
1295 SPOOL_R_SETJOB;
1296
1297 typedef struct spool_q_enumprinterdrivers
1298 {
1299         uint32 name_ptr;
1300         UNISTR2 name;
1301         uint32 environment_ptr;
1302         UNISTR2 environment;
1303         uint32 level;
1304         NEW_BUFFER *buffer;
1305         uint32 offered;
1306 }
1307 SPOOL_Q_ENUMPRINTERDRIVERS;
1308
1309 typedef struct spool_r_enumprinterdrivers
1310 {
1311         NEW_BUFFER *buffer;
1312         uint32 needed;
1313         uint32 returned;
1314         WERROR status;
1315 }
1316 SPOOL_R_ENUMPRINTERDRIVERS;
1317
1318 #define FORM_USER    0
1319 #define FORM_BUILTIN 1
1320 #define FORM_PRINTER 2
1321
1322 typedef struct spool_form_1
1323 {
1324         uint32 flag;
1325         UNISTR name;
1326         uint32 width;
1327         uint32 length;
1328         uint32 left;
1329         uint32 top;
1330         uint32 right;
1331         uint32 bottom;
1332 }
1333 FORM_1;
1334
1335 typedef struct spool_q_enumforms
1336 {
1337         POLICY_HND handle;
1338         uint32 level;
1339         NEW_BUFFER *buffer;
1340         uint32 offered;
1341 }
1342 SPOOL_Q_ENUMFORMS;
1343
1344 typedef struct spool_r_enumforms
1345 {
1346         NEW_BUFFER *buffer;
1347         uint32 needed;
1348         uint32 numofforms;
1349         WERROR status;
1350 }
1351 SPOOL_R_ENUMFORMS;
1352
1353 typedef struct spool_q_getform
1354 {
1355         POLICY_HND handle;
1356         UNISTR2 formname;
1357         uint32 level;
1358         NEW_BUFFER *buffer;
1359         uint32 offered;
1360 }
1361 SPOOL_Q_GETFORM;
1362
1363 typedef struct spool_r_getform
1364 {
1365         NEW_BUFFER *buffer;
1366         uint32 needed;
1367         WERROR status;
1368 }
1369 SPOOL_R_GETFORM;
1370
1371 typedef struct spool_printer_info_level_1
1372 {
1373         uint32 flags;
1374         uint32 description_ptr;
1375         uint32 name_ptr;
1376         uint32 comment_ptr;
1377         UNISTR2 description;
1378         UNISTR2 name;
1379         UNISTR2 comment;        
1380 } SPOOL_PRINTER_INFO_LEVEL_1;
1381
1382 typedef struct spool_printer_info_level_2
1383 {
1384         uint32 servername_ptr;
1385         uint32 printername_ptr;
1386         uint32 sharename_ptr;
1387         uint32 portname_ptr;
1388         uint32 drivername_ptr;
1389         uint32 comment_ptr;
1390         uint32 location_ptr;
1391         uint32 devmode_ptr;
1392         uint32 sepfile_ptr;
1393         uint32 printprocessor_ptr;
1394         uint32 datatype_ptr;
1395         uint32 parameters_ptr;
1396         uint32 secdesc_ptr;
1397         uint32 attributes;
1398         uint32 priority;
1399         uint32 default_priority;
1400         uint32 starttime;
1401         uint32 untiltime;
1402         uint32 status;
1403         uint32 cjobs;
1404         uint32 averageppm;
1405         UNISTR2 servername;
1406         UNISTR2 printername;
1407         UNISTR2 sharename;
1408         UNISTR2 portname;
1409         UNISTR2 drivername;
1410         UNISTR2 comment;
1411         UNISTR2 location;
1412         UNISTR2 sepfile;
1413         UNISTR2 printprocessor;
1414         UNISTR2 datatype;
1415         UNISTR2 parameters;
1416 }
1417 SPOOL_PRINTER_INFO_LEVEL_2;
1418
1419 typedef struct spool_printer_info_level_3
1420 {
1421         uint32 secdesc_ptr;
1422 }
1423 SPOOL_PRINTER_INFO_LEVEL_3;
1424
1425 typedef struct spool_printer_info_level
1426 {
1427         uint32 level;
1428         uint32 info_ptr;
1429         SPOOL_PRINTER_INFO_LEVEL_1 *info_1;
1430         SPOOL_PRINTER_INFO_LEVEL_2 *info_2;
1431         SPOOL_PRINTER_INFO_LEVEL_3 *info_3;
1432 }
1433 SPOOL_PRINTER_INFO_LEVEL;
1434
1435 typedef struct spool_printer_driver_info_level_3
1436 {
1437         uint32 cversion;
1438         uint32 name_ptr;
1439         uint32 environment_ptr;
1440         uint32 driverpath_ptr;
1441         uint32 datafile_ptr;
1442         uint32 configfile_ptr;
1443         uint32 helpfile_ptr;
1444         uint32 monitorname_ptr;
1445         uint32 defaultdatatype_ptr;
1446         uint32 dependentfilessize;
1447         uint32 dependentfiles_ptr;
1448
1449         UNISTR2 name;
1450         UNISTR2 environment;
1451         UNISTR2 driverpath;
1452         UNISTR2 datafile;
1453         UNISTR2 configfile;
1454         UNISTR2 helpfile;
1455         UNISTR2 monitorname;
1456         UNISTR2 defaultdatatype;
1457         BUFFER5 dependentfiles;
1458
1459 }
1460 SPOOL_PRINTER_DRIVER_INFO_LEVEL_3;
1461
1462 /* SPOOL_PRINTER_DRIVER_INFO_LEVEL_6 structure */
1463 typedef struct {
1464         uint32 version;
1465         uint32 name_ptr;
1466         uint32 environment_ptr;
1467         uint32 driverpath_ptr;
1468         uint32 datafile_ptr;
1469         uint32 configfile_ptr;
1470         uint32 helpfile_ptr;
1471         uint32 monitorname_ptr;
1472         uint32 defaultdatatype_ptr;
1473         uint32 dependentfiles_len;
1474         uint32 dependentfiles_ptr;
1475         uint32 previousnames_len;
1476         uint32 previousnames_ptr;
1477         NTTIME  driverdate;
1478         UINT64_S        driverversion;
1479         uint32  dummy4;
1480         uint32 mfgname_ptr;
1481         uint32 oemurl_ptr;
1482         uint32 hardwareid_ptr;
1483         uint32 provider_ptr;
1484         UNISTR2 name;
1485         UNISTR2 environment;
1486         UNISTR2 driverpath;
1487         UNISTR2 datafile;
1488         UNISTR2 configfile;
1489         UNISTR2 helpfile;
1490         UNISTR2 monitorname;
1491         UNISTR2 defaultdatatype;
1492         BUFFER5 dependentfiles;
1493         BUFFER5 previousnames;
1494         UNISTR2 mfgname;
1495         UNISTR2 oemurl;
1496         UNISTR2 hardwareid;
1497         UNISTR2 provider;
1498 } SPOOL_PRINTER_DRIVER_INFO_LEVEL_6;
1499
1500
1501 typedef struct spool_printer_driver_info_level
1502 {
1503         uint32 level;
1504         uint32 ptr;
1505         SPOOL_PRINTER_DRIVER_INFO_LEVEL_3 *info_3;
1506         SPOOL_PRINTER_DRIVER_INFO_LEVEL_6 *info_6;
1507 }
1508 SPOOL_PRINTER_DRIVER_INFO_LEVEL;
1509
1510
1511 /* this struct is undocumented */
1512 /* thanks to the ddk ... */
1513 typedef struct spool_user_level_1
1514 {
1515         uint32 size;
1516         uint32 client_name_ptr;
1517         uint32 user_name_ptr;
1518         uint32 build;
1519         uint32 major;
1520         uint32 minor;
1521         uint32 processor;
1522         UNISTR2 client_name;
1523         UNISTR2 user_name;
1524 }
1525 SPOOL_USER_LEVEL_1;
1526
1527 typedef struct spool_user_level
1528 {
1529         SPOOL_USER_LEVEL_1 *user_level_1;
1530 }
1531 SPOOL_USER_LEVEL;
1532
1533 typedef struct spool_q_setprinter
1534 {
1535         POLICY_HND handle;
1536         uint32 level;
1537         SPOOL_PRINTER_INFO_LEVEL info;
1538         SEC_DESC_BUF *secdesc_ctr;
1539         DEVMODE_CTR devmode_ctr;
1540
1541         uint32 command;
1542
1543 }
1544 SPOOL_Q_SETPRINTER;
1545
1546 typedef struct spool_r_setprinter
1547 {
1548         WERROR status;
1549 }
1550 SPOOL_R_SETPRINTER;
1551
1552 typedef struct spool_q_addprinter
1553 {
1554         UNISTR2 server_name;
1555         uint32 level;
1556         SPOOL_PRINTER_INFO_LEVEL info;
1557         DEVMODE_CTR devmode_ctr;
1558         SEC_DESC_BUF *secdesc_ctr;
1559         uint32 user_level;
1560         SPOOL_USER_LEVEL user;
1561 }
1562 SPOOL_Q_ADDPRINTER;
1563
1564 typedef struct spool_r_addprinter
1565 {
1566         WERROR status;
1567 }
1568 SPOOL_R_ADDPRINTER;
1569
1570 typedef struct spool_q_deleteprinter
1571 {
1572         POLICY_HND handle;
1573 }
1574 SPOOL_Q_DELETEPRINTER;
1575
1576 typedef struct spool_r_deleteprinter
1577 {
1578         POLICY_HND handle;
1579         WERROR status;
1580 }
1581 SPOOL_R_DELETEPRINTER;
1582
1583 typedef struct spool_q_abortprinter
1584 {
1585         POLICY_HND handle;
1586 }
1587 SPOOL_Q_ABORTPRINTER;
1588
1589 typedef struct spool_r_abortprinter
1590 {
1591         WERROR status;
1592 }
1593 SPOOL_R_ABORTPRINTER;
1594
1595
1596 typedef struct spool_q_addprinterex
1597 {
1598         uint32 server_name_ptr;
1599         UNISTR2 server_name;
1600         uint32 level;
1601         SPOOL_PRINTER_INFO_LEVEL info;
1602         DEVMODE_CTR devmode_ctr;
1603         SEC_DESC_BUF *secdesc_ctr;
1604         uint32 user_switch;
1605         SPOOL_USER_CTR user_ctr;
1606 }
1607 SPOOL_Q_ADDPRINTEREX;
1608
1609 typedef struct spool_r_addprinterex
1610 {
1611         POLICY_HND handle;
1612         WERROR status;
1613 }
1614 SPOOL_R_ADDPRINTEREX;
1615
1616
1617 typedef struct spool_q_addprinterdriver
1618 {
1619         uint32 server_name_ptr;
1620         UNISTR2 server_name;
1621         uint32 level;
1622         SPOOL_PRINTER_DRIVER_INFO_LEVEL info;
1623 }
1624 SPOOL_Q_ADDPRINTERDRIVER;
1625
1626 typedef struct spool_r_addprinterdriver
1627 {
1628         WERROR status;
1629 }
1630 SPOOL_R_ADDPRINTERDRIVER;
1631
1632
1633 typedef struct driver_directory_1
1634 {
1635         UNISTR name;
1636 }
1637 DRIVER_DIRECTORY_1;
1638
1639 typedef struct driver_info_ctr_info
1640 {
1641         DRIVER_DIRECTORY_1 *info1;
1642 }
1643 DRIVER_DIRECTORY_CTR;
1644
1645 typedef struct spool_q_getprinterdriverdirectory
1646 {
1647         uint32 name_ptr;
1648         UNISTR2 name;
1649         uint32 environment_ptr;
1650         UNISTR2 environment;
1651         uint32 level;
1652         NEW_BUFFER *buffer;
1653         uint32 offered;
1654 }
1655 SPOOL_Q_GETPRINTERDRIVERDIR;
1656
1657 typedef struct spool_r_getprinterdriverdirectory
1658 {
1659         NEW_BUFFER *buffer;
1660         uint32 needed;
1661         WERROR status;
1662 }
1663 SPOOL_R_GETPRINTERDRIVERDIR;
1664
1665 typedef struct spool_q_addprintprocessor
1666 {
1667         uint32 server_ptr;
1668         UNISTR2 server;
1669         UNISTR2 environment;
1670         UNISTR2 path;
1671         UNISTR2 name;
1672 }
1673 SPOOL_Q_ADDPRINTPROCESSOR;
1674
1675 typedef struct spool_r_addprintprocessor
1676 {
1677         WERROR status;
1678 }
1679 SPOOL_R_ADDPRINTPROCESSOR;
1680
1681
1682 typedef struct spool_q_enumprintprocessors
1683 {
1684         uint32 name_ptr;
1685         UNISTR2 name;
1686         uint32 environment_ptr;
1687         UNISTR2 environment;
1688         uint32 level;
1689         NEW_BUFFER *buffer;
1690         uint32 offered;
1691 }
1692 SPOOL_Q_ENUMPRINTPROCESSORS;
1693
1694 typedef struct printprocessor_1
1695 {
1696         UNISTR name;
1697 }
1698 PRINTPROCESSOR_1;
1699
1700 typedef struct spool_r_enumprintprocessors
1701 {
1702         NEW_BUFFER *buffer;
1703         uint32 needed;
1704         uint32 returned;
1705         WERROR status;
1706 }
1707 SPOOL_R_ENUMPRINTPROCESSORS;
1708
1709 typedef struct spool_q_enumprintprocdatatypes
1710 {
1711         uint32 name_ptr;
1712         UNISTR2 name;
1713         uint32 processor_ptr;
1714         UNISTR2 processor;
1715         uint32 level;
1716         NEW_BUFFER *buffer;
1717         uint32 offered;
1718 }
1719 SPOOL_Q_ENUMPRINTPROCDATATYPES;
1720
1721 typedef struct ppdatatype_1
1722 {
1723         UNISTR name;
1724 }
1725 PRINTPROCDATATYPE_1;
1726
1727 typedef struct spool_r_enumprintprocdatatypes
1728 {
1729         NEW_BUFFER *buffer;
1730         uint32 needed;
1731         uint32 returned;
1732         WERROR status;
1733 }
1734 SPOOL_R_ENUMPRINTPROCDATATYPES;
1735
1736 typedef struct printmonitor_1
1737 {
1738         UNISTR name;
1739 }
1740 PRINTMONITOR_1;
1741
1742 typedef struct printmonitor_2
1743 {
1744         UNISTR name;
1745         UNISTR environment;
1746         UNISTR dll_name;
1747 }
1748 PRINTMONITOR_2;
1749
1750 typedef struct spool_q_enumprintmonitors
1751 {
1752         uint32 name_ptr;
1753         UNISTR2 name;
1754         uint32 level;
1755         NEW_BUFFER *buffer;
1756         uint32 offered;
1757 }
1758 SPOOL_Q_ENUMPRINTMONITORS;
1759
1760 typedef struct spool_r_enumprintmonitors
1761 {
1762         NEW_BUFFER *buffer;
1763         uint32 needed;
1764         uint32 returned;
1765         WERROR status;
1766 }
1767 SPOOL_R_ENUMPRINTMONITORS;
1768
1769
1770 typedef struct spool_q_enumprinterdata
1771 {
1772         POLICY_HND handle;
1773         uint32 index;
1774         uint32 valuesize;
1775         uint32 datasize;
1776 }
1777 SPOOL_Q_ENUMPRINTERDATA;
1778
1779 typedef struct spool_r_enumprinterdata
1780 {
1781         uint32 valuesize;
1782         uint16 *value;
1783         uint32 realvaluesize;
1784         uint32 type;
1785         uint32 datasize;
1786         uint8 *data;
1787         uint32 realdatasize;
1788         WERROR status;
1789 }
1790 SPOOL_R_ENUMPRINTERDATA;
1791
1792 typedef struct spool_q_setprinterdata
1793 {
1794         POLICY_HND handle;
1795         UNISTR2 value;
1796         uint32 type;
1797         uint32 max_len;
1798         uint8 *data;
1799         uint32 real_len;
1800         uint32 numeric_data;
1801 }
1802 SPOOL_Q_SETPRINTERDATA;
1803
1804 typedef struct spool_r_setprinterdata
1805 {
1806         WERROR status;
1807 }
1808 SPOOL_R_SETPRINTERDATA;
1809
1810 typedef struct spool_q_resetprinter
1811 {
1812         POLICY_HND handle;
1813         uint32 unknown1;
1814         DEVMODE_CTR devmode_ctr;
1815
1816 } SPOOL_Q_RESETPRINTER;
1817
1818 typedef struct spool_r_resetprinter
1819 {
1820         WERROR status;
1821
1822 SPOOL_R_RESETPRINTER;
1823
1824
1825
1826 typedef struct _form
1827 {
1828         uint32 flags;
1829         uint32 name_ptr;
1830         uint32 size_x;
1831         uint32 size_y;
1832         uint32 left;
1833         uint32 top;
1834         uint32 right;
1835         uint32 bottom;
1836         UNISTR2 name;
1837 }
1838 FORM;
1839
1840 typedef struct spool_q_addform
1841 {
1842         POLICY_HND handle;
1843         uint32 level;
1844         uint32 level2;          /* This should really be part of the FORM structure */
1845         FORM form;
1846 }
1847 SPOOL_Q_ADDFORM;
1848
1849 typedef struct spool_r_addform
1850 {
1851         WERROR status;
1852 }
1853 SPOOL_R_ADDFORM;
1854
1855 typedef struct spool_q_setform
1856 {
1857         POLICY_HND handle;
1858         UNISTR2 name;
1859         uint32 level;
1860         uint32 level2;
1861         FORM form;
1862 }
1863 SPOOL_Q_SETFORM;
1864
1865 typedef struct spool_r_setform
1866 {
1867         WERROR status;
1868 }
1869 SPOOL_R_SETFORM;
1870
1871 typedef struct spool_q_deleteform
1872 {
1873         POLICY_HND handle;
1874         UNISTR2 name;
1875 }
1876 SPOOL_Q_DELETEFORM;
1877
1878 typedef struct spool_r_deleteform
1879 {
1880         WERROR status;
1881 }
1882 SPOOL_R_DELETEFORM;
1883
1884 typedef struct spool_q_getjob
1885 {
1886         POLICY_HND handle;
1887         uint32 jobid;
1888         uint32 level;
1889         NEW_BUFFER *buffer;
1890         uint32 offered;
1891 }
1892 SPOOL_Q_GETJOB;
1893
1894 typedef struct pjob_info_info
1895 {
1896         union
1897         {
1898                 JOB_INFO_1 *job_info_1;
1899                 JOB_INFO_2 *job_info_2;
1900                 void *info;
1901         }
1902         job;
1903
1904 }
1905 PJOB_INFO;
1906
1907 typedef struct spool_r_getjob
1908 {
1909         NEW_BUFFER *buffer;
1910         uint32 needed;
1911         WERROR status;
1912 }
1913 SPOOL_R_GETJOB;
1914
1915 typedef struct spool_q_replyopenprinter
1916 {
1917         UNISTR2 string;
1918         uint32 printer;
1919         uint32 type;
1920         uint32 unknown0;
1921         uint32 unknown1;
1922 }
1923 SPOOL_Q_REPLYOPENPRINTER;
1924
1925 typedef struct spool_r_replyopenprinter
1926 {
1927         POLICY_HND handle;
1928         WERROR status;
1929 }
1930 SPOOL_R_REPLYOPENPRINTER;
1931
1932 typedef struct spool_q_routerreplyprinter
1933 {
1934         POLICY_HND handle;
1935         uint32 condition;
1936         uint32 unknown1;        /* 0x00000001 */
1937         uint32 change_id;
1938         uint8  unknown2[5];     /* 0x0000000001 */
1939 }
1940 SPOOL_Q_ROUTERREPLYPRINTER;
1941
1942 typedef struct spool_r_routerreplyprinter
1943 {
1944         WERROR status;
1945 }
1946 SPOOL_R_ROUTERREPLYPRINTER;
1947
1948 typedef struct spool_q_replycloseprinter
1949 {
1950         POLICY_HND handle;
1951 }
1952 SPOOL_Q_REPLYCLOSEPRINTER;
1953
1954 typedef struct spool_r_replycloseprinter
1955 {
1956         POLICY_HND handle;
1957         WERROR status;
1958 }
1959 SPOOL_R_REPLYCLOSEPRINTER;
1960
1961 typedef struct spool_q_rrpcn
1962 {
1963         POLICY_HND handle;
1964         uint32 change_low;
1965         uint32 change_high;
1966         uint32 unknown0;
1967         uint32 unknown1;
1968         uint32 info_ptr;
1969         SPOOL_NOTIFY_INFO info; 
1970 }
1971 SPOOL_Q_REPLY_RRPCN;
1972
1973 typedef struct spool_r_rrpcn
1974 {
1975         uint32 unknown0;
1976         WERROR status;
1977 }
1978 SPOOL_R_REPLY_RRPCN;
1979
1980 typedef struct spool_q_getprinterdataex
1981 {
1982         POLICY_HND handle;
1983         UNISTR2 keyname;
1984         UNISTR2 valuename;
1985         uint32 size;
1986 }
1987 SPOOL_Q_GETPRINTERDATAEX;
1988
1989 typedef struct spool_r_getprinterdataex
1990 {
1991         uint32 type;
1992         uint32 size;
1993         uint8 *data;
1994         uint32 needed;
1995         WERROR status;
1996 }
1997 SPOOL_R_GETPRINTERDATAEX;
1998
1999 typedef struct spool_q_setprinterdataex
2000 {
2001         POLICY_HND handle;
2002         UNISTR2 key;
2003         UNISTR2 value;
2004         uint32 type;
2005         uint32 max_len;
2006         uint8 *data;
2007         uint32 real_len;
2008         uint32 numeric_data;
2009 }
2010 SPOOL_Q_SETPRINTERDATAEX;
2011
2012 typedef struct spool_r_setprinterdataex
2013 {
2014         WERROR status;
2015 }
2016 SPOOL_R_SETPRINTERDATAEX;
2017
2018
2019 typedef struct spool_q_enumprinterkey
2020 {
2021         POLICY_HND handle;
2022         UNISTR2 key;
2023         uint32 size;
2024 }
2025 SPOOL_Q_ENUMPRINTERKEY;
2026
2027 typedef struct spool_r_enumprinterkey
2028 {
2029         BUFFER5 keys;
2030         uint32 needed;  /* in bytes */
2031         WERROR status;
2032 }
2033 SPOOL_R_ENUMPRINTERKEY;
2034
2035 typedef struct printer_enum_values
2036 {
2037         UNISTR valuename;
2038         uint32 value_len;
2039         uint32 type;
2040         uint8  *data;
2041         uint32 data_len; 
2042         
2043 }
2044 PRINTER_ENUM_VALUES;
2045
2046 typedef struct printer_enum_values_ctr
2047 {
2048         uint32 size;
2049         uint32 size_of_array;
2050         PRINTER_ENUM_VALUES *values;
2051 }
2052 PRINTER_ENUM_VALUES_CTR;
2053
2054 typedef struct spool_q_enumprinterdataex
2055 {
2056         POLICY_HND handle;
2057         UNISTR2 key;
2058         uint32 size;
2059 }
2060 SPOOL_Q_ENUMPRINTERDATAEX;
2061
2062 typedef struct spool_r_enumprinterdataex
2063 {
2064         PRINTER_ENUM_VALUES_CTR ctr;
2065         uint32 needed;
2066         uint32 returned;
2067         WERROR status;
2068 }
2069 SPOOL_R_ENUMPRINTERDATAEX;
2070
2071 typedef struct printprocessor_directory_1
2072 {
2073         UNISTR name;
2074 }
2075 PRINTPROCESSOR_DIRECTORY_1;
2076
2077 typedef struct spool_q_getprintprocessordirectory
2078 {
2079         UNISTR2 name;
2080         UNISTR2 environment;
2081         uint32 level;
2082         NEW_BUFFER *buffer;
2083         uint32 offered;
2084 }
2085 SPOOL_Q_GETPRINTPROCESSORDIRECTORY;
2086
2087 typedef struct spool_r_getprintprocessordirectory
2088 {
2089         NEW_BUFFER *buffer;
2090         uint32 needed;
2091         WERROR status;
2092 }
2093 SPOOL_R_GETPRINTPROCESSORDIRECTORY;
2094
2095 #define PRINTER_DRIVER_VERSION 2
2096 #define PRINTER_DRIVER_ARCHITECTURE "Windows NT x86"
2097
2098 #endif /* _RPC_SPOOLSS_H */
2099