How to download a file only once

Laura Creighton lac at strakt.com
Sun Jan 26 00:00:28 CET 2003


> Hi all,
>  
> My Python application runs on  users' computers.
>  I want to allow  one and only one user to download one file from the list of
>  files that are on 
> server. This file, after being downloaded, can not be downloaded any more.
> What is the best solution of that problem?
> Thanks for help.
> Ladislav

You have 2 problems here.  The first is authenticating that you have
your real trusted user here.  There are lots of ways to do this.
How secure do you need to be?

The second problem is to make sure that he only gets one copy. 
Why do you need this?  Is it for your convenience?  If you put up
a web page, with links to the files, and 'click on this to download'
and then made the links unclickable after every download, would this be 
good enough?  Or do you need a robust solution that will withstand a
hostile attempt to subvert your will?  (I am not sure you can get one.
This is a hard problem.)

More a questions -- by 'one user' do you mean 'there is only one user on
the planet I want to give the file to' or are there lots of them, all
active at the same time, each of which should only get one copy?

What do you want to happen when your user makes a mistake in
downloading?  He ends up with a file in the wrong encoding he cannot
read, or his disk filled up, or he lost his connection in the middle
of the session and so only half the file is there?

Laura Creighton







More information about the Python-list mailing list