MediaWiki: How to totally prevent anonymous users from register?

4

0

I've installed MediaWiki aiming to create some one-man-editing Wiki;
Anyone can read in that wiki (no one has to register to read and can read anonymously) but editing is only by me; a website where I can write on detailed subjects from my own standpoint.

I went through the documentation but I found no variable that controls whether anonymous users can create an account or not.

Do you know how can an admin user totally disable the option to create an accounts?

JohnDoea

Posted 2019-04-04T13:50:28.507

Reputation: 1 029

Answers

3

If you are trying to set up a Simple private wiki, this is done by adding the following options to the MediaWiki configuration file LocalSettings.php :

# Disable reading by anonymous users
$wgGroupPermissions['*']['read'] = false;

# Disable anonymous editing
$wgGroupPermissions['*']['edit'] = false;

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

For restricting only editing but not reading, omit the first instruction, leaving in place the last two.

Omit also the last instruction if you want to allow new user registrations.

harrymc

Posted 2019-04-04T13:50:28.507

Reputation: 306 093

Hi dear Harry. Question edited. – JohnDoea – 2019-04-10T06:00:50.863

Answer also edited. – harrymc – 2019-04-10T06:10:58.317

Thanks ! It worked opposite (true, false, false); Can award bounty in 22 hours. – JohnDoea – 2019-04-10T06:17:47.690

2

I've gone through this a few times and you have a couple options. None of these alone will solve all of your fake user issues, but together they will go a long way. Before we about disabling accounts, let's talk about prevention (because you will get more fake accounts in the future). This page has a lot of good information in regards to this topic, but I'll highlight a few things that helped me specifically.

  1. Make sure you add a captcha Adding a required captcha or re-captcha to a media wiki will help with bots, but less with people spamming the site. I noticed when I added this I saw a large downturn in fake users. Eventually though, they picked back up because real-people began adding to the site.

  2. Email validation If you're running a more personal media wiki (for example, a research lab) it may be practical to have users admins authenticate additional users. Of course, this isn't practical if this is a general media wiki site. You can also enable email validation for the users themselves. You'd be suprised how far you can go with requiring users to put in a valid email.

  3. Password Security You can require that your password be very specfic in order to combat bot usage that many times have a specfic combination of letters and numbers for their generated passwords. Plus, you can set password expirations to help with bots that are stateless.

juicedatom

Posted 2019-04-04T13:50:28.507

Reputation: 121

Thank you I thumbed up. – JohnDoea – 2019-04-14T03:58:02.387