htaccess Elite

.htaccess tutorial


All times are UTC [ DST ]





Post new topic Reply to topic  [ 2 posts ] 
Author Message
 Post subject: Simple .htaccess for Controlling HTTP File Downloads
PostPosted: Jul 29th, '07, 22:46 
Offline

Joined: Jul 29th, '07, 22:36
Posts: 1
I looked for the proper forum but all of them but this one block posts by anyone but moderators. So here it is...

I have a website called uber-goober.com and all my download files are stored in http://uber-goober.com/forums/Files. I have a Robots.txt that pretty much shuts all out all of the common search engines. I don't want anyone but uber-goober.com to have permission to access thess files via either FTP or HTTP. We have a Links and Downloads Manager and it shows as an agent called "LDM Manager". I want LDM to be the only allowed agent to download these files.

How can I set this up, please? I tired to do this myself and it just shut down the website period. So I moved the .htaccess into the http://george.com/forums/Files directory and the website comes up fine, but the downloads can't be downloaded by LDM Manager:

IndexIgnore */*
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http(s)?://(www\.)?uber-goober.com [NC]
RewriteRule .*\.(.*jpg|jpeg|gif|png|bmp|pdf|ppt|sim|chm|vcx|wr f|wvx)$ http://www.uber-goober.com/forums/Files/ [R,NC]
RewriteCond %{HTTP_REFERER} !^http(s)?://(www\.)?uber-goober.com$ [NC]

What am I doing wrong?


Top
 Profile  
 
 Post subject: Re: Simple .htaccess for Controlling HTTP File Downloads
PostPosted: Aug 20th, '07, 15:14 
Offline

Joined: Feb 28th, '07, 17:16
Posts: 40
josiespencer wrote:
http://george.com/forums/Files directory and the website comes up fine, but the downloads can't be downloaded by LDM Manager:

IndexIgnore */*
RewriteEngine on
RewriteCond %{HTTP_REFERER} !^http(s)?://(www\.)?uber-goober.com [NC]
RewriteRule .*\.(.*jpg|jpeg|gif|png|bmp|pdf|ppt|sim|chm|vcx|wr f|wvx)$ http://www.uber-goober.com/forums/Files/ [R,NC]
RewriteCond %{HTTP_REFERER} !^http(s)?://(www\.)?uber-goober.com$ [NC]

What am I doing wrong?


Putting this in your /forums/Files/.htaccess file will block anyone without uber-goober.com in the referer and the user-agent LDM

Code:
Options -Indexes

RewriteEngine On
RewriteCond %{HTTP_REFERER} !^.*uber-goober\.com [NC]
RewriteCond %{HTTP_USER_AGENT} !^LDM [NC]
RewriteRule .* - [F]


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 2 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: MSN [Bot] and 4 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

Search for:
Jump to:  
cron
Powered by phpBB