Password Protecting a Directory in Webmin

How to Password Protect a directory in Webmin.

Normally, when our web server is Apache, we use .htaccess and .htpassword for setting up a username/password for restricting access to a certain page, folder or directory.

In Webmin, there is a function called “Password protecting a directory” already set up for you.

Below are the easy steps to password protect a directory using Webmin:

1) login in to the Webmin interface

2) Browse to Main menu -> choose “Others” -> choose “Protected Web Directories” -> “if any, or choose automatically File containing groups: if any, or choose None

Password encryption: choose the encryption type Authentication realm: the name will appear in login box, e.g.: “Admin Area”

Users to allow: put the username you want to setup in “Only Users:” field

4) click the “Create” button

5) On the next page, you can add/edit a password for this user, then click submit/save button.

It’s done!

Useful links: