[tex-k] more el_gordo fun with METAFONT

胡亚捷 (Hu Yajie) 2500418497 at qq.com
Mon Jun 1 16:49:21 CEST 2020


Here's a similar bug in mf.web that can be exploited.
Section 968 says that transformations are computed as p*t + q*u + delta.
The additions are unchecked, so if you make the first two terms slightly
less than el_gordo, the result can wrap to a value pretty close to zero.

transform t;
(0,0) transformed t = (0,0);
(0,1) transformed t = (180,180);
(1,0) transformed t = (180,180);  % t = (0,0,180,180,180,180)
z = (180, 180) transformed t;     % this computes 180*180+180*180 = 64800
show z;                           % and my computer reports (-736,-736)

I suspect more bugs can be revealed by doing a thorough boundary testing
of the METAFONT program.  On the other hand, David Fuchs probably has
already done it.



More information about the tex-k mailing list.