Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I've occasionally had occasion when I needed to share some as-yet "private" data (i.e. unedited drafts of audio lectures) so it can be reviewed by authorized people before being made public. Typically I do this by giving the file an obscure name (i.e. a newly generated GUID) and emailing or IMing the link to the person. Of course there is no link to the file from other pages on the site. Is this actually safe or is there some vulnerability I'm overlooking? Not that there are any nuclear secrets being passed this way, but I still want to make sure I'm not missing something.

share|improve this question

4 Answers 4

If the information you're sharing isn't secret, as such, just "not really for public consumption", and especially if it's temporary, I don't see that there's a huge risk here. The one thing to be careful of is to make sure that there's no way that a directory index could lead a spider or human to the file.

For instance, if you store the file in /foo/bar/baz/wombat/GUID.pdf, if accessing /foo gives a dirindex that links to /foo/bar, and /foo/bar gives a dirindex that links to /foo/bar/baz, and so on... well, it's a lot easier for someone to be playing around and get /foo then follow the links than it is to have to guess all of those directory components.

A .htaccess file turning off DirIndex in the directory that the files are in should do the trick (or put an index.html in there saying "Go Away").

share|improve this answer
    
No, there is no directory index –  JoelFan Nov 30 '09 at 21:38

Security through obscurity really offers no security at all.

I cannot stress this heavily enough, if you don't want documents to be public -- do not make them publicly accessible. End of story.

Keep in mind, it only takes one single person to link to the page somewhere on the Internet for google to crawl the page, subsequently caching the page leaving the content available to everyone (and now searchable in google), even after you delete the page...

share|improve this answer

In the academic world, where attackers are constantly trying to listen to conversations between Alice and Bob, this is not safe for a myriad of reasons that others will list.

In the real world it is a combined probability:

  • how much you trust the other peers (the probability of them posting the link somewhere, or IM'ing to their friends, etc)
  • how much you trust your ISP (is it going to make backups, keeping them for years and does its employees have unrestricted access to those?) --consider encryption here
  • what is the value of the document is loss
  • how a leakage might affect your career|position|etc and the one of others

Don't forget that a leaked document might stay around forever. Do you want such things to come to bite you in the back in 10 years? In 20?

share|improve this answer

This is NOT SAFE since the URLs will be going over the wire in plain text. An attacker can use a tool like Ethereal to sniff the URLs and then visit them himself. Maybe add an htaccess/htpasswd to a "Secure Area" or equivalent if not using Apache?

share|improve this answer
    
What about just using https without htaccess? Then the URLs are not going over the wire in plain text. –  JoelFan Nov 30 '09 at 3:45
    
If the data being transferred is security-critical this might be a concern -- but, given the content that the OP mentioned (drafts of audio lectures), this is probably not a big deal. –  duskwuff Nov 30 '09 at 4:57
    
Ethereal was renamed to/superseded by Wireshark over three years ago –  Dennis Williamson Nov 30 '09 at 5:57
1  
So, to prevent an attacker from sniffing URLs and visiting them, you propose to password-protect the files with a password that is send in the clear alongside the URL of interest. Bravo. –  womble Nov 30 '09 at 6:34

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.