louisdem / plan9front

Automatically exported from code.google.com/p/plan9front
0 stars 0 forks source link

gs aborts while reading the POODLE paper #227

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
to reproduce:

; hget https://www.openssl.org/~bodo/ssl-poodle.pdf > poodle.pdf
; gs -sOutputFile'=poodle%d.bit' poodle.pdf
AFPL Ghostscript 8.53 (2005-10-20)
Copyright (C) 2005 artofcode LLC, Benicia, CA.  All rights reserved.
This software comes with NO WARRANTY: see the file PUBLIC for details.
Processing pages 1 through 4.
Page 1
>>showpage, press <return> to continue<<

Page 2
Error: /rangecheck in --string--
Operand stack:
   --dict:5/5(L)--   F2   15   --dict:6/6(L)--   --dict:6/6(L)--   AppleSymbols   --dict:9/12(ro)(G)--   --nostringval--   --dict:7/7(L)--   --dict:7/7(L)--   11495   --dict:7/7(L)--   --nostringval--   2228188   2228188
Execution stack:
   %interp_exit   .runexec2   --nostringval--   --nostringval--   --nostringval--   2   %stopped_push   --nostringval--   --nostringval--   --nostringval--   false   1   %stopped_push   1   3   %oparray_pop   1   3   %oparray_pop   1   3   %oparray_pop   --nostringval--   --nostringval--   3   1   4   --nostringval--   %for_pos_int_continue   --nostringval--   --nostringval--   --nostringval--   --nostringval--   %array_continue   --nostringval--   false   1   %stopped_push   --nostringval--   %loop_continue   --nostringval--   --nostringval--   --nostringval--   --nostringval--   --nostringval--   --nostringval--   %array_continue   --nostringval--   --nostringval--   --nostringval--   --nostringval--   --nostringval--   --nostringval--   --nostringval--   --nostringval--   %array_continue   --nostringval--   --nostringval--   --nostringval--
Dictionary stack:
   --dict:1120/1686(ro)(G)--   --dict:2/20(G)--   --dict:75/200(L)--   --dict:75/200(L)--   --dict:105/127(ro)(G)--   --dict:258/347(ro)(G)--   --dict:21/24(L)--   --dict:4/6(L)--   --dict:20/20(L)--   --dict:1/1(ro)(G)--   --dict:13/20(L)--   --dict:33/50(ro)(G)--   --dict:15/40(L)--
Current allocation mode is local
Last OS error: 20
AFPL Ghostscript 8.53: Unrecoverable error, exit code 1
; 

Original issue reported on code.google.com by mischief@offblast.org on 12 Nov 2014 at 2:22

GoogleCodeExporter commented 9 years ago
problem is that ghostscript is limited to 64K strings. this one creates a 2MB 
one.
the ref.rsize field is a ushort, too small. changing it to uint works on amd64, 
but
breaks 386 with crashes in the garbage collector.

Original comment by cinap_le...@felloff.net on 21 Feb 2015 at 12:24

GoogleCodeExporter commented 9 years ago
fixed in reb125d73d829

Original comment by cinap_le...@felloff.net on 21 Feb 2015 at 9:59