Mediawiki/Hardening

From r00tedvw.com wiki
(Difference between revisions)
Jump to: navigation, search
(Created page with "==Disable user self registration== Add the following to LocalSettings.php # Prevent new user registrations except by sysops $wgGroupPermissions['*']['createaccount'] = false;")
 
Line 3: Line 3:
 
  # Prevent new user registrations except by sysops
 
  # Prevent new user registrations except by sysops
 
  $wgGroupPermissions['*']['createaccount'] = false;
 
  $wgGroupPermissions['*']['createaccount'] = false;
 +
==Uploads Dir security==
 +
add to the bottom of your Virtual site config, before you close it:
 +
<Directory /var/www/yoursite.com/wiki/images/>
 +
              # Ignore .htaccess files
 +
              AllowOverride None
 +
              # Serve HTML as plaintext, don't execute SHTML
 +
              AddType text/plain .html .htm .shtml .php
 +
              # Don't run arbitrary PHP code.
 +
              php_admin_flag engine off
 +
                # If you've other scripting languages, disable them too.
 +
</Directory>

Revision as of 23:33, 11 October 2014

Disable user self registration

Add the following to LocalSettings.php

# Prevent new user registrations except by sysops
$wgGroupPermissions['*']['createaccount'] = false;

Uploads Dir security

add to the bottom of your Virtual site config, before you close it:

<Directory /var/www/yoursite.com/wiki/images/>
              # Ignore .htaccess files
              AllowOverride None
              # Serve HTML as plaintext, don't execute SHTML
              AddType text/plain .html .htm .shtml .php
              # Don't run arbitrary PHP code.
              php_admin_flag engine off
               # If you've other scripting languages, disable them too.
</Directory>
Personal tools
Namespaces

Variants
Actions
Navigation
Mediawiki
Confluence
DevOps Tools
Open Source Products
Ubuntu
Ubuntu 22
Mac OSX
Oracle Linux
AWS
Windows
OpenVPN
Grafana
InfluxDB2
TrueNas
MagicMirror
OwnCloud
Pivotal
osTicket
OTRS
phpBB
WordPress
VmWare ESXI 5.1
Crypto currencies
HTML
CSS
Python
Java Script
PHP
Raspberry Pi
Canvas LMS
Kaltura Media Server
Plex Media Server
MetaSploit
Zoneminder
ShinobiCE
Photoshop CS2
Fortinet
Uploaded
Certifications
General Info
Games
Meal Plans
NC Statutes
Politics
Volkswagen
Covid
NCDMV
Toolbox