Hi Roberto,
One solution is to provide a temporary identifyer via cookie, which gets
set if the user sees your page but is not set if she wants to
download it directly. A simple non guessable scrable mechanism
using your page url, file url and probably ip of the downloader
should do for the cookie
One way to do this is to peek at the HTTP_REFERER value coming from the
browser before you serve the document. If the document is in a file object,
then you can use a precondition for this, which is a callable object.
It could be written as follows in a python script:
request = context.REQUEST