spoolss: retrieve published printer GUID if not in registry
commit88e22cdb3b1fc8d43b4bd172b7ecb74bd2317c82
authorAndreas Schneider <asn@samba.org>
Thu, 18 Dec 2014 15:14:36 +0000 (18 15:14 +0000)
committerKarolin Seeger <kseeger@samba.org>
Sun, 15 Mar 2015 21:13:08 +0000 (15 22:13 +0100)
tree198bbc7ce8a43de92f3ec82cdfee2cb31584d567
parent40a9097649cce1d61bcbc652738ef1c60488d68a
spoolss: retrieve published printer GUID if not in registry

When a printer is published, the GUID for the published DN is retrieved
from the domain controller and stored in the registry.
When handling a spoolss GetPrinter(level=7) request, the same GUID is
obtained from the registry and returned to the client.

This change sees the spoolss server query the DC for the published
printer GUID if it is not present in the registry when handling a
spoolss GetPrinter(level=7) request.

BUG: https://bugzilla.samba.org/show_bug.cgi?id=11018

Pair-Programmed-With: David Disseldorp <ddiss@samba.org>
Signed-off-by: Andreas Schneider <asn@samba.org>
Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
(cherry picked from commit a4157e7c5d75be7003ad0b72fdfe9856a9e5ba8f)
source3/rpc_server/spoolss/srv_spoolss_nt.c