473,698 Members | 2,082 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

how to protect clips files by php, apache, mysql, sessions

I have a members area full of video clips.
Clips are inside /hide/videoclips/ and /hide is apache protected directory
by .htaccess
Users can enter by a login.php (entering user and password) managed by
php, sessions and mysql.
When they enter I create a symbolic temp link pointing to
/private/videoclips so they can download the clips.
By the crontab I clean the temp link every now and then.
So if someone post the link http://www.mydomain.com/hide/clip1.mpg on a
forum, nobody can enter thanks to the apache login.
Is this the best secure way to organize a members area or is there a best
more secure way to create it?

Jul 17 '05 #1
5 2827
On 2005-05-05, fr*********@nos pam.com <fr*********@no spam.com> wrote:
I have a members area full of video clips.
Clips are inside /hide/videoclips/ and /hide is apache protected directory
by .htaccess
Users can enter by a login.php (entering user and password) managed by
php, sessions and mysql.
When they enter I create a symbolic temp link pointing to
/private/videoclips so they can download the clips.
By the crontab I clean the temp link every now and then.
So if someone post the link http://www.mydomain.com/hide/clip1.mpg on a
forum, nobody can enter thanks to the apache login.
Is this the best secure way to organize a members area or is there a best
more secure way to create it?


I'm using apache's own authorization mechanism for restricting access to
some files. I believe this is easier and safer than your solution.

--
Med venlig hilsen
- Jacob Atzen
Jul 17 '05 #2
>I'm using apache's own authorization mechanism for restricting access to
some files. I believe this is easier and safer than your solution.

But you need to edit a file each new sign up or cancel then connect to
your site, make an ftp,....
I have paypal and by its IPN my php script add and cancel users while I
sleep.
Furthermore if someone post a username and password in a forum are you
able to discover the problem?
I have a db with ip and state of the user so if I receive many login from
different states I can lock it, and you?


Jul 17 '05 #3
On 2005-05-05, fr*********@nos pam.com <fr*********@no spam.com> wrote:
I'm using apache's own authorization mechanism for restricting access to
some files. I believe this is easier and safer than your solution.

But you need to edit a file each new sign up or cancel then connect to
your site, make an ftp,....
I have paypal and by its IPN my php script add and cancel users while I
sleep.
Furthermore if someone post a username and password in a forum are you
able to discover the problem?
I have a db with ip and state of the user so if I receive many login from
different states I can lock it, and you?


You can update the apache login information from your php script. The
sharing of passwords is the same problem one way or the other.

--
Cheers,
- Jacob Atzen
Jul 17 '05 #4
>ou can update the apache login information from your php script. The
sharing of passwords is the same problem one way or the other.

Jacob: I want a db because I want to know date of last access (sometimes
someone say he can't login), where he is from, ip, ...
I can stop the sharing password problem after 5 unahautorized access and
you can't.
Jul 17 '05 #5
fr*********@yah oo.com wrote:
ou can update the apache login information from your php script. The
sharing of passwords is the same problem one way or the other.


Jacob: I want a db because I want to know date of last access (sometimes
someone say he can't login), where he is from, ip, ...
I can stop the sharing password problem after 5 unahautorized access and
you can't.


For a start, check out http://sourceforge.net/projects/modauthmysql/.
It allows you to use a MySQL database with Apache authorization.

Won't give you the other stuff you want, however.

--
=============== ===
Remove the "x" from my email address
Jerry Stuckle
JDS Computer Training Corp.
js*******@attgl obal.net
=============== ===
Jul 17 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
1976
by: Andrea A | last post by:
Hi, i'm setting up a website with a forecast traffic of 70.000 sessions and 1.000.000 pageviews a day. I'm in trouble about the short budget I have (about 10K $) and the big traffic and so the best architecture I can set up. Any Idea about I can do? Thank you in advance, Andrea
2
2355
by: Flier_75 | last post by:
Hi, I just password-protected an intranet site by including a password authentication script in each page of a private section. The script checks the login against the mySQL database. Appropriate file permissions have been set up on the private directory. My concern is now about protecting the Mysql password. Let's assume I use Apache to protect the access to this password (<files></files> or SetEnv in httpd.conf).
4
2392
by: Jan Nordgreen | last post by:
The following code only generates the first csv file. The second request is just ignored. What am I doing wrong? I am using Mozilla Firefox, Windows XP, and Xampp. <?php require 'bm_connect.php'; // export to csv file the table bmbookmark and call it bookmarks.csv header("Content-type: text/csv");
4
2807
by: MLH | last post by:
A programmer developed an AMP (Apache/MySQL/PHP) application for me. When he was done, he sent me the PHP files and the MySQL dump file. Now, when I connect to the application on my LAN using http://192.168.1.106/~mlh/credifree/index.php the AMP app still thinks the data resides somewhere else. It runs fine - as long as I leave my LAN's external internet connection up. But if I unplug my LAN from the world, my app locks up. Before I...
11
3358
by: siliconmike | last post by:
Is there a way to protect data files from access by root ? I have a data-centered website and would like to protect data piracy from any foot-loose hosting company employee. Any ideas? Thanks Mike
3
3442
by: Christian Kienle | last post by:
Hello, at the moment I try to write a little CGI library written in C++. I want offer a PostgreeSQL interface for all the user of my CGI library. Is there any book or a good documentation how I use the C headerfiles Postgree SQL hopefully offers? I know, that Postgree SQL is written with C - so there should be C header files - and perhaps there are C++ header files too.
12
4484
by: Pallas | last post by:
Hi all, I've produced some high-def videos and I want people to be able to watch them on my website, but I may want to prevent downloads and I certainly want to prevent them from editing them. How can I impose such limitations? I have asked Google Video if they will ever permit
3
4841
by: ManWithNoName | last post by:
Hi guys. I’m still occupied with school, however, I can’t quite help thinking about a part of my project that I’m very curious about. I want to protect files and folders on the web server, so that no one can access the files through the web server OS (using e.g. windows explorer to see, open and edit the html or php files). I want to clarify: I do not want to “hide” the html source file, or any other file that otherwise is accessible...
0
1176
by: Shawn Milochik | last post by:
This isn't really a Python question -- it's a Web development question. The easy answer is to just password protect the directory all the pages are stored in, and require a password. This can be set up using Apache or IIS. If what you really meant to ask was how to prevent anyone from accessing certain functionality, then you should look into using sessions, and write the pages you're worried about to require an authenticated session....
0
8671
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
9016
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
8856
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
1
6515
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5858
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4360
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4613
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3037
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
1997
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.