Bug 352711 - missing /etc/httpd/conf.d/mediawiki.conf
Summary: missing /etc/httpd/conf.d/mediawiki.conf
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: mediawiki
Version: rawhide
Hardware: All
OS: Linux
low
medium
Target Milestone: ---
Assignee: Axel Thimm
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2007-10-25 16:49 UTC by Felix Bellaby
Modified: 2009-07-26 21:06 UTC (History)
5 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2009-03-29 17:06:02 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)
Example mediawiki.conf (499 bytes, text/plain)
2007-10-25 16:49 UTC, Felix Bellaby
no flags Details

Description Felix Bellaby 2007-10-25 16:49:13 UTC
Description of problem:

The absence of a /etc/httpd/conf.d/mediawiki.conf file means that
mediawiki has to be fixed up by the user before it will work.

There are a variety of other ways of getting mediawiki to work 
described on the web, but none is documented with the Fedora
distribution. Using a mediawiki.conf seems to be the neatest.

Version-Release number of selected component (if applicable):

mediawiki-1.10.2-36.fc8

Solution:

The attached mediawiki.conf file could be installed into the 
/etc/httpd/conf.d/ directory. This file works and could be 
edited by more sophisicated users wishing to change the skins, etc.

Ideally, a postinstall script should be added to the src rpm as well
to reload the httpd and get the mediawiki.conf into the running server:

...

%post
/sbin/service httpd reload

...


The user will then be able to go to http://localhost/wiki/ and
follow the instructions to get a working wiki.

Comment 1 Felix Bellaby 2007-10-25 16:49:13 UTC
Created attachment 237661 [details]
Example mediawiki.conf

Comment 2 Bug Zapper 2008-05-14 03:43:58 UTC
Changing version to '9' as part of upcoming Fedora 9 GA.
More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 3 wvillard 2008-08-24 08:02:59 UTC
Thanks Felix for your mediawiki.conf It works great !

Comment 4 Walter Francis 2008-09-24 18:20:33 UTC
This is still not part of the mediawiki RPM and it should be.  The attachment given here works good, except it needs an additional setting.

<Location /wiki/>
Allow from All
</Location>

Otherwise, one does not have access to it.  I haven't investigated why this is, but without it in F9 it does not work.

Comment 5 Felix Bellaby 2008-09-25 19:26:55 UTC
I deliberately avoided granting access to the /wiki/ location inside the proposed conf file. I do not think that an rpm package should open up access to server resources when it is installed and there is no way that we can anticipate who is supposed to be granted access.

Comment 6 Walter Francis 2008-09-25 19:36:35 UTC
I might have done something wrong then, but without the granting to /wiki/ nobody could access the MediaWiki website.  If that in itself was deliberate, it's worth mentioning it, and perhaps put in something like:

<Location /wiki/>
Order deny,allow
Deny from all
Allow from 127.0.0.1
</Location>

That way they have local access, but then can open it up to all if they desire to in the future.  Sorry if I've missed something and I'm just spamming this bug!

Comment 7 Austin 2009-03-26 07:37:07 UTC
I think it's a damn shame that after 18 months it's still not included in the RPM. Is there any reason why it hasn't been included yet? From Fedora 8 through to Fedora 10?

Comment 8 Axel Thimm 2009-03-29 17:06:02 UTC
Alias /wiki/index.php "/var/www/wiki/index.php"
Alias /wiki/config/ "/var/www/wiki/config/"
Alias /wiki/images/ "/var/www/wiki/images/"
Alias /wiki/ "/usr/share/mediawiki/"

This looks quite dangerous to me. The current setup never exposes /usr/share/mediawiki/ to the remote user. Now it would expose all but index.php, config and images including for example /usr/share/mediawiki/maintenance.

There is no actual need for any special config in http. You just copy one or more instances, browse into their configs and then finally remove these config folders. And it's even mentioned in the package description.

Also automatically exposing /config and restarting httpd even if only accessible from localhost is a security risk.

Comment 9 Austin 2009-03-30 07:10:07 UTC
Umm... how does one "browse to the configs" if not via http://hostname/<URL-of-media-wiki-here> ?

And then how does one access it, if not via a mapping into the web-server's URL space via an alias?

Comment 10 Axel Thimm 2009-07-26 21:06:57 UTC
The current package in rawhide has some package specific documentation and sample configuration. Some wrong dependencies for minimal (mathless) installations have been fixed as well. From the changelog:

- Add a README.RPM and a sample apache mediawiki.conf file.
- All (runtime) dependencies from mediawiki need to move to
  mediawiki-nomath.

See also
http://cvs.fedoraproject.org/viewvc/rpms/mediawiki/devel/README.RPM?view=co
http://cvs.fedoraproject.org/viewvc/rpms/mediawiki/devel/mediawiki.conf?view=co

Please check if the issues are ironed out and reopen if not. The package in rawhide may further change before F12 to address bug #463784.


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