如何通过 Amazon Cloudfront 控制下载数量

发布于 2024-12-04 13:12:02 字数 290 浏览 1 评论 0原文

有没有办法创建一个 CloudFront 签名 URL 来限制文件下载的次数?

根据这篇文章Controlling number of downloads on Amazon S3,您可以通过cloudfront api获取文件下载的数量(但在亚马逊网站上找不到任何对此的引用)

有人设法通过CloudFront实现这一目标吗?

Is there a way to create a CloudFront signed url that limits the number of times that a file can be downloaded?

According to this post Controlling number of downloads on Amazon S3, you can get the number of file downloads via the cloudfront api (but it cant find any reference to this on the amazon site)

Has anyone managed to achieve this via CloudFront?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

假装爱人 2024-12-11 13:12:02

是的,通过 CloudFront,您可以提供私有内容

基本上,您可以通过两种方式保护您的内容:

  • 要求您的用户使用特殊的 CloudFront 签名 URL 来访问您的内容,而不是标准的 CloudFront 公共 URL。

  • 要求您的用户使用 CloudFront URL(而不是 Amazon S3 URL)访问您的 Amazon S3 内容。

当您为对象创建签名 URL 时,您可以指定:

  • 结束日期和时间,在此之后 URL 将不再有效。
  • (可选)URL 生效的日期和时间。
  • (可选)可用于访问您的内容的计算机的 IP 地址或地址范围。

Yes, with CloudFront you can serve Private Content.

Basically you can protect your content in two ways:

  • Require that your users use special CloudFront signed URLs to access your content, not the standard CloudFront public URLs.

  • Require that your users access your Amazon S3 content using CloudFront URLs, not Amazon S3 URLs.

When you create signed URLs for your objects, you can specify:

  • An ending date and time, after which the URL is no longer valid.
  • (Optional) The date and time that the URL becomes valid.
  • (Optional) The IP address or range of addresses of the computers that can be used to access your content.
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文