Forum

Directory Authentication

Kapageridis Stavros
10 December 2014, 20:47
Hi,

yesterday i try to set authentication for a folder by using wigwam. I successfully create the username and password , settings applied with success too. The problem is that authentication cover all domain and not only the folder.
What i mean , is that i want to authenticate the entrance to /admin/ folder, but the authentication asked even if someone try to connect to main site too.
Is this have to do with a toolkit ? I must make a toolkit, something like we make for wordpress ?

*Some related info
1. I make the usename and password with wigwam -b username password
2. I create a file .paswords inside the /admin/ folder.
3. Copy andf paste the username and password there.
4. I set PasswordFile = basic:/home/website/admin/.passwords to /etc/hiawatha/enable-sites/website inside Virtual Host { ..}
5. Reboot hiawatha and php5-fpm services.

Hiawatha version: 9.9
Operating System: Ubuntu 14.04 x64
Hugo Leisink
11 December 2014, 08:55
Move the PasswordFile setting to a .hiawatha file which you place in the admin folder. The location of the .passwords file is irrelevant.
Kapageridis Stavros
11 December 2014, 20:30
Ok, thank you very much Hugo. I will respond back.
Kapageridis Stavros
14 December 2014, 02:03
Hi Hugo, sorry for the delayed reply.
As you say i move the PasswordFile setting to a .hiawatha file inside the folder i want to protect with authentication and place the return of wigwam -b username password inside a .password file. It is working correctly now .

*For anyone in the future with the same question i just note that both files must have www-data:www-data as owner:group, with root:root it is not working.

Thank you very much for another time
This topic has been closed.