☰
Server - Contents
Pmwiki-PartD
new: 09-Sep-2023
Extras - Pmwiki
Creating a Secure PmWiki on the Internet
Block all editing or even viewing of Pmwiki pages, PmWiki built-in user authentication system Pmwiki-AuthUser
Step1: Activating AuthUser
Recommended initial reading: Pmwiki-QuickStart For AuthUser
Via your terminal, do the following:
sammy@imega:$ nano pmwiki/local/config.php
make these changes in config.php
Note: the above should feature on a line above these below:
around line#40 [add]: $DefaultPasswords['admin'] = pmcrypt('some_secret_password');
around line#45 [add]: include_once('scripts/authuser.php'); save and exit
then goto: http://yourwiki.com/pmwiki.php?n=SiteAdmin/AuthUser&action=attr
[add]: @admins in both 'read' and 'edit' entries then save
Edit the sidebar by [add]: %sidehead% [[SiteAdmin/SiteAdmin]] and save
Open 'SiteAdmin' and with open link 'AuthUser'
Create a blank line and enter: @admins followed by your chosen 'username'
Create two blank lines and enter: username: (:encrypt some_password :)
return to config.php [replace]: $DefaultPasswords['admin'] ='@admins';
below it also [add]: $DefaultPasswords['attr'] = '@admins';
also [add]: $DefaultPasswords['edit'] = 'id.*'; - editing for logged on users only
also [add]: $DefaultPasswords['view'] = 'id.*'; - if one does not public viewing
References: Pmwiki-PasswordsAdmin
Step 2: Managing Users from within Pmwiki
Users with their passwords can be easily established by the user with admin rights.
From the SiteAdmin page, again select link: AuthUser and listing users (blank line between) as follows:
- [add]: username: (:encrypt mysecretpasswd :)
- to have additional admins, on the line with @admins: username, username2 ...
Note: One has to logout and login to make changes effective.