Project

General

Profile

Actions

Bug #13745

closed

Make SMBsrv compatible with Modern Cups/ OpenPrinting Cups

Added by Till Wegmüller about 1 year ago. Updated about 1 year ago.

Status:
Closed
Priority:
High
Assignee:
Category:
cifs - CIFS server and client
Start date:
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:
Gerrit CR:

Description

Our SMB server is using a deprecated interface in IPP to print. This has been removed in cups 2.3 and thus SMB_PRINTING does not compile anymore. In OmniOS IPP Prinitng is implicitly disabled and in OpenIndiana It is now explicitly disabled.

What also happened, is that Apple has not updated Cups in a while and an organization called OpenPrinting has forked the project on Github: https://github.com/OpenPrinting/cups/ The OpenPrinting folks are fixing several CVE's and patches and are much better as an upstream as Apple, but illumos-gate does not build against a modern enough cups.

According to The code on Github from Apple (https://github.com/apple/cups/blob/master/CHANGES.md):
"Removed support for -D_IPP_PRIVATE_STRUCTURES=1 developer cheat - the IPP accessor functions should be used instead."

So we need to port our code to use the accessor functions instead,

Currently, to make a release we disabled printing support for SMB
https://github.com/OpenIndiana/oi-userland/pull/6683

Currently, it looks like the Printing support for SMB is not tested anymore outside of OI.

Testing by Toomas Soome: I have defined printer in cups ("epson"), so I did build the gate with this patch and installed it. Then I did create print$ share with: zfs set sharesmb=name=print$ rpool/export/print and made sure sharectl does show print_enable=true for smb protocol.

After this, windows 10 did start to show "epson" in shares list, I did add it as printer in windows and did print test page. Nothing did appear on printer. I found the data file in /export/print drectory; lpr from OI did send it to printer and it was wiondows test page. Then I found entry from log:

May  5 20:48:11 beastie smbd[1175]: [ID 856668 daemon.error] smbd_spool_copyfile: printer Postscript: client-error-not-found

Apparently smbd is looking for printer "Postscript", so I did create printer with this name (my epson is networked, adding another queue is trivial). After this, windows print jobs are sent via illumos smb service to printer.

Actions

Also available in: Atom PDF