Commit Graph

18 Commits

Author SHA1 Message Date
devtty1er d561c49ae5
Update Dockerfiles (#4070)
* Use LABEL in place of MAINTAINER

* Remove LABEL maintainer from Dockerfiles
2020-07-06 13:18:23 -07:00
Sebastian Rasmussen f3955c875a
[ghostscript] Add another project member to the CC-list. (#3632) 2020-04-13 06:36:21 -07:00
Sebastian Rasmussen b96dd54183
[ghostscript] Make sure that all state kept in memory. (#3619)
The default setting allows for state to be temporarily saved to disk.
This is likely to interfere with the fuzzer's knowledge about state of data.
2020-04-11 06:13:26 -07:00
Sebastian Rasmussen 41c719f127
[ghostscript] Enable flag also used in valgrind builds. (#3620)
Valgrind may complain when software reads out partially uninitialized data
and stores it elsewhere, but only reads the initialized parts from this
latter location. The flag enables code that initializes all the data to
avoid valgrind reporting false positives. Presumably MSAN suffers from
similar issues so, try enabling this flag.
2020-04-11 06:13:02 -07:00
Sebastian Rasmussen e2e155fe0e
Update flags and enable new sanitizer (#3587)
* [ghostscript] Replace deprecated flag by current flag.

In old versions of Ghostscript the flag -dPARANOIDSAFER did
more checks than -dSAFER did. In modern versions the two flags
are identical. Moreover the flag -dPARANOIDSAFER has been
deprecated for a long time, and may be removed in the future.

In Ghostscript 9.50 and later -dSAFER is the default, and does
not have to be specified. To be able to test older yet still
modern Ghostscript versions without problems -dSAFER is used.

* [ghostscript] Force enable banding while rendering.

Ghostscript uses the set resolution to determine if banding should be
enabled during rendering, or not. Under normal circumstances documents
are rendered at maybe 600 DPI, but to conserve memory while running in
OSS-fuzz 200 DPI is used (-r200x200). To still test the banding code
used under normal circumstances banding is force enabled.

Moreover BufferSpace is used to determine the band height and thus the
number of bands. At 600 DPI this is normally 4Mbyte, so a reasonable
approximate at 200 DPI is 450k. Thus BufferSpace is also set.

* [ghostscript] Enable another sanitizer to see more issues.
2020-04-07 09:10:11 -07:00
Sebastian Rasmussen 96b94f6741
[ghostscript] Use official git server URL. (#3578)
This is the correct URL according to https://www.freetype.org/developer.html

This resolves the HTTP 502 error from the git server.
2020-04-03 07:29:23 -07:00
Sebastian Rasmussen 3b695b10de
[ghostscript] Build using the bundled tiff and jpeg libraries. (#3579)
The previous configuration tried to use the system tiff library with
the bundled jpeg library. That configuration is not supported by
Ghostscript.
2020-04-03 05:30:19 -07:00
Sebastian Rasmussen cd848bbd39
[ghostscript] Avoid printing raster output to stdout. (#3547)
Previously raster output data was printed on stdout. While this
is similar to how Ghostscript is run by CUPS's gstoraster filter it
unnecessarily prolongs execution time for many files.

Changing the output file still means that CUPS will be sent the
rasterized page and will be asked to convert it to a PWG raster which
it then dutifully writes to /dev/null. Thus no major difference is
expected in what code is executed in Ghostscript (or CUPS).

When run locally on a testcase found among the problematic files here:
gs://ghostscript-corpus.clusterfuzz-external.appspot.com/libFuzzer/
fuzzer target reported a timeout after 120 seconds before this commit.
After this commit the fuzzer target succeeded after about 3 seconds.
2020-03-27 13:32:10 -07:00
Max Moroz 71f4914c45
[presubmit] Enforce language attribute in project.yaml to be always set. (#3477)
* [presubmit] Enforce language attribute in projectt.yaml to be always set.

* Update documentation, better presubmit check, new project template.

* add docstring to templates.py

* Add example values in the project.yaml template and remove python value for now

* Add "project: c++" to 256 projects

* format

* Add labels and selective_unpack sections to the presubmit check

* fix incorrect auto_ccs format in three projects

* fix nss emails after rebase
2020-03-10 11:08:01 -07:00
Sebastian Rasmussen 65390a9774
[ghostscript] Relicense target fuzzer under Apache 2.0 license. (#3440)
When contributed to OSS-fuzz the Ghostscript target fuzzer was
licensed under a "BSD-style" license, referring to a LICENSE file
that actually contained an Apache 2.0 license! Recently the OSS-fuzz
project has added a presubmit check that validates the license of
each project's target fuzzer, causing the Ghostscript target fuzzer
to now fail the test. The Ghostscript target fuzzer therefore needs
to be relicensed under Apache 2.0.

This commit relicenses the existing target fuzzer code under
Apache 2.0 so that the Ghostscript target fuzzer code will pass
OSS-fuzz's presubmit checks allowing for further development.
2020-02-28 12:32:13 -08:00
Sebastian Rasmussen 879e06798f
[ghostscript] Add place holder program name. (#3438)
The first element in the argument array to gsapi_new_instance()
is ignored since it normally is the program name. This means that
the commit introducing the "-K" argument to limit memory usage did
not have its intended effect since the "-K" argument was ignored.
Moreover, prior to that the resolution argument "-r200x200" was
being unintentionally ignored. By introducing a place holder program
name all arguments are taken into account and the reader is reminded
that the first argument is the program name.
2020-02-27 12:29:14 -08:00
Sean Kau e3de965fa9
Add additional maintainers from Artifex (#3435) 2020-02-26 16:51:54 -08:00
Sean Kau 8e2d57684b Switch Ghostscript to upstream freetype (#3286)
* Switch to freetype library.

Reintegrate freetype

* remove pkg-config dependency
2020-01-22 18:24:10 -08:00
Sebastian Rasmussen 198345dc17 [ghostscript] Limit ghostscript memory usage to 1Gbyte. (#2890) 2019-09-26 08:35:13 -07:00
Sean Kau 86f5130543 [ghostscript] Run ./autogen.sh instead of autoconf and add $ORIGIN to rpath (#2564)
* Run ./autogen.sh instead of autoconf.
* Add $ORIGIN to the rpath
2019-07-03 09:56:39 -07:00
Benjamin Gordon 8934ff6f8b Two fixes for ghostcript (#2562)
* [ghostscript] Fix ininitialized pointer

Passing an invalid pointer causes a crash in gs_new_instance.

* [ghostscript] Add seed corpus

Use the examples distributed with ghostcript as a seed corpus.
2019-07-02 07:38:50 -07:00
Sean Kau ad63d0e0ed Add upstream maintainer for ghostscript (#2549) 2019-06-28 14:43:09 -07:00
Benjamin Gordon 9b715c91c2 [ghostscript] New project: ghostscript (#2544) 2019-06-27 09:59:20 -07:00