Bug 51636 - fonts.dir can be read after running mkfontdir
fonts.dir can be read after running mkfontdir
Product: Red Hat Linux
Classification: Retired
Component: XFree86 (Show other bugs)
i386 Linux
medium Severity high
: ---
: ---
Assigned To: Mike A. Harris
David Lawrence
Depends On:
  Show dependency treegraph
Reported: 2001-08-13 10:14 EDT by Niels Basjes
Modified: 2007-04-18 12:35 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2001-08-13 11:03:06 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)
The patch I decided to use for now. (508 bytes, patch)
2001-08-13 10:15 EDT, Niels Basjes
no flags Details | Diff

  None (edit)
Description Niels Basjes 2001-08-13 10:14:17 EDT
From Bugzilla Helper:
User-Agent: Mozilla/4.75 [en] (X11; U; Linux 2.2.14-5.0 i686)

Description of problem:
As can be seen in /etc/rc.d/init.d/xfs after mkfontdir a chmod a+r must be
performed in order to allow the xfs which is using -droppriv to read the
fonts.dir file. Without read rights the X server won't start at all.

After installing a package like kdebase-2.1.1-8.i386.rpm (which  includes
some fonts), the post install script of this RPM runs the mkfontdir
application te regenerate the fonts.dir file without the (for xfs
-dropppriv) required chmod command. Because the xfs script only does the
chmod command if the fonts.dir is older than the fonts it will not be run
because the RPM script already ran the mkfontdir program.

2 possible solutions:
1) Change mkfontdir to create the fonts.dir file with 644 rights.
2) Change /etc/rc.d/init.d/xfs to set the correct rights.
3) Nolonger run xfs with -droppriv (BAD idea !!)

How reproducible:

Steps to Reproduce:
1. Ensure X is not running.
2. /usr/X11R6/bin/mkfontdir /usr/X11R6/lib/X11/fonts/misc
3. /etc/rc.d/init.d/xfs restart 
4. startx

Actual Results:  The X-server doesn't start and gives the error:

Fatal server error:
could not open default cursor font

Expected Results:  X-server starts.

Additional info:

The file /etc/rc.d/init.d/xfs comes from
Comment 1 Niels Basjes 2001-08-13 10:15:36 EDT
Created attachment 27515 [details]
The patch I decided to use for now.
Comment 2 Mike A. Harris 2001-08-13 11:03:02 EDT
Patched mkfontdir to create new files with mode 0644.

Will appear in rawhide sometime.

Note You need to log in before you can comment on or make changes to this bug.