View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 3 posts ] 
Print view Previous topic   Next topic  
Author Message
Search for:
PostPosted: Wed Feb 13, 2008 12:17 pm 
Offline
Joined: Sat May 26, 2007 9:51 pm
Posts: 130
I am using Knoppmyth R5F27 which by default provides preset Digest authentication (htdigest) for the Apache webserver (lets call it "http://mythbox/"). All was great when I wanted to create one or more users with access to the entire Apache webserver. And this was described in SecuringMythWebHowTo.

Now I'd like to create a seperate user who ONLY has access to a specific subdirectory, say http://mythbox/limitedaccess/. I thought I'd be able to do this by adding a <directory> section in /etc/apache2/apache2.conf. And then creating a new user, in a new realm, with a new htdigest file. (ex. "htdigest -c /etc/htdigest_limited_access limitedRealm newuser"). But, I couldn't get it to work right as it always seems to ask for username/pw in the MythTV realm, regardless of directory.

First, is what I am trying to do possible? Or is there a better way of creating an isolated subdirectory?

Second, if it is possible, am I approaching it the right way? (edit apache2.conf and use htdigest)?


Top
 Profile  
 
 Post subject:
PostPosted: Wed Feb 13, 2008 1:55 pm 
Offline
Joined: Sat May 26, 2007 9:51 pm
Posts: 130
I found this link on apache describing how to have diverent virtual hosts running on seperate ports, or from different DNS entries. Maybe I'll just try that to keep them isolated complete. Does that seem to make better sense?


Top
 Profile  
 
 Post subject:
PostPosted: Wed Feb 13, 2008 9:08 pm 
Offline
Joined: Sat May 26, 2007 9:51 pm
Posts: 130
Ok I played around more this evening and got it working. So to close it out (for reference to others) this is what I did:

Following: this tutorial, and this tutorial

1. Modified /etc/apache2/sites-available/default to only serve on port 80 (NameVirtualHost *:80, <VirtualHost *:80>

2. Moved the htdigest authentication block within <directory /> of /etc/apache2/apache2.conf into /etc/apache2/sites-available/default.

(This allows Apache to default to the main website when on port 80)

3. Create a new file /etc/apache2/sites-available/newsite, running only on port 81. (Following tutorials)

4. Used 'a2ensite newsite' to enable the site, and restarted apache

(+ some other tweaks)


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 


All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 24 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu