Bug 12245 - fix _spoolss_GetPrinterDataEx by moving the keyname length check
Summary: fix _spoolss_GetPrinterDataEx by moving the keyname length check
Status: RESOLVED FIXED
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: Printing (show other bugs)
Version: 4.4.5
Hardware: All All
: P5 normal (vote)
Target Milestone: ---
Assignee: Guenther Deschner
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-09-07 07:36 UTC by Stefan Metzmacher
Modified: 2021-01-11 10:42 UTC (History)
2 users (show)

See Also:


Attachments
Patches for v4-5-test (4.35 KB, patch)
2016-09-07 07:39 UTC, Stefan Metzmacher
gd: review+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stefan Metzmacher 2016-09-07 07:36:52 UTC
We need to backport d8b57e3828eac084ad302a90b33c35ff4e918e5a.
Comment 1 Stefan Metzmacher 2016-09-07 07:39:56 UTC
Created attachment 12450 [details]
Patches for v4-5-test
Comment 2 Guenther Deschner 2016-09-07 09:03:12 UTC
Please add to 4.5
Comment 3 Stefan Metzmacher 2016-09-07 09:06:17 UTC
Pushed to autobuild-v4-5-test.
Comment 4 Guenther Deschner 2016-09-07 09:07:10 UTC
Short description of the bug:

When Windows 10 calls GetPrinterDataEx with a printserver handle (not a printer handle) to query for values like Architecture, MajorVersion, etc. in order to identify the server properties and capabilities, samba currently returns WERR_INVALID_PARAMETER for all of these queries when the keyname is "". The solution is to just ignore the keyname for printerserver handle queries completely.
Comment 5 Stefan Metzmacher 2016-09-07 15:11:52 UTC
Pushed to v4-5-test.

Needs backports to other branches.
Comment 6 Björn Jacke 2021-01-11 10:42:06 UTC
closing, it's fixed in master and there will coee no more backports.