Hi!

I crashed my RedHat Linux 7.1 box once when viewing one of my handwritten web pages, 
and
after some debugging is seems that bad html on Mozilla starts xfs font server spinning
out of control. xfs eats all CPU time and memory after opening the page
with Mozilla, which seems to be asking for larger and larger fonts.

Perhaps someone from xfree or mozilla lists can debug the details.

There is a bug in Mozilla when viewing this kind of page, but xfs still
should not go crazy. I did not have time to install newer versions of Xfree, but at 
least
http://www.xfree.org/security/ does not show a fix for this.

Linux setup:

$ uname -a
Linux lnx 2.4.2-2 #1 Sun Apr 8 20:41:30 EDT 2001 i686 unknown

$ X -version

XFree86 Version 4.0.3 / X Window System
(protocol Version 11, revision 0, vendor release 6400)
Release Date: 16 March 2001
        If the server is older than 6-12 months, or if your card is
        newer than the above date, look for a newer version before
        reporting problems.  (See http://www.XFree86.Org/FAQ)
Operating System: Linux 2.2.17-8smp i686 [ELF]
Module Loader present

$ mozilla -version
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.6) Gecko/20011120, build 2001112012

$ mozilla -version
Mozilla/5.0 (X11; N; Linux 2.4.2-2 i686), build 2001031614

The 'not-that-bad' html page:

$ perl -e 'print "<HTML>" x 1; print "<BODY>" x 1;print "<CENTER><P><H3>A" x 100; 
print "</BODY>" x 1;print "</HTML>" x 1'

top log:
<snip>

  4:07pm  up 23:08,  6 users,  load average: 0.02, 0.06, 0.02
1 processes: 1 sleeping, 0 running, 0 zombie, 0 stopped
CPU states:  2.7% user,  0.8% system,  0.0% nice, 44.8% idle
Mem:   125640K av,  122956K used,    2684K free,       0K shrd,    1604K buff
Swap:  208804K av,   99844K used,  108960K free                   64972K cached
  PID USER     PRI  NI  SIZE  RSS SHARE STAT %CPU %MEM   TIME COMMAND
 1208 xfs        9   0 73100  27M 20948 S     0.0 22.4  17:18 xfs
 1208 xfs        9   0 73100  27M 20948 S     0.0 22.4  17:18 xfs
 1208 xfs       17   0 73100  30M 23816 D    45.3 24.5  17:19 xfs
 1208 xfs       17   0 73100  27M 24080 D    30.0 22.1  17:20 xfs
 1208 xfs       15   0 73056  31M 29092 D    15.1 25.7  17:20 xfs
 1208 xfs       15   0 73056  34M 32284 D    12.1 28.3  17:20 xfs
 1208 xfs       17   0 73056  39M 37056 D     6.6 32.1  17:20 xfs
 1208 xfs       17   0 73056  42M 39852 D     2.4 34.3  17:20 xfs

  4:08pm  up 23:09,  6 users,  load average: 0.54, 0.16, 0.05
1 processes: 1 sleeping, 0 running, 0 zombie, 0 stopped
CPU states:  4.3% user,  7.1% system,  0.0% nice, 88.5% idle
Mem:   125640K av,  122436K used,    3204K free,       0K shrd,     404K buff
Swap:  208804K av,  114312K used,   94492K free                   63136K cached

  PID USER     PRI  NI  SIZE  RSS SHARE STAT %CPU %MEM   TIME COMMAND
 1208 xfs       17   0 73056  45M 43728 D     5.7 37.4  17:21 xfs

<had to killall mozilla-bin to avoid out-of-mem, snip>

It seems that neither xfs nor Mozilla have any real security holes, since
Mozilla only asks for larger and larger fonts. However, this is way too
easy to reproduce, and when the xfs dies the whole X session becomes
unstable...

Regards,
-Mikko

Reply via email to