Basically you want to have two things:
- One single account on your website that is also used by MediaWiki.
- Automatically login to mediawiki when a user logs in to your website.
Central user database
Mediawiki has several extensions with connecting user management to another database, for example:
You should take a look at ExtAuthDB, as it should be enough for you.
Single sign-on
Single Sign-On (SSO) is mainly done through the sharing of cookies between web applications. For this to happen, you need to have a wiki in the subdomain of your main page, i.e. wiki.example.org when your site is in example.org .
Set a cookie for .example.org on your website (note the leading point in the cookie domain), so it is also available for wiki.example.org .
The content of the cookie can be either a full mediawiki file (which you need to create on your website) or a cookie with the relevant user information that the wiki extension itself reads and logs in. I suggest looking at how Phpbb_Single_Sign-On is implemented and does the same for your site.
source share