Jump to content

Setting file permissions for SECURE download


gcreddy

Recommended Posts

Hello....I am a novice and have been developing a secure file transfer system in php....I want to enable ONLY my clients to be able to download their files......for example....in my code....if I write the following line

 

<a href="/images/image1.jpg">Download here</a>

 

My client should be able to download that file.....however.....if someone types "http://www.domainname.com/Folder1/images/image1.jpg" and pastes it into their browser....the access should be denied....

 

Infact....if some one types "http://www.domainname.com/Folder1/" the contents of the folder also shouldn't be displayed....

 

Can someone tell me how I should change the permissions (right now all the permissions are set to 0755 i.e. rwxr-xr-x) on my server and the changes (if any) that should be done to my code to enable this feature??

 

Regards,

G.C.Reddy

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.