[cups.development] A postscript rendering filter

Michael Sweet mike at easysw.com
Fri May 19 16:54:05 PDT 2006


Matt Anderson wrote:
> The problem I'm trying to solve is how to take a multipage postscript
> document and render it to bitmaps so that it can be passed along to
> other filters and eventually to a printer for the purpose of an LSPP
> Common Criteria evaluation.  Since LSPP requires the system to have the
> ability to label all output, a filter is needed to be able to apply
> banners to the top and bottom of each printed page.  Given the
> postscript is a complete language its possible for malicious postscript
> to override these banners, which cannot happen.

You *do* know that CUPS includes specific features for this, right?
The Classification directive and page-label option provide this very
functionality, and it is good enough for the US DoD to use (and was
specifically designed for that...)

You can run any PostScript input through Ghostscript to generate
printer-independent PostScript and then run it through the existing
pstops filter to get around malicious PS code.

> One intermediate idea was to convert the PS to PDF, this solves the
> multiple pages issue nicely, but the PDF spec is very large so that
> presents a documentation problem when it comes to a low level design for
> meeting EAL4.  So far the solution I have is to render the postscript
> and pass along images which will have a higher level of trust.  This has
> a drawback of still requiring postscript as the output container as I am
> not aware of any image format which support multiple pages.

GIF, MNG, TIFF, and CUPS raster are all possible formats you can use.

CUPS raster is already supported by Ghostscript, can provide high-
resolution images, and can easily be interfaced with laser and inkjet
printers.  It should be trivial to watermark this data and then pass
it to any of the existing CUPS raster drivers...

-- 
______________________________________________________________________
Michael Sweet, Easy Software Products           mike at easysw dot com
Internet Printing and Publishing Software        http://www.easysw.com




More information about the cups mailing list