通过电子邮件发送一个时间链接以下载软件 [英] Emailing one time link to download software

查看:51
本文介绍了通过电子邮件发送一个时间链接以下载软件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一些Beta版的软件,人们可以下载.

我正在跟踪IP地址和日期,因此我对它的下载频率有所了解,但我想跟踪谁.我自己下载了许多程序,您必须在其中填写表格,然后服务器会向您发送指向您提供的电子邮件地址的一次性链接.
我可以填写表格,存储信息并发送电子邮件(php,mysql).没什么大不了的.但是我找不到有关如何进行一次性链接"的信息.这是否意味着每次有人提交表单时,我都必须使用随机名称(例如GUID)将软件复制到新文件夹中?
这将意味着该软件在许多不同的下载文件夹中具有许多副本.好像错了然后设置时间限制,这样一来,他们发送的链接将在一天或2天后不再起作用.这是我在
上遗失的最后两个部分
如何实施?任何建议,将不胜感激.

谢谢. :-)

I have some software that''s in beta that people can download.

I''m tracking IP address and date so I have an idea of how often it''s downloaded but I''d like to track who. I''ve downloaded many programs myself where you have to fill in a form and then the server sends you a one time link to the email address you provided.
I can do the form, store the info and send out an email (php, mysql). That''s not a big deal. But I can''t find info on how to do the "one time link" thing. Does that mean that I have to copy my software into a new folder with a random name (like a GUID) each time someone submits a form ?
That would mean many copies of the software in lots of different download folders. That seems wrong. And then to put a time limit on it as well so the link they are sent no longer works after a day or 2. It''s these last 2 parts I''m lost on

How to implement? Any suggestions would be appreciated.

Thanks. :-)

推荐答案

看看 ^ ] ...它将回答您的问题...

希望这可以帮助! :thumbsup:
Take a look here[^]... it will answer your questions...

Hope this helps! :thumbsup:


这很有帮助.我知道那是怎么回事.但这并没有涵盖任何内容.该代码通过一个包含在查询字符串中的链接发送给用户.然后,当用户单击链接时,将验证该代码.我遵循所有这些. (并且我认为"readfile" http://php.net/manual/zh/function.readfile.php [ ^ ]涵盖了这一部分.下载文件不应仅来自服务器cuz上的任何旧文件夹,否则任何人都可以手动访问它.因此,在该过程的这一部分我不清楚,看来您必须要下载文件保存在带有用户名和密码的受保护的文件夹中.然后,当用户单击其唯一链接时,验证代码还将打开受保护的文件夹,然后开始下载.
That helps. I see how that works. But it doesn''t cover something. The code is sent to the user in a link that has it in a query string. Then that code is validated when the user clicks the link. I follow all that. (and I assume that "readfile" http://php.net/manual/en/function.readfile.php[^] covers that part. But the download should not come from just any old folder on your server cuz then anyone could get to it manually. So I''m not clear on that part of the process. It seems like you''d have to have your file for download in a protected folder with a user name and password. Then when the user clicks their unique link, the validation code would also then open up the protected folder and the download would begin. I''m not sure I''m following what to do there.


您要发送的文件应位于一个文件夹中,存档robots.txt应告知搜索引擎不要编制索引,因此没有明确了解该文件夹的人将无法进行索引进入它.

没有人会知道该文件夹存在,因此无需输入密码或用户名即可进入该文件夹.

此外,用户将使用不会以任何方式表示文件夹名称或文件名的哈希值.因此,这些项目是安全的,因为它们仍然是未知的.
您的担心是正确的,但是我发现即使使用散列来保护网站的某些部分,也无法使用它们来为数据库输入用户名和密码,因此请在最后,您就可以完全依靠robots.txt进入服务器安全了(在这种情况下).

希望这对您有帮助...
The files you are sending should be inside a folder that the archive robots.txt should tell the search engines not to index so no one without express knowledge of that folder would be able to get into it.

No one will know that the folder exists, so no need to put passwords or usernames to get inside that folder.

Moreover the user will use a hash that will not represent in any way the name of the folder neither the file name... So those items are safe as they remain unknown.

Your worry is correct, but I''ve found that even if you use hashes to protect some parts of the web site, you won''t be capable to use them in order to put the username and password for your database so at the end you finish relying on the robots.txt and into the safety of your server (like in this case).

Hope this helps...


这篇关于通过电子邮件发送一个时间链接以下载软件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆