Password protect Serendipity's home directory

Having trouble installing serendipity?
Post Reply
alblee
Posts: 4
Joined: Sun Apr 08, 2018 12:39 pm

Password protect Serendipity's home directory

Post by alblee » Sun Apr 08, 2018 12:48 pm

I would like to password restrict my Serendipity installation but the app's home directory already has a default .htaccess file that doesn't seem to allow any tampering [the install breaks when the app is called]. How can I password protect the Serendipity home directory on Linux/Apache? Danke!

thh
Regular
Posts: 232
Joined: Thu Oct 26, 2006 2:38 pm
Location: Stuttgart, Germany
Contact:

Re: Password protect Serendipity's home directory

Post by thh » Sun Apr 08, 2018 4:37 pm

alblee wrote:I would like to password restrict my Serendipity installation but the app's home directory already has a default .htaccess file that doesn't seem to allow any tampering [the install breaks when the app is called].
You can generally modify the default .htaccess file without breaking Serendipity.

Did you try add your basic auth to the .htaccess file outside the

Code: Select all

# BEGIN s9y
[...]
# END s9y
markers? - That shouldn't break anything.

Does your basic auth work at all (without Serendipity)? Error messages after adding basic auth may be due to a wrong location of the password filde or basic auth being disabled by your hoster.

alblee
Posts: 4
Joined: Sun Apr 08, 2018 12:39 pm

Re: Password protect Serendipity's home directory

Post by alblee » Mon Apr 09, 2018 2:11 am

Thanks @thh. I will try inserting
your suggested lines again,

alblee
Posts: 4
Joined: Sun Apr 08, 2018 12:39 pm

Re: Password protect Serendipity's home directory

Post by alblee » Mon Apr 09, 2018 10:36 am

@thh, Hi!

I tried adding the following lines outside of the
# BEGIN s9y
[ ... blah ... ]
# END s9y



BEGIN MY INSERTION
AuthType Basic
AuthName “Sinuswerte Ka? Hwag Road Please”
AuthUserFile somepath/somepath/.htpasswd
require valid-user
END MY INSERTION


and that broke the Serendipity-default .htaccess file in its home directory.
But when I removed the offending four lines. The forum came back in fine shape.
I still want to password protect that Serendipity home directory from public eyes for now. It:s just that the revised .htaccess file doesn't work, heh heh.

Or would you have a suggestion how to make the Serendipity front door publicly invisible except to the few of us who have password keys to open the private blog? This effectively makes our Serendipity a private team space, for now, until we decide it is time to go public?

Thanks very much again. :)

thh
Regular
Posts: 232
Joined: Thu Oct 26, 2006 2:38 pm
Location: Stuttgart, Germany
Contact:

Re: Password protect Serendipity's home directory

Post by thh » Mon Apr 09, 2018 9:39 pm

alblee wrote:BEGIN MY INSERTION
AuthType Basic
AuthName “Sinuswerte Ka? Hwag Road Please”
AuthUserFile somepath/somepath/.htpasswd
require valid-user
END MY INSERTION

and that broke the Serendipity-default .htaccess file in its home directory.
But when I removed the offending four lines. The forum came back in fine shape.
Does that work somewhere else, i.e. can you test that in another directory or vhost?

It may be that the path to your .htpasswd is wrong or your provider does not allow basic auth in .htaccess files.

Your code should work with Serendipity.

alblee
Posts: 4
Joined: Sun Apr 08, 2018 12:39 pm

Re: Password protect Serendipity's home directory

Post by alblee » Tue Apr 10, 2018 2:51 am

Yes, @thh, I had thought so.
I will try submitting a service ticket to the hosting admin.

Thanks.
thh wrote:
alblee wrote:BEGIN MY INSERTION
AuthType Basic
AuthName “Sinuswerte Ka? Hwag Road Please”
AuthUserFile somepath/somepath/.htpasswd
require valid-user
END MY INSERTION

and that broke the Serendipity-default .htaccess file in its home directory.
But when I removed the offending four lines. The forum came back in fine shape.
Does that work somewhere else, i.e. can you test that in another directory or vhost?

It may be that the path to your .htpasswd is wrong or your provider does not allow basic auth in .htaccess files.

Your code should work with Serendipity.

Post Reply