Auto generated email and restrict user to access only specific link or file.
In my application, we have huge file download option so if download takes more time then we are planning to give a alert message stating that "Your download request is still being processed and will receive an email notification with a link to download the file as soon your request is processed".
Now, we need to send auto generated email to user with the link to download,
for example : https://abc.com/downloads/xyz.xls. And we should restrict users from accessing or hacking other directories or files with in or outside the provided link i.e. trying to get list of files inside downloads directory https://abc.com/downloads or trying to access other files inside downloads directory https://abc.com/downloads/abc.xls.
I am using jdk1.4, WSAD 6.0.
Please let me know what would be the better approach for sending auto generated email and restricting users to access only to specific file and if any examples.