Fix bug 9900: is_printer_published GUID retrieval
authorDavid Disseldorp <ddiss@samba.org>
Wed, 22 May 2013 15:58:38 +0000 (17:58 +0200)
committerKarolin Seeger <kseeger@samba.org>
Tue, 4 Jun 2013 07:52:33 +0000 (09:52 +0200)
commit577b2e554cff29d7676ef74ace1536210503601c
tree6d8f0e0de86a722baf68490a35d79d585b858db1
parentd867da670e42e3cbcf5f251a8a758f9506511086
Fix bug 9900: is_printer_published GUID retrieval

Samba currently always responds to GetPrinter(level = 7) requests with
DSPRINT_UNPUBLISH, regardless of the AD publish status tracked via the
PRINTER_ATTRIBUTE_PUBLISHED flag. This is due to erroneous "objectGUID"
unmarshalling in is_printer_published().

This change splits "objectGUID" retrieval into a separate function, and
adds a pull_reg_sz() call to correctly unmarshall the GUID.
source3/include/nt_printing.h
source3/printing/nt_printing_ads.c
source3/rpc_server/spoolss/srv_spoolss_nt.c
source3/smbd/server_reload.c