带有对象存储存储桶的视频流

发布于 2025-02-10 17:44:07 字数 366 浏览 0 评论 0 原文

我们将视频存储在对象存储(AWS S3/OCI OS)中,并且使用对象URI可以播放HTML视频播放器的视频。但是,如果我们使存储桶作为私有访问权限,则可能使用预验证的URL或使用对象存储SDK API获取视频对象的输入流,请使用 resourceRecergion 使用数据缓冲区流式传输数据。在WebFlux中(我们可以处理所有身份验证内容以访问私有存储桶数据)。

我的查询是否有更好的方法访问私人存储桶视频(内容交付& streaming)?我们可以直接向客户端提供代理URL,而是直接提供视频对象URI,因为我可以处理一些身份验证&在此URL上的授权内容,并将隐藏实际的视频对象URI,以防止视频从任何第三方应用程序下载。

请为此提供建议。

We are storing the videos in object storage (aws s3/oci os) and using object uri's we are able to play the videos from HTML video player. but if we make the bucket access as private then possible ways are use the pre-authenticated urls or use the object storage sdk api to get the input stream for video object, stream the data using data buffers with ResourceRegion in webflux (we can handle all the authentication stuff to access private bucket data).

My query is there any better way to access the private bucket videos (content delivery & streaming)? Can we provide a proxy url instead video object uri directly to client, because I can handle some authentication & authorisation stuff on this url and will hidden the actual video object uri so that we can prevent the video downloading from any third party apps.

Kindly provide suggestions on this.

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

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

发布评论

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

评论(2

枫林﹌晚霞¤ 2025-02-17 17:44:07

是的,有办法。一种方法是让代理服务器路由外部HTTP调用。但这只有有限的功能。另一个选择是通过HTTP端点具有自定义的自定义书面微服务来从私有/公共存储桶中传输数据,并具有其他自定义业务逻辑。

您可以参考此示例Spring Boot微服务代码以从OCI对象存储中流式传输内容。

https> https:// github。 com/oracle-devrel/oci-sdk-java-samples/tree/main/usecases/storage-file-treaming

Yes, there are ways. One way is to have a proxy server route external HTTP calls. But that will have only limited features. Another option is to have custom written microservice to stream data from a private/public bucket via an HTTP endpoint with additional custom business logic.

You may refer to this sample Spring Boot microservice code to stream content from OCI Object Storage.

https://github.com/oracle-devrel/oci-sdk-java-samples/tree/main/usecases/storage-file-streaming

暖伴 2025-02-17 17:44:07

您可以生成从您的S3存储中,创建一个小/简单,并且每当您的应用程序需要一个视频URL时,它都可以将请求发送到服务的新URL,该URL可以在其上有到期时间。
另外,在您的API中,您可以确保只有应用程序才能访问新URL的请求。

但是,如果您只是希望浏览器或客户端是唯一可以访问视频的人,那么这可能很困难。从上面,您可以控制谁可以访问URL,URL活动的时间多长,谁能调用API。第三方必须做很多绕过您的限制

You can generate a new access key and secret from your s3 storage, create a small/simple service/api with node or any language of your choice, and every time your app needs a url for a video, it can send a request to the service for a new url which can have an expiration time on it.
Also, in your api you can ensure only your app can access the request for new url.

However, if you mean you want only your browser or your client's to be the only ones that can access the video then that may be difficult. From the above, you can control who can access the url, how long the url is active and who can call the api. Third parties have to do a lot bypass your restrictions

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文