WebFaction
Community site: login faq

Hi, We have created a new webfaction account. Using Apps -Django 1.3 with mod_wsgi and apache

Our website streams audio/video files to our customers and we serve it through apache in a secured way. As of now we are achieving this by editing our apache-httpd.conf file and allowing accesss to the media files if a cookies is present in HTTP Response. Now we are moving to webfaction.After setting up django,symbolic link to django_media and static only access.Can we go ahead and edit appache2 httpd.conf file to allow access to this directory only if a cookie is set? Is this possible with webfaction.

asked 27 Oct '11, 20:58

AKV
135
accept rate: 0%

edited 27 Oct '11, 20:59


Yes, it is possible with Apache, you can do it using the following rewrite rules in your httpd.conf:

RewriteCond %{HTTP_COOKIE} !(^|\ |;)auth=true;
RewriteRule ^ - [R=401,L]

The above is just an example, you can use any other cookie values too.

permanent link

answered 27 Oct '11, 22:26

neeravk
1.5k3412
accept rate: 41%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×27

question asked: 27 Oct '11, 20:58

question was seen: 1,845 times

last updated: 27 Oct '11, 22:26

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2019 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM